mirror of
https://github.com/zeromq/cppzmq.git
synced 2024-12-13 10:52:57 +01:00
Problem: Travis requires sudo
sudo was required for for pkg-config libzmq build as cppzmq could not find not installed pkg-config libzmq. Solution: cppzmq to use cmake prefix paths for pkg config paths as well.
This commit is contained in:
parent
9d058b3a5e
commit
115bfffc50
@ -4,6 +4,7 @@ language: cpp
|
||||
|
||||
dist: trusty
|
||||
cache: ccache
|
||||
sudo: false
|
||||
|
||||
matrix:
|
||||
include:
|
||||
@ -24,7 +25,6 @@ matrix:
|
||||
|
||||
# GCC default, draft disabled, older libzmq with pkg-config
|
||||
- os: linux
|
||||
sudo: true
|
||||
env: ZMQ_VERSION=4.2.0 BUILD_TYPE=pkgconfig
|
||||
|
||||
# GCC default, draft disabled, default libzmq (defined in ci_build.sh)
|
||||
|
15
ci_build.sh
15
ci_build.sh
@ -25,9 +25,9 @@ libzmq_install() {
|
||||
pushd .
|
||||
cd libzmq-${ZMQ_VERSION}
|
||||
./autogen.sh &&
|
||||
./configure &&
|
||||
make VERBOSE=1 -j${JOBS}
|
||||
sudo make install
|
||||
./configure --prefix=${LIBZMQ} &&
|
||||
make -j${JOBS}
|
||||
make install
|
||||
popd
|
||||
fi
|
||||
}
|
||||
@ -36,9 +36,7 @@ libzmq_install() {
|
||||
# build zeromq first
|
||||
cppzmq_build() {
|
||||
pushd .
|
||||
if [ "${BUILD_TYPE}" = "cmake" ] ; then
|
||||
export ZeroMQ_DIR=${LIBZMQ}
|
||||
fi
|
||||
CMAKE_PREFIX_PATH=${LIBZMQ} \
|
||||
cmake -H. -B${CPPZMQ} -DENABLE_DRAFTS=${ENABLE_DRAFTS}
|
||||
cmake --build ${CPPZMQ} -- -j${JOBS}
|
||||
popd
|
||||
@ -53,10 +51,7 @@ cppzmq_tests() {
|
||||
|
||||
cppzmq_demo() {
|
||||
pushd .
|
||||
if [ "${BUILD_TYPE}" = "cmake" ] ; then
|
||||
export ZeroMQ_DIR=${LIBZMQ}
|
||||
fi
|
||||
cppzmq_DIR=${CPPZMQ} \
|
||||
CMAKE_PREFIX_PATH=${LIBZMQ}:${CPPZMQ} \
|
||||
cmake -Hdemo -Bdemo/build
|
||||
cmake --build demo/build
|
||||
cd demo/build
|
||||
|
@ -1,3 +1,4 @@
|
||||
set(PKG_CONFIG_USE_CMAKE_PREFIX_PATH ON)
|
||||
find_package(PkgConfig)
|
||||
pkg_check_modules(PC_LIBZMQ QUIET libzmq)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user