Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
L
libzmq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
libzmq
Commits
eda042d6
Commit
eda042d6
authored
Nov 05, 2014
by
Pieter Hintjens
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1243 from jemc/master
Problem: qt-android build doesn't fully work for downstream builds
parents
57eff1be
5b6293c5
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
29 additions
and
29 deletions
+29
-29
.travis.yml
.travis.yml
+2
-2
android_build_helper.sh
builds/qt-android/android_build_helper.sh
+2
-2
build.sh
builds/qt-android/build.sh
+25
-25
No files found.
.travis.yml
View file @
eda042d6
...
@@ -3,8 +3,8 @@
...
@@ -3,8 +3,8 @@
language
:
c
language
:
c
env
:
env
:
-
BUILD_TYPE=default
-
BUILD_TYPE=default
-
BUILD_TYPE=qt-android
-
BUILD_TYPE=qt-android
# Build and check this project according to the BUILD_TYPE
# Build and check this project according to the BUILD_TYPE
script
:
./ci_build.sh
script
:
./ci_build.sh
builds/qt-android/android_build_helper.sh
View file @
eda042d6
...
@@ -60,7 +60,7 @@ ANDROID_BUILD_FAIL=()
...
@@ -60,7 +60,7 @@ ANDROID_BUILD_FAIL=()
function
android_build_check_fail
{
function
android_build_check_fail
{
if
[
!
${#
ANDROID_BUILD_FAIL
[@]
}
-eq
0
]
;
then
if
[
!
${#
ANDROID_BUILD_FAIL
[@]
}
-eq
0
]
;
then
echo
"
qt-a
ndroid build failed for the following reasons:"
echo
"
A
ndroid build failed for the following reasons:"
for
reason
in
"
${
ANDROID_BUILD_FAIL
[@]
}
"
;
do
for
reason
in
"
${
ANDROID_BUILD_FAIL
[@]
}
"
;
do
local
formatted_reason
=
"
${
reason
}
"
local
formatted_reason
=
"
${
reason
}
"
echo
"
${
formatted_reason
}
"
echo
"
${
formatted_reason
}
"
...
@@ -248,7 +248,7 @@ function android_build_opts {
...
@@ -248,7 +248,7 @@ function android_build_opts {
local
CFLAGS
=
"--sysroot=
${
ANDROID_BUILD_SYSROOT
}
-I
${
ANDROID_BUILD_PREFIX
}
/include"
local
CFLAGS
=
"--sysroot=
${
ANDROID_BUILD_SYSROOT
}
-I
${
ANDROID_BUILD_PREFIX
}
/include"
local
CPPFLAGS
=
"--sysroot=
${
ANDROID_BUILD_SYSROOT
}
-I
${
ANDROID_BUILD_PREFIX
}
/include"
local
CPPFLAGS
=
"--sysroot=
${
ANDROID_BUILD_SYSROOT
}
-I
${
ANDROID_BUILD_PREFIX
}
/include"
local
CXXFLAGS
=
"--sysroot=
${
ANDROID_BUILD_SYSROOT
}
-I
${
ANDROID_BUILD_PREFIX
}
/include"
local
CXXFLAGS
=
"--sysroot=
${
ANDROID_BUILD_SYSROOT
}
-I
${
ANDROID_BUILD_PREFIX
}
/include"
local
LDFLAGS
=
""
local
LDFLAGS
=
"
-L
${
ANDROID_BUILD_PREFIX
}
/lib
"
local
LIBS
=
"-lc -lgcc -ldl"
local
LIBS
=
"-lc -lgcc -ldl"
_android_build_opts_process_binaries
_android_build_opts_process_binaries
...
...
builds/qt-android/build.sh
View file @
eda042d6
#!/usr/bin/env bash
#!/usr/bin/env bash
# Get directory of current script
# Use directory of current script as the build directory and working directory
ANDROID_BUILD_DIR
=
"
$(
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
&&
pwd
)
"
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
ANDROID_BUILD_DIR
=
"
$(
pwd
)
"
# Get access to android_build functions and variables
# Get access to android_build functions and variables
source
${
ANDROID_BUILD_DIR
}
/android_build_helper.sh
source
${
ANDROID_BUILD_DIR
}
/android_build_helper.sh
...
@@ -13,44 +14,43 @@ ANDROID_BUILD_CXXSTL="gnustl_shared_48"
...
@@ -13,44 +14,43 @@ ANDROID_BUILD_CXXSTL="gnustl_shared_48"
android_build_env
android_build_env
android_build_opts
android_build_opts
#
Clear
a temporary build directory
#
Use
a temporary build directory
cache
=
"/tmp/android_build/
${
TOOLCHAIN_NAME
}
"
cache
=
"/tmp/android_build/
${
TOOLCHAIN_NAME
}
"
rm
-rf
"
${
cache
}
"
mkdir
-p
"
${
cache
}
"
mkdir
-p
"
${
cache
}
"
##
# Build libsodium from latest release tarball
echo
(
android_build_verify_so
"libsodium.so"
&> /dev/null
)
||
{
echo
"Building qt-android libsodium from latest release tarball..."
rm
-rf
"
${
cache
}
/libsodium"
echo
(
cd
"
${
cache
}
"
&&
mkdir
libsodium
\
&&
wget https://download.libsodium.org/libsodium/releases/LATEST.tar.gz
\
-O
"
${
cache
}
/libsodium.tar.gz"
\
&&
tar
-C
libsodium
-xf
libsodium.tar.gz
--strip
=
1
)
||
exit
1
wget
"https://download.libsodium.org/libsodium/releases/LATEST.tar.gz"
\
(
cd
"
${
cache
}
/libsodium"
&&
./autogen.sh
\
-O
"
${
cache
}
/libsodium.tar.gz"
(
cd
"
${
cache
}
"
&&
mkdir
libsodium
\
&&
tar
-C
libsodium
-xf
libsodium.tar.gz
--strip
=
1
\
&&
cd
"libsodium"
&&
./autogen.sh
\
&&
./configure
"
${
ANDROID_BUILD_OPTS
[@]
}
"
--disable-soname-versions
\
&&
./configure
"
${
ANDROID_BUILD_OPTS
[@]
}
"
--disable-soname-versions
\
&&
make
\
&&
make
\
&&
make
install
)
||
exit
1
&&
make
install
)
||
exit
1
}
##
# Build libzmq from local source
echo
LIBTOOL_EXTRA_LDFLAGS
=
'-avoid-version'
echo
"Building qt-android libzmq from local source..."
echo
cp
-r
../..
"
${
cache
}
/libzmq"
(
android_build_verify_so
"libzmq.so"
"libsodium.so"
&> /dev/null
)
||
{
rm
-rf
"
${
cache
}
/libzmq"
(
cp
-r
../..
"
${
cache
}
/libzmq"
&&
cd
"
${
cache
}
/libzmq"
&&
make clean
)
(
cd
"
${
cache
}
/libzmq"
&&
./autogen.sh
\
(
cd
"
${
cache
}
/libzmq"
&&
./autogen.sh
\
&&
./configure
"
${
ANDROID_BUILD_OPTS
[@]
}
"
--with-libsodium
=
yes
\
&&
./configure
"
${
ANDROID_BUILD_OPTS
[@]
}
"
--with-libsodium
=
yes
\
&&
make
\
&&
make
\
&&
make
install
)
||
exit
1
&&
make
install
)
||
exit
1
}
echo
##
echo
"Verifying qt-android libsodium.so and libzmq.so libraries..."
# Verify shared libraries in prefix
echo
android_build_verify_so
"libsodium.so"
android_build_verify_so
"libsodium.so"
android_build_verify_so
"libzmq.so"
"libsodium.so"
android_build_verify_so
"libzmq.so"
"libsodium.so"
echo
echo
"Completed qt-android build!"
echo
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment