Compilation and installation of DCMTK
Moderator: Moderator Team
GGK
Posts: 20 Joined: Mon, 2012-11-12, 14:49
#1
Post
by GGK » Tue, 2015-09-15, 13:32
Hi,
trying to compile DCMTK for Android following your manual
http://support.dcmtk.org/redmine/projec ... ileAndroid I get the named error in CMake 3.3.1, Win7, NDK r10e.
In my android.toolchain.cmake file the flag "-mfloat-abi=softfp" is set for my ANDROID_ABI which is "armabi-v7a" (some other deliver the same error)
if( ARMEABI_V7A )
set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -march=armv7-a -mfloat-abi=softfp" )
g++.exe: error: unrecognized command line option '-mfloat-abi=softfp'
g++.exe: error: unrecognized command line option '-mfpu=vfpv3-d16'
Output from Errorlog:
__declspec(align) is supported failed with the following output:
Change Dir: G:/DCMTK_SRC/Build-3.6.0/CMakeFiles/CMakeTmp
Run Build Command:"C:/MinGW/bin/mingw32-make.exe" "cmTC_a15fc/fast"
C:/MinGW/bin/mingw32-make.exe -f CMakeFiles\cmTC_a15fc.dir\build.make CMakeFiles/cmTC_a15fc.dir/build
mingw32-make.exe[1]: Entering directory 'G:/DCMTK_SRC/Build-3.6.0/CMakeFiles/CMakeTmp'
Building CXX object CMakeFiles/cmTC_a15fc.dir/src.cxx.o
C:\MinGW\bin\g++.exe -DANDROID -fexceptions -frtti -Wno-psabi --sysroot=G:/Programme/SKDs/android-ndk-r10e/platforms/android-8/arch-arm -fpic -funwind-tables -finline-limit=64 -fsigned-char -no-canonical-prefixes -march=armv7-a -mfloat-abi=softfp -mfpu=vfpv3-d16 -fdata-sections -ffunction-sections -Wa,--noexecstack -D_XOPEN_SOURCE_EXTENDED -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -D_BSD_COMPAT -D_OSF_SOURCE -D_POSIX_C_SOURCE=199506L -isystem G:\Programme\SKDs\android-ndk-r10e\platforms\android-8\arch-arm\usr\include -isystem G:\Programme\SKDs\android-ndk-r10e\sources\cxx-stl\gnu-libstdc++\4.9\include -isystem G:\Programme\SKDs\android-ndk-r10e\sources\cxx-stl\gnu-libstdc++\4.9\libs\armeabi-v7a\include -o CMakeFiles\cmTC_a15fc.dir\src.cxx.o -c G:\DCMTK_SRC\Build-3.6.0\CMakeFiles\CMakeTmp\src.cxx
g++.exe: error: unrecognized command line option '-mfloat-abi=softfp'
g++.exe: error: unrecognized command line option '-mfpu=vfpv3-d16'
CMakeFiles\cmTC_a15fc.dir\build.make:64: recipe for target 'CMakeFiles/cmTC_a15fc.dir/src.cxx.o' failed
mingw32-make.exe[1]: *** [CMakeFiles/cmTC_a15fc.dir/src.cxx.o] Error 1
mingw32-make.exe[1]: Leaving directory 'G:/DCMTK_SRC/Build-3.6.0/CMakeFiles/CMakeTmp'
Makefile:125: recipe for target 'cmTC_a15fc/fast' failed
mingw32-make.exe: *** [cmTC_a15fc/fast] Error 2
Thanks for helping me...
PS. Didn't find this error searching the forum
GGK
Jan Schlamelcher
OFFIS DICOM Team
Posts: 318 Joined: Mon, 2014-03-03, 09:51
Location: Oldenburg, Germany
#2
Post
by Jan Schlamelcher » Tue, 2015-09-15, 14:50
There is something seriously wrong here:
GGK wrote: C:\MinGW\bin\g++.exe -DANDROID -fexceptions [...]
Why is it using the g++ from your MinGW?! It should obviously use the g++ from your NDK instead! It is not surprising that MinGW does not know about the specific commadline options of the NDK crosscompiler.
GGK
Posts: 20 Joined: Mon, 2012-11-12, 14:49
#3
Post
by GGK » Tue, 2015-09-15, 15:05
I will check your hint...
but on the way find a solutione on my own...I deleted the cache of CMake so I have to start again..
Now I have problems to get start the emulator (it runs under Windows commandline useing the Commandline Output from CMake).
Starting the Android device emulator...
Emulator UUID: 817ae274b14b45afd758a5d5cac77415
G:/Programme/SKDs/android-sdk-windows/tools/emulator.exe -avd DCMKT -no-boot-anim -noaudio -prop emu.uuid=817ae274b14b45afd758a5d5cac77415
CMake Error at CMake/dcmtkUseAndroidSDK.cmake:344 (MESSAGE):
Error starting Android emulator.
Call Stack (most recent call first):
CMake/dcmtkPrepare.cmake:145 (DCMTK_ANDROID_START_EMULATOR)
CMakeLists.txt:8 (INCLUDE)
Configuring incomplete, errors occurred!
See also "G:/DCMTK_SRC/Build-3.6.0/CMakeFiles/CMakeOutput.log".
Do You have a hint for this error or how I can't find it. Editing dcmtkUseAndroid.SDK.cmake doesn't deliver more output?
GGK
GGK
Posts: 20 Joined: Mon, 2012-11-12, 14:49
#4
Post
by GGK » Wed, 2015-09-16, 10:20
Solved both problems...
Emulater Problem: as soon as the problem comes...it's gone...but I don't really understand it
GGK
Jan Schlamelcher
OFFIS DICOM Team
Posts: 318 Joined: Mon, 2014-03-03, 09:51
Location: Oldenburg, Germany
#5
Post
by Jan Schlamelcher » Thu, 2015-09-17, 10:28
What happens if you run
Code: Select all
G:/Programme/SKDs/android-sdk-windows/tools/emulator.exe -avd DCMKT -no-boot-anim -noaudio -prop
manually?
GGK
Posts: 20 Joined: Mon, 2012-11-12, 14:49
#6
Post
by GGK » Thu, 2015-09-17, 13:47
AVD starts...
Actually it runs...
Edit: Maybe I found the reason....the CMAKE_SH variable could have been wrong.
GGK
Users browsing this forum: No registered users and 1 guest