mirror of
https://github.com/ilyakooo0/urbit.git
synced 2025-01-07 23:51:22 +03:00
build: restore division between pkg-config and regular deps
This commit is contained in:
parent
f40b519cce
commit
507c681555
38
pkg/urbit/configure
vendored
38
pkg/urbit/configure
vendored
@ -4,13 +4,29 @@ set -euo pipefail
|
|||||||
|
|
||||||
URBIT_VERSION="$(cat ./version)"
|
URBIT_VERSION="$(cat ./version)"
|
||||||
|
|
||||||
|
# we require pkg-config metadata to statically link these
|
||||||
|
#
|
||||||
|
pkgc_deps=" \
|
||||||
|
libcurl \
|
||||||
|
libh2o \
|
||||||
|
liburcrypt \
|
||||||
|
libuv \
|
||||||
|
openssl \
|
||||||
|
"
|
||||||
|
|
||||||
deps=" \
|
deps=" \
|
||||||
curl gmp sigsegv ent h2o uv murmur3 softfloat3 \
|
ent \
|
||||||
urcrypt ssl crypto z lmdb pthread \
|
gmp \
|
||||||
|
lmdb \
|
||||||
|
murmur3 \
|
||||||
|
pthread \
|
||||||
|
sigsegv \
|
||||||
|
softfloat3 \
|
||||||
"
|
"
|
||||||
|
|
||||||
headers=" \
|
headers=" \
|
||||||
ivory.h ca-bundle.h \
|
ca-bundle.h \
|
||||||
|
ivory.h \
|
||||||
"
|
"
|
||||||
|
|
||||||
echo '#pragma once' >include/config.h
|
echo '#pragma once' >include/config.h
|
||||||
@ -132,8 +148,6 @@ case $(tr A-Z a-z <<< $os) in
|
|||||||
|
|
||||||
defmacro U3_OS_osx 1
|
defmacro U3_OS_osx 1
|
||||||
|
|
||||||
deps="${deps/ssl/openssl}"
|
|
||||||
deps="${deps/uv/libuv}"
|
|
||||||
compat="${compat-} posix m1brew"
|
compat="${compat-} posix m1brew"
|
||||||
;;
|
;;
|
||||||
*linux*)
|
*linux*)
|
||||||
@ -150,7 +164,7 @@ case $(tr A-Z a-z <<< $os) in
|
|||||||
;;
|
;;
|
||||||
*freebsd*)
|
*freebsd*)
|
||||||
defmacro U3_OS_bsd 1
|
defmacro U3_OS_bsd 1
|
||||||
extra_libs="${extra_libs} kvm"
|
deps="$deps kvm" # XX use new compat.mk pattern
|
||||||
;;
|
;;
|
||||||
*openbsd*)
|
*openbsd*)
|
||||||
defmacro U3_OS_bsd 1
|
defmacro U3_OS_bsd 1
|
||||||
@ -168,10 +182,11 @@ then
|
|||||||
PKG_CONFIG="$PKG_CONFIG --static"
|
PKG_CONFIG="$PKG_CONFIG --static"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
for dep in ${osdeps-} $deps
|
CFLAGS="${CFLAGS-} $($PKG_CONFIG --cflags $pkgc_deps)"
|
||||||
do
|
LDFLAGS="${LDFLAGS-} $($PKG_CONFIG --libs $pkgc_deps)"
|
||||||
LDFLAGS="${LDFLAGS-} $($PKG_CONFIG --libs "lib$dep" 2>/dev/null || echo -l$dep)"
|
|
||||||
CFLAGS="${CFLAGS-} $($PKG_CONFIG --cflags "lib$dep" 2>/dev/null || true)"
|
for dep in $deps; do
|
||||||
|
LDFLAGS="${LDFLAGS-} -l$dep"
|
||||||
done
|
done
|
||||||
|
|
||||||
for header in $headers; do
|
for header in $headers; do
|
||||||
@ -179,8 +194,7 @@ for header in $headers; do
|
|||||||
done
|
done
|
||||||
|
|
||||||
compat="${compat-posix}"
|
compat="${compat-posix}"
|
||||||
for citem in $compat
|
for citem in $compat; do
|
||||||
do
|
|
||||||
CFLAGS="${CFLAGS-} -Icompat/$citem"
|
CFLAGS="${CFLAGS-} -Icompat/$citem"
|
||||||
done
|
done
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user