I an trying to install the OpenCV-iOS cocoapod. When I ran pod install it give me a big error message.
Error Message: (part of it)
Trying OpenCV-iOS
[!] /bin/bash -c
set -e
mkdir build-iphoneos
cd build-iphoneos
cmake -GXcode -DBUILD_SHARED_LIBS=ON -DCMAKE_MACOSX_BUNDLE=ON -DCMAKE_XCODE_ATTRIBUTE_CODE_SIGNING_REQUIRED=NO -DAPPLE_FRAMEWORK=ON -DCMAKE_INSTALL_PREFIX=install -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=../platforms/ios/cmake/Toolchains/Toolchain-iPhoneOS_Xcode.cmake -DENABLE_NEON=ON ../
xcodebuild -arch armv7 -arch armv7s -arch arm64 -sdk iphoneos -configuration Release -parallelizeTargets -jobs 4 ONLY_ACTIVE_ARCH=NO -target ALL_BUILD build OTHER_CFLAGS="$(inherited) -Wno-implicit-function-declaration"
cmake -DCMAKE_INSTALL_PREFIX=install -P cmake_install.cmake
mkdir ../build-iphonesimulator
cd ../build-iphonesimulator
cmake -GXcode -DBUILD_SHARED_LIBS=ON -DCMAKE_MACOSX_BUNDLE=ON -DCMAKE_XCODE_ATTRIBUTE_CODE_SIGNING_REQUIRED=NO -DAPPLE_FRAMEWORK=ON -DCMAKE_INSTALL_PREFIX=install -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=../platforms/ios/cmake/Toolchains/Toolchain-iPhoneSimulator_Xcode.cmake ../
xcodebuild -arch x86_64 -arch i386 -sdk iphonesimulator -configuration Release -parallelizeTargets -jobs 4 ONLY_ACTIVE_ARCH=NO -target ALL_BUILD build OTHER_CFLAGS="$(inherited) -Wno-implicit-function-declaration"
mv ../build-iphoneos/install/ ../
cd ../install
lipo -create lib/libopencv_world.dylib ../build-iphonesimulator/lib/Release/libopencv_world.dylib -output lib/libopencv2.dylib
install_name_tool -id #rpath/libopencv2.dylib lib/libopencv2.dylib
-- Setting up iPhoneOS toolchain
-- iPhoneOS toolchain loaded
-- Setting up iPhoneOS toolchain
-- iPhoneOS toolchain loaded
-- The CXX compiler identification is AppleClang 9.0.0.9000039
-- The C compiler identification is AppleClang 9.0.0.9000039
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - failed
-- Detecting CXX compile features
-- Detecting CXX compile features - failed
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - failed
-- Detecting C compile features
-- Detecting C compile features - failed
-- Performing Test HAVE_CXX_FSIGNED_CHAR
-- Performing Test HAVE_CXX_FSIGNED_CHAR - Failed
-- Performing Test HAVE_C_FSIGNED_CHAR
...
-- Performing Test HAVE_CXX_FVISIBILITY_INLINES_HIDDEN - Failed
-- Performing Test HAVE_C_FVISIBILITY_INLINES_HIDDEN
-- Performing Test HAVE_C_FVISIBILITY_INLINES_HIDDEN - Failed
-- FP16: Compiler support is not available
-- Looking for fseeko
-- Looking for fseeko - not found
-- Looking for unistd.h
-- Looking for unistd.h - not found
-- Looking for sys/types.h
-- Looking for sys/types.h - not found
-- Looking for stdint.h
-- Looking for stdint.h - not found
-- Looking for stddef.h
-- Looking for stddef.h - not found
-- Check size of off64_t
-- Check size of off64_t - failed
-- Performing Test HAVE_C_WNO_SHORTEN_64_TO_32
-- Performing Test HAVE_C_WNO_SHORTEN_64_TO_32 - Failed
-- Performing Test HAVE_C_WNO_ATTRIBUTES
-- Performing Test HAVE_C_WNO_ATTRIBUTES - Failed
-- Performing Test HAVE_C_WNO_STRICT_PROTOTYPES
-- Performing Test HAVE_C_WNO_STRICT_PROTOTYPES - Failed
-- Performing Test HAVE_C_WNO_MISSING_PROTOTYPES
...
--
-- General configuration for OpenCV 3.1.0-dev =====================================
-- Version control: unknown
--
-- Platform:
-- Timestamp: 2018-01-17T00:03:59Z
-- Host: Darwin 17.3.0 x86_64
-- Target: iOS
-- CMake: 3.10.1
-- CMake generator: Xcode
-- CMake build tool: /usr/bin/xcodebuild
-- Xcode: 9.2
--
-- C/C++:
-- Built as dynamic libs?: YES
-- C++ Compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ (ver 9.0.0.9000039)
-- C++ flags (Release): -stdlib=libc++ -fvisibility=hidden -fvisibility-inlines-hidden -Wno-unused-function -Wno-overloaded-virtual -DNDEBUG -O3 -fomit-frame-pointer -ffast-math -DNDEBUG
-- C++ flags (Debug): -stdlib=libc++ -fvisibility=hidden -fvisibility-inlines-hidden -Wno-unused-function -Wno-overloaded-virtual -g -O0 -DDEBUG -D_DEBUG
-- C Compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang
-- C flags (Release): -O3 -DNDEBUG -DNDEBUG
-- C flags (Debug): -g -O0 -DDEBUG -D_DEBUG
-- Linker flags (Release):
-- Linker flags (Debug):
-- Precompiled headers: NO
-- Extra dependencies: -framework Accelerate -framework AVFoundation -framework CoreGraphics -framework CoreImage -framework CoreMedia -framework CoreVideo -framework QuartzCore -framework AssetsLibrary -framework UIKit
-- 3rdparty dependencies: libjpeg libpng zlib
--
-- OpenCV modules:
-- To be built: core flann imgproc ml photo video imgcodecs shape videoio highgui objdetect features2d calib3d stitching videostab world
-- Disabled: -
-- Disabled by dependency: -
-- Unavailable: cudaarithm cudabgsegm cudacodec cudafeatures2d cudafilters cudaimgproc cudalegacy cudaobjdetect cudaoptflow cudastereo cudawarping cudev java python2 superres ts viz
--
-- GUI:
-- Cocoa: YES
-- OpenGL support: NO
-- VTK support: NO
--
-- Media I/O:
-- ZLib: build (ver 1.2.8)
-- JPEG: build (ver 90)
-- WEBP: NO
-- PNG: build (ver 1.6.19)
-- TIFF: NO
-- JPEG 2000: NO
-- OpenEXR: NO
-- GDAL: NO
-- GDCM: NO
--
-- Video I/O:
-- AVFoundation: YES
-- GStreamer: NO
-- QuickTime: NO
-- QTKit: NO
-- V4L/V4L2: NO/NO
-- XIMEA: NO
-- gPhoto2: NO
--
-- Parallel framework: GCD
--
-- Other third-party libraries:
-- Use IPP: NO
-- Use VA: NO
-- Use Intel VA-API/OpenCL: NO
-- Use Lapack: NO
-- Use Eigen: NO
-- Use Cuda: NO
-- Use OpenCL: NO
-- Use custom HAL: NO
--
-- Python 2:
-- Interpreter: NO
--
-- Python 3:
-- Interpreter: NO
--
-- Python (for build): NO
--
-- Java:
-- ant: NO
-- JNI: NO
-- Java wrappers: NO
-- Java tests: NO
--
-- Matlab: NO
--
-- Documentation:
-- Doxygen: NO
-- PlantUML: NO
--
-- Tests and samples:
-- Tests: NO
-- Performance tests: NO
-- C/C++ Examples: NO
--
-- Install path: /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/install
--
-- cvconfig.h is in: /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos
-- -----------------------------------------------------------------
--
-- Configuring done
-- Generating done
-- Build files have been written to: /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos
User defaults from command line:
IDEBuildOperationMaxNumberOfConcurrentCompileTasks = 4
Build settings from command line:
ARCHS = armv7 armv7s arm64
ONLY_ACTIVE_ARCH = NO
OTHER_CFLAGS = -Wno-implicit-function-declaration
SDKROOT = iphoneos11.2
Build Preparation
Build task concurrency set to 4 via user default IDEBuildOperationMaxNumberOfConcurrentCompileTasks
=== BUILD AGGREGATE TARGET ZERO_CHECK OF PROJECT OpenCV WITH CONFIGURATION Release ===
Check dependencies
warning: iOS 11.2.0 does not support armv7
warning: iOS 11.2.0 does not support armv7s
Write auxiliary files
write-file /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/OpenCV.build/Release-iphoneos/ZERO_CHECK.build/Script-7DAC25DC952F47CE8C67268C.sh
chmod 0755 /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/OpenCV.build/Release-iphoneos/ZERO_CHECK.build/Script-7DAC25DC952F47CE8C67268C.sh
PhaseScriptExecution CMake\ Rules /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/OpenCV.build/Release-iphoneos/ZERO_CHECK.build/Script-7DAC25DC952F47CE8C67268C.sh
cd /var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS
/bin/sh -c /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/OpenCV.build/Release-iphoneos/ZERO_CHECK.build/Script-7DAC25DC952F47CE8C67268C.sh
echo ""
make -f /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/CMakeScripts/ReRunCMake.make
make[1]: `/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/CMakeFiles/cmake.check_cache' is up to date.
=== BUILD TARGET zlib OF PROJECT OpenCV WITH CONFIGURATION Release ===
Check dependencies
warning: iOS 11.2.0 does not support armv7
warning: iOS 11.2.0 does not support armv7s
Write auxiliary files
/bin/mkdir -p /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/arm64
write-file /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/arm64/zlib.LinkFileList
/bin/mkdir -p /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7
write-file /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/zlib.LinkFileList
/bin/mkdir -p /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7s
write-file /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7s/zlib.LinkFileList
CompileC /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/adler32.o 3rdparty/zlib/adler32.c normal armv7 c com.apple.compilers.llvm.clang.1_0.compiler
cd /var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS
export LANG=en_US.US-ASCII
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x c -arch armv7 -fmessage-length=0 -fdiagnostics-show-note-include-stack -fmacro-backtrace-limit=0 -Wno-trigraphs -fpascal-strings -O3 -Wno-missing-field-initializers -Wno-missing-prototypes -Wno-return-type -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wno-unused-variable -Wunused-value -Wno-empty-body -Wno-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wno-constant-conversion -Wno-int-conversion -Wno-bool-conversion -Wno-enum-conversion -Wno-float-conversion -Wno-non-literal-null-conversion -Wno-objc-literal-conversion -Wno-shorten-64-to-32 -Wpointer-sign -Wno-newline-eof -DCMAKE_INTDIR=\"Release-iphoneos\" -DNO_FSEEKO -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS11.2.sdk -fstrict-aliasing -Wdeprecated-declarations -miphoneos-version-min=11.2 -Wno-sign-conversion -Wno-infinite-recursion -Wno-comma -Wno-block-capture-autoreleasing -Wno-strict-prototypes -fembed-bitcode-marker -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/lib/Release/include -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/3rdparty/zlib -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/DerivedSources/armv7 -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/DerivedSources -Wmost -Wno-four-char-constants -Wno-unknown-pragmas -F/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/lib/Release -Wno-implicit-function-declaration -MMD -MT dependencies -MF /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/adler32.d --serialize-diagnostics /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/adler32.dia -c /var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/3rdparty/zlib/adler32.c -o /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/adler32.o
clang: error: invalid iOS deployment version '-miphoneos-version-min=11.2', iOS 10 is the maximum deployment target for 32-bit targets [-Winvalid-ios-deployment-target]
CompileC /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/compress.o 3rdparty/zlib/compress.c normal armv7 c com.apple.compilers.llvm.clang.1_0.compiler
cd /var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS
export LANG=en_US.US-ASCII
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x c -arch armv7 -fmessage-length=0 -fdiagnostics-show-note-include-stack -fmacro-backtrace-limit=0 -Wno-trigraphs -fpascal-strings -O3 -Wno-missing-field-initializers -Wno-missing-prototypes -Wno-return-type -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wno-unused-variable -Wunused-value -Wno-empty-body -Wno-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wno-constant-conversion -Wno-int-conversion -Wno-bool-conversion -Wno-enum-conversion -Wno-float-conversion -Wno-non-literal-null-conversion -Wno-objc-literal-conversion -Wno-shorten-64-to-32 -Wpointer-sign -Wno-newline-eof -DCMAKE_INTDIR=\"Release-iphoneos\" -DNO_FSEEKO -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS11.2.sdk -fstrict-aliasing -Wdeprecated-declarations -miphoneos-version-min=11.2 -Wno-sign-conversion -Wno-infinite-recursion -Wno-comma -Wno-block-capture-autoreleasing -Wno-strict-prototypes -fembed-bitcode-marker -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/lib/Release/include -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/3rdparty/zlib -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/DerivedSources/armv7 -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/DerivedSources -Wmost -Wno-four-char-constants -Wno-unknown-pragmas -F/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/lib/Release -Wno-implicit-function-declaration -MMD -MT dependencies -MF /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/compress.d --serialize-diagnostics /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/compress.dia -c /var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/3rdparty/zlib/compress.c -o /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/compress.o
clang: error: invalid iOS deployment version '-miphoneos-version-min=11.2', iOS 10 is the maximum deployment target for 32-bit targets [-Winvalid-ios-deployment-target]
CompileC /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/crc32.o 3rdparty/zlib/crc32.c normal armv7 c com.apple.compilers.llvm.clang.1_0.compiler
cd /var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS
export LANG=en_US.US-ASCII
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x c -arch armv7 -fmessage-length=0 -fdiagnostics-show-note-include-stack -fmacro-backtrace-limit=0 -Wno-trigraphs -fpascal-strings -O3 -Wno-missing-field-initializers -Wno-missing-prototypes -Wno-return-type -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wno-unused-variable -Wunused-value -Wno-empty-body -Wno-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wno-constant-conversion -Wno-int-conversion -Wno-bool-conversion -Wno-enum-conversion -Wno-float-conversion -Wno-non-literal-null-conversion -Wno-objc-literal-conversion -Wno-shorten-64-to-32 -Wpointer-sign -Wno-newline-eof -DCMAKE_INTDIR=\"Release-iphoneos\" -DNO_FSEEKO -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS11.2.sdk -fstrict-aliasing -Wdeprecated-declarations -miphoneos-version-min=11.2 -Wno-sign-conversion -Wno-infinite-recursion -Wno-comma -Wno-block-capture-autoreleasing -Wno-strict-prototypes -fembed-bitcode-marker -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/lib/Release/include -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/3rdparty/zlib -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/DerivedSources/armv7 -I/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/DerivedSources -Wmost -Wno-four-char-constants -Wno-unknown-pragmas -F/private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/lib/Release -Wno-implicit-function-declaration -MMD -MT dependencies -MF /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/crc32.d --serialize-diagnostics /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/crc32.dia -c /var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/3rdparty/zlib/crc32.c -o /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/crc32.o
clang: error: invalid iOS deployment version '-miphoneos-version-min=11.2', iOS 10 is the maximum deployment target for 32-bit targets [-Winvalid-ios-deployment-target]
CompileC /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/deflate.o 3rdparty/zlib/deflate.c normal armv7 c com.apple.compilers.llvm.clang.1_0.compiler
cd /var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS
export LANG=en_US.US-ASCII
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin"
...
=== BUILD TARGET libjpeg OF PROJECT OpenCV WITH CONFIGURATION Release ===
Check dependencies
warning: iOS 11.2.0 does not support armv7
warning: iOS 11.2.0 does not support armv7s
Write auxiliary files
/bin/mkdir -p /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/libjpeg/OpenCV.build/Release-iphoneos/libjpeg.build/Objects-normal/armv7
write-file /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/libjpeg/OpenCV.build/Release-iphoneos/libjpeg.build/Objects-normal/armv7/libjpeg.LinkFileList
/bin/mkdir -p /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/libjpeg/OpenCV.build/Release-iphoneos/libjpeg.build/Objects-normal/armv7s
write-file /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/libjpeg/OpenCV.build/Release-iphoneos/libjpeg.build/Objects-normal/armv7s/libjpeg.LinkFileList
/bin/mkdir -p /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/libjpeg/OpenCV.build/Release-iphoneos/libjpeg.build/Objects-normal/arm64
write-file /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/libjpeg/OpenCV.build/Release-iphoneos/libjpeg.build/Objects-normal/arm64/libjpeg.LinkFileList
CMake Deprecation Warning at CMakeLists.txt:72 (cmake_policy):
The OLD behavior for policy CMP0020 will be removed from a future version
of CMake.
The cmake-policies(7) manual explains that the OLD behaviors of all
policies are deprecated and that a policy should be set to OLD only under
specific short-term circumstances. Projects should be ported to the NEW
behavior and not rely on setting a policy to OLD.
CMake Deprecation Warning at CMakeLists.txt:76 (cmake_policy):
The OLD behavior for policy CMP0022 will be removed from a future version
of CMake.
The cmake-policies(7) manual explains that the OLD behaviors of all
policies are deprecated and that a policy should be set to OLD only under
specific short-term circumstances. Projects should be ported to the NEW
behavior and not rely on setting a policy to OLD.
CMake Deprecation Warning at CMakeLists.txt:81 (cmake_policy):
The OLD behavior for policy CMP0026 will be removed from a future version
of CMake.
The cmake-policies(7) manual explains that the OLD behaviors of all
policies are deprecated and that a policy should be set to OLD only under
specific short-term circumstances. Projects should be ported to the NEW
behavior and not rely on setting a policy to OLD.
/bin/bash: line 5: inherited: command not found
** BUILD FAILED **
The following build commands failed:
CompileC /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/adler32.o 3rdparty/zlib/adler32.c normal armv7 c com.apple.compilers.llvm.clang.1_0.compiler
CompileC /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/compress.o 3rdparty/zlib/compress.c normal armv7 c com.apple.compilers.llvm.clang.1_0.compiler
CompileC /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/crc32.o 3rdparty/zlib/crc32.c normal armv7 c com.apple.compilers.llvm.clang.1_0.compiler
CompileC /private/var/folders/lb/2_dfvxbj1bz6jl33bdhktfy40000gq/T/CocoaPods/Try/OpenCV-iOS/build-iphoneos/3rdparty/zlib/OpenCV.build/Release-iphoneos/zlib.build/Objects-normal/armv7/deflate.o 3rdparty/zlib/deflate.c normal armv7 c com.apple.compilers.llvm.clang.1_0.compiler
(4 failures)
I have installed make using the CMake installer and then install the command line tools by pasting this in terminal sudo "/Applications/CMake.app/Contents/bin/cmake-gui" --install. I have also run the Xcode-select --install command. I am staring to believe that the there is something wrong with how I installed cmake. I tried reinstalling using homebrew which did not work.
Is there anything I need to do after running the install command?
Could there be another problem?
Related
Description
I'm trying build iphonesimulator-only targeted library witn architecture arm64, but linking step failed with error:
${LDCMD:-/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang} -O3 -fvisibility=hidden -miphoneos-version-min=9.0 -fembed-bitcode -fPIC -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.5.sdk -L. -Wl,-search_paths_first \
-o apps/openssl apps/asn1pars.o apps/ca.o apps/ciphers.o apps/cms.o apps/crl.o apps/crl2p7.o apps/dgst.o apps/dhparam.o apps/dsa.o apps/dsaparam.o apps/ec.o apps/ecparam.o apps/enc.o apps/errstr.o apps/gendsa.o apps/genpkey.o apps/genrsa.o apps/nseq.o apps/ocsp.o apps/openssl.o apps/passwd.o apps/pkcs12.o apps/pkcs7.o apps/pkcs8.o apps/pkey.o apps/pkeyparam.o apps/pkeyutl.o apps/prime.o apps/rand.o apps/rehash.o apps/req.o apps/rsa.o apps/rsautl.o apps/s_client.o apps/s_server.o apps/s_time.o apps/sess_id.o apps/smime.o apps/speed.o apps/spkac.o apps/srp.o apps/storeutl.o apps/ts.o apps/verify.o apps/version.o apps/x509.o \
apps/libapps.a -lssl -lcrypto
ld: building for iOS, but linking in .tbd file (/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.5.sdk/usr/lib/libSystem.tbd) built for iOS Simulator, file '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.5.sdk/usr/lib/libSystem.tbd' for architecture arm64
Configuraton command:
./Configure iossimulator-xcrun threads no-shared "-fvisibility=hidden -miphoneos-version-min=9.0 -fembed-bitcode -fPIC" no-asm no-hw no-async --prefix=/Users/macosuser/Build/OpenSSL/Install "-arch arm64" "-isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.5.sdk"
Configuring OpenSSL version 1.1.1j (0x101010afL) for iossimulator-xcrun
Using os-specific seed configuration
Creating configdata.pm
Creating Makefile
Build commands look like this:
...
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -I. -Iinclude -Iapps -O3 -fvisibility=hidden -miphoneos-version-min=9.0 -fembed-bitcode -fPIC -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.5.sdk -D_REENTRANT -DNDEBUG -MMD -MF apps/x509.d.tmp -MT apps/x509.o -c -o apps/x509.o apps/x509.c
...
Question
I can't figure out why for other architectures (i386, x86_64) the build happens without problems.
Perhaps I am missing some nuance, but I cannot understand which one.
Why do I need this - an application using this library must run on a simulator in a macbook with an M1 processor.
Environment specifications
MacOS 11.4
XCode v12.5
OpenSSL v1.1.1j
Compiler - AppleClang 12.0.5.12050022
Because i'm not an iOS developer, i didn't immediately understand the specifics of building libraries through make for this platform.
The problem was this:
-miphoneos-version-min specifies the deployment target for iOS, but since i am building library for the iOS simulator, me need to use -mios-simulator-version-min.
As a result, the configuration command should look like this:
./Configure iossimulator-xcrun threads no-shared "-fvisibility=hidden -mios-simulator-version-min=9.0 -fembed-bitcode -fPIC" no-asm no-hw no-async --prefix=/Users/macosuser/Build/OpenSSL/Install "-arch arm64" "-isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.5.sdk"
If anyone can explain why the -miphoneos-version-min flag works as expected for i386 and x86_64 architectures, i would be grateful.
I'm needing to use custom libc++ so I'm passing -nostdinc++ for CMAKE_CXX_FLAGS. This works fine for libraries but for executables, I get this warning:
clang: warning: argument unused during compilation: '-nostdinc++' [-Wunused-command-line-argument]
Question: Why?
More details
My CMAKE_CXX_FLAGS flags passed to compiler are:
set(CMAKE_CXX_FLAGS "-nostdinc++ -isystem ${LIBCXX_INC_PATH}")
My CMAKE_EXE_LINKER_FLAGS flags passed to linked are:
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -stdlib=libc++ -lc++ -lc++abi -lm -lc -lgcc_s -lgcc -ldl -Wl,-rpath,${LIBCXX_LIB_PATH}")
Clang verbos output:
Scanning dependencies of target DroneServer
[ 98%] Building CXX object DroneServer/CMakeFiles/DroneServer.dir/home/shitals/GitHubSrc/AirSim/DroneServer/main.cpp.o
clang version 3.9.1-4ubuntu3~16.04.1 (tags/RELEASE_391/rc2)
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/bin
Found candidate GCC installation: /usr/bin/../lib/gcc/x86_64-linux-gnu/5
Found candidate GCC installation: /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0
Found candidate GCC installation: /usr/bin/../lib/gcc/x86_64-linux-gnu/6
Found candidate GCC installation: /usr/bin/../lib/gcc/x86_64-linux-gnu/6.0.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5.4.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6.0.0
Selected GCC installation: /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0
Candidate multilib: .;#m64
Selected multilib: .;#m64
"/usr/lib/llvm-3.9/bin/clang" -cc1 -triple x86_64-pc-linux-gnu -emit-obj -mrelax-all -disable-free -disable-llvm-verifier -discard-value-names -main-file-name main.cpp -mrelocation-model pic -pic-level 2 -pic-is-pie -mthread-model posix -mdisable-fp-elim -fmath-errno -masm-verbose -mconstructor-aliases -munwind-tables -fuse-init-array -target-cpu x86-64 -v -dwarf-column-info -debug-info-kind=limited -dwarf-version=4 -debugger-tuning=gdb -coverage-file /home/shitals/GitHubSrc/AirSim/build_debug/DroneServer/CMakeFiles/DroneServer.dir/home/shitals/GitHubSrc/AirSim/DroneServer/main.cpp.o -nostdinc++ -resource-dir /usr/lib/llvm-3.9/bin/../lib/clang/3.9.1 -isystem /home/shitals/GitHubSrc/AirSim/llvm-build/output/include/c++/v1 -I /home/shitals/GitHubSrc/AirSim/eigen/eigen3 -I /home/shitals/GitHubSrc/AirSim/DroneServer -I /home/shitals/GitHubSrc/AirSim/MavLinkCom/include -I /home/shitals/GitHubSrc/AirSim/external/rpclib/include -I /home/shitals/GitHubSrc/AirSim/AirLib/include -D __CLANG__ -D MSGPACK_PP_VARIADICS_MSVC=0 -internal-isystem /usr/local/include -internal-isystem /usr/lib/llvm-3.9/bin/../lib/clang/3.9.1/include -internal-externc-isystem /usr/include/x86_64-linux-gnu -internal-externc-isystem /include -internal-externc-isystem /usr/include -Wall -Wextra -Wstrict-aliasing -Wunreachable-code -Wcast-qual -Wctor-dtor-privacy -Wdisabled-optimization -Wformat=2 -Winit-self -Wmissing-include-dirs -Wswitch-default -Wold-style-cast -Woverloaded-virtual -Wredundant-decls -Wshadow -Wstrict-overflow=5 -Wswitch-default -Wundef -Wno-variadic-macros -Wno-parentheses -Wno-unused-function -Wno-unused -Wno-documentation -std=c++14 -fdeprecated-macro -fdebug-compilation-dir /home/shitals/GitHubSrc/AirSim/build_debug/DroneServer -ferror-limit 10 -fmessage-length 286 -pthread -fobjc-runtime=gcc -fcxx-exceptions -fexceptions -fdiagnostics-show-option -fcolor-diagnostics -o CMakeFiles/DroneServer.dir/home/shitals/GitHubSrc/AirSim/DroneServer/main.cpp.o -x c++ /home/shitals/GitHubSrc/AirSim/DroneServer/main.cpp
clang -cc1 version 3.9.1 based upon LLVM 3.9.1 default target x86_64-pc-linux-gnu
ignoring nonexistent directory "/include"
#include "..." search starts here:
#include <...> search starts here:
/home/shitals/GitHubSrc/AirSim/eigen/eigen3
/home/shitals/GitHubSrc/AirSim/DroneServer
/home/shitals/GitHubSrc/AirSim/MavLinkCom/include
/home/shitals/GitHubSrc/AirSim/external/rpclib/include
/home/shitals/GitHubSrc/AirSim/AirLib/include
/home/shitals/GitHubSrc/AirSim/llvm-build/output/include/c++/v1
/usr/local/include
/usr/lib/llvm-3.9/bin/../lib/clang/3.9.1/include
/usr/include/x86_64-linux-gnu
/usr/include
End of search list.
[100%] Linking CXX executable ../output/bin/DroneServer
clang version 3.9.1-4ubuntu3~16.04.1 (tags/RELEASE_391/rc2)
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/bin
Found candidate GCC installation: /usr/bin/../lib/gcc/x86_64-linux-gnu/5
Found candidate GCC installation: /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0
Found candidate GCC installation: /usr/bin/../lib/gcc/x86_64-linux-gnu/6
Found candidate GCC installation: /usr/bin/../lib/gcc/x86_64-linux-gnu/6.0.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5.4.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6.0.0
Selected GCC installation: /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0
Candidate multilib: .;#m64
Selected multilib: .;#m64
clang: warning: argument unused during compilation: '-nostdinc++' [-Wunused-command-line-argument]
"/usr/bin/ld" -z relro --hash-style=gnu --eh-frame-hdr -m elf_x86_64 -dynamic-linker /lib64/ld-linux-x86-64.so.2 -o ../output/bin/DroneServer /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/../../../x86_64-linux-gnu/crt1.o /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/../../../x86_64-linux-gnu/crti.o /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/crtbegin.o -L/usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0 -L/usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/../../../x86_64-linux-gnu -L/lib/x86_64-linux-gnu -L/lib/../lib64 -L/usr/lib/x86_64-linux-gnu -L/usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/../../.. -L/usr/lib/llvm-3.9/bin/../lib -L/lib -L/usr/lib -lc++ -lc++abi -lm -lc -lgcc_s -lgcc -ldl -rpath /home/shitals/GitHubSrc/AirSim/llvm-build/output/lib CMakeFiles/DroneServer.dir/home/shitals/GitHubSrc/AirSim/DroneServer/main.cpp.o -lpthread ../output/lib/libAirLib.a ../output/lib/libMavLinkCom.a ../output/lib/libAirSim-rpclib.a -lpthread -lpthread -lc++ -lm -lgcc_s -lgcc -lpthread -lc -lgcc_s -lgcc /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/crtend.o /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/../../../x86_64-linux-gnu/crtn.o
[100%] Built target DroneServer
I am using an OpenSUSE 13.2-X86-64 and a Geforce 940M GPU. I want to work with it on the Qt5 IDE.
For this purpose, i have installed my GPU Driver with the Cuda7.5 toolkit rpm from the cudazone. Everything is nearly fine.
It detects everything I have made and executed a couple of the cuda samples.
As next step, i have installed the current FFmpeg version with nvenc and other libraries like Xvid and many of
the other usefull stuff which would be to much to list it here. After that i have downloaded the current
OpenCV-3.0.0 source code and ran cmake-gui where i have added cuda, ffmpeg, Qt5 etc and maked it.
On different points of the make session (make -j4) i get this kind of mistake from my console (The list of the Multiple definition
error is much longer). This is the first one.
.
.
.
.
.
.
nvlink error : Multiple definition of '_ZN2cv5cudev16color_cvt_detail15c_HlsSectorDataE' in '/home/peter/Programme/opencv/build/modules/cudev/test/CMakeFiles/opencv_test_cudev.dir//./opencv_test_cudev_generated_test_arithm_func.cu.o', first defined in '/home/peter/Programme/opencv/build/modules/cudev/test/CMakeFiles/opencv_test_cudev.dir//./opencv_test_cudev_generated_test_lut.cu.o'
nvlink error : Multiple definition of '_ZN2cv5cudev16color_cvt_detail16c_sRGBGammaTab_bE' in '/home/peter/Programme/opencv/build/modules/cudev/test/CMakeFiles/opencv_test_cudev.dir//./opencv_test_cudev_generated_test_arithm_func.cu.o', first defined in '/home/peter/Programme/opencv/build/modules/cudev/test/CMakeFiles/opencv_test_cudev.dir//./opencv_test_cudev_generated_test_lut.cu.o'
nvlink error : Multiple definition of '_ZN2cv5cudev16color_cvt_detail14c_sRGBGammaTabE' in '/home/peter/Programme/opencv/build/modules/cudev/test/CMakeFiles/opencv_test_cudev.dir//./opencv_test_cudev_generated_test_arithm_func.cu.o', first defined in '/home/peter/Programme/opencv/build/modules/cudev/test/CMakeFiles/opencv_test_cudev.dir//./opencv_test_cudev_generated_test_lut.cu.o'
nvlink error : Multiple definition of '_ZN2cv5cudev16color_cvt_detail17c_sRGBInvGammaTabE' in '/home/peter/Programme/opencv/build/modules/cudev/test/CMakeFiles/opencv_test_cudev.dir//./opencv_test_cudev_generated_test_arithm_func.cu.o', first defined in '/home/peter/Programme/opencv/build/modules/cudev/test/CMakeFiles/opencv_test_cudev.dir//./opencv_test_cudev_generated_test_lut.cu.o'
nvlink error : Multiple definition of '_ZN2cv5cudev16color_cvt_detail12c_LabCbrtTabE' in '/home/peter/Programme/opencv/build/modules/cudev/test/CMakeFiles/opencv_test_cudev.dir//./opencv_test_cudev_generated_test_arithm_func.cu.o', first defined in '/home/peter/Programme/opencv/build/modules/cudev/test/CMakeFiles/opencv_test_cudev.dir//./opencv_test_cudev_generated_test_lut.cu.o'
modules/cudev/test/CMakeFiles/opencv_test_cudev.dir/build.make:5302: recipe for target 'modules/cudev/test/CMakeFiles/opencv_test_cudev.dir/./opencv_test_cudev_intermediate_link.o' failed
make[2]: *** [modules/cudev/test/CMakeFiles/opencv_test_cudev.dir/./opencv_test_cudev_intermediate_link.o] Error 255
CMakeFiles/Makefile2:1182: recipe for target 'modules/cudev/test/CMakeFiles/opencv_test_cudev.dir/all' failed
make[1]: *** [modules/cudev/test/CMakeFiles/opencv_test_cudev.dir/all] Error 2
Makefile:137: recipe for target 'all' failed
make: *** [all] Error 2
And I have no idea how to fix that.
Thx!
Edit: added cmake configuration
~/Programme/opencv/build> cmake /home/peter/Programme/opencv-3.0.0
CMake Error: The source "/home/peter/Programme/opencv-3.0.0/CMakeLists.txt" does not match the source "/home/peter/Programme/opencv/CMakeLists.txt" used to generate cache. Re-run cmake with a different source directory.
peter#linux-3mgc:~/Programme/opencv/build> cmake /home/peter/Programme/opencv
-- Detected version of GNU GCC: 48 (408)
-- Found ZLIB: /usr/lib64/libz.so (found suitable version "1.2.8", minimum required is "1.2.3")
-- Found ZLIB: /usr/lib64/libz.so (found version "1.2.8")
-- checking for module 'gstreamer-video-0.10'
-- package 'gstreamer-video-0.10' not found
-- checking for module 'gstreamer-app-0.10'
-- package 'gstreamer-app-0.10' not found
-- checking for module 'gstreamer-riff-0.10'
-- package 'gstreamer-riff-0.10' not found
-- checking for module 'gstreamer-pbutils-0.10'
-- package 'gstreamer-pbutils-0.10' not found
-- Looking for linux/videodev.h
-- Looking for linux/videodev.h - not found
-- Looking for linux/videodev2.h
-- Looking for linux/videodev2.h - found
-- Looking for sys/videoio.h
-- Looking for sys/videoio.h - not found
-- checking for module 'libavresample'
-- package 'libavresample' not found
-- Looking for libavformat/avformat.h
-- Looking for libavformat/avformat.h - found
-- Looking for ffmpeg/avformat.h
-- Looking for ffmpeg/avformat.h - not found
-- found IPP (ICV version): 8.2.1 [8.2.1]
-- at: /home/peter/Programme/opencv/3rdparty/ippicv/unpack/ippicv_lnx
-- CUDA detected: 7.5
-- CUDA NVCC target flags: -gencode;arch=compute_50,code=sm_50
-- To enable PlantUML support, set PLANTUML_JAR environment variable or pass -DPLANTUML_JAR=<filepath> option to cmake
-- Found PythonInterp: /usr/bin/python2.7 (found suitable version "2.7.8", minimum required is "2.7")
-- Found PythonLibs: /usr/lib64/libpython2.7.so (found suitable exact version "2.7.8")
-- Found PythonInterp: /usr/bin/python3.4 (found suitable version "3.4.1", minimum required is "3.4")
-- Found PythonLibs: /usr/lib64/libpython3.4m.so (found suitable exact version "3.4.1")
Traceback (most recent call last):
File "<string>", line 1, in <module>
ImportError: No module named 'numpy'
-- Found apache ant 1.8.0: /usr/bin/ant
-- Could NOT find JNI (missing: JAVA_INCLUDE_PATH JAVA_INCLUDE_PATH2 JAVA_AWT_INCLUDE_PATH)
-- Could NOT find Matlab (missing: MATLAB_MEX_SCRIPT MATLAB_INCLUDE_DIRS MATLAB_ROOT_DIR MATLAB_LIBRARIES MATLAB_LIBRARY_DIRS MATLAB_MEXEXT MATLAB_ARCH MATLAB_BIN)
-- VTK support is disabled. Incompatible combination: OpenCV + Qt5 and VTK ver.6.1.0 + Qt4
--
-- General configuration for OpenCV 3.0.0-dev =====================================
-- Version control: 3.0.0-528-g3a3f403-dirty
--
-- Platform:
-- Host: Linux 3.16.7-24-desktop x86_64
-- CMake: 3.0.2
-- CMake generator: Unix Makefiles
-- CMake build tool: /usr/bin/gmake
-- Configuration: Release
--
-- C/C++:
-- Built as dynamic libs?: YES
-- C++ Compiler: /usr/bin/c++ (ver 4.8.3)
-- C++ flags (Release): -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wshadow -Wsign-promo -Wno-narrowing -Wno-delete-non-virtual-dtor -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -msse -msse2 -mno-avx -msse3 -mno-ssse3 -mno-sse4.1 -mno-sse4.2 -ffunction-sections -fvisibility=hidden -fvisibility-inlines-hidden -fopenmp -O3 -DNDEBUG -DNDEBUG
-- C++ flags (Debug): -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wshadow -Wsign-promo -Wno-narrowing -Wno-delete-non-virtual-dtor -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -msse -msse2 -mno-avx -msse3 -mno-ssse3 -mno-sse4.1 -mno-sse4.2 -ffunction-sections -fvisibility=hidden -fvisibility-inlines-hidden -fopenmp -g -O0 -DDEBUG -D_DEBUG
-- C Compiler: /usr/bin/cc
-- C flags (Release): -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wshadow -Wno-narrowing -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -msse -msse2 -mno-avx -msse3 -mno-ssse3 -mno-sse4.1 -mno-sse4.2 -ffunction-sections -fvisibility=hidden -fopenmp -O3 -DNDEBUG -DNDEBUG
-- C flags (Debug): -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wshadow -Wno-narrowing -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -msse -msse2 -mno-avx -msse3 -mno-ssse3 -mno-sse4.1 -mno-sse4.2 -ffunction-sections -fvisibility=hidden -fopenmp -g -O0 -DDEBUG -D_DEBUG
-- Linker flags (Release):
-- Linker flags (Debug):
-- Precompiled headers: YES
-- Extra dependencies: /usr/lib64/libcuda.so /usr/lib64/libnvcuvid.so Qt5::Core Qt5::Gui Qt5::Widgets Qt5::Test Qt5::Concurrent Qt5::OpenGL /usr/lib64/libwebp.so /usr/lib64/libpng.so /usr/lib64/libz.so /usr/lib64/libtiff.so /usr/lib64/libjasper.so /usr/lib64/libjpeg.so gstbase-0.10 gstreamer-0.10 gobject-2.0 gmodule-2.0 gthread-2.0 xml2 ucil glib-2.0 unicap dc1394 xine v4l1 v4l2 avcodec avformat avutil swscale gphoto2 gphoto2_port exif /usr/lib64/libbz2.so dl m pthread rt /usr/lib64/libGLU.so /usr/lib64/libGL.so /usr/lib64/libSM.so /usr/lib64/libICE.so /usr/lib64/libX11.so /usr/lib64/libXext.so cudart nppc nppi npps cublas cufft
-- 3rdparty dependencies: IlmImf ippicv
--
-- OpenCV modules:
-- To be built: cudev hal core cudaarithm flann imgproc ml video cudabgsegm cudafilters cudaimgproc cudawarping imgcodecs photo shape videoio cudacodec highgui objdetect ts features2d calib3d cudafeatures2d cudalegacy cudaobjdetect cudaoptflow cudastereo stitching superres videostab python2
-- Disabled: world
-- Disabled by dependency: -
-- Unavailable: java python3 viz
--
-- GUI:
-- QT 5.x: YES (ver 5.4.2)
-- QT OpenGL support: YES (Qt5::OpenGL 5.4.2)
-- OpenGL support: YES (/usr/lib64/libGLU.so /usr/lib64/libGL.so /usr/lib64/libSM.so /usr/lib64/libICE.so /usr/lib64/libX11.so /usr/lib64/libXext.so)
-- VTK support: NO
--
-- Media I/O:
-- ZLib: /usr/lib64/libz.so (ver 1.2.8)
-- JPEG: /usr/lib64/libjpeg.so (ver )
-- WEBP: /usr/lib64/libwebp.so (ver encoder: 0x0202)
-- PNG: /usr/lib64/libpng.so (ver 1.2.51)
-- TIFF: /usr/lib64/libtiff.so (ver 42 - 4.0.4)
-- JPEG 2000: /usr/lib64/libjasper.so (ver 1.900.1)
-- OpenEXR: build (ver 1.7.1)
-- GDAL: NO
--
-- Video I/O:
-- DC1394 1.x: NO
-- DC1394 2.x: YES (ver 2.2.2)
-- FFMPEG: YES
-- codec: YES (ver 57.3.100)
-- format: YES (ver 57.2.100)
-- util: YES (ver 55.2.100)
-- swscale: YES (ver 4.0.100)
-- resample: NO
-- gentoo-style: YES
-- GStreamer: NO
-- OpenNI: NO
-- OpenNI PrimeSensor Modules: NO
-- OpenNI2: NO
-- PvAPI: NO
-- GigEVisionSDK: NO
-- UniCap: YES (ver 0.9.12)
-- UniCap ucil: YES (ver 0.9.10)
-- V4L/V4L2: Using libv4l1 (ver 1.2.1) / libv4l2 (ver 1.2.1)
-- XIMEA: NO
-- Xine: YES (ver 1.2.6)
-- gPhoto2: YES
--
-- Parallel framework: OpenMP
--
-- Other third-party libraries:
-- Use IPP: 8.2.1 [8.2.1]
-- at: /home/peter/Programme/opencv/3rdparty/ippicv/unpack/ippicv_lnx
-- Use IPP Async: NO
-- Use VA: NO
-- Use Intel VA-API/OpenCL: NO
-- Use Eigen: YES (ver 3.2.2)
-- Use Cuda: YES (ver 7.5)
-- Use OpenCL: YES
--
-- NVIDIA CUDA
-- Use CUFFT: YES
-- Use CUBLAS: YES
-- USE NVCUVID: YES
-- NVIDIA GPU arch: 50
-- NVIDIA PTX archs:
-- Use fast math: YES
--
-- OpenCL:
-- Version: dynamic
-- Include path: /home/peter/Programme/opencv/3rdparty/include/opencl/1.2
-- Use AMDFFT: NO
-- Use AMDBLAS: NO
--
-- Python 2:
-- Interpreter: /usr/bin/python2.7 (ver 2.7.8)
-- Libraries: /usr/lib64/libpython2.7.so (ver 2.7.8)
-- numpy: /usr/lib64/python2.7/site-packages/numpy/core/include (ver 1.9.0)
-- packages path: lib/python2.7/site-packages
--
-- Python 3:
-- Interpreter: /usr/bin/python3.4 (ver 3.4.1)
--
-- Python (for build): /usr/bin/python2.7
--
-- Java:
-- ant: /usr/bin/ant (ver 1.8.0)
-- JNI: NO
-- Java wrappers: NO
-- Java tests: NO
--
-- Matlab:
-- mex: NO
--
-- Documentation:
-- Doxygen: /usr/bin/doxygen (ver 1.8.8)
-- PlantUML: NO
--
-- Tests and samples:
-- Tests: YES
-- Performance tests: YES
-- C/C++ Examples: NO
--
-- Install path: /usr/local
--
-- cvconfig.h is in: /home/peter/Programme/opencv/build
--
-----------------------------------------------------------------
--
-- Configuring done
-- Generating done
-- Build files have been written to: /home/peter/Programme/opencv/build
So after trying and trying again i have solved the problem on a different way. I stepped back from opencv3 to 2.4.11, i stepped back from the latest ffmpeg (this solved a lot of issues). Another problem was that an installed openv-2.4.9 version always wanted to be used and not my cuda compiled libraries. I am not a guy who wants to read in cmakefiles. OpenCV has a whole bunch of that so more than the cmake would definitly a big land of confusion for me.
Nevertheless i have solved my issues. Not with OpenCV3 but with opencv-2.4.11, Cuda-5.0 and which would be enough for my purposes. To get run this combination i wrote some shell scripts to feed back my self and analyse for issues. This file you should run as superuser and replace the name of the user of course or install the files maybe in your custom system.
-- Please not that you maybe have to restart bumbleed daemon,to use mkinitrd and to reboot another time. The second forced installation was done because of the instruction like here --> https://en.opensuse.org/SDB:NVIDIA_Bumblebee
in the endsection. It is proposed if you want to use cuda development.
After this you have to reboot to get it done.
mkdir /home/peter/programs
cd /home/peter/programs
# 3rd part library and qt library packages installed. Not even sure that everyone is needed
zypper --non-interactive in gcc git libwebp-devel vtk vtk-devel eigen3-devel libeigen2-devel python-numpy-devel python python3-numpy python3-numpy-devel ant java-1_7_0-openjdk-devel java-1_7_0-openjdk-src python-Sphinx openexr openexr-devel libpng12-devel openjpeg openjpeg-devel tiff jasper libjasper-devel pbzip2 python3-cairo python3-cairo-devel ilmbase-devel cmake-gui gtk2-devel libdc1394 libdc1394-devel libv4l-devel libxine-devel gstreamer-0_10-devel gstreamer-devel openmpi openmpi-devel openmpi-libs VirtualGL-devel Mesa-libGLESv3-devel ftgl-devel glew glproto-devel gltt gltt-devel gtkglext-devel libGLw1 libftgl2 libglfw-devel libgltf-devel python-opengl gluegen2 gluegen2-devel libjnidispatch gphoto libgphoto2-devel libunicap2 libunicap-devel libucil-devel libucil2 zypper libbz2-devel doxygen jna zypper libQt5Bluetooth5 libQt5Bootstrap-devel-static libQt5Concurrent-devel libQt5Concurrent5 libQt5Core-devel libQt5Core-private-headers-devel libQt5Designer5 libQt5DesignerComponents5 libQt5Gui-devel libQt5Gui-private-headers-devel libQt5Help5 libQt5Network-devel libQt5Network-private-headers-devel libQt5Network5 libQt5OpenGL-devel libQt5OpenGL-private-headers-devel libQt5OpenGL5 libQt5OpenGLExtensions-devel-static libQt5PlatformHeaders-devel libQt5PlatformSupport-devel-static libQt5PlatformSupport-private-headers-devel libQt5Widgets-devel libqt5-creator libqt5-qtdoc libqt5-qttools libqt5-qttools-devel python-qt5 python-qt5-devel python-qt5-utils freetype freetype-devel freetype2-devel dpic libvpx1 libvpx-devel nasm yasm libopus-devel autoconf automake libass-devel libfreetype6 libSDL-devel libSDL2-devel libtheora-devel libtool libva1 libva-devel libtool libvdpau-devel libvorbis-devel libxcb-devel libxcb-shm0 libxcb-xfixes0 pkg-config latex2html zlib zlib-devel
# downloading and preparing libs that should be installed form the scratch
wget http://developer.download.nvidia.com/compute/cuda/repos/opensuse132/x86_64/cuda-repo-opensuse132-7.5-18.x86_64.rpm
mkdir SDK
cd SDK
wget http://developer.download.nvidia.com/compute/nvenc/v5.0/nvenc_5.0.1_sdk.zip -O nvenc-sdk.zip
unzip nvenc-sdk.zip
cd nvenc_5.0.1_sdk
cd /home/peter/programs
wget http://download.videolan.org/pub/x264/snapshots/last_x264.tar.bz2
tar xjvf last_x264.tar.bz2
wget -O fdk-aac.zip https://github.com/mstorsjo/fdk-aac/zipball/master
unzip fdk-aac.zip
wget http://downloads.sourceforge.net/project/lame/lame/3.99/lame-3.99.5.tar.gz
tar xzvf lame-3.99.5.tar.gz
wget http://downloads.xvid.org/downloads/xvidcore-1.3.4.tar.gz
tar xzvf xvidcore-1.3.4.tar.gz
wget http://ffmpeg.org/releases/ffmpeg-2.6.1.tar.bz2
tar xjvf ffmpeg-2.6.1.tar.bz2
wget http://sourceforge.net/projects/opencvlibrary/files/opencv-unix/2.4.11/opencv-2.4.11.zip/download --output-document=opencv.zip
unzip opencv.zip
cd opencv-2.4.11
mkdir build
cd /home/peter/programs
rpm -i cuda-repo-opensuse132-7.5-18.x86_64.rpm
zypper --gpg-auto-import-keys refresh
zypper addrepo http://download.opensuse.org/repositories/X11:Bumblebee/openSUSE_13.2/X11:Bumblebee.repo
zypper --gpg-auto-import-keys refresh
zypper --non-interactive --gpg-auto-import-keys in bumblebee
usermod -G video,bumblebee peter
systemctl enable bumblebeed
mkinitrd
zypper --gpg-auto-import-keys --non-interactive in cuda
systemctl enable dkms
zypper --non-interactive in nvidia-bumblebee-32bit
zypper --gpg-auto-import-keys --non-interactive in cuda
zypper --non-interactive in cuda-gdb-src-7-5
zypper --gpg-auto-import-keys --non-interactive in -f nvidia-bumblebee
cd /etc/ld.so.conf.d
echo -e "/usr/local/cuda-7.5/lib64" > cudald.conf
ldconfig
cd /home/peter
echo -e "export LD_LIBRARY_PATH=/usr/local/cuda-7.5/lib64:$LD_LIBRARY_PATH\nexport PATH=/usr/local/cuda-7.5/bin:$PATH" >> .bashrc
chmod 777 -R programs
reboot
I am not sure whether it is a source of issues but after rebooting you maybe open a new shell and run this file. Again don't forget to customize the shell script. Before starting you should extend your sudo session or run it as superuser again.
Remove any other opencv-libs that maybe comes with the rpms. Then you can start this snippet to install it.
-- Note the optirun commands are needed at the end to have at all steps the correct architecture. The configuration sometimes restarts with make or make install. To keep the configuration let it run with optimus.
cd /home/peter/programs/SDK/nvenc_5.0.1_sdk
sudo cp Samples/common/inc/* /usr/include/
cd /home/peter/programs/x264-snapshot*
./configure --enable-static --enable-shared --enable-pic
make
sudo make install
make distclean
cd /home/peter/programs/mstorsjo-fdk-aac*
autoreconf -fiv
./configure
make
sudo make install
make distclean
cd /home/peter/programs/lame-3.99.5
./configure --enable-nasm
make
sudo make install
make distclean
cd /home/peter/programs/xvidcore/build/generic
./configure
make
sudo make install
make distclean
cd /home/peter/programs/ffmpeg-2.6.1
./configure \
--enable-shared \
--enable-gpl \
--enable-libass \
--enable-libfdk-aac \
--enable-libfreetype \
--enable-libmp3lame \
--enable-libopus \
--enable-libtheora \
--enable-libvorbis \
--enable-libvpx \
--enable-libx264 \
--enable-libxvid \
--enable-nonfree \
--enable-nvenc
make -j8
sudo make install
make distclean
hash -r
echo "Complete!"
cd /home/peter/programs/opencv-2.4.11/build
optirun cmake -D BUILD_EXAMPLES:BOOL=TRUE -D CUDA_ARCH_BIN:STRING=5.0 -D CUDA_ARCH_PTX:STRING=5.0 -D CUDA_BUILD_CUBIN:BOOL=TRUE -D CUDA_FAST_MATH:BOOL=TRUE -D CUDA_GENERATION:STRING=Auto -D INSTALL_C_EXAMPLES:BOOL=TRUE -D INSTALL_PYTHON_EXAMPLES:BOOL=TRUE -D WITH_CUDA:BOOL=ON -D INSTALL_TESTS:BOOL=TRUE -D WITH_CUBLAS:BOOL=TRUE -D WITH_NVCUVID:BOOL=TRUE -D WITH_OPENCLAMDBLAS:BOOL=FALSE -D WITH_OPENCLAMDFFT:BOOL=FALSE -D WITH_OPENGL:BOOL=TRUE -D WITH_UNICAP:BOOL=TRUE -D WITH_XINE:BOOL=TRUE -D WITH_QT:BOOL=TRUE -D CUDA_nvcuvid_LIBRARY:FILEPATH=/usr/lib64/libnvcuvid.so.1 /home/peter/programs/opencv-2.4.11/
optirun make -j8
sudo optirun make install
With starting qtcreator with optirun iyou should be able to compile and run opencv_gpu files like every other opencv program.
Thx peter
I need to hand in a new version of our app to submit my request for new Facebook permissions.
The problem is, that it is not possible to build the iOS simulator build like described here.
I attached my complete output on gist.
The most important parts are these ones:
SebastiansMBP2:ios <user>$ xcodebuild -arch i386 -sdk iphonesimulator8.0
Build settings from command line:
ARCHS = i386
SDKROOT = iphonesimulator8.0
=== BUILD TARGET CordovaLib OF PROJECT CordovaLib WITH THE DEFAULT CONFIGURATION (Release) ===
Check dependencies
...
2014-10-21 11:44:28.029 xcodebuild[67280:364513] DeveloperPortal: Using pre-existing current store at URL (file:///Users/<user>/Library/Developer/Xcode/DeveloperPortal%206.0.db).
=== BUILD TARGET <ProjectName> OF PROJECT <ProjectName> WITH THE DEFAULT CONFIGURATION (Release) ===
CompileC build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/AdjustCordova.o <ProjectName>/Plugins/com.adjust.sdk/AdjustCordova.m normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
cd /Users/<user>/Development/20/<ProjectName>/platforms/ios
export LANG=en_US.US-ASCII
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Users/<user>/.rvm/gems/ruby-2.0.0-p451/bin:/Users/<user>/.rvm/gems/ruby-2.0.0-p451#global/bin:/Users/<user>/.rvm/rubies/ruby-2.0.0-p451/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Users/<user>/.rvm/bin:/Users/<user>/.adt/tools:/Users/<user>/.adt/platform-tools"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x objective-c -arch i386 -fmessage-length=270 -fdiagnostics-show-note-include-stack -fmacro-backtrace-limit=0 -fcolor-diagnostics -std=c99 -fobjc-arc -Wno-trigraphs -fpascal-strings -Os -Wno-missing-field-initializers -Wno-missing-prototypes -Wno-implicit-atomic-properties -Wno-receiver-is-weak -Wno-arc-repeated-use-of-weak -Wduplicate-method-match -Wno-missing-braces -Wparentheses -Wswitch -Wunused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wempty-body -Wuninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wconstant-conversion -Wint-conversion -Wbool-conversion -Wenum-conversion -Wno-shorten-64-to-32 -Wpointer-sign -Wno-newline-eof -Wno-selector -Wno-strict-selector-match -Wundeclared-selector -Wno-deprecated-implementations -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator8.0.sdk -fexceptions -fasm-blocks -fstrict-aliasing -Wprotocol -Wdeprecated-declarations -g -fvisibility=hidden -Wno-sign-conversion -fobjc-abi-version=2 -fobjc-legacy-dispatch -mios-simulator-version-min=7.0 -iquote /Users/<user>/Development/20/<ProjectName>/platforms/ios/build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/<ProjectName>-generated-files.hmap -I/Users/<user>/Development/20/<ProjectName>/platforms/ios/build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/<ProjectName>-own-target-headers.hmap -I/Users/<user>/Development/20/<ProjectName>/platforms/ios/build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/<ProjectName>-all-target-headers.hmap -iquote /Users/<user>/Development/20/<ProjectName>/platforms/ios/build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/<ProjectName>-project-headers.hmap -I/Users/<user>/Development/20/<ProjectName>/platforms/ios/build/Release-iphonesimulator/include -I/Users/<user>/Development/20/<ProjectName>/platforms/ios/build/Release-iphonesimulator/usr/local/lib/include -I/Users/<user>/Development/20/<ProjectName>/platforms/ios/build/UninstalledProducts/include -I/Users/<user>/Development/20/<ProjectName>/platforms/ios/build/Release-iphonesimulator -I/Users/<user>/Development/20/<ProjectName>/platforms/ios/build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/DerivedSources/i386 -I/Users/<user>/Development/20/<ProjectName>/platforms/ios/build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/DerivedSources -F/Users/<user>/Development/20/<ProjectName>/platforms/ios/build/Release-iphonesimulator -F/Users/<user>/Development/20/<ProjectName>/platforms/ios/Safe -F/Users/<user>/Development/20/<ProjectName>/platforms/ios/<ProjectName>/Plugins/com.phonegap.plugins.facebookconnect -include /var/folders/pn/gg2pmp494ddc28vb35296c7r0000gn/C/com.apple.DeveloperTools/6.0-6A313/Xcode/SharedPrecompiledHeaders/<ProjectName>-Prefix-buzdrrssmquhyjccbctulbjeosdy/<ProjectName>-Prefix.pch -MMD -MT dependencies -MF /Users/<user>/Development/20/<ProjectName>/platforms/ios/build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/AdjustCordova.d --serialize-diagnostics /Users/<user>/Development/20/<ProjectName>/platforms/ios/build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/AdjustCordova.dia -c /Users/<user>/Development/20/<ProjectName>/platforms/ios/<ProjectName>/Plugins/com.adjust.sdk/AdjustCordova.m -o /Users/<user>/Development/20/<ProjectName>/platforms/ios/build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/AdjustCordova.o
In file included from /Users/<user>/Development/20/<ProjectName>/platforms/ios/<ProjectName>/Plugins/com.adjust.sdk/AdjustCordova.m:9:
/Users/<user>/Development/20/<ProjectName>/platforms/ios/<ProjectName>/Plugins/com.adjust.sdk/AdjustCordova.h:9:9: fatal error: 'Cordova/CDV.h' file not found
#import <Cordova/CDV.h>
^
1 error generated.
... ////////// This error happens multiple times.
/Users/<user>/Development/20/<ProjectName>/platforms/ios/<ProjectName>/Plugins/com.aquto.cordova.AppleAdvertising/AppleAdvertising.h:2:9: fatal error: 'Cordova/CDV.h' file not found
#import <Cordova/CDV.h>
^
1 error generated.
** BUILD FAILED **
The following build commands failed:
CompileC build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/AdjustCordova.o <ProjectName>/Plugins/com.adjust.sdk/AdjustCordova.m normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/APPLocalNotification.o <ProjectName>/Plugins/de.appplant.cordova.plugin.local-notification/APPLocalNotification.m normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/CDVConnection.o <ProjectName>/Plugins/org.apache.cordova.network-information/CDVConnection.m normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/CDVAssetLibraryFilesystem.o <ProjectName>/Plugins/org.apache.cordova.file/CDVAssetLibraryFilesystem.m normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/AppDelegate.o <ProjectName>/Classes/AppDelegate.m normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/CDVLocalFilesystem.o <ProjectName>/Plugins/org.apache.cordova.file/CDVLocalFilesystem.m normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/CDVDevice.o <ProjectName>/Plugins/org.apache.cordova.device/CDVDevice.m normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/<ProjectName>.build/Release-iphonesimulator/<ProjectName>.build/Objects-normal/i386/AppleAdvertising.o <ProjectName>/Plugins/com.aquto.cordova.AppleAdvertising/AppleAdvertising.m normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(8 failures)
No I run the command with the workspace set up and the scheme as well.
SebastiansMBP2:ios <user>$ xcodebuild -arch i386 -sdk iphonesimulator8.0 -workspace <ProjectName>.xcodeproj/project.xcworkspace -scheme <ProjectName>
Build settings from command line:
ARCHS = i386
SDKROOT = iphonesimulator8.0
=== BUILD TARGET CordovaLib OF PROJECT CordovaLib WITH CONFIGURATION Debug ===
Check dependencies
2014-10-21 11:44:44.905 xcodebuild[67925:365372] DeveloperPortal: Using pre-existing current store at URL (file:///Users/<user>/Library/Developer/Xcode/DeveloperPortal%206.0.db).
=== BUILD TARGET <ProjectName> OF PROJECT <ProjectName> WITH CONFIGURATION Debug ===
Check dependencies
....
** BUILD SUCCEEDED **
Now I run the generated build on an ios-sim:
SebastiansMBP2:ios <user>$ ios-sim launch /Users/<user>/Development/20/<ProjectName>/platforms/ios/build/Release-iphonesimulator/<ProjectName>.app
Session could not be started: Error Domain=LaunchServicesError Code=0 "Unable to run app in Simulator" UserInfo=0x7f8993721ad0 {Error=ExecutableTwiddleFailed, ErrorDescription=Failed to chmod file:///Users/<user>/Library/Developer/CoreSimulator/Devices/B745FCEF-0713-419B-B5EF-5274C912DA7E/data/Library/Caches/com.apple.containermanagerd/Temp/Bundle/Application/D615484C-04F7-496D-AB61-4A988E4357C3/<ProjectName>.app/<ProjectName> : No such file or directory, NSLocalizedFailureReason=An error was encountered while running (Domain = LaunchServicesError, Code = 0), NSUnderlyingError=0x7f8993415850 "The operation couldn’t be completed. (LaunchServicesError error 0.)", NSLocalizedDescription=Unable to run app in Simulator}
(username, project name and other privacy related parts have been replaced)
Do you have any ideas how to fix this and how to build a version that can be used to upload it to Facebook?
I'm running Xcode 6, updated the ios-sim to version 3.0.0 and updated cordova-cli to version 4.0.0 with the iOS platform version 3.6.3.
Building the application via cordova build iOS and via Xcode directly works fine!
Thanks!
Just as an information for you guys, I was able to solve it by running the application from Xcode and then just zipping the content of the iOS/build/Emulator/ folder.
The biggest difference between both is, that the mentioned folder contains a separate library libCordova.a and a folder include. With this two elements I was able to hand the iOS application in to Facebook (I just added them to the ZIP-File).
Hope this helps you ;)
I had the same issue, and was related to the cordova-ios version. I had to upgrade it, and then it solved the issue. Cordova-ios with problem was 4.3.0
Here is part of my compilation result:
===============================================================================
You are ready to build VLC and its contribs
make: '.gas' is up to date.
[info] Building contrib for iOS in '/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/contrib/iPhoneOS-arm64'
[info] LD FLAGS SELECTED = '-L/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk/usr/lib -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk -miphoneos-version-min=5.1'
/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc
error: invalid deployment target '5.1.0' for architecture 'arm64' (requires
'7.0.0' or later)
1 error generated.
make: Nothing to be done for `fetch'.
error: invalid deployment target '5.1.0' for architecture 'arm64' (requires
'7.0.0' or later)
1 error generated.
sed -i.orig s/-ansi// freetype/builds/unix/configure
cd freetype && GNUMAKE=make CC="xcrun clang" CXX="xcrun clang++" LD="xcrun ld" AR="xcrun ar" CCAS="gas-preprocessor.pl xcrun clang -c" RANLIB="xcrun ranlib" STRIP="xcrun strip" PATH="/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/contrib/arm-apple-darwin11-arm64/bin:/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/extras/tools/build/bin:/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/extras/tools/build/bin:/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/contrib/arm-apple-darwin11/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin" CPPFLAGS="-isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk -arch arm64 -miphoneos-version-min=5.1 -O3 -g -arch arm64 -miphoneos-version-min=5.1 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk -arch arm64 -miphoneos-version-min=5.1 -O3 -g -I/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/contrib/arm-apple-darwin11-arm64/include" CFLAGS="-isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk -arch arm64 -miphoneos-version-min=5.1 -O3 -g -arch arm64 -miphoneos-version-min=5.1 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk -arch arm64 -miphoneos-version-min=5.1 -O3 -g -I/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/contrib/arm-apple-darwin11-arm64/include -g" CXXFLAGS="-isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk -arch arm64 -miphoneos-version-min=5.1 -O3 -g -arch arm64 -miphoneos-version-min=5.1 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk -arch arm64 -miphoneos-version-min=5.1 -O3 -g -arch arm64 -miphoneos-version-min=5.1 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk -arch arm64 -miphoneos-version-min=5.1 -O3 -g -I/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/contrib/arm-apple-darwin11-arm64/include -g -I/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/contrib/arm-apple-darwin11-arm64/include -g" LDFLAGS="-L/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk/usr/lib -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk -miphoneos-version-min=5.1 -arch arm64 -miphoneos-version-min=5.1 -L/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk/usr/lib -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk -miphoneos-version-min=5.1 -L/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/contrib/arm-apple-darwin11-arm64/lib" ./configure --without-png --prefix="/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/contrib/arm-apple-darwin11-arm64" --build="arm-apple-darwin11" --host="x86_64-apple-darwin11" --target="x86_64-apple-darwin11" --program-prefix="" --enable-static --disable-shared --disable-dependency-tracking --with-pic
FreeType build system -- automatic system detection
The following settings are used:
platform unix
compiler xcrun clang
configuration directory ./builds/unix
configuration rules ./builds/unix/unix.mk
If this does not correspond to your system or settings please remove the file
`config.mk' from this directory then read the INSTALL file for help.
Otherwise, simply type `make' again to build the library,
or `make refdoc' to build the API reference (the latter needs python).
cd builds/unix; /bin/sh ./configure '--without-png' '--prefix=/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/contrib/arm-apple-darwin11-arm64' '--build=arm-apple-darwin11' '--host=x86_64-apple-darwin11' '--target=x86_64-apple-darwin11' '--program-prefix=' '--enable-static' '--disable-shared' '--disable-dependency-tracking' '--with-pic'
configure: WARNING: unrecognized options: --disable-dependency-tracking
checking build system type... arm-apple-darwin11
checking host system type... x86_64-apple-darwin11
checking for x86_64-apple-darwin11-gcc... xcrun clang
checking whether the C compiler works... no
configure: error: in `/Users/nikhil.t/VLCKit/MobileVLCKit/ImportedSources/vlc/contrib/iPhoneOS-arm64/freetype/builds/unix':
configure: error: C compiler cannot create executables
See `config.log' for more details
make[1]: *** [setup] Error 77
make: *** [.freetype2] Error 2
===================================================================
I am using guideline provided by VLC
I tried to change the xcrun path in build.sh (ImportedSources/vlc/extras/package/ios/build.sh) but it resets to original once I build the script.
Is there another way I could change this, so that c compiler works for me?
I am stuck on this for the last 9 days, please provide some guidance.
Thanks,
Albin.K.J
The first error is:
error: invalid deployment target '5.1.0' for architecture 'arm64' (requires
'7.0.0' or later)
... so I would suggest trying what it suggests: bumping the deployment target up from 5.1.0 to 7.0.0, or remove arm64 support.
May be wrong compiler path.
Check the CC points to the correct path also it is as expected in the script file.
I also have the same issue, setting CC correctly did the trick for me.
The required compilers are missing from your system. You need both a C++ compiler and a C compiler.
You can install the compilers (GCC and G++) using apt-get install gcc g++.