I have followed all the steps written in the pjsip-startup guide.
But the last step (make dep && make clean && make) is giving me the following errors. I am on Windows 7.
$ make dep && make clean && make
for dir in pjlib/build pjlib-util/build pjnath/build third_party/build pjmedia/b uild pjsip/build pjsip-apps/build ; do \
if make -C $dir dep; then \
true; \
else \
exit 1; \
fi; \
done
make[1]: Entering directory '/cygdrive/d/android/pjproject-2.2.1/pjlib/build'
make -f /cygdrive/d/android/pjproject-2.2.1/build/rules.mak APP=PJLIB app=pjlib depend
make[2]: Entering directory '/cygdrive/d/android/pjproject-2.2.1/pjlib/build'
.pjlib-arm-unknown-linux-androideabi.depend:1: *** multiple target patterns. St op.
make[2]: Leaving directory '/cygdrive/d/android/pjproject-2.2.1/pjlib/build'
Makefile:88: recipe for target 'depend' failed
make[1]: *** [depend] Error 2
make[1]: Leaving directory '/cygdrive/d/android/pjproject-2.2.1/pjlib/build'
Makefile:14: recipe for target 'dep' failed
make: *** [dep] Error 1
Can someone help me to resolve these errors? Thanks!
After some research I come to know that don't use WINDOWS for building the PJSIP v2.x version. Now I am going to install Ubuntu on my system.
The build system is known to work on the following hosts:
Linux, many types of distributions.
MacOS X 10.2 mingw (Win2K, XP)
FreeBSD (must use gmake instead of make)
Building Win32 applications with Cygwin is currently not supported by the autoconf script (there are some conflicts with Windows headers), but one can still use the old configure script by calling ./configure-legacy. More over, cross-compilations might also work with Cygwin using this build system.
See the link for details.
Related
I'm experiencing an issue with Qt Creator in Windows:
I made an application that is using QtSerialPort and QtSerialBus libraries, I built and deployed it for windows and everything went well.
Now I'm trying to built it for Android but those libraries are not available as the official documentation states.
I downloaded the sources of QtSerialPort and QtSerialBus from Github and I'm now trying to build them by myself for Android.
AFAIK the issue I'm encountering is in the make install step, and this is the message I get:
08:05:28: Starting: "C:\Android\ndk-bundle\prebuilt\windows-x86_64\bin\make.exe" "INSTALL_ROOT=C:\Users\giovanni.lucenti\Downloads\qtserialport\android-build" install
cd src\ && ( if not exist Makefile C:\Qt\5.14.2\android\bin\qmake.exe -o Makefile C:\Users\giovanni.lucenti\Downloads\qtserialport-dev\src\src.pro -spec android-clang "CONFIG+=qtquickcompiler" "ANDROID_ABIS=armeabi-v7a" ) && C:/Android/ndk-bundle/prebuilt/windows-x86_64/bin/make -f Makefile install
make[1]: Entering directory 'C:/Users/giovanni.lucenti/Downloads/qtserialport/src'
cd serialport\ && ( if not exist Makefile C:\Qt\5.14.2\android\bin\qmake.exe -o Makefile C:\Users\giovanni.lucenti\Downloads\qtserialport-dev\src\serialport\serialport.pro -spec android-clang "CONFIG+=qtquickcompiler" "ANDROID_ABIS=armeabi-v7a" ) && C:/Android/ndk-bundle/prebuilt/windows-x86_64/bin/make -f Makefile install
make[2]: Entering directory 'C:/Users/giovanni.lucenti/Downloads/qtserialport/src/serialport'
La sintassi del nome del file, della directory o del volume non Š corretta.
make[2]: *** [Makefile:639: install_target] Error 1
make[2]: Leaving directory 'C:/Users/giovanni.lucenti/Downloads/qtserialport/src/serialport'
make[1]: *** [Makefile:59: sub-serialport-install_subtargets] Error 2
make[1]: Leaving directory 'C:/Users/giovanni.lucenti/Downloads/qtserialport/src'
make: *** [Makefile:61: sub-src-install_subtargets] Error 2
08:05:30: The process "C:\Android\ndk-bundle\prebuilt\windows-x86_64\bin\make.exe" exited with code 2.
Error while building/deploying project qtserialport (kit: Android for armeabi-v7a,arm64-v8a,x86,x86_64 (Clang Qt 5.14.2 for Android))
When executing step "Copy application data"
08:05:30: Elapsed time: 00:23.
I already tried to move the folder in a shorter path (C:\tmpbuild) but everything goes the same.
Am I missing something?
Where am I supposed to set the make install target path?
These are my Qt Creator build settings
You can't use QSerialPort on Android, as it is not suported there.
There is a very good instruction in Redex page at http://fbredex.com/.
I follow the instruction but I have problem in two steps.
1.I have no problem with run of first command (my OS is Ubuntu)
sudo apt-get install \
g++ \
automake \
autoconf \
autoconf-archive \
libtool \
libboost-all-dev \
libevent-dev \
libdouble-conversion-dev \
libgoogle-glog-dev \
libgflags-dev \
liblz4-dev \
liblzma-dev \
libsnappy-dev \
make \
zlib1g-dev \
binutils-dev \
libjemalloc-dev \
libssl-dev \
libiberty-dev
I clone folly repo somewhere on my laptop
I go to the directory by $ cd android/projects/folly/folly/
I run git submodule update --init but nothing happens. I even run this command in $ cd android/projects/folly/ but nothing happens either.
I run autoreconf -ivf && ./configure && make && make install. Seems works as I see process takes around a minute or two and there are a lot og messages print out.
I copy/paste a sample .apk file to my Desktop and run redex ~/Desktop/my_android_app.apk -o ~/Desktop/my_android_app-redexed.apk. However, I'm getting this message on terminal.
No command 'redex' found, did you mean: Command 'redet' from package
'redet' (universe) redex: command not found
I ran above command when I am in /home/hesam/android/projects/folly/folly or /home/hesam/android/projects/folly/. But I get same output.
Update
I cloned Redex repo and followed Bert's Instruction. It works and I could see something is happening by running git submodule update --init. So thanks to Bert. However, I got error at the end of autoreconf -ivf && ./configure && make && make install command.
Please have a look at following output:
Making all in unit
make[3]: Entering directory `/home/hesam/android/projects/redex/test/unit'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/hesam/android/projects/redex/test/unit'
make[2]: Leaving directory `/home/hesam/android/projects/redex/test'
make[1]: Leaving directory `/home/hesam/android/projects/redex'
Making install in third-party/folly/folly
make[1]: Entering directory `/home/hesam/android/projects/redex/third-party/folly/folly'
Making install in .
make[2]: Entering directory `/home/hesam/android/projects/redex/third-party/folly/folly'
make[3]: Entering directory `/home/hesam/android/projects/redex/third-party/folly/folly'
/bin/mkdir -p '/usr/local/lib'
/bin/bash ./libtool --mode=install /usr/bin/install -c libfolly.la libfollybenchmark.la '/usr/local/lib'
libtool: install: /usr/bin/install -c .libs/libfolly.so.57.0.0 /usr/local/lib/libfolly.so.57.0.0
/usr/bin/install: cannot create regular file '/usr/local/lib/libfolly.so.57.0.0': Permission denied
make[3]: *** [install-libLTLIBRARIES] Error 1
make[3]: Leaving directory `/home/hesam/android/projects/redex/third-party/folly/folly'
make[2]: *** [install-am] Error 2
make[2]: Leaving directory `/home/hesam/android/projects/redex/third-party/folly/folly'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/home/hesam/android/projects/redex/third-party/folly/folly'
make: *** [install-recursive] Error 1
hesam: redex (master) $ redex ~/Desktop/my_android_app.apk -o ~/Desktop/my_android_app-redexed.apk
No command 'redex' found, did you mean:
Command 'redet' from package 'redet' (universe)
redex: command not found
hesam: redex (master) $
You don't need to separately clone folly; it's included as a submodule of redex. Just do:
git clone https://github.com/facebook/redex.git
cd redex
git submodule update --init
and then configure/make according to the instructions.
there is a difference regard instructions you see in fbredex and what you see in Github redex page. Please follow what Github page says for make and install.
autoreconf -ivf && ./configure && make
sudo make install
Regard my above problem, A developer from Redex team called me and after few minutes he found and solved the problem. He has updated FAQ section on Redex page that you can see at here. Since there is no explanation there I copy/paste what he said on chat.
So, as an optimization, the runtime linker doesn't actually go
trawling through everything to look for libs anymore It uses the cache
file, which is generated by ldconfig
Update
I forgot to mention that you must have ANDROID_SDK in your PATH. I have following paths in my .profile. Don't forget to source it after making change in it. ~/android/sdk is path to my Android SDK directory.
export ANDROID_HOME=~/android/sdk
export ANDROID_SDK=${ANDROID_HOME}
export PATH=${PATH}:$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools
I'm trying to compile GMP for android (arm) but I'm received a very strange error. First, I set up a few things as described another SO question here:
export NDKROOT=/prod/ndk
$NDKROOT/build/tools/make-standalone-toolchain.sh --platform=android-9 -- install-dir=$NDKROOT/android_armeabi
export CC="$NDKROOT/android_armeabi/bin/arm-linux-androideabi-gcc --sysroot=$NDKROOT/android_armeabi/sysroot"
export CXX="$NDKROOT/android_armeabi/bin/arm-linux-androideabi-g++ --sysroot=$NDKROOT/android_armeabi/sysroot"
export AR="$NDKROOT/android_armeabi/bin/arm-linux-androideabi-ar"
export SYSROOT="$NDKROOT/android_armeabi/sysroot"
export PATH="$NDKROOT/android_armeabi/bin":$PATH
Then I simply run ./configure --enable-cxx --prefix=/local/to/where/i/want/to/install --host=arm-none-linux-gnueabi and configuration goes well, with the following being part of the output:
Version: GNU MP 5.1.1
Host type: arm-none-linux-gnueabi
ABI: standard
Install prefix: /location/to/where/i/want/to/install
Compiler: /prod/ndk/android_armeabi/bin/arm-linux-androideabi-gcc -- sysroot=/prod/ndk/android_armeabi/sysroot -std=gnu99
Static libraries: yes
Shared libraries: yes
Up to here it goes well, but when I run make, I receive the following error:
ismpf.cc: In function 'std::istream& operator>>(std::istream&, mpf_ptr)':
ismpf.cc:48:43: error: 'struct lconv' has no member named 'decimal_point'
make[2]: *** [ismpf.lo] Error 1
make[2]: Leaving directory `~/Downloads/gmp-5.1.1/cxx'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `~/Downloads/gmp-5.1.1'
make: *** [all] Error 2
So my first problem is there. Any ideas?
Just out of curiosity, I tried to rerun the same exact configure command as above but using sudo ahead of it. After a few seconds I receive the following:
configure: error: Oops, mp_limb_t is 64 bits, but the assembler code
in this configuration expects 32 bits.
There is the second (and really weird problem that arises).
Just out of curiosity again, I tried to reboot and clear all the variables we created, and simply run the command that the GMP manual recommends:
./configure --prefix=/location/ --enable-cxx --host=arm-linux-androideabi
The ./configure runs, the make goes well, but all 9/9 tests fail when I do make check. Can anybody point me in the right direction with these errors, or about how to try and correctly compile GMP for android? Any help is immensely appreciated.
Unsetting the CFLAGS env var solved the problem for me.
i have downloaded the latest android ndk r8b on my ubuntu 12.10 beta 2 .
i have included the ndk directory in the PATH variable (when i write ndk-b in terminal and hit tab it auto-completes it) .
but when i try :
cd android-ndk/samples/san-angeles/jni
ndk-build
i get this error:
make: /home/mixpro/Android/android-ndk/toolchains/arm-linux-androideabi-4.6/prebuilt/linux-x86/bin/arm-linux-androideabi-gcc: Command not found
make: /home/mixpro/Android/android-ndk/toolchains/arm-linux-androideabi-4.6/prebuilt/linux-x86/bin/arm-linux-androideabi-gcc: Command not found
Compile thumb : sanangeles <= importgl.c
make: /home/mixpro/Android/android-ndk/toolchains/arm-linux-androideabi-4.6/prebuilt/linux-x86/bin/arm-linux-androideabi-gcc: Command not found
make: *** [/home/mixpro/Android/android-ndk/samples/san-angeles/obj/local/armeabi/objs/sanangeles/importgl.o] Error 127
when checking the /android-ndk/toolchains/arm-linux-androideabi-4.6/prebuilt/linux-x86/bin directory using ls i get:
arm-linux-androideabi-addr2line arm-linux-androideabi-g++
arm-linux-androideabi-gdbtui arm-linux-androideabi-size
arm-linux-androideabi-c++filt arm-linux-androideabi-gcc-4.6.x-google
arm-linux-androideabi-gprof arm-linux-androideabi-strings
arm-linux-androideabi-cpp arm-linux-androideabi-gcov
arm-linux-androideabi-readelf arm-linux-androideabi-elfedit
arm-linux-androideabi-gdb arm-linux-androideabi-run
meaning there is no arm-linux-androideabi-gcc in the directory
I am afraid that somehow you got arm-linux-androideabi-addr2line arm-linux-androideabi-gcc deleted. On linux, it is just a symlink to arm-linux-androideabi-gcc-4.6.x-google, so it's very easy to restore it. But maybe, to be on the safe side, it's worthwhile to reinstall NDK.
you should create symbolic link like this : ln -s /usr/bin/arm-linux-gnueabi-gcc-4.7 "/home/sofien/Bureau/android-ndk-r8c/toolchains/arm-linux-androideabi-4.6/prebuilt/linux-x86/bin/arm-linux-androideabi-gcc"
I'm trying to compile vlc using the following instructions http://wiki.videolan.org/AndroidCompile.
i get the vlc source using git but when i'm doing the next command:
cd extras/contrib
./bootstrap -t arm-eabi -d android
i'm getting this error:
[contrib] No install dir specified, using '/android-sdk-mac_x86/vlc-android/extras/contrib/hosts/arm-eabi'
[contrib] *****************************************************************
[contrib] * If you need contribs with all debug information, run this *
[contrib] * line and compile the libraries on your own. *
[contrib] * CONTRIBS_RELEASE=no ./bootstrap *
[contrib] *****************************************************************
[contrib] Using 1 processor(s)
when i make the next step that is 'make' i got the following failure;
make -C build-src tools
make[1]: Nothing to be done for `tools'.
make -C build-src
(cd zlib; CC="arm-linux-androideabi-gcc --sysroot=/android-ndk-r5b//platforms/android-9/arch-arm" CXX="arm-linux-androideabi-g++ --sysroot=/android-ndk-r5b//platforms/android-9/arch-arm" LD="arm-linux-androideabi-ld" RANLIB="arm-linux-androideabi-ranlib" AR="arm-linux-androideabi-ar" STRIP="arm-linux-androideabi-strip" ./configure --prefix=/android-sdk-mac_x86/vlc-android/extras/contrib/hosts/arm-eabi --static && make install)
Building static library libz.a version 1.2.5 with arm-linux-androideabi-gcc --sysroot=/android-ndk-r5b//platforms/android-9/arch-arm.
Checking for off64_t... No.
Checking for fseeko... No.
Checking for unistd.h... No.
Checking whether to use vs[n]printf() or s[n]printf()... using s[n]printf().
Checking for snprintf() in stdio.h... No.
WARNING: snprintf() not found, falling back to sprintf(). zlib
can build but will be open to possible buffer-overflow security
vulnerabilities.
Checking for return value of sprintf()... No.
WARNING: apparently sprintf() does not return a value. zlib
can build but will be open to possible string-format security
vulnerabilities.
arm-linux-androideabi-gcc --sysroot=/android-ndk-r5b//platforms/android-9/arch-arm -I/android-sdk-mac_x86/vlc-android/extras/contrib/hosts/arm-eabi/include -DNDEBUG -D__STDC_VERSION__=199901L -I/android-ndk-r5b//sources/cxx-stl/gnu-libstdc++/include -I/android-ndk-r5b//sources/cxx-stl/gnu-libstdc++/libs/armeabi/include -isystem /android-sdk-mac_x86/vlc-android/extras/contrib/hosts/arm-eabi/include -I/android-ndk-r5b//platforms/android-9/arch-arm/usr/include -DNO_FSEEKO -DNO_snprintf -DHAS_sprintf_void -I/android-sdk-mac_x86/vlc-android/extras/contrib/hosts/arm-eabi/include -DNDEBUG -D__STDC_VERSION__=199901L -I/android-ndk-r5b//sources/cxx-stl/gnu-libstdc++/include -I/android-ndk-r5b//sources/cxx-stl/gnu-libstdc++/libs/armeabi/include -isystem /android-sdk-mac_x86/vlc-android/extras/contrib/hosts/arm-eabi/include -I/android-ndk-r5b//platforms/android-9/arch-arm/usr/include -c -o adler32.o adler32.c
make[2]: arm-linux-androideabi-gcc: No such file or directory
make[2]: *** [adler32.o] Error 1
make[1]: *** [.zlib] Error 2
make: *** [using-src] Error 2
anyone can help? i'm using mac OS X 10.6.6
tnx
Given prior Linux CLI experience, the best I can tell you is that it doesn't look like your tool-chain is fully initialized and needs some setup. Below is a link that documents initialization for a MAC build environment:
http://source.android.com/source/initializing.html
You probably should have set your NDK installation properly.
Download the latest Android NDK.
Unzip and move the extracted “android-ndk-r6″ directory to “/Applications”, so you end up with “/Applications/android-ndk-r6″.
Edit “~/.profile” to add the following:
export ANDROID_NDK=/Applications/android-ndk-r5b
export PATH=$PATH:$ANDROID_NDK:$ANDROID_NDK/toolchains/arm-linux-androideabi-4.4.3/prebuilt/darwin-x86/bin
The PATH was the key to solve this kind of problem to me. Because it makes possible to find and use "arm-linux-androideabi-gcc".
Refer to this web site.
http://www.doitscared.com/632/eclipse-indigo-for-android-development-on-mac-os-x-snow-leopard/