diff options
author | Timo Gurr <timo.gurr@gmail.com> | 2016-10-26 16:47:24 +0200 |
---|---|---|
committer | Timo Gurr <timo.gurr@gmail.com> | 2016-10-26 16:47:24 +0200 |
commit | 12b6f6ccc3586f85fbc22b5b2f02c2b4d585afef (patch) | |
tree | 57563e73610e1daeaf53d98b45d6cccfe9e85284 | |
parent | 9a7fc35b4c4a9db124d9659e8b34b695e68af100 (diff) |
libdvd/Makefile: cross-compile, allow to specify the ar command
Allow specifying the AR variable to fix build in cross environments
that have the ar command prefixed with e.g. the host triplet, like
x86_64-pc-linux-gnu-ar.
-rw-r--r-- | lib/libdvd/Makefile.in | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/lib/libdvd/Makefile.in b/lib/libdvd/Makefile.in index 00827cf2d6..5a4508bfff 100644 --- a/lib/libdvd/Makefile.in +++ b/lib/libdvd/Makefile.in @@ -1,4 +1,5 @@ +AR=@AR@ ARCH=@ARCH@ CC=@CC@ CXX=@CXX@ @@ -54,7 +55,7 @@ ifeq ($(findstring osx,$(ARCH)), osx) $(SYSDIR)/libdvdcss-$(ARCH).so: $(WRAPPER) $(DVDREAD_DEPS) [ -d libdvdcss ] || mkdir libdvdcss - cd libdvdcss; ar x $(DVDCSS_A) + cd libdvdcss; $(AR) x $(DVDCSS_A) $(CC) $(SO_LDFLAGS) -Wl,-alias_list,$(WRAPPER_MACH_ALIAS) -o $@ \ $(WRAPPER) $(DVDCSS_OBJS) $(BUNDLE1_O) @@ -62,16 +63,16 @@ $(SYSDIR)/libdvdnav-$(ARCH).so: $(WRAPPER) $(DVDNAV_A) $(DVDREAD_A) $(DVDREAD_DE [ -d libdvdread ] || mkdir libdvdread [ -d libdvdnav ] || mkdir libdvdnav [ $(BUILD_DVDCSS) -eq 1 ] && { [ -d libdvdcss ] || mkdir libdvdcss; } || : - [ $(BUILD_DVDCSS) -eq 1 ] && { cd libdvdcss && ar x $(DVDCSS_A); } || : - cd libdvdnav; ar x $(DVDNAV_A) - cd libdvdread; ar x $(DVDREAD_A) + [ $(BUILD_DVDCSS) -eq 1 ] && { cd libdvdcss && $(AR) x $(DVDCSS_A); } || : + cd libdvdnav; $(AR) x $(DVDNAV_A) + cd libdvdread; $(AR) x $(DVDREAD_A) $(CC) $(SO_LDFLAGS) -Wl,-alias_list,$(WRAPPER_MACH_ALIAS) -o $@ \ $(WRAPPER) libdvdread/*.o libdvdnav/*.o $(DVDCSS_OBJS) $(BUNDLE1_O) else $(SYSDIR)/libdvdcss-$(ARCH).so: $(WRAPPER) $(WRAPPER_DEF) $(DVDCSS_A) [ -d libdvdcss ] || mkdir libdvdcss - cd libdvdcss; ar x $(DVDCSS_A) + cd libdvdcss; $(AR) x $(DVDCSS_A) $(CC) -o $@ $(SO_LDFLAGS) -Wl,--soname,$@ $(DVDCSS_OBJS) -Wl,--unresolved-symbols=ignore-all -lm \ `cat $(WRAPPER_DEF)` $(WRAPPER) @@ -79,9 +80,9 @@ $(SYSDIR)/libdvdnav-$(ARCH).so: $(WRAPPER) $(WRAPPER_DEF) $(DVDNAV_A) $(DVDREAD_ [ -d libdvdread ] || mkdir libdvdread [ -d libdvdnav ] || mkdir libdvdnav [ $(BUILD_DVDCSS) -eq 1 ] && { [ -d libdvdcss ] || mkdir libdvdcss; } || : - [ $(BUILD_DVDCSS) -eq 1 ] && { cd libdvdcss && ar x $(DVDCSS_A); } || : - cd libdvdnav; ar x $(DVDNAV_A) - cd libdvdread; ar x $(DVDREAD_A) + [ $(BUILD_DVDCSS) -eq 1 ] && { cd libdvdcss && $(AR) x $(DVDCSS_A); } || : + cd libdvdnav; $(AR) x $(DVDNAV_A) + cd libdvdread; $(AR) x $(DVDREAD_A) $(CC) -o $@ $(SO_LDFLAGS) -Wl,--soname,$@ libdvdread/*.o libdvdnav/*.o $(DVDCSS_OBJS) -lm -Wl,--unresolved-symbols=ignore-all \ `cat $(WRAPPER_DEF)` $(WRAPPER) endif |