Open springmeyer opened 10 years ago
Current master is unbuilt if crosscompiling on mac due to -stdlib=libc++ option:
[2013-09-26 20:29:21] >$ ./scripts/build_mapnik_mobile.sh
Building mapnik minimal ios
ERROR:root:code for hash sha224 was not found.
Traceback (most recent call last):
File "/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/platform/lib/python2.7/hashlib.py", line 139, in
Welcome to Mapnik...
Configuring build environment... SCons CONFIG found: 'config.py', variables will be inherited... Configuring on Darwin in release mode... Checking for freetype-config... yes Checking for xml2-config... yes Searching for boost libs and headers... (cached) Found boost libs: /Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/lib Found boost headers: /Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include Checking for pkg-config... no Not building with cairo support, pass CAIRO=True to enable
All Required dependencies found!
Overwriting and re-saving file 'config.py'... Will hold custom path variables from commandline and python config file(s)...
Note: will build without these OPTIONAL dependencies:
Configure completed: run make
to build or make install
ERROR:root:code for hash sha224 was not found.
Traceback (most recent call last):
File "/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/platform/lib/python2.7/hashlib.py", line 139, in
Welcome to Mapnik...
scons: done reading SConscript files. scons: Building targets ... arm-linux-androideabi-g++ -o deps/agg/src/agg_arc.o -c -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -fvisibility-inlines-hidden -DNDEBUG -O3 -D_FILE_OFFSET_BITS=64 -fPIC -D_LITTLE_ENDIAN -DU_CHARSET_IS_UTF8=1 -DUCONFIG_NO_COLLATION=1 -DU_HAVE_NL_LANGINFO_CODESET=0 -std=c++11 -stdlib=libc++ -Wall -ftemplate-depth-300 -O3 -fno-strict-aliasing -finline-functions -Wno-inline -Wno-parentheses -Wno-char-subscripts -fPIC -DBIGINT -DDARWIN -DMAPNIK_THREADSAFE -DBOOST_SPIRIT_USE_PHOENIX_V3=1 -DNDEBUG -DMAPNIK_STATIC_PLUGIN_SHAPE -DMAPNIK_STATIC_PLUGIN_CSV -DMAPNIK_STATIC_PLUGIN_GEOJSON -DMAPNIK_STATIC_PLUGINS -Ideps -Ideps/clipper/include -Ideps/agg/include -Iinclude -I. -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/freetype2 -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/libxml2 deps/agg/src/agg_arc.cpp arm-linux-androideabi-g++: error: unrecognized command line option '-stdlib=libc++' arm-linux-androideabi-g++ -o deps/agg/src/agg_arrowhead.o -c -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -fvisibility-inlines-hidden -DNDEBUG -O3 -D_FILE_OFFSET_BITS=64 -fPIC -D_LITTLE_ENDIAN -DU_CHARSET_IS_UTF8=1 -DUCONFIG_NO_COLLATION=1 -DU_HAVE_NL_LANGINFO_CODESET=0 -std=c++11 -stdlib=libc++ -Wall -ftemplate-depth-300 -O3 -fno-strict-aliasing -finline-functions -Wno-inline -Wno-parentheses -Wno-char-subscripts -fPIC -DBIGINT -DDARWIN -DMAPNIK_THREADSAFE -DBOOST_SPIRIT_USE_PHOENIX_V3=1 -DNDEBUG -DMAPNIK_STATIC_PLUGIN_SHAPE -DMAPNIK_STATIC_PLUGIN_CSV -DMAPNIK_STATIC_PLUGIN_GEOJSON -DMAPNIK_STATIC_PLUGINS -Ideps -Ideps/clipper/include -Ideps/agg/include -Iinclude -I. -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/freetype2 -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/libxml2 deps/agg/src/agg_arrowhead.cpp arm-linux-androideabi-g++: error: unrecognized command line option '-stdlib=libc++' arm-linux-androideabi-g++ -o deps/agg/src/agg_bezier_arc.o -c -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -fvisibility-inlines-hidden -DNDEBUG -O3 -D_FILE_OFFSET_BITS=64 -fPIC -D_LITTLE_ENDIAN -DU_CHARSET_IS_UTF8=1 -DUCONFIG_NO_COLLATION=1 -DU_HAVE_NL_LANGINFO_CODESET=0 -std=c++11 -stdlib=libc++ -Wall -ftemplate-depth-300 -O3 -fno-strict-aliasing -finline-functions -Wno-inline -Wno-parentheses -Wno-char-subscripts -fPIC -DBIGINT -DDARWIN -DMAPNIK_THREADSAFE -DBOOST_SPIRIT_USE_PHOENIX_V3=1 -DNDEBUG -DMAPNIK_STATIC_PLUGIN_SHAPE -DMAPNIK_STATIC_PLUGIN_CSV -DMAPNIK_STATIC_PLUGIN_GEOJSON -DMAPNIK_STATIC_PLUGINS -Ideps -Ideps/clipper/include -Ideps/agg/include -Iinclude -I. -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/freetype2 -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/libxml2 deps/agg/src/agg_bezier_arc.cpp arm-linux-androideabi-g++: error: unrecognized command line option '-stdlib=libc++' arm-linux-androideabi-g++ -o deps/agg/src/agg_bspline.o -c -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -fvisibility-inlines-hidden -DNDEBUG -O3 -D_FILE_OFFSET_BITS=64 -fPIC -D_LITTLE_ENDIAN -DU_CHARSET_IS_UTF8=1 -DUCONFIG_NO_COLLATION=1 -DU_HAVE_NL_LANGINFO_CODESET=0 -std=c++11 -stdlib=libc++ -Wall -ftemplate-depth-300 -O3 -fno-strict-aliasing -finline-functions -Wno-inline -Wno-parentheses -Wno-char-subscripts -fPIC -DBIGINT -DDARWIN -DMAPNIK_THREADSAFE -DBOOST_SPIRIT_USE_PHOENIX_V3=1 -DNDEBUG -DMAPNIK_STATIC_PLUGIN_SHAPE -DMAPNIK_STATIC_PLUGIN_CSV -DMAPNIK_STATIC_PLUGIN_GEOJSON -DMAPNIK_STATIC_PLUGINS -Ideps -Ideps/clipper/include -Ideps/agg/include -Iinclude -I. -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/freetype2 -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/libxml2 deps/agg/src/agg_bspline.cpp arm-linux-androideabi-g++: error: unrecognized command line option '-stdlib=libc++' arm-linux-androideabi-g++ -o deps/agg/src/agg_curves.o -c -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -fvisibility-inlines-hidden -DNDEBUG -O3 -D_FILE_OFFSET_BITS=64 -fPIC -D_LITTLE_ENDIAN -DU_CHARSET_IS_UTF8=1 -DUCONFIG_NO_COLLATION=1 -DU_HAVE_NL_LANGINFO_CODESET=0 -std=c++11 -stdlib=libc++ -Wall -ftemplate-depth-300 -O3 -fno-strict-aliasing -finline-functions -Wno-inline -Wno-parentheses -Wno-char-subscripts -fPIC -DBIGINT -DDARWIN -DMAPNIK_THREADSAFE -DBOOST_SPIRIT_USE_PHOENIX_V3=1 -DNDEBUG -DMAPNIK_STATIC_PLUGIN_SHAPE -DMAPNIK_STATIC_PLUGIN_CSV -DMAPNIK_STATIC_PLUGIN_GEOJSON -DMAPNIK_STATIC_PLUGINS -Ideps -Ideps/clipper/include -Ideps/agg/include -Iinclude -I. -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/freetype2 -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/libxml2 deps/agg/src/agg_curves.cpp arm-linux-androideabi-g++: error: unrecognized command line option '-stdlib=libc++' scons: * [deps/agg/src/agg_arc.o] Error 1 arm-linux-androideabi-g++ -o deps/agg/src/agg_embedded_raster_fonts.o -c -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -fvisibility-inlines-hidden -DNDEBUG -O3 -D_FILE_OFFSET_BITS=64 -fPIC -D_LITTLE_ENDIAN -DU_CHARSET_IS_UTF8=1 -DUCONFIG_NO_COLLATION=1 -DU_HAVE_NL_LANGINFO_CODESET=0 -std=c++11 -stdlib=libc++ -Wall -ftemplate-depth-300 -O3 -fno-strict-aliasing -finline-functions -Wno-inline -Wno-parentheses -Wno-char-subscripts -fPIC -DBIGINT -DDARWIN -DMAPNIK_THREADSAFE -DBOOST_SPIRIT_USE_PHOENIX_V3=1 -DNDEBUG -DMAPNIK_STATIC_PLUGIN_SHAPE -DMAPNIK_STATIC_PLUGIN_CSV -DMAPNIK_STATIC_PLUGIN_GEOJSON -DMAPNIK_STATIC_PLUGINS -Ideps -Ideps/clipper/include -Ideps/agg/include -Iinclude -I. -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/freetype2 -I/Users/lexis_tikh/a/mapnik/mapnik-packaging/osx/out/build-libstdc++-gcc-arm/include/libxml2 deps/agg/src/agg_embedded_raster_fonts.cpp scons: * [deps/agg/src/agg_arrowhead.o] Error 1 scons: * [deps/agg/src/agg_bezier_arc.o] Error 1 scons: * [deps/agg/src/agg_bspline.o] Error 1 scons: * [deps/agg/src/agg_curves.o] Error 1 arm-linux-androideabi-g++: error: unrecognized command line option '-stdlib=libc++' scons: * [deps/agg/src/agg_embedded_raster_fonts.o] Error 1 scons: building terminated because of errors. make: *\ [mapnik] Error 2
It is due to this commit at mapnik repo https://github.com/mapnik/mapnik/commit/ec53cd9a02203b8e337a75cd286a22e60089f9d0 I have no python knowledge but it looks if sys.platform == 'darwin': is always executed at os x even if cross compiling
@lexis-t - can you update master and try again? However, keep in mind that master has just moved to requiring c++11 support and you will likely be better off sticking with the 2.3.x
branch for now.
HI,
I'm quite new to Android, I'm using this procedure with mapnik-packaging Release 0.0.1 on OSX 10.9.5 but I'm having this error:
source Android.sh downloading http://dl.google.com/android/ndk/android-ndk64-r10-darwin-x86_64.tar.bz2 unpacking android-ndk64-r10-darwin-x86_64.tar.bz2 [NOTE in your procedure I already downloaded version r9 and in a different location] creating android toolchain with arm-linux-androideabi-4.9/android-L at /Users/imac/Work/Android/mapnik-fromWeb/mapnik-packaging/osx/out/packages/android-ndk-r10/active-platform/ Copying prebuilt binaries... Copying sysroot headers and libraries... Copying c++ runtime headers and libraries (with libc++abi)... ERROR: Cant' copy from non-directory: /Users/imac/Work/Android/mapnik-fromWeb/mapnik-packaging/osx/out/packages/android-ndk-r10/sources/android/compiler-rt/libs/armeabi [NOTE this directory does not exist in NDK r10] using /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ version : 4.2.1
\ building against libstdcpp in cpp03 mode with /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ **
So I'm not sure what is the issue, seems like selecting ANDROID_CROSS_COMPILER="arm-linux-androideabi-4.9" is not possible with NDK r10, could you kindly give some help ? Thanks
Yes, it is possible the 4.9 is out of sync. I feel like I've seen this error before but don't recall the solution so I'd need to test myself to figure it out but won't have time today. Let me know what you find.
Hi, thanks for the info but do you think it is better if I "go back" using NDK r9d or I must use NDK r10 for some reason ? One more small point, the instructions above have some problems (e.g. ./scripts/download_deps.sh and ./scripts/build_core_deps.sh not present), does it mean that I should simply skip the missing scripts or that the sequence should be drastically different ?
Hi sorry to bother you but after some days of work trying to follow above instructions I have a list of doubts, please let me know in case this is not the right place for them where I could ask for support: 1) at this path http://mapnik.s3.amazonaws.com/index.html?path=dist/dev/ I cannot find any SDK for android (maybe looking for wrong name ?) 2) I'm using the mapnik-packaging for the 8 Aug (just before you made the changes for r10, is it "correct" or for some reasons it is meaningless?) 3) why you first build icu, boost and protobuf for MacOSX ? this libs shall not be compiled for Android ? 4) Shall I then rebuild boost and icu for Android ? .. I know a lot of question but I'm really confused. Thanks
@cbo1964 - sorry the instructions at the top were way out of date. I've updated them - can you try again? There may be problems since I've not run this recently, but just share your errors exactly.
@springmeyer - thanks for your help, unfortunately I'm having some problems (see below log) about conflicting types.
LOG:
Warning: autoconf-2.69 already installed Warning: automake-1.14.1 already installed Warning: libtool-2.4.2 already installed Warning: makedepend-1.0.5 already installed Warning: cmake-2.8.12.2 already installed
[COMMENT Downloading and "installing" ndk r10b]
** building pkg-config **
[COMMENT pkg-config is fine]
\ building against libcpp in cpp03 mode with aarch64-linux-android-clang++ **
\ using cached icu4c-53_1-src.tgz **
\ building icu **
[COMMENT icu for host x86_64 macosx is fine]
\ building against libcpp in cpp03 mode with aarch64-linux-android-clang++ **
[COMMENT Now building icu for target and THIS FAIL, see at the end of this post, for what I understood up to now seems something related so stdlib ]
patching file tools/toolutil/ucbuf.c
configure: WARNING: if you wanted to set the --build type, don't use --host.
If a cross compiler is detected then cross compile mode will be used
checking for ICU version numbers... release 53.1, library 53.1, unicode version 6.3
checking build system type... x86_64-apple-darwin13.4.0
checking host system type... aarch64-unknown-linux-android
checking whether to build debug libraries... no
checking whether to build release libraries... yes
checking for aarch64-linux-android-clang... aarch64-linux-android-clang
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... yes
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether aarch64-linux-android-clang accepts -g... yes
checking for aarch64-linux-android-clang option to accept ISO C89... none needed
checking whether we are using the GNU C++ compiler... yes
checking whether aarch64-linux-android-clang++ accepts -g... yes
checking how to run the C preprocessor... aarch64-linux-android-clang -E
checking for a BSD-compatible install... /usr/bin/install -c
checking for gmake... no
checking for gnumake... /usr/bin/gnumake
Using cross buildroot: /Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/../../icu-x86_64/source
checking for doxygen... no
checking checking for executable suffix...
checking whether strict compiling is on... yes
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking size of void *... 8
checking whether runnable 64 bit binaries are built by default... yes
checking which Makefile fragment to use for aarch64-unknown-linux-android... mh-linux
checking for floor in -lm... yes
checking whether to build shared libraries... no
checking whether to build static libraries... yes
checking whether we can use static library optimization option... yes
checking whether to enable auto cleanup of libraries... no
checking whether to enable draft APIs... yes
checking for aarch64-linux-android-ranlib... aarch64-linux-android-ranlib
checking for aarch64-linux-android-ar... aarch64-linux-android-ar
checking whether to enable renaming of symbols... yes
checking whether to enable function and data tracing... no
checking elf.h usability... yes
checking elf.h presence... yes
checking for elf.h... yes
checking whether to enable dynamic loading of plugins... no
checking for gettimeofday... yes
checking if we have a C++ compiler... Good
checking if we have a C++11 compiler... yes
configure: Adding CXXFLAGS option --std=c++0x
checking if #include
ICU for C/C++ 53.1 is ready to be built.
=== Important Notes: ===
Data Packaging: archive
This means: ICU data will be stored in a single .dat file.
To locate data: ICU will look in /Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/build-cpp03-libcpp-gcc-arm-android/share/icu/53.1 which is the installation location. Call u_setDataDirectory() or use the ICU_DATA environment variable to override.
Building ICU: Use a GNU make such as /usr/bin/gnumake to build ICU.
checking the version of "/usr/bin/gnumake"... 3.81 (we wanted at least 3.80)
ok
C++ apps may want to build with CXXFLAGS = --std=c++0x
cd ./config; \
make -f pkgdataMakefile
rm -rf config/icu-config
rebuilding config/icucross.mk
rebuilding config/icucross.inc
/usr/bin/install -c ./config/icu-config-top config/icu-config
/bin/sh ./mkinstalldirs lib
/bin/sh ./mkinstalldirs bin
chmod u+w config/icu-config
mkdir lib
mkdir bin
rm -rf pkgdata.inc
make[0]: Making all' in
stubdata'
(deps) stubdata.c
LC_ALL=C sed -f ./config/make2sh.sed < ./config/Makefile.inc | grep -v '#M#' | uniq >> config/icu-config
LC_ALL=C sed -f ./config/make2sh.sed < ./config/mh-linux | grep -v '#M#' | uniq >> config/icu-config
cat ./config/icu-config-bottom >> config/icu-config
echo "# Rebuilt on "date
>> config/icu-config
config/icu-i18n.pc updated.
config/icu-uc.pc updated.
aarch64-linux-android-clang ... stubdata.c
chmod u-w config/icu-config
aarch64-linux-android-ar r libicudata.a stubdata.ao
aarch64-linux-android-ar: creating libicudata.a
aarch64-linux-android-ranlib libicudata.a
make[0]: Making all' in
common'
(deps) simplepatternformatter.cpp
(deps) lrucache.cpp
(deps) listformatter.cpp
(deps) icuplug.c
(deps) sharedobject.cpp
(deps) icudataver.c
(deps) uloc_tag.c
Note: rebuild with "make VERBOSE=1 " to show all compiler parameters.
(deps) ulist.c
(deps) propsvec.c
(deps) ucnvsel.cpp
(deps) dtintrv.cpp
(deps) wintz.c
(deps) cwchar.c
(deps) locbased.cpp
(deps) parsepos.cpp
(deps) util_props.cpp
(deps) util.cpp
(deps) punycode.cpp
(deps) uts46.cpp
(deps) usprep.cpp
(deps) uidna.cpp
(deps) servslkf.cpp
(deps) servrbf.cpp
(deps) servlkf.cpp
(deps) servlk.cpp
(deps) servls.cpp
(deps) servnotf.cpp
(deps) serv.cpp
(deps) rbbitblb.cpp
(deps) rbbistbl.cpp
(deps) rbbisetb.cpp
(deps) rbbiscan.cpp
(deps) rbbirb.cpp
(deps) rbbinode.cpp
(deps) rbbidata.cpp
(deps) rbbi.cpp
(deps) dictbe.cpp
(deps) brkeng.cpp
(deps) ubrk.cpp
(deps) brkiter.cpp
(deps) uarrsort.c
(deps) unifunct.cpp
(deps) unifilt.cpp
(deps) caniter.cpp
(deps) ruleiter.cpp
(deps) usetiter.cpp
(deps) uniset.cpp
(deps) uset.cpp
(deps) uniset_closure.cpp
(deps) uniset_props.cpp
(deps) uset_props.cpp
(deps) unisetspan.cpp
(deps) bmpset.cpp
(deps) utrie2_builder.cpp
(deps) utrie2.cpp
(deps) utrie.cpp
(deps) unames.cpp
(deps) usc_impl.c
(deps) uscript_props.cpp
(deps) uscript.c
(deps) ushape.cpp
(deps) ubidiln.c
(deps) ubidiwrt.c
(deps) ubidi.c
(deps) ubidi_props.c
(deps) propname.cpp
(deps) ucase.cpp
(deps) uprops.cpp
(deps) uchar.c
(deps) patternprops.cpp
(deps) uiter.cpp
(deps) uchriter.cpp
(deps) schriter.cpp
(deps) chariter.cpp
(deps) unormcmp.cpp
(deps) unorm.cpp
(deps) normlzr.cpp
(deps) filterednormalizer2.cpp
(deps) normalizer2.cpp
(deps) normalizer2impl.cpp
(deps) ustr_titlecase_brkiter.cpp
(deps) unistr_titlecase_brkiter.cpp
(deps) ustrcase_locale.cpp
(deps) unistr_case_locale.cpp
(deps) utext.cpp
(deps) ustr_wcs.cpp
(deps) ustrtrns.cpp
(deps) ustrfmt.c
(deps) cstring.c
(deps) ucasemap_titlecase_brkiter.cpp
(deps) ucasemap.cpp
(deps) ustrcase.cpp
(deps) ustring.cpp
(deps) utf_impl.c
(deps) unistr_props.cpp
(deps) unistr_case.cpp
(deps) unistr.cpp
(deps) unistr_cnv.cpp
(deps) ustr_cnv.c
(deps) appendable.cpp
(deps) dictionarydata.cpp
(deps) ucharstrieiterator.cpp
(deps) ucharstriebuilder.cpp
(deps) ucharstrie.cpp
(deps) bytestrieiterator.cpp
(deps) bytestrie.cpp
(deps) bytestriebuilder.cpp
(deps) stringtriebuilder.cpp
(deps) stringpiece.cpp
(deps) bytestream.cpp
(deps) locresdata.cpp
(deps) loclikely.cpp
(deps) locdispnames.cpp
(deps) locavailable.cpp
(deps) locutil.cpp
(deps) locid.cpp
(deps) uloc.cpp
(deps) locmap.c
(deps) ucat.c
(deps) messagepattern.cpp
(deps) resbund_cnv.cpp
(deps) resbund.cpp
(deps) uresdata.c
(deps) ures_cnv.c
(deps) uresbund.cpp
(deps) ucnv_ct.c
(deps) ucnv_set.c
(deps) ucnvdisp.c
(deps) ucnvisci.c
(deps) ucnv_lmb.c
(deps) ucnvhz.c
(deps) ucnv2022.cpp
(deps) ucnvmbcs.c
(deps) ucnv_ext.cpp
(deps) ucnvbocu.cpp
(deps) ucnvscsu.c
(deps) ucnv_u32.c
(deps) ucnv_u16.c
(deps) ucnv_u8.c
(deps) ucnv_u7.c
(deps) ucnvlat1.c
(deps) ucnv_err.c
(deps) ucnv_cb.c
(deps) ucnv_io.cpp
(deps) ucnv_cnv.c
(deps) ucnv_bld.cpp
(deps) ucnv.c
(deps) uvectr64.cpp
(deps) uvectr32.cpp
(deps) ustack.cpp
(deps) uvector.cpp
(deps) ustrenum.cpp
(deps) uenum.c
(deps) uhash_us.cpp
(deps) uhash.c
(deps) utrace.c
(deps) ucol_swp.cpp
(deps) udataswp.c
(deps) umapfile.c
(deps) udatamem.c
(deps) ucmndata.c
(deps) udata.cpp
(deps) charstr.cpp
(deps) cmemory.c
(deps) uobject.cpp
(deps) uinit.cpp
(deps) ucln_cmn.c
(deps) umutex.cpp
(deps) uinvchar.c
(deps) utypes.c
(deps) umath.c
(deps) putil.cpp
(deps) errorcode.cpp
generating ../common/svchook.mk
cd .. \
&& CONFIG_FILES=common/Makefile CONFIG_HEADERS= /bin/sh ./config.status
config.status: creating common/Makefile
aarch64-linux-android-clang++ ... errorcode.cpp
aarch64-linux-android-clang++ ... putil.cpp
aarch64-linux-android-clang ... umath.c
aarch64-linux-android-clang ... utypes.c
aarch64-linux-android-clang ... uinvchar.c
aarch64-linux-android-clang++ ... umutex.cpp
aarch64-linux-android-clang ... ucln_cmn.c
aarch64-linux-android-clang++ ... uinit.cpp
aarch64-linux-android-clang++ ... uobject.cpp
aarch64-linux-android-clang ... cmemory.c
aarch64-linux-android-clang++ ... charstr.cpp
aarch64-linux-android-clang++ ... udata.cpp
aarch64-linux-android-clang ... ucmndata.c
aarch64-linux-android-clang ... udatamem.c
In file included from putil.cpp:52:
In file included from /Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/common/cstring.h:31:
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform//bin/../lib/gcc/aarch64-linux-android/4.9/../../../../include/c++/4.9/stdlib.h:49:22: error:
conflicting types for 'strtoll_l'
long long strtoll_l(const char _nptr, char _endptr, int base, locale_t loc);
^
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform/bin/../sysroot/usr/include/stdlib.h:79:18: note:
previous declaration is here
extern long long strtolll(const char , char _, size_t, locale_t) LIBC_ABI_PUBLIC;
^
In file included from putil.cpp:52:
In file included from /Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/common/cstring.h:31:
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform//bin/../lib/gcc/aarch64-linux-android/4.9/../../../../include/c++/4.9/stdlib.h:50:22: error:
conflicting types for 'strtoull_l'
unsigned long long strtoull_l(const char _nptr, char _endptr, int base, locale_t loc);
^
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform/bin/../sysroot/usr/include/stdlib.h:80:27: note:
previous declaration is here
extern unsigned long long strtoulll(const char , char _, size_t, locale_t) LIBC_ABI_PUBLIC;
^
In file included from charstr.cpp:18:
In file included from /Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/common/cstring.h:31:
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform//bin/../lib/gcc/aarch64-linux-android/4.9/../../../../include/c++/4.9/stdlib.h:49:22: error:
conflicting types for 'strtoll_l'
long long strtoll_l(const char _nptr, char _endptr, int base, locale_t loc);
^
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform/bin/../sysroot/usr/include/stdlib.h:79:18: note:
previous declaration is here
extern long long strtolll(const char , char _, size_t, locale_t) LIBC_ABI_PUBLIC;
^
In file included from charstr.cpp:18:
In file included from /Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/common/cstring.h:31:
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform//bin/../lib/gcc/aarch64-linux-android/4.9/../../../../include/c++/4.9/stdlib.h:50:22: error:
conflicting types for 'strtoull_l'
unsigned long long strtoull_l(const char _nptr, char _endptr, int base, locale_t loc);
^
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform/bin/../sysroot/usr/include/stdlib.h:80:27: note:
previous declaration is here
extern unsigned long long strtoulll(const char , char _, size_t, locale_t) LIBC_ABI_PUBLIC;
^
aarch64-linux-android-clang ... umapfile.c
2 errors generated.
aarch64-linux-android-clang ... udataswp.c
* Failed compilation command follows: ----------------------------------------------------------
aarch64-linux-android-clang++ -DANDROID -I/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/common -I/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/tools/tzcode/ -ffunction-sections -fdata-sections -D_REENTRANT -DU_HAVE_ELF_H=1 -DU_ENABLE_DYLOAD=0 -DU_HAVE_STD_STRING=0 -DU_HAVE_ATOMIC=1 -DU_OVERRIDE_CXX_ALLOCATION=0 -I. -DDEFAULT_ICU_PLUGINS="/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/build-cpp03-libcpp-gcc-arm-android/lib/icu" -DU_ICU_DATA_DEFAULT_DIR="/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/build-cpp03-libcpp-gcc-arm-android/share/icu/53.1" -DU_ATTRIBUTE_DEPRECATED= -DU_COMMON_IMPLEMENTATION -I/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/build-cpp03-libcpp-gcc-arm-android/include -DNDEBUG -O3 -D_FILE_OFFSET_BITS=64 -fPIC -D_LITTLE_ENDIAN -W -Wall -pedantic -Wpointer-arith -Wwrite-strings -Wno-long-long --std=c++0x -c -o charstr.ao charstr.cpp
--- ( rebuild with "make VERBOSE=1 all" to show all parameters ) --------
make[1]: * [charstr.ao] Error 1
make[1]: * Waiting for unfinished jobs....
putil.cpp:2285:26: warning: unused parameter 'libName' [-Wunused-parameter]
uprv_dl_open(const char _libName, UErrorCode status) {
^
putil.cpp:2292:21: warning: unused parameter 'lib' [-Wunused-parameter]
uprv_dl_close(void lib, UErrorCode status) {
^
putil.cpp:2300:23: warning: unused parameter 'lib' [-Wunused-parameter]
uprv_dlsym_func(void lib, const char_ sym, UErrorCode _status) {
^
putil.cpp:2300:40: warning: unused parameter 'sym' [-Wunused-parameter]
uprv_dlsymfunc(void *lib, const char sym, UErrorCode _status) {
^
4 warnings and 2 errors generated.
In file included from udata.cpp:31:
In file included from /Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/common/cstring.h:31:
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform//bin/../lib/gcc/aarch64-linux-android/4.9/../../../../include/c++/4.9/stdlib.h:49:22: error:
conflicting types for 'strtoll_l'
long long strtoll_l(const char nptr, char _endptr, int base, locale_t loc);
^
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform/bin/../sysroot/usr/include/stdlib.h:79:18: note:
previous declaration is here
extern long long strtolll(const char , char *_, size_t, locale_t) LIBC_ABI_PUBLIC;
^
In file included from udata.cpp:31:
In file included from /Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/common/cstring.h:31:
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform//bin/../lib/gcc/aarch64-linux-android/4.9/../../../../include/c++/4.9/stdlib.h:50:22: error:
conflicting types for 'strtoull_l'
unsigned long long strtoull_l(const char _nptr, char _endptr, int base, locale_t loc);
^
/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/android-ndk-r10b/active-platform/bin/../sysroot/usr/include/stdlib.h:80:27: note:
previous declaration is here
extern unsigned long long strtoulll(const char , char _, size_t, locale_t) LIBC_ABI_PUBLIC;
^
* Failed compilation command follows: ----------------------------------------------------------
aarch64-linux-android-clang++ -DANDROID -I/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/common -I/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/tools/tzcode/ -ffunction-sections -fdata-sections -D_REENTRANT -DU_HAVE_ELF_H=1 -DU_ENABLE_DYLOAD=0 -DU_HAVE_STD_STRING=0 -DU_HAVE_ATOMIC=1 -DU_OVERRIDE_CXX_ALLOCATION=0 -I. -DDEFAULT_ICU_PLUGINS="/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/build-cpp03-libcpp-gcc-arm-android/lib/icu" -DU_ICU_DATA_DEFAULT_DIR="/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/build-cpp03-libcpp-gcc-arm-android/share/icu/53.1" -DU_ATTRIBUTE_DEPRECATED= -DU_COMMON_IMPLEMENTATION -I/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/build-cpp03-libcpp-gcc-arm-android/include -DNDEBUG -O3 -D_FILE_OFFSET_BITS=64 -fPIC -D_LITTLE_ENDIAN -W -Wall -pedantic -Wpointer-arith -Wwrite-strings -Wno-long-long --std=c++0x -c -o putil.ao putil.cpp
--- ( rebuild with "make VERBOSE=1 all" to show all parameters ) --------
make[1]: * [putil.ao] Error 1
2 errors generated.
* Failed compilation command follows: ----------------------------------------------------------
aarch64-linux-android-clang++ -DANDROID -I/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/common -I/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/packages/icu-gcc-arm/source/tools/tzcode/ -ffunction-sections -fdata-sections -D_REENTRANT -DU_HAVE_ELF_H=1 -DU_ENABLE_DYLOAD=0 -DU_HAVE_STD_STRING=0 -DU_HAVE_ATOMIC=1 -DU_OVERRIDE_CXX_ALLOCATION=0 -I. -DDEFAULT_ICU_PLUGINS="/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/build-cpp03-libcpp-gcc-arm-android/lib/icu" -DU_ICU_DATA_DEFAULT_DIR="/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/build-cpp03-libcpp-gcc-arm-android/share/icu/53.1" -DU_ATTRIBUTE_DEPRECATED= -DU_COMMON_IMPLEMENTATION -I/Users/imac/Work/Android/mapnik/mapnik-packaging-master/osx/out/build-cpp03-libcpp-gcc-arm-android/include -DNDEBUG -O3 -D_FILE_OFFSET_BITS=64 -fPIC -D_LITTLE_ENDIAN -W -Wall -pedantic -Wpointer-arith -Wwrite-strings -Wno-long-long --std=c++0x -c -o udata.ao udata.cpp
--- ( rebuild with "make VERBOSE=1 all" to show all parameters ) --------
make[1]: * [udata.ao] Error 1
make: * [all-recursive] Error 2
@springmeyer - in this post (continuously editing) I'm trying to make it compile making some changes, maybe could be useful also for you, let me know if you prefer that I make a branch,
FIRST, I'm using an "older" (hoping more stable) configuration export MASON_ANDROID_ARCH="arm" export MASON_API_LEVEL="android-19" export MASON_ANDROID_TARGET="arm-linux-androideabi" export MASON_ANDROID_CROSS_COMPILER="${MASON_ANDROID_TARGET}-4.8"
please note that I'm still using ndk r10b but for 32 bit targets.
1) it compiles successfully pkgconfig for host x86_64 macosx
2) t compiles successfully icu for host x86_64 macosx
3) does not compile icu for target arm android with this error:
config.status: creating tools/genrb/genrb.1
arm-linux-androideabi-clang++ -I/Users/imac/Work/Android/mapnik/CURRENT/osx/out/build-cpp03-libcpp-gcc-arm-android/include -DNDEBUG -O3 -D_FILE_OFFSET_BITS=64 -fPIC -D_LITTLE_ENDIAN -W -Wall -pedantic -Wpointer-arith -Wwrite-strings -Wno-long-long --std=c++0x -L/Users/imac/Work/Android/mapnik/CURRENT/osx/out/build-cpp03-libcpp-gcc-arm-android/lib -O3 -Wl,--gc-sections -o ../../bin/genrb errmsg.o genrb.o parse.o read.o reslist.o ustr.o rbutil.o wrtjava.o rle.o wrtxml.o prscmnts.o -L../../lib -licutu -L../../lib -licui18n -L../../lib -licuuc -L../../stubdata -licudata -lm
../../lib/libicui18n.a(collationroot.ao):collationroot.cpp:function icu_53::uprv_collation_root_cleanup(): error: undefined reference to '__atomic_store_4'
[SOLUTION] I set --disable-tools in build_icu (not sure if tools are needed for mapnik), this anyway allow to compile icu and go to next step
4) does not compile the boost lib with an error: FIRST time I launch the build i get \ generating user-config.jam **
patching file libs/regex/src/fileiter.cpp gcc-arm.jam: No such file or directory /Users/imac/Work/Android/mapnik/CURRENT/osx/out/packages/boost_1_56_0-gcc-arm/tools/build/src/build/toolset.jam:43: in toolset.using ERROR: rule "gcc-arm.init" unknown in module "toolset".
=> for what i understood this is caused because in build_boost.sh when creating the user-config.jam there is this line: echo "using ${BOOST_TOOLSET} : : $(which ${CXX})" > user-config.jam with BOOST_TOOLSET=gcc-arm set in the settings.sh for the Android platform BUT gcc-arm.jam does not exist at tools/build/src/tools boost directory as does not exist the toolset gcc-arm rule in the build.jam at tools/build/src/engine
[SOLUTION] so I set BOOST_TOOLSET=gcc and with this change boost compiled
5) compiled freetype, harfbuzz
6) does not compile xml2 with this error: In file included from glob.c:83: ./glob.h:43:9: error: unknown type name 'size_t' typedef size_t size_t; [SOLUTION] Commented this typedef and this part compile but then I have a new problem: CCLD testlimits runtest.o:runtest.c:function runtest: error: undefined reference to 'glob' runtest.o:runtest.c:function runtest: error: undefined reference to 'globfree' clang34: error: linker command failed with exit code 1 (use -v to see invocation)
=> problem is that LIBS variable is not used but autoconf and so it is not set in final Makefile. Not expert of autconf I don't know how to solve, only solution I found is to add following line to build_libxml2 even if it is not correct accordingly to autoconf manual: [SOLUTION] LDFLAGS="${LDFLAGS} -l${RIGHT_HERE}/glob.o"
7) nasm does not compile
[SOLUTION] added MASON_CROSS=1 in ensure_nasm in settings.sh when switching platform, so line: source "${ROOTDIR}/${HOST_PLATFORM}.sh" becomes MASON_CROSS=1 source "${ROOTDIR}/${HOST_PLATFORM}.sh", same for source "${ROOTDIR}/${OLD_PLATFORM}.sh"
8) it compiles jpeg_turbo, libpng, proj4
9) webp not compiling, found this in build_webp.sh TODO - android: cpu.c:17:26: fatal error: cpu-features.h: No such file or directory
[SOLUTION] I added CFLAGS="${CFLAGS} -I${NDK_PATH}/sources/android/cpufeatures" to build_webp, not sure if it is correct but it compiles.
10) tiff does not compile: configure says: Invalid configuration `arm-linux-androideabi'
[SOLUTION] I replaced config.sub and config.guess in the config subdir in tiff because too old
11) protobuf compiles for x86_64 macosx but not for arm android c/ios.cpp:function std::1::ios_base::xalloc(): error: undefined reference to '__atomic_fetch_add_4' [__SOLUTION] I comment the protobuf compilation because (if I understood correctly) it is optional for mapnik mobile
12) Finally trying to compile mapnik but I get a strange error: KeyError: 'BOOST_LIB_VERSION_FROM_HEADER': File "/Users/imac/Work/Android/mapnik/CURRENT/osx/mapnik-cpp03-libcpp/SConstruct", line 1688: boost_version_from_header = int(env['BOOST_LIB_VERSION_FROMHEADER'].split('')[1]) File "/Users/imac/Work/Android/mapnik/CURRENT/osx/mapnik-cpp03-libcpp/scons/scons-local-2.3.0/SCons/Environment.py", line 412: return self._dict[key]
[SOLUTION] commented line 1688 in SConstruct and set by hands 56 as boost lib (is a trick but I don't know how to solve)
13) Now I get an error regarding gdal, I see that in the build.sh gdal is not compiled if BOOST_ARCH = arm (as cairo and pitman) but then in the build_mapnik.sh gdal is given ad INPUT_PLUGIN ... same issue for cairo, it is not compiled il BOOST_ARCH = arm but then it is needed to compile mapnik
Sorry, I'm confused about the needed dependencies for mapnik for mobile.
@springmeyer How can i use this library in Android? i wan't to tile rendering with this.
Ticket to track creation of build scripts and a resulting Mapnik SDK to support Android out of the box.
So far my methods are to cross compile all Mapnik deps and Mapnik itself on OS X. This is mostly working nicely on OS X.
To set up on OS X do:
TODO: