issue in installing Sphinx on mac - ruby-on-rails

Compiling the code using :-
LDFLAGS="-arch x86_64" ./configure --prefix=/usr/local --with-mysql=/usr/local/mysql-5.5.9-osx10.6-x86_64
O/p for the compilation.
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating libstemmer_c/Makefile
config.status: creating sphinx.conf.dist
config.status: creating sphinx-min.conf.dist
config.status: creating config/config.h
config.status: executing depfiles commands
configuration done
------------------
You can now run 'make' to build Sphinx binaries,
and then run 'make install' to install them.
O/p for make:--
g++ -DHAVE_CONFIG_H -I. -I../config -DSYSCONFDIR="\"/usr/local/etc\"" -I/usr/local/include -I/usr/local/mysql-5.5.9-osx10.6-x86_64/include -Os -g -fno-common -fno-strict-aliasing -arch x86_64 -Wall -g -D_FILE_OFFSET_BITS=64 -O3 -DNDEBUG -MT tests.o -MD -MP -MF .deps/tests.Tpo -c -o tests.o tests.cpp
mv -f .deps/tests.Tpo .deps/tests.Po
g++ -Wall -g -D_FILE_OFFSET_BITS=64 -O3 -DNDEBUG -arch x86_64 -o tests tests.o libsphinx.a -L/usr/local/mysql-5.5.9-osx10.6-x86_64/lib -lmysqlclient -lpthread -lodbc -lz -lexpat -L/usr/local/lib -lpthread
Making all in test
make[1]: Nothing to be done for `all'.
make[1]: Nothing to be done for `all-am'.
O/p for make install:--
Making install in src
if test -d ../.svn; then svn info .. --xml | perl svnxrev.pl; fi;
make install-am
test -z "/usr/local/bin" || ../config/install-sh -c -d "/usr/local/bin"
/usr/bin/install -c 'indexer' '/usr/local/bin/indexer'
/usr/bin/install -c 'searchd' '/usr/local/bin/searchd'
/usr/bin/install -c 'search' '/usr/local/bin/search'
/usr/bin/install -c 'spelldump' '/usr/local/bin/spelldump'
/usr/bin/install -c 'indextool' '/usr/local/bin/indextool'
make[3]: Nothing to be done for `install-data-am'.
Making install in test
make[1]: Nothing to be done for `install'.
test -z "/usr/local/etc" || config/install-sh -c -d "/usr/local/etc"
/usr/bin/install -c -m 644 'sphinx.conf.dist' '/usr/local/etc/sphinx.conf.dist'
/usr/bin/install -c -m 644 'sphinx-min.conf.dist' '/usr/local/etc/sphinx-min.conf.dist'
/usr/bin/install -c -m 644 'example.sql' '/usr/local/etc/example.sql'
make install-data-hook
mkdir -p /usr/local/var/data && mkdir -p /usr/local/var/log
If I try to run thinking sphinx server:-
rake thinking_sphinx:index
(in /Users/mohit/projects/urbanAdda)
sh: line 1: 26356 Trace/BPT trap indexer 2>&1
sh: line 1: 26359 Trace/BPT trap indexer 2>&1
Sphinx cannot be found on your system. You may need to configure the following
settings in your config/sphinx.yml file:
* bin_path
* searchd_binary_name
* indexer_binary_name
For more information, read the documentation:
http://freelancing-god.github.com/ts/en/advanced_config.html
sh: line 1: 26361 Trace/BPT trap indexer 2>&1
Generating Configuration to /Users/mohit/projects/urbanAdda/config/development.sphinx.conf
dyld: Library not loaded: libmysqlclient.16.dylib
Referenced from: /usr/local/bin/indexer
Reason: image not found

sudo install_name_tool -change libmysqlclient.16.dylib /usr/local/mysql-5.5.9-osx10.6-x86_64//lib/libmysqlclient.16.dylib /usr/local/bin/indexer
and
sudo install_name_tool -change libmysqlclient.16.dylib /usr/local/mysql-5.5.9-osx10.6-x86_64//lib/libmysqlclient.16.dylib /usr/local/bin/searchd
solved my problem

The dynamic linker cannot find the mysqlclient library.
Try to add the path where it's installed to the DYLD_LIBRARY_PATH environment variable.
And when/if you plan to rebuild it, add "-Wl,-rpath /path/to/lib" to LDFLAGS.

Related

Using hyperledger-fabric v1.0.0 make docker got an error

Because of the need of the project, we have changed the core/chaincode/shim of fabric1.0.0. The tree structure of shim is:
shim
├── chaincode.go
├── handler.go
├── inprocstream.go
├── interfaces.go
├── java
│ └── ···
├── mockstub.go
├── mockstub_test.go
├── response.go
├── myxxxutil.go
├── shim_test.go
└── myxxx.go
Some of these functions require cgo, which is writen in c++, there is some code snippet:
//myxxx.go
package shim
/*
#cgo CFLAGS: -I/opt/xxxsrc
#cgo LDFLAGS: -L/usr/lib -lmyxxx
#include "interface.hpp"
#include <stdlib.h>
*/
import "C"
func SomeFucn(){
··· //the C++ source code is in /opt/xxxsrc folder,so is interface.hpp file,the libmyxxx.so file is in /usr/lib folder
}
The, I used the make docker command to create a peer image based on hyperledger/fabric-baseimage:x86_64-0.3.1 under fabric directory. This hyperledger/fabric-baseimage:x86_64-0.3.1 has been modified by me. I put the libmyxxx. so file into /usr/lib folder of this "baseimage", and put the c++ soure code into /opt/xxxsrc, Then the execution log is:
Building build/docker/bin/peer
(the docker command line is:
docker run -i --rm --user=0 -v /home/my/gopath/src/github.com/hyperledger/fabric:/opt/gopath/src/github.com/hyperledger/fabric -w /opt/gopath/src/github.com/hyperledger/fabric -v /home/my/gopath/src/github.com/hyperledger/fabric/build/docker/bin:/opt/gopath/bin -v /home/my/gopath/src/github.com/hyperledger/fabric/build/docker/peer/pkg:/opt/gopath/pkg hyperledger/fabric-baseimage:x86_64-0.3.1
go install -ldflags "-X github.com/hyperledger/fabric/common/metadata.Version=1.0.0 -X github.com/hyperledger/fabric/common/metadata.BaseVersion=0.3.1 -X github.com/hyperledger/fabric/common/metadata.BaseDockerLabel=org.hyperledger.fabric -X github.com/hyperledger/fabric/common/metadata.DockerNamespace=hyperledger -X github.com/hyperledger/fabric/common/metadata.BaseDockerNamespace=hyperledger -linkmode external -extldflags -static -lpthread" github.com/hyperledger/fabric/peer
)
github.com/hyperledger/fabric/core/chaincode/shim
mkdir -p $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/
cd /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/shim
CGO_LDFLAGS="-g" "-O2" "-L/usr/lib" "-lmyxxx" "-L/usr/lib" "-lmyxxx" /opt/go/pkg/tool/linux_amd64/cgo -objdir $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/ -importpath github.com/hyperledger/fabric/core/chaincode/shim – -I $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/ -I/opt/xxxsrc -I/opt/xxxsrc myxxxutil.go myxxx.go
cd /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/shim
gcc -I . -fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=$WORK=/tmp/go-build -gno-record-gcc-switches -I $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/ -g -O2 -I/opt/xxxsrc -I/opt/xxxsrc -o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_cgo_main.o -c $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_cgo_main.c
cd /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/shim
gcc -I . -fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=$WORK=/tmp/go-build -gno-record-gcc-switches -I $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/ -g -O2 -I/opt/xxxsrc -I/opt/xxxsrc -o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_cgo_export.o -c $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_cgo_export.c
gcc -I . -fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=$WORK=/tmp/go-build -gno-record-gcc-switches -I $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/ -g -O2 -I/opt/xxxsrc -I/opt/xxxsrc -o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/myxxxutil.cgo2.o -c $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/myxxxutil.cgo2.c
gcc -I . -fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=$WORK=/tmp/go-build -gno-record-gcc-switches -I $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/ -g -O2 -I/opt/xxxsrc -I/opt/xxxsrc -o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/xxx.cgo2.o -c $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/xxx.cgo2.c
cd /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/shim
gcc -I . -fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=$WORK=/tmp/go-build -gno-record-gcc-switches -o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/obj/_cgo.o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_cgo_main.o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_cgo_export.o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/myxxxutil.cgo2.o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/myxxx.cgo2.o -g -O2 -L/usr/lib -lmyxxx -L/usr/lib -lmyxxx
cd /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/shim
/opt/go/pkg/tool/linux_amd64/cgo -objdir $WORK/github.com/hyperledger/fabric/core/chaincode/shim/obj/ -dynpackage shim -dynimport $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_cgo.o -dynout $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_cgo_import.go
gcc I . -fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=$WORK=/tmp/go-build -gno-record-gcc-switches -o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_all.o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_cgo_export.o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/myxxxutil.cgo2.o $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/myxxx.cgo2.o -g -O2 -L/usr/lib -L/usr/lib -Wl,-r -nostdlib -no-pie -Wl,-build-id=none
/opt/go/pkg/tool/linux_amd64/compile -o $WORK/github.com/hyperledger/fabric/core/chaincode/shim.a -trimpath $WORK -p github.com/hyperledger/fabric/core/chaincode/shim -buildid 2ee9889b3f3fdd6fc02e5029d94e8c287f977ccb -importmap github.com/golang/protobuf/proto=github.com/hyperledger/fabric/vendor/github.com/golang/protobuf/proto -importmap github.com/golang/protobuf/ptypes/timestamp=github.com/hyperledger/fabric/vendor/github.com/golang/protobuf/ptypes/timestamp -importmap github.com/looplab/fsm=github.com/hyperledger/fabric/vendor/github.com/looplab/fsm -importmap github.com/op/go-logging=github.com/hyperledger/fabric/vendor/github.com/op/go-logging -importmap github.com/spf13/viper=github.com/hyperledger/fabric/vendor/github.com/spf13/viper -importmap golang.org/x/net/context=github.com/hyperledger/fabric/vendor/golang.org/x/net/context -importmap google.golang.org/grpc=github.com/hyperledger/fabric/vendor/google.golang.org/grpc -D _/opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/shim -I $WORK -I /opt/gopath/pkg/linux_amd64 -pack ./chaincode.go ./fileIO.go ./handler.go ./inprocstream.go ./interfaces.go ./mockstub.go ./response.go $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_cgo_gotypes.go $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/myxxxutil.cgo1.go $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/myxxx.cgo1.go $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_cgo_import.go
cd /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/shim
pack r $WORK/github.com/hyperledger/fabric/core/chaincode/shim.a $WORK/github.com/hyperledger/fabric/core/chaincode/shim/_obj/_all.o # internal
cp $WORK/github.com/hyperledger/fabric/core/chaincode/shim.a /opt/gopath/pkg/linux_amd64/github.com/hyperledger/fabric/core/chaincode/shim.a
/opt/go/pkg/tool/linux_amd64/link -o $WORK/github.com/hyperledger/fabric/peer/_obj/exe/a.out -L $WORK -L /opt/gopath/pkg/linux_amd64 -extld=gcc -buildmode=exe -buildid=c7ee3188106eddcbae7255ad032536402bc38b29 -X github.com/hyperledger/fabric/common/metadata.Version=1.0.0 -X github.com/hyperledger/fabric/common/metadata.BaseVersion=0.3.1 -X github.com/hyperledger/fabric/common/metadata.BaseDockerLabel=org.hyperledger.fabric -X github.com/hyperledger/fabric/common/metadata.DockerNamespace=hyperledger -X github.com/hyperledger/fabric/common/metadata.BaseDockerNamespace=hyperledger -linkmode external -extldflags "-static -lpthread" $WORK/github.com/hyperledger/fabric/peer.a
github.com/hyperledger/fabric/peer
/opt/go/pkg/tool/linux_amd64/link: running gcc failed: exit status 1
/usr/bin/ld: cannot find -lmyxxx
/usr/bin/ld: cannot find -lmyxxx
/usr/lib/gcc/x86_64-linux-gnu/5/../../../x86_64-linux-gnu/libltdl.a(dlopen.o): In function `vm_open':
(.text+0x5e): warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/tmp/go-link-940349017/000001.o: In function `_cgo_7a2d42f1a351_C2func_getaddrinfo':
/tmp/workdir/go/src/net/cgo_unix.go:66: warning: Using 'getaddrinfo' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
collect2: error: ld returned 1 exit status
Makefile:197: recipe for target 'build/docker/bin/peer' failed
make: *** [build/docker/bin/peer] Error 2
I already tried to add path (/usr/lib) in /etc/ld.so.conf file, and executed "ldconfig", and also tried to add path to environment variables LD_LIBRARY_PATH and LIBRARY_PATH, the problem still reappears, so I would like to ask if there is any solution to the problem, thank you

Error - magick/ImageMagick.h: No such file or directory

I am trying to install driver for fingerprint sensor from source. I have already ran sudo ./configure and it doesn't give any error. Then while trying to do sudo make I run into the following error.
uname#computer:~/libfprint-0.0.6$ sudo make
make all-recursive
make[1]: Entering directory '/home/nirmal/libfprint-0.0.6'
Making all in libfprint
make[2]: Entering directory '/home/nirmal/libfprint-0.0.6/libfprint'
/bin/bash ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -fvisibility=hidden -I./nbis/include -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -fopenmp -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/usr/local/include/ImageMagick-7 -std=gnu99 -fgnu89-inline -Wall -Wundef -Wunused -Wstrict-prototypes -Werror-implicit-function-declaration -Wno-pointer-sign -Wshadow -g -O2 -MT libfprint_la-imgdev.lo -MD -MP -MF .deps/libfprint_la-imgdev.Tpo -c -o libfprint_la-imgdev.lo `test -f 'imgdev.c' || echo './'`imgdev.c
gcc -DHAVE_CONFIG_H -I. -I.. -fvisibility=hidden -I./nbis/include -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -fopenmp -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/usr/local/include/ImageMagick-7 -std=gnu99 -fgnu89-inline -Wall -Wundef -Wunused -Wstrict-prototypes -Werror-implicit-function-declaration -Wno-pointer-sign -Wshadow -g -O2 -MT libfprint_la-imgdev.lo -MD -MP -MF .deps/libfprint_la-imgdev.Tpo -c imgdev.c -fPIC -DPIC -o .libs/libfprint_la-imgdev.o
imgdev.c:23:32: fatal error: magick/ImageMagick.h: No such file or directory
compilation terminated.
Makefile:456: recipe for target 'libfprint_la-imgdev.lo' failed
make[2]: *** [libfprint_la-imgdev.lo] Error 1
make[2]: Leaving directory '/home/nirmal/libfprint-0.0.6/libfprint'
Makefile:304: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/nirmal/libfprint-0.0.6'
Makefile:215: recipe for target 'all' failed
make: *** [all] Error 2
I have already installed following libraries to avoid the 'ImageMagick.h not found error' but still can't get rid of this error:
graphicsmagick
graphicsmagick-dbg
graphicsmagick-imagemagick-compat
graphicsmagick-libmagick-dev-compat
imagemagick-6.q16
imagemagick-7.0.8
imagemagick-common
imagemagick-dbg
imagemagick-doc
libgraphics-magick-perl
libgraphicsmagick++-q16-12
libgraphicsmagick++1-dev
libgraphicsmagick-q16-3
libgraphicsmagick1-dev
libmage-magick-q16-perl
libmagick++-6-headers
libmagick++-6.q16-5v5
libmagick++-6.q16-dev
libmagickcore-6-arch-config
libmagickcore-6.q16-2
libmagickcore-6.q16-2-extra
libmagickcore-6.q16-dev
libmagickwand-6-headers
libmagickwand-6.q16-2
libmagickwand-6.q16-dev
libmagickwand-dev
Thanks in advance!

how to install glib2 package in docker

I use docker to install centos 6.5 and opensource c++ mysql proxy : DBPORXY(https://github.com/Meituan-Dianping/DBProxy.git), when I run into the last command, I failed.From the error info, I think that is glib2 problem,but I have installed glib2! that is my public docker : [
docker pull xujianhai/dbproxy], the method I use to implement glib2 :
cd glib-2.42.0
./configure
make
make install
vi /etc/ld.so.conf
add a row and exit: /usr/local/lib
ldconfig
the detail error message when I run into the last command :
bash-4.1# make
make all-recursive
make[1]: Entering directory `/DBProxy'
Making all in src
make[2]: Entering directory `/DBProxy/src'
make all-am
make[3]: Entering directory `/DBProxy/src'
/bin/sh ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -I/usr/include/mysql -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -pthread -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -ggdb -g -O0 -MT libmysql_chassis_glibext_la-glib-ext.lo -MD -MP -MF .deps/libmysql_chassis_glibext_la-glib-ext.Tpo -c -o libmysql_chassis_glibext_la-glib-ext.lo `test -f 'glib-ext.c' || echo './'`glib-ext.c
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I.. -I/usr/include/mysql -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -pthread -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -ggdb -g -O0 -MT libmysql_chassis_glibext_la-glib-ext.lo -MD -MP -MF .deps/libmysql_chassis_glibext_la-glib-ext.Tpo -c glib-ext.c -fPIC -DPIC -o .libs/libmysql_chassis_glibext_la-glib-ext.o
glib-ext.c: In function 'g_string_get_time':
glib-ext.c:121: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'm'
glib-ext.c:121: error: 'm' undeclared (first use in this function)
glib-ext.c:121: error: (Each undeclared identifier is reported only once
glib-ext.c:121: error: for each function it appears in.)
make[3]: *** [libmysql_chassis_glibext_la-glib-ext.lo] Error 1
make[3]: Leaving directory `/DBProxy/src'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/DBProxy/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/DBProxy'
make: *** [all] Error 2

clang error invalid version number in -miphoneos-version-min=.sd

When i compile librtmp for ios, the script shows below:
#!/bin/sh
# OS X Yosemite, Xcode 6.1
set -ex
DEVELOPER="/Applications/Xcode.app/Contents/Developer"
DEVICE_SDK="$DEVELOPER/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk"
SIMULATOR_SDK="$DEVELOPER/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk"
CURRPATH=`pwd`
SOURCE="rtmpdump"
DSTDIR="librtmp"
LIBSSL=`cd ../OpenSSL/libssl;pwd`
ARCHS="i386 x86_64 armv7 armv7s arm64"
rm -rf $DSTDIR
mkdir $DSTDIR
if [ ! -d $SOURCE ]; then
git clone git://git.ffmpeg.org/rtmpdump $SOURCE
else
cd $SOURCE
git fetch
cd ..
fi
cd $SOURCE/librtmp
for ARCH in $ARCHS; do
mkdir -p ../$DSTDIR/$ARCH
if [[ $ARCH == arm* ]]; then
SDK=$DEVICE_SDK
else
SDK=$SIMULATOR_SDK
fi
perl -i -pe 's|^AR=\$\(CROSS_COMPILE\)ar|AR=xcrun ar|' Makefile
CROSS_COMPILE="$DEVELOPER/usr/bin/" \
XCFLAGS="-O0 -isysroot $SDK -I$LIBSSL/include -arch $ARCH " \
XLDFLAGS="-isysroot $SDK -L$LIBSSL/lib -arch $ARCH -miphoneos-version-min=7.0 " \
make SYS=darwin
make SYS=darwin prefix="$CURRPATH/$DSTDIR/$ARCH" install
make clean
done
mkdir -p $CURRPATH/$DSTDIR/lib
cd $CURRPATH/$DSTDIR/$ARCH/lib
LIBS=`ls *.a`
cd $CURRPATH
for LIB in $LIBS; do
lipo -create `find $DSTDIR -name $LIB` -output $DSTDIR/lib/$LIB
done
cp -rf $DSTDIR/$ARCH/include $DSTDIR
for ARCH in $ARCHS; do
rm -rf $DSTDIR/$ARCH
done
when statement make SYS=darwin runs, error shows:
/Applications/Xcode.app/Contents/Developer/usr/bin/gcc -Wall -O0 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk -I/Users/Smeegol/Desktop/AVCodecs2/OpenSSL/libssl/include -arch armv7 -DRTMPDUMP_VERSION=\"v2.4\" -DUSE_OPENSSL -O2 -fPIC -c -o rtmp.o rtmp.c
clang: error: invalid version number in '-miphoneos-version-min=.sd'
make: *** [rtmp.o] Error 1
Why? I have set XLDFLAGS="-isysroot $SDK -L$LIBSSL/lib -arch $ARCH -miphoneos-version-min=7.0 " and why invalid version number in '-miphoneos-version-min=.sd' occurs?
I had the same problem and resolved it by changing the -isysroot argument from:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk
to:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.3.sdk
Note that the latter is a symlink to the former on my system.
It appears that clang is implicitly setting -miphoneos-version-min= from the iPhoneOSXXX.sdk directory name. Using the link with the version number in it seems to fix the compilation issue.

ChatSecure-iOS, [Travis Detected] GPG verification disabled - Compiling for i386 only

I am working on Open Source ChatSecure (iOS). (https://chatsecure.org/developers/)
But while creating build I am getting error "missing required architecture x86_64 in file". This error occurs only if I am using 64-bit architecture simulator, Its working fine with other simulators.
In log I have checked that errors are because of these three libraries (libotr.a, libgcrypt.a, libgpg-error.a) which are part of OTRKit (Submodule of ChatSecure-iOS). These libraries are not building properly which compatibles with x86_64 architecture.
For building those libraries I have followed following steps,
1) $ git submodule add https://github.com/ChatSecure/OTRKit.git Submodules/OTRKit (added OTRKit as a Submodule in ChatSecure app)
2) $ bash build-libgpg-error.sh
3) $ bash build-libgcrypt.sh
4) $ bash build-libotr.sh
Following log is generated while building libgpg-error.a,
xxx-Mac-Minixxx:OTRKit xxx$ bash build-libgpg-error.sh
Building libgpg-error...
[Travis Detected] GPG verification disabled - Compiling for i386 only
Downloading libgpg-error-1.12.tar.bz2
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 477k 100 477k 0 0 13777 0 0:00:35 0:00:35 --:--:-- 19253
Building without ccache
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for i386-apple-darwin-strip... no
checking for strip... strip
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking build system type... x86_64-apple-darwin12.5.0
checking host system type... i386-apple-darwin
configure: autobuild project... libgpg-error
configure: autobuild revision... 1.12
configure: autobuild hostname... xxx-Mac-Minixxx.local
configure: autobuild timestamp... 20140830-194606
checking for i386-apple-darwin-gcc... no
checking for gcc... gcc
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... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking whether gcc and cc understand -c and -o together... rm: conftest.dSYM: is a directory
yes
checking how to run the C preprocessor... gcc -E
checking for gawk... (cached) awk
checking for i386-apple-darwin-ar... no
checking for ar... ar
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... rm: conftest.dSYM: is a directory
rm: conftest.dSYM: is a directory
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 minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking whether it is safe to define __EXTENSIONS__... yes
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for fgrep... /usr/bin/grep -F
checking for ld used by gcc... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld
checking if the linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) is GNU ld... no
checking for BSD- or MS-compatible name lister (nm)... no
checking for i386-apple-darwin-dumpbin... no
checking for i386-apple-darwin-link... no
checking for dumpbin... no
checking for link... link -dump
checking the name lister (nm) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 196608
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-apple-darwin12.5.0 file names to i386-apple-darwin format... func_convert_file_noop
checking how to convert x86_64-apple-darwin12.5.0 file names to toolchain format... func_convert_file_noop
checking for /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld option to reload object files... -r
checking for i386-apple-darwin-objdump... no
checking for objdump... no
checking how to recognize dependent libraries... pass_all
checking for i386-apple-darwin-dlltool... no
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for i386-apple-darwin-ar... ar
checking for archiver #FILE support... no
checking for i386-apple-darwin-strip... strip
checking for i386-apple-darwin-ranlib... no
checking for ranlib... ranlib
checking command to parse nm output from gcc object... ok
checking for sysroot... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk
checking for i386-apple-darwin-mt... no
checking for mt... no
checking if : is a manifest tool... no
checking for i386-apple-darwin-dsymutil... no
checking for dsymutil... dsymutil
checking for i386-apple-darwin-nmedit... no
checking for nmedit... nmedit
checking for i386-apple-darwin-lipo... no
checking for lipo... lipo
checking for i386-apple-darwin-otool... no
checking for otool... otool
checking for i386-apple-darwin-otool64... no
checking for otool64... no
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... yes
checking for gcc option to produce PIC... -fno-common -DPIC
checking if gcc PIC flag -fno-common -DPIC works... yes
checking if gcc static flag -static works... no
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... darwin dyld
checking how to hardcode library paths into programs... immediate
checking for i386-apple-darwin-windres... no
checking for windres... no
checking for cc for build... gcc
checking whether NLS is requested... yes
checking for msgfmt... no
checking for gmsgfmt... :
checking for xgettext... no
checking for msgmerge... no
checking for ld used by GCC... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld
checking if the linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) is GNU ld... no
checking for shared library run path origin... done
checking for CFPreferencesCopyAppValue... yes
checking for CFLocaleCopyCurrent... yes
checking for GNU gettext in libc... no
checking for iconv... yes
checking for working iconv... yes
checking how to link with libiconv... -liconv
checking for GNU gettext in libintl... no
checking whether to use NLS... no
checking for ANSI C header files... (cached) yes
checking for stdlib.h... (cached) yes
checking locale.h usability... yes
checking locale.h presence... yes
checking for locale.h... yes
checking whether strerror_r is declared... yes
checking for strerror_r... yes
checking whether strerror_r returns char *... no
checking for strerror_r... (cached) yes
checking for an ANSI C-conforming const... yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/gpg-error-config
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing libtool commands
config.status: executing po-directories commands
config.status: creating po/POTFILES
config.status: creating po/Makefile
libgpg-error-1.12 prepared for make
Revision: 12243ce (4644)
Platform: i386-apple-darwin
make all-recursive
Making all in m4
make[2]: Nothing to be done for `all'.
Making all in src
awk -f ./mkerrnos.awk ./errnos.in >code-to-errno.h
awk -f ./mkerrcodes1.awk ./errnos.in >_mkerrcodes.h
gcc -E _mkerrcodes.h | grep GPG_ERR_ | \
awk -f ./mkerrcodes.awk >mkerrcodes.h
awk -f ./mkstrtable.awk -v textidx=2 -v nogettext=1 \
./err-sources.h.in >err-sources-sym.h
awk -f ./mkstrtable.awk -v textidx=2 -v nogettext=1 \
./err-codes.h.in >err-codes-sym.h
awk -f ./mkstrtable.awk -v textidx=2 -v nogettext=1 \
-v prefix=GPG_ERR_ -v namespace=errnos_ \
./errnos.in >errnos-sym.h
rm extra-h.in
rm: extra-h.in: No such file or directory
make[2]: [extra-h.in] Error 1 (ignored)
echo "/* The version string of this header. */" >>extra-h.in
rm _mkerrcodes.h
echo "#define GPG_ERROR_VERSION \"1.12\"" >>extra-h.in
cat ./gpg-error.def.in >_gpg-error.def.h
echo >>extra-h.in
echo "/* The version number of this header. */" >>extra-h.in
gcc -E -I. -I.. _gpg-error.def.h | \
grep -v '^#' >gpg-error.def
echo "#define GPG_ERROR_VERSION_NUMBER 0x010c00" >>extra-h.in
echo >>extra-h.in
echo EOF >>extra-h.in
echo "/*dummy*/" > mkw32errmap.map.c
gcc -I. -I. -o mkerrcodes ./mkerrcodes.c
rm _gpg-error.def.h
awk -f ./mkheader.awk \
./err-sources.h.in \
./err-codes.h.in \
./errnos.in \
extra-h.in \
./gpg-error.h.in > gpg-error.h
./mkerrcodes | awk -f ./mkerrcodes2.awk >code-from-errno.h
make all-am
/bin/sh ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-init.lo -MD -MP -MF .deps/libgpg_error_la-init.Tpo -c -o libgpg_error_la-init.lo `test -f 'init.c' || echo './'`init.c
/bin/sh ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-version.lo -MD -MP -MF .deps/libgpg_error_la-version.Tpo -c -o libgpg_error_la-version.lo `test -f 'version.c' || echo './'`version.c
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-version.lo -MD -MP -MF .deps/libgpg_error_la-version.Tpo -c version.c -fno-common -DPIC -o libgpg_error_la-version.o
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-init.lo -MD -MP -MF .deps/libgpg_error_la-init.Tpo -c init.c -fno-common -DPIC -o libgpg_error_la-init.o
mv -f .deps/libgpg_error_la-init.Tpo .deps/libgpg_error_la-init.Plo
mv -f .deps/libgpg_error_la-version.Tpo .deps/libgpg_error_la-version.Plo
/bin/sh ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-strsource.lo -MD -MP -MF .deps/libgpg_error_la-strsource.Tpo -c -o libgpg_error_la-strsource.lo `test -f 'strsource.c' || echo './'`strsource.c
/bin/sh ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-strerror.lo -MD -MP -MF .deps/libgpg_error_la-strerror.Tpo -c -o libgpg_error_la-strerror.lo `test -f 'strerror.c' || echo './'`strerror.c
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-strsource.lo -MD -MP -MF .deps/libgpg_error_la-strsource.Tpo -c strsource.c -fno-common -DPIC -o libgpg_error_la-strsource.o
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-strerror.lo -MD -MP -MF .deps/libgpg_error_la-strerror.Tpo -c strerror.c -fno-common -DPIC -o libgpg_error_la-strerror.o
mv -f .deps/libgpg_error_la-strsource.Tpo .deps/libgpg_error_la-strsource.Plo
/bin/sh ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-code-to-errno.lo -MD -MP -MF .deps/libgpg_error_la-code-to-errno.Tpo -c -o libgpg_error_la-code-to-errno.lo `test -f 'code-to-errno.c' || echo './'`code-to-errno.c
mv -f .deps/libgpg_error_la-strerror.Tpo .deps/libgpg_error_la-strerror.Plo
/bin/sh ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-code-from-errno.lo -MD -MP -MF .deps/libgpg_error_la-code-from-errno.Tpo -c -o libgpg_error_la-code-from-errno.lo `test -f 'code-from-errno.c' || echo './'`code-from-errno.c
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-code-to-errno.lo -MD -MP -MF .deps/libgpg_error_la-code-to-errno.Tpo -c code-to-errno.c -fno-common -DPIC -o libgpg_error_la-code-to-errno.o
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT libgpg_error_la-code-from-errno.lo -MD -MP -MF .deps/libgpg_error_la-code-from-errno.Tpo -c code-from-errno.c -fno-common -DPIC -o libgpg_error_la-code-from-errno.o
mv -f .deps/libgpg_error_la-code-to-errno.Tpo .deps/libgpg_error_la-code-to-errno.Plo
gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT gpg_error-strsource-sym.o -MD -MP -MF .deps/gpg_error-strsource-sym.Tpo -c -o gpg_error-strsource-sym.o `test -f 'strsource-sym.c' || echo './'`strsource-sym.c
mv -f .deps/libgpg_error_la-code-from-errno.Tpo .deps/libgpg_error_la-code-from-errno.Plo
gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT gpg_error-strerror-sym.o -MD -MP -MF .deps/gpg_error-strerror-sym.Tpo -c -o gpg_error-strerror-sym.o `test -f 'strerror-sym.c' || echo './'`strerror-sym.c
mv -f .deps/gpg_error-strsource-sym.Tpo .deps/gpg_error-strsource-sym.Po
gcc -DHAVE_CONFIG_H -I. -I.. -DLOCALEDIR=\"/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/locale\" -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT gpg_error-gpg-error.o -MD -MP -MF .deps/gpg_error-gpg-error.Tpo -c -o gpg_error-gpg-error.o `test -f 'gpg-error.c' || echo './'`gpg-error.c
mv -f .deps/gpg_error-strerror-sym.Tpo .deps/gpg_error-strerror-sym.Po
/bin/sh ../libtool --tag=CC --mode=link gcc -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -version-info 10:0:10 -arch i386 -fPIE -miphoneos-version-min=6.0 -L/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/lib -o libgpg-error.la -rpath /Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/lib libgpg_error_la-init.lo libgpg_error_la-version.lo libgpg_error_la-strsource.lo libgpg_error_la-strerror.lo libgpg_error_la-code-to-errno.lo libgpg_error_la-code-from-errno.lo
t-version.c:86:42: warning: data argument not used by format string
[-Wformat-extra-args]
" for a newer version\n", logpfx);
~~~~~~~~~~~~~~~~~~~~~~~~ ^
1 warning generated.
mv -f .deps/t-version.Tpo .deps/t-version.Po
gcc -DHAVE_CONFIG_H -I. -I.. -I../src -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -MT t-syserror.o -MD -MP -MF .deps/t-syserror.Tpo -c -o t-syserror.o t-syserror.c
mv -f .deps/t-strerror.Tpo .deps/t-strerror.Po
/bin/sh ../libtool --tag=CC --mode=link gcc -g -arch i386 -fPIE -miphoneos-version-min=6.0 -I/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -arch i386 -fPIE -miphoneos-version-min=6.0 -L/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/dependencies/lib -o t-syserror t-syserror.o ../src/libgpg-error.la
make install-am
.././install-sh -c -d '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/lib'
/bin/sh ../libtool --mode=install /usr/bin/install -c libgpg-error.la '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/lib'
libtool: install: /usr/bin/install -c .libs/libgpg-error.lai /Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/lib/libgpg-error.la
libtool: install: /usr/bin/install -c .libs/libgpg-error.a /Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/lib/libgpg-error.a
libtool: install: chmod 644 /Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/lib/libgpg-error.a
libtool: install: ranlib /Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/lib/libgpg-error.a
.././install-sh -c -d '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/bin'
/bin/sh ../libtool --mode=install /usr/bin/install -c gpg-error '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/bin'
libtool: install: /usr/bin/install -c gpg-error /Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/bin/gpg-error
.././install-sh -c -d '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/bin'
/usr/bin/install -c gpg-error-config '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/bin'
.././install-sh -c -d '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/include'
/usr/bin/install -c -m 644 gpg-error.h '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/include'
.././install-sh -c -d '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/aclocal'
/usr/bin/install -c -m 644 gpg-error.m4 '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/aclocal'
Making install in tests
make[2]: Nothing to be done for `install-exec-am'.
make[2]: Nothing to be done for `install-data-am'.
Making install in po
if test "libgpg-error" = "gettext-tools"; then \
.././install-sh -c -d /Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/gettext/po; \
for file in Makefile.in.in remove-potcdate.sin quot.sed boldquot.sed en#quot.header en#boldquot.header insert-header.sin Rules-quot Makevars.template; do \
/usr/bin/install -c -m 644 ./$file \
/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/gettext/po/$file; \
done; \
for file in Makevars; do \
rm -f /Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/gettext/po/$file; \
done; \
else \
: ; \
fi
Making install in lang
Making install in cl
make[3]: Nothing to be done for `install-exec-am'.
../.././install-sh -c -d '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/common-lisp/source/gpg-error'
/usr/bin/install -c -m 644 gpg-error.asd gpg-error-package.lisp gpg-error.lisp '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/common-lisp/source/gpg-error'
../.././install-sh -c -d '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/common-lisp/source/gpg-error'
/usr/bin/install -c -m 644 gpg-error-codes.lisp '/Users/xxx/Desktop/ChatSecure-iOS/27-08-2014/ChatSecure-iOS/Submodules/OTRKit/build/built/iPhoneSimulator7.1-i386.sdk/share/common-lisp/source/gpg-error'
Making clean in tests
rm -rf .libs _libs
rm -f t-version t-strerror t-syserror
rm -f *.o
rm -f *.lo
Making clean in src
rm -f gpg-error
test -z "err-sources.h err-codes.h code-to-errno.h code-from-errno.h gpg-error.h mkerrcodes mkerrcodes.h gpg-error.def mkw32errmap.tab.h mkw32errmap.map.c err-sources-sym.h err-codes-sym.h errnos-sym.h gpg-extra/errno.h extra-h.in _mkerrcodes.h _gpg-error.def.h mkw32errmap.tab.h mkw32errmap.map.c" || rm -f err-sources.h err-codes.h code-to-errno.h code-from-errno.h gpg-error.h mkerrcodes mkerrcodes.h gpg-error.def mkw32errmap.tab.h mkw32errmap.map.c err-sources-sym.h err-codes-sym.h errnos-sym.h gpg-extra/errno.h extra-h.in _mkerrcodes.h _gpg-error.def.h mkw32errmap.tab.h mkw32errmap.map.c
I have also post same issue in GitHub but didn't get any update. Hopefully expecting here. Thanks!
I am new in iOS development, Any help would be appreciated !
In order to use a library, the library has to be built with the same architecture as the code you're linking it into. In this case, it looks like those three libraries (libotr.a, libgcrypt.a, libgpg-error.a) were built in 32 bit, so you can't link them into a 64 bit build.
You need to get the x86_64 builds of those three libraries. This might involve rebuilding them yourself. Ideally, you would get/rebuild them in "universal" format, which means the library would contain both architectures, so you can link the same files into both 32bit and 64bit builds.
Notice that the OTRKit build script output says:
[Travis Detected] GPG verification disabled - Compiling for i386 only
i386 is the Intel 32bit architecture. The build script for OTR think's you're Travis, so you need to do export TRAVIS=0 before you build, in order to get the x86_64 arch built.
Someone has already submitted the bug here: https://github.com/ChatSecure/OTRKit/issues/15

Resources