MacOSX --with-adobe link issue. Work in progress. Code and documentation update.

v0.27.3
Robin Mills 8 years ago
parent 134df403e8
commit aefa3e3d34

@ -50,7 +50,7 @@
######################################################################## ########################################################################
SHELL = /bin/sh SHELL = /bin/sh
ENABLE_XMP = 1 ENABLE_XMP = 2016
.PHONY: all doc config samples xmpsdk \ .PHONY: all doc config samples xmpsdk \
mostlyclean clean distclean maintainer-clean \ mostlyclean clean distclean maintainer-clean \
@ -146,7 +146,6 @@ mostlyclean clean: config/config.mk
cd config && $(MAKE) -f config.make $(MAKECMDGOALS) cd config && $(MAKE) -f config.make $(MAKECMDGOALS)
cd po && $(MAKE) $(MAKECMDGOALS) cd po && $(MAKE) $(MAKECMDGOALS)
rm -f include/exiv2/exv_conf.h rm -f include/exiv2/exv_conf.h
if [ -e xmpsdk/Adobe ]; then rm -rf xmpsdk/Adobe ; fi
# `make distclean' also removes files created by configuring # `make distclean' also removes files created by configuring
@ -156,6 +155,7 @@ distclean: clean
rm -f config.log config.status libtool rm -f config.log config.status libtool
rm -f *~ *.bak rm -f *~ *.bak
if [ -e bin ]; then rm -rf bin ; fi if [ -e bin ]; then rm -rf bin ; fi
if [ -e xmpsdk/Adobe ]; then rm -rf xmpsdk/Adobe ; fi
# This removes almost everything, including the configure script! # This removes almost everything, including the configure script!
maintainer-clean: distclean maintainer-clean: distclean

@ -0,0 +1,173 @@
Puzzle with autotools/--with-adobe MacOS-X Only
-----------------------------------------------
Added : 2017-08-17
Modified: 2017-08-18
The --with-adobe code is new (added on Monday/Tuesday 2017-08-15).
It's very much "Work in Progress" and will get lots more polishing.
This builds and links on Mac and Linux (Cygwin isn't ready yet).
Autotools isn't used with Visual Studio
Default build (which compile/links xmpsdk/src) is fine (and passes test suite)
$ sudo make distclean ; make config ; ./configure ; make ; sudo make install ; make samples ; make tests
Status: The 2016/AdobeXMPsdk requires an entry point that's not in the C++ STL library
./configure is building and passing the test suite
./configure --with-adobe=2014 is broken on __ZNSs4_Rep11_S_terminalE
./configure --with-adobe=2016 is broken on __ZNSiD0Ev
The missing entry points are in /usr/lib/libstdc++.6.dylib
When I use install_name_tool to change to libstdc++.6.dylib, I crash in this:
$ c++filt __ZNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED1Ev
std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >::~basic_string()
$
There's something mixed up concerning the libraries used by Adobe's XMPSDK and libexiv2.26.dylib
-stdlib=libstdc++ will link /usr/lib/libstdc++.6.dylib, however the compiler warns:
clang: warning: libstdc++ is deprecated; move to libc++ [-Wdeprecated]
To build without the external Adobe SDK:
- - - - - - - - - - - - - - - - - - - -
Edit config/config.mk.in and modify:
XMPSDK_LIBS= -lXMPCore
to
XMPSDK_LIBS = ''
$ sudo make distclean ; make config ; ./configure --with-adobe ; make
The following command works:
$ bin/exiv2 http://clanmills.com/Stonehenge.jpg is working
On 2017-08-15 The following command crashes when it attempts to execute XMPsdk code
$ bin/exiv2 --verbose --version
........
config_path=/Users/rmills/.exiv2
uid=501
euid=501
gid=20
dyld: lazy symbol binding failed: Symbol not found: _WXMPMeta_Initialize_1
Referenced from: /Users/rmills/gnu/github/exiv2/src/.libs/libexiv2.26.dylib
Expected in: flat namespace
dyld: Symbol not found: _WXMPMeta_Initialize_1
Referenced from: /Users/rmills/gnu/github/exiv2/src/.libs/libexiv2.26.dylib
Expected in: flat namespace
Abort trap: 6
$
This is correct. libXMPCore.a is not in the mix.
ls -alt src/.libs/libexiv2.26.dylib
-rwxr-xr-x+ 1 rmills staff 2238124 Aug 17 11:07 src/.libs/libexiv2.26.dylib
-------
To add the external Adobe SDK to the mix:
- - - - - - - - - - - - - - - - - - - - -
Edit src/Makefile#242 and change:
@$(LIBTOOL) --mode=link $(LINK.cc) -o ../bin/$@ $(LIBRARY) $(EXIV2OBJ) $(EXIV2COBJ) -rpath $(libdir)
to:
@$(LIBTOOL) --mode=link $(LINK.cc) -lXMPCore -o ../bin/$@ $(LIBRARY) $(EXIV2OBJ) $(EXIV2COBJ) -rpath $(libdir)
$ touch src/version.cpp src/exiv2.cpp ; make
$ ls -alt src/.libs/libexiv2.26.dylib
-rwxr-xr-x+ 1 rmills staff 4312308 Aug 17 11:17 src/.libs/libexiv2.26.dylib
-------
$ bin/exiv2
dyld: Symbol not found: __ZNSiD0Ev
Referenced from: /Users/rmills/gnu/github/exiv2/src/.libs/libexiv2.26.dylib
Expected in: flat namespace
in /Users/rmills/gnu/github/exiv2/src/.libs/libexiv2.26.dylib
Abort trap: 6
605 rmills@rmillsmbp:~/gnu/github/exiv2 $
$ c++filt _ZNSiD0Ev
std::basic_istream<char, std::char_traits<char> >::~basic_istream()
This code is being accessed by Adobe XMPSDK 2016 libXMPCore.a and isn't in the c++ library.
$ nm -g xmpsdk/Adobe/libXMPCore.a | grep _ZNSiD0Ev
U __ZNSiD0Ev
$
Adobe XMPSDK 2014 has a similar problem with __ZNSs4_Rep11_S_terminalE
$ nm -g Adobe/XMP-Toolkit-SDK-CC201412/libXMPCore.a | grep __ZNSs4_Rep11_S_terminalE | sort --unique
U __ZNSs4_Rep11_S_terminalE
$ c++filt __ZNSs4_Rep11_S_terminalE
std::string::_Rep::_S_terminal
Notes (mostly to remind me of painful discoveries)
--------------------------------------------------
How does the build get generated?
$ make config
This generates ./configure by reading config/configure.ac
When you use --with-adobe, CXXFLAGS and LDFLAGS are modified and ENABLE_XMP is set to 2016.
Makefile has code to execute the script xmpsdk/buildXMPsdk.sh which
downloads and builds the XMPsdk to create libCore.a (which we need) and libFiles.a
config/config.mk.in is converted into config/config.mk and included in xmpsdk/src/Makefile
This is really ugly. config.mk also messes with CPPFLAGS and LDFLAGS
To get -lXMPCore into the mix, set XMPSDK_LIBS in config/config.mk.in
XMPSDK_LIBS = -lXMPCore
508 rmills@rmillsmbp:~/gnu/github/exiv2 $ finder Makefile | xargs grep -H config.mk | grep include
./contrib/organize/Makefile:include $(top_srcdir)/config/config.mk
./doc/Makefile:include $(top_srcdir)/config/config.mk
./samples/Makefile:include $(top_srcdir)/config/config.mk
./src/Makefile:include $(top_srcdir)/config/config.mk
./xmpsdk/src/Makefile:include $(top_srcdir)/config/config.mk
509 rmills@rmillsmbp:~/gnu/github/exiv2 $
Compiler options used to build Adobe XMPsdk
-------------------------------------------
For sure, Adobe's code is being built with MacOSX10.8.sdk and -std=c++11
/usr/bin/c++
-DBUILDING_XMPCORE_AS_STATIC=1
-DBUILDING_XMPCORE_LIB=1
-DENABLE_CPP_DOM_MODEL=1
-DHAVE_EXPAT_CONFIG_H=1
-DMAC_ENV=1
-DXML_STATIC=1
-DXMP_64=1
-DXMP_COMPONENT_INT_NAMESPACE=AdobeXMPCore_Int
-DXMP_StaticBuild=1
-I/Users/rmills/gnu/github/exiv2/xmpsdk/Adobe/XMP-Toolkit-SDK-CC201607/XMPCore/build/../..
-I/Users/rmills/gnu/github/exiv2/xmpsdk/Adobe/XMP-Toolkit-SDK-CC201607/XMPCore/build/../../public/include
-I/Users/rmills/gnu/github/exiv2/xmpsdk/Adobe/XMP-Toolkit-SDK-CC201607/XMPCore/build/../../third-party/expat/public/lib
-I/Users/rmills/gnu/github/exiv2/xmpsdk/Adobe/XMP-Toolkit-SDK-CC201607/XMPCore/build/../resource/mac
-funsigned-char
-fshort-enums
-fno-common
-Wall
-Wextra
-Wno-missing-field-initializers
-Wno-shadow
-Wno-reorder
-std=c++11
-Wnon-virtual-dtor
-Woverloaded-virtual
-Wno-unused-variable
-Wno-unused-function
-Wno-unused-parameter
-fstack-protector
-O3
-DNDEBUG=1
-D_NDEBUG=1
-arch x86_64
-isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk
-mmacosx-version-min=10.7
-o CMakeFiles/XMPCoreStatic.dir/Users/rmills/gnu/github/exiv2/xmpsdk/Adobe/XMP-Toolkit-SDK-CC201607/XMPCore/source/XMPMeta-GetSet.cpp.o
-c /Users/rmills/gnu/github/exiv2/xmpsdk/Adobe/XMP-Toolkit-SDK-CC201607/XMPCore/source/XMPMeta-GetSet.cpp

@ -1,116 +0,0 @@
2017-08-17
Puzzle with autotools/--with-adobe (solved: seems to confined to my Mac Book Pro).
-----------------------------------------------------------------------------------
The --with-adobe code is new (added on Monday/Tuesday 2017-08-15).
It's very much "Work in Progress" and will get lots more polishing.
This builds and links on Mac and Linux (Cygwin isn't ready yet).
Autotools isn't used with Visual Studio
Default build (which compile/links xmpsdk/src) is fine (and passes test suite)
$ sudo make distclean ; make config ; ./configure ; make ; sudo make install ; make samples ; make tests
To build with the external Adobe SDK:
$ sudo make distclean ; make config ; ./configure --with-adobe ; make
Linux --with-adobe is working when I remove calls to DeleteNamespace in src/xmp.cpp.
The test suite is mostly OK. Some XMP output format has changed.
There are some test crashes to be investigated.
So, this issue only concerns linking on the Mac.
The following command works:
$ bin/exiv2 http://clanmills.com/Stonehenge.jpg is working
The following command crashes when it attempts to execute XMPsdk code
$ bin/exiv2 --verbose --version
........
config_path=/Users/rmills/.exiv2
uid=501
euid=501
gid=20
dyld: lazy symbol binding failed: Symbol not found: _WXMPMeta_Initialize_1
Referenced from: /Users/rmills/gnu/github/exiv2/src/.libs/libexiv2.26.dylib
Expected in: flat namespace
dyld: Symbol not found: _WXMPMeta_Initialize_1
Referenced from: /Users/rmills/gnu/github/exiv2/src/.libs/libexiv2.26.dylib
Expected in: flat namespace
Abort trap: 6
$
This is correct. libXMPCore.a is not in the mix.
ls -alt src/.libs/libexiv2.26.dylib
-rwxr-xr-x+ 1 rmills staff 2238124 Aug 17 11:07 src/.libs/libexiv2.26.dylib
-------
Edit src/Makefile#242 and change:
@$(LIBTOOL) --mode=link $(LINK.cc) -o ../bin/$@ $(LIBRARY) $(EXIV2OBJ) $(EXIV2COBJ) -rpath $(libdir)
to:
@$(LIBTOOL) --mode=link $(LINK.cc) -lXMPCore -o ../bin/$@ $(LIBRARY) $(EXIV2OBJ) $(EXIV2COBJ) -rpath $(libdir)
$ touch src/version.cpp src/exiv2.cpp ; make
$ ls -alt src/.libs/libexiv2.26.dylib
-rwxr-xr-x+ 1 rmills staff 4312308 Aug 17 11:17 src/.libs/libexiv2.26.dylib
-------
$ bin/exiv2
dyld: Symbol not found: __ZNSiD0Ev
Referenced from: /Users/rmills/gnu/github/exiv2/src/.libs/libexiv2.26.dylib
Expected in: flat namespace
in /Users/rmills/gnu/github/exiv2/src/.libs/libexiv2.26.dylib
Abort trap: 6
605 rmills@rmillsmbp:~/gnu/github/exiv2 $
$ c++filt _ZNSiD0Ev
std::basic_istream<char, std::char_traits<char> >::~basic_istream()
It appears that libexiv2.26.dylib isn't linked to the STL libraries.
However I think problem may be with the "flat namespace" which tells the
dynamic linker to search for library names. The search order is:
$ otool -L bin/.libs/exiv2
bin/.libs/exiv2:
/usr/local/lib/libexiv2.26.dylib (compatibility version 26.0.0, current version 26.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1238.60.2)
/usr/local/lib/libintl.8.dylib (compatibility version 10.0.0, current version 10.2.0)
/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
/usr/local/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.11)
/usr/local/lib/libexpat.1.dylib (compatibility version 8.0.0, current version 8.0.0)
/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 307.5.0)
So, when he's loading libexiv2.26.dylib, he needs a symbol from libc++.1.dylib
Amazingly, I got it to work on Wednesday morning.
I must have been confused. Something was working!
Notes (mostly to remind of painful discoveries)
-----------------------------------------------
How does the build get generated?
$ make config
This generates ./configure by reading config/configure.ac
When you use --with-adobe, CXXFLAGS and LDFLAGS are modified and ENABLE_XMP is set to 2016.
Makefile has code to execute the script xmpsdk/buildXMPsdk.sh which
downloads and builds the XMPsdk to create libCore.a (which we need) and libFiles.a
config/config.mk.in is converted into config/config.mk and included in xmpsdk/src/Makefile
This is really ugly. config.mk also messes with CPPFLAGS and LDFLAGS
To get -lXMPCore into the mix, set XMPSDK_LIBS in config/config.mk.in
XMPSDK_LIBS = -lXMPCore
508 rmills@rmillsmbp:~/gnu/github/exiv2 $ finder Makefile | xargs grep -H config.mk | grep include
./contrib/organize/Makefile:include $(top_srcdir)/config/config.mk
./doc/Makefile:include $(top_srcdir)/config/config.mk
./samples/Makefile:include $(top_srcdir)/config/config.mk
./src/Makefile:include $(top_srcdir)/config/config.mk
./xmpsdk/src/Makefile:include $(top_srcdir)/config/config.mk
509 rmills@rmillsmbp:~/gnu/github/exiv2 $

@ -146,7 +146,6 @@ mostlyclean clean: config/config.mk
cd config && $(MAKE) -f config.make $(MAKECMDGOALS) cd config && $(MAKE) -f config.make $(MAKECMDGOALS)
cd po && $(MAKE) $(MAKECMDGOALS) cd po && $(MAKE) $(MAKECMDGOALS)
rm -f include/exiv2/exv_conf.h rm -f include/exiv2/exv_conf.h
if [ -e xmpsdk/Adobe ]; then rm -rf xmpsdk/Adobe ; fi
# `make distclean' also removes files created by configuring # `make distclean' also removes files created by configuring
@ -156,6 +155,7 @@ distclean: clean
rm -f config.log config.status libtool rm -f config.log config.status libtool
rm -f *~ *.bak rm -f *~ *.bak
if [ -e bin ]; then rm -rf bin ; fi if [ -e bin ]; then rm -rf bin ; fi
if [ -e xmpsdk/Adobe ]; then rm -rf xmpsdk/Adobe ; fi
# This removes almost everything, including the configure script! # This removes almost everything, including the configure script!
maintainer-clean: distclean maintainer-clean: distclean

@ -107,7 +107,7 @@ ifeq ($(ENABLE_XMP),2016)
XMPSDK_CPPFLAGS = -I$(XMPSDK_DIR)/Adobe/XMP-Toolkit-SDK-CC201607 \ XMPSDK_CPPFLAGS = -I$(XMPSDK_DIR)/Adobe/XMP-Toolkit-SDK-CC201607 \
-I$(XMPSDK_DIR)/Adobe/XMP-Toolkit-SDK-CC201607/public/include \ -I$(XMPSDK_DIR)/Adobe/XMP-Toolkit-SDK-CC201607/public/include \
-DEXV_ADOBE_XMPSDK=2016 -DEXV_ADOBE_XMPSDK=2016
XMPSDK_LDFLAGS = -L$(XMPSDK_DIR)/Adobe/ XMPSDK_LDFLAGS = -L$(XMPSDK_DIR)/Adobe/XMP-Toolkit-SDK-CC201607
XMPSDK_LIBS = -lXMPCore XMPSDK_LIBS = -lXMPCore
CPPFLAGS_MORE = X CPPFLAGS_MORE = X
endif endif
@ -118,7 +118,7 @@ ifeq ($(ENABLE_XMP),2014)
XMPSDK_CPPFLAGS = -I$(XMPSDK_DIR)/Adobe/XMP-Toolkit-SDK-CC201412 \ XMPSDK_CPPFLAGS = -I$(XMPSDK_DIR)/Adobe/XMP-Toolkit-SDK-CC201412 \
-I$(XMPSDK_DIR)/Adobe/XMP-Toolkit-SDK-CC201412/public/include \ -I$(XMPSDK_DIR)/Adobe/XMP-Toolkit-SDK-CC201412/public/include \
-DEXV_ADOBE_XMPSDK=2014 -DEXV_ADOBE_XMPSDK=2014
XMPSDK_LDFLAGS = -L$(XMPSDK_DIR)/Adobe/ XMPSDK_LDFLAGS = -L$(XMPSDK_DIR)/Adobe/XMP-Toolkit-SDK-CC201412
XMPSDK_LIBS = -lXMPCore XMPSDK_LIBS = -lXMPCore
CPPFLAGS_MORE = X CPPFLAGS_MORE = X
endif endif

@ -394,12 +394,11 @@ if test "$ADOBE" == "yes"; then ADOBE=2016; fi
if test "$ADOBE" = "2016" -o "$ADOBE" = "2014" ; then if test "$ADOBE" = "2016" -o "$ADOBE" = "2014" ; then
ADOBE_SDK=XMP-Toolkit-SDK-CC201607 ADOBE_SDK=XMP-Toolkit-SDK-CC201607
if test "$ADOBE" == "2014" ; then ADOBE_SDK=XMP-Toolkit-SDK-CC2014.12; fi if test "$ADOBE" == "2014" ; then ADOBE_SDK=XMP-Toolkit-SDK-CC201412; fi
ENABLE_XMP=$ADOBE ENABLE_XMP=$ADOBE
XMPSDK_CPPFLAGS='-Ixmpsdk/Adobe/$ADOBE_SDK/public/include' XMPSDK_CPPFLAGS="-Ixmpsdk/Adobe/$ADOBE_SDK/public/include"
XMPSDK_LDFLAGS='-Lxmpsdk/Adobe/' XMPSDK_LDFLAGS="-Lxmpsdk/Adobe/$ADOBE_SDK"
XMPSDK_LIBS='' # XMPSDK_LIBS='-lXMPCore'
# '-lXMPCore.a -lXMPFiles.a'
fi fi
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
@ -457,7 +456,7 @@ yes) echo "-- Nikon lens database............ YES" ;;
esac esac
case "$USE_XMP_TOOLKIT" in case "$USE_XMP_TOOLKIT" in
yes) echo "-- XMP metadata support........... YES (ADOBE_SDK = $ADOBE)" ;; yes) echo "-- XMP metadata support........... YES" ;;
*) echo "-- XMP metadata support........... NO" *) echo "-- XMP metadata support........... NO"
echo "" echo ""
echo "Expat is required for XMP support. Make sure the Expat header" echo "Expat is required for XMP support. Make sure the Expat header"
@ -505,7 +504,6 @@ fi
echo "CPPFLAGS =" "$CPPFLAGS $SSH_CPPFLAGS $CURL_CPPFLAGS $XMPSDK_CPPFLAGS" echo "CPPFLAGS =" "$CPPFLAGS $SSH_CPPFLAGS $CURL_CPPFLAGS $XMPSDK_CPPFLAGS"
echo "LDFLAGS =" "$LDFLAGS $SSH_LDFLAGS $CURL_LDFLAGS $EXPAT_LDFLAGS $XMPSDK_LDFLAGS" echo "LDFLAGS =" "$LDFLAGS $SSH_LDFLAGS $CURL_LDFLAGS $EXPAT_LDFLAGS $XMPSDK_LDFLAGS"
echo "LIBS =" "$LIBS $SSH_LIBS $CURL_LIBS $EXPAT_LIBS $XMPSDK_LIBS" echo "LIBS =" "$LIBS $SSH_LIBS $CURL_LIBS $EXPAT_LIBS $XMPSDK_LIBS"
echo "ENABLE_XMP =" "$ENABLE_XMP"
echo "CXX =" "$CXX" echo "CXX =" "$CXX"
echo "------------------------------------------------------------------" echo "------------------------------------------------------------------"
echo "" echo ""

@ -312,6 +312,7 @@ void Exiv2::dumpLibraryInfo(std::ostream& os,const exv_grep_keys_t& keys)
int have_sys_mman =0; int have_sys_mman =0;
int have_libz =0; int have_libz =0;
int have_xmptoolkit =0; int have_xmptoolkit =0;
int adobe_xmpsdk =0;
int have_bool =0; int have_bool =0;
int have_strings =0; int have_strings =0;
int have_sys_types =0; int have_sys_types =0;
@ -429,6 +430,10 @@ void Exiv2::dumpLibraryInfo(std::ostream& os,const exv_grep_keys_t& keys)
have_xmptoolkit=1; have_xmptoolkit=1;
#endif #endif
#ifdef EXV_ADOBE_XMPSDK
adobe_xmpsdk=EXV_ADOBE_XMPSDK;
#endif
#ifdef EXV_HAVE_BOOL #ifdef EXV_HAVE_BOOL
have_bool=1; have_bool=1;
#endif #endif
@ -559,6 +564,7 @@ void Exiv2::dumpLibraryInfo(std::ostream& os,const exv_grep_keys_t& keys)
output(os,keys,"have_sys_mman" ,have_sys_mman ); output(os,keys,"have_sys_mman" ,have_sys_mman );
output(os,keys,"have_libz" ,have_libz ); output(os,keys,"have_libz" ,have_libz );
output(os,keys,"have_xmptoolkit" ,have_xmptoolkit ); output(os,keys,"have_xmptoolkit" ,have_xmptoolkit );
output(os,keys,"adobe_xmpsdk" ,adobe_xmpsdk );
output(os,keys,"have_bool" ,have_bool ); output(os,keys,"have_bool" ,have_bool );
output(os,keys,"have_strings" ,have_strings ); output(os,keys,"have_strings" ,have_strings );
output(os,keys,"have_sys_types" ,have_sys_types ); output(os,keys,"have_sys_types" ,have_sys_types );

@ -544,7 +544,7 @@ namespace Exiv2 {
#endif #endif
} }
catch (const XMP_Error& e) { catch (const XMP_Error& e) {
throw Error(40, e.GetID(), e.GetErrMsg()); // throw Error(40, e.GetID(), e.GetErrMsg());
} }
} // XmpParser::registerNs } // XmpParser::registerNs
#else #else

@ -25,6 +25,9 @@ if [ "$1" == "2014" ]; then
SDK=XMP-Toolkit-SDK-CC201412 SDK=XMP-Toolkit-SDK-CC201412
fi fi
# if it's already built, we're done
if [ -e Adobe/$SDK/libXMPCore.a ]; then exit 0 ; fi
## ##
# Download the code from Adobe # Download the code from Adobe
if [ ! -e Adobe/$SDK ]; then ( if [ ! -e Adobe/$SDK ]; then (
@ -105,21 +108,19 @@ if [ -z "$result" ]; then (
# report archives we can see # report archives we can see
cd Adobe/$SDK cd Adobe/$SDK
rm -rf *.a *.ar
find public -name "*.a" -o -name "*.ar" | xargs ls -alt find public -name "*.a" -o -name "*.ar" | xargs ls -alt
cd ../
# move the library/archives into xmpsdk # move the library/archives into xmpsdk
case "$uname" in case "$uname" in
Linux) Linux)
rm -rf *.a *.ar find public -name "*.ar" -exec cp {} . ';'
find $SDK/public -name "*.ar" -exec cp {} . ';'
mv staticXMPCore.ar libXMPCore.a mv staticXMPCore.ar libXMPCore.a
mv staticXMPFiles.ar libXMPFiles.a mv staticXMPFiles.ar libXMPFiles.a
;; ;;
Darwin) Darwin)
rm -rf *.a *.ar find public -name "*.a" -exec cp {} . ';'
find $SDK/public -name "*.a" -exec cp {} . ';'
mv libXMPCoreStatic.a libXMPCore.a mv libXMPCoreStatic.a libXMPCore.a
mv libXMPFilesStatic.a libXMPFiles.a mv libXMPFilesStatic.a libXMPFiles.a
;; ;;

Loading…
Cancel
Save