Hi, Johnson! On Aug 27, Johnson Cheng wrote: > Dear Sergei, > > Sorry to update again. (I am a newer on cmake) > I did some modifications on my configure command as below, > LD=/home/johnson/x86_64_TCglibc-2.19-3/usr/bin/x86_64-buildroot-linux-gnu-ld > NM=/home/johnson/x86_64_TCglibc-2.19-3/usr/bin/x86_64-buildroot-linux-gnu-nm > CC=/home/johnson/x86_64_TCglibc-2.19-3/usr/bin/x86_64-buildroot-linux-gnu-gcc > GCC=/home/johnson/x86_64_TCglibc-2.19-3/usr/bin/x86_64-buildroot-linux-gnu-gcc > > CXX=/home/johnson/x86_64_TCglibc-2.19-3/usr/bin/x86_64-buildroot-linux-gnu-g++ > > RANLIB=/home/johnson/x86_64_TCglibc-2.19-3/usr/bin/x86_64-buildroot-linux-gnu-ranlib > \ > CFLAGS="-I/home/johnson/cross_prj/sysroot/usr/include > -I/home/johnson/cross_prj/sysroot/include" \ > CXXFLAGS="-I/home/johnson/cross_prj/sysroot/usr/include > -I/home/johnson/cross_prj/sysroot/include" \ > LDFLAGS="-L/home/johnson/cross_prj/sysroot/lib > -L/home/johnson/cross_prj/sysroot/usr/lib -lm -lz -ldl -lcrypt -pthread" \ > CXXLDFLAGS="-L/home/johnson/cross_prj/sysroot/lib > -L/home/johnson/cross_prj/sysroot/usr/lib -lm -lz -ldl -lcrypt -pthread" \ > ../../cmake/HOST-cmake/bin/cmake . \ > -DCMAKE_TOOLCHAIN_FILE=../cross.cmake \ > > -DIMPORT_EXECUTABLES=/home/johnson/SanSoft/model/Phoenix_130313/Package/mariadb/native/import_executables.cmake > \ > -DXTRADB_OK=1
This is not a good idea. I mean -DXTRADB_OK=1. XTRADB_OK is set internally if HAVE_IB_GCC_ATOMIC_BUILTINS or HAVE_IB_SOLARIS_ATOMICS or MSVC is defined. Depending on what exactly is defined, different parts of the code are enabled. When you force XTRADB_OK=1 without enabling any of the other defines, XtraDB will not enable any of these parts of the code. Most probably it won't compile at all. Instead of forcing -DXTRADB_OK=1, you need to do -DHAVE_IB_GCC_ATOMIC_BUILTINS=1. Then XtraDB will compile as if gcc atomic builtins were available. They probably are anyway, but cross-compilation caused the test to fail. > It can success to configure, but it still has DB warning message. I am > not sure if I can ignore it?? > CMake Warning at storage/tokudb/CMakeLists.txt:17 (MESSAGE): > TokuDB is enabled, but jemalloc is not. This configuration is not > supported If you intend to use tokudb, then you probably should not ignore it. if you don't intend to use tokudb, you can as well specify -DWITHOUT_TOKUDB=1 and it won't be compiled at all. > Now I type "make" to do cross compiling, It seems it's not easy... > [ 17%] Building CXX object > storage/xtradb/CMakeFiles/xtradb.dir/buf/buf0buddy.cc.o > [ 17%] Building CXX object > storage/xtradb/CMakeFiles/xtradb.dir/buf/buf0buf.cc.o > > /home/johnson/SanSoft/model/Phoenix_130313/Package/mariadb/mariadb-10.0.21/storage/xtradb/buf/buf0buf.cc: > In function �buf_block_t* buf_page_get_gen(ulint, ulint, ulint, ulint, > buf_block_t*, ulint, const char*, ulint, mtr_t*)’: > > /home/johnson/SanSoft/model/Phoenix_130313/Package/mariadb/mariadb-10.0.21/storage/xtradb/buf/buf0buf.cc:3021:55: > error: �os_atomic_increment_ulint’ was not declared in this scope > os_atomic_increment_ulint(&buf_pool->n_pend_unzip, 1); > ^ That's exactly what I meant above. This error happens because you've defined TOKUDB_OK=1 Regards, Sergei _______________________________________________ Mailing list: https://launchpad.net/~maria-discuss Post to : [email protected] Unsubscribe : https://launchpad.net/~maria-discuss More help : https://help.launchpad.net/ListHelp

