Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

misc: use explicit filenames instead of wildcards for third-party libs #35

Merged
merged 1 commit into from
Feb 18, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 11 additions & 8 deletions platforms/android/arm64-v8a/external.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,15 @@ set -e
LIBFRAMEUTIL_SHA=30048ca23d41ca0a8f7d5ab75d3f646a19a90182
SOCKPP_SHA=e6c4688a576d95f42dd7628cefe68092f6c5cd0f

echo "Building libraries..."
echo " LIBFRAMEUTIL_SHA: ${LIBFRAMEUTIL_SHA}"
echo " SOCKPP_SHA: ${SOCKPP_SHA}"
echo ""

if [ -z "${BUILD_TYPE}" ]; then
BUILD_TYPE="Release"
fi

if [[ $(uname) == "Linux" ]]; then
NUM_PROCS=$(nproc)
elif [[ $(uname) == "Darwin" ]]; then
Expand All @@ -13,16 +22,10 @@ else
NUM_PROCS=1
fi

echo "Building libraries..."
echo " LIBFRAMEUTIL_SHA: ${LIBFRAMEUTIL_SHA}"
echo " SOCKPP_SHA: ${SOCKPP_SHA}"
echo " NUM_PROCS: ${NUM_PROCS}"
echo "Build type: ${BUILD_TYPE}"
echo "Procs: ${NUM_PROCS}"
echo ""

if [ -z "${BUILD_TYPE}" ]; then
BUILD_TYPE="Release"
fi

rm -rf external
mkdir external
cd external
Expand Down
8 changes: 6 additions & 2 deletions platforms/ios/arm64/external.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ set -e
LIBFRAMEUTIL_SHA=30048ca23d41ca0a8f7d5ab75d3f646a19a90182
SOCKPP_SHA=e6c4688a576d95f42dd7628cefe68092f6c5cd0f

NUM_PROCS=$(sysctl -n hw.ncpu)

echo "Building libraries..."
echo " LIBFRAMEUTIL_SHA: ${LIBFRAMEUTIL_SHA}"
echo " SOCKPP_SHA: ${SOCKPP_SHA}"
Expand All @@ -17,6 +15,12 @@ if [ -z "${BUILD_TYPE}" ]; then
BUILD_TYPE="Release"
fi

NUM_PROCS=$(sysctl -n hw.ncpu)

echo "Build type: ${BUILD_TYPE}"
echo "Procs: ${NUM_PROCS}"
echo ""

rm -rf external
mkdir external
cd external
Expand Down
13 changes: 8 additions & 5 deletions platforms/linux/aarch64/external.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,20 +7,23 @@ LIBSERIALPORT_SHA=21b3dfe5f68c205be4086469335fd2fc2ce11ed2
LIBFRAMEUTIL_SHA=30048ca23d41ca0a8f7d5ab75d3f646a19a90182
SOCKPP_SHA=e6c4688a576d95f42dd7628cefe68092f6c5cd0f

NUM_PROCS=$(nproc)

echo "Building libraries..."
echo " CARGS_SHA: ${CARGS_SHA}"
echo " LIBSERIALPORT_SHA: ${LIBSERIALPORT_SHA}"
echo " LIBFRAMEUTIL_SHA: ${LIBFRAMEUTIL_SHA}"
echo " SOCKPP_SHA: ${SOCKPP_SHA}"
echo " NUM_PROCS: ${NUM_PROCS}"
echo ""

if [ -z "${BUILD_TYPE}" ]; then
BUILD_TYPE="Release"
fi

NUM_PROCS=$(nproc)

echo "Build type: ${BUILD_TYPE}"
echo "Procs: ${NUM_PROCS}"
echo ""

rm -rf external
mkdir external
cd external
Expand All @@ -39,7 +42,7 @@ cmake \
-B build
cmake --build build -- -j${NUM_PROCS}
cp include/cargs.h ../../third-party/include/
cp -a build/*.so ../../third-party/runtime-libs/linux/aarch64/
cp build/libcargs.so ../../third-party/runtime-libs/linux/aarch64/
cd ..

#
Expand All @@ -55,7 +58,7 @@ cp libserialport.h ../../third-party/include
./configure
make -j${NUM_PROCS}
cp .libs/libserialport.a ../../third-party/build-libs/linux/aarch64
cp -a .libs/*.{so,so.*} ../../third-party/runtime-libs/linux/aarch64
cp -a .libs/libserialport.{so,so.*} ../../third-party/runtime-libs/linux/aarch64
cd ..

#
Expand Down
13 changes: 8 additions & 5 deletions platforms/linux/x64/external.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,20 +7,23 @@ LIBSERIALPORT_SHA=21b3dfe5f68c205be4086469335fd2fc2ce11ed2
LIBFRAMEUTIL_SHA=30048ca23d41ca0a8f7d5ab75d3f646a19a90182
SOCKPP_SHA=e6c4688a576d95f42dd7628cefe68092f6c5cd0f

NUM_PROCS=$(nproc)

echo "Building libraries..."
echo " CARGS_SHA: ${CARGS_SHA}"
echo " LIBSERIALPORT_SHA: ${LIBSERIALPORT_SHA}"
echo " LIBFRAMEUTIL_SHA: ${LIBFRAMEUTIL_SHA}"
echo " SOCKPP_SHA: ${SOCKPP_SHA}"
echo " NUM_PROCS: ${NUM_PROCS}"
echo ""

if [ -z "${BUILD_TYPE}" ]; then
BUILD_TYPE="Release"
fi

NUM_PROCS=$(nproc)

echo "Build type: ${BUILD_TYPE}"
echo "Procs: ${NUM_PROCS}"
echo ""

rm -rf external
mkdir external
cd external
Expand All @@ -39,7 +42,7 @@ cmake \
-B build
cmake --build build -- -j${NUM_PROCS}
cp include/cargs.h ../../third-party/include/
cp -a build/*.so ../../third-party/runtime-libs/linux/x64/
cp build/libcargs.so ../../third-party/runtime-libs/linux/x64/
cd ..

#
Expand All @@ -55,7 +58,7 @@ cp libserialport.h ../../third-party/include
./configure
make -j${NUM_PROCS}
cp .libs/libserialport.a ../../third-party/build-libs/linux/x64
cp -a .libs/*.{so,so.*} ../../third-party/runtime-libs/linux/x64
cp -a .libs/libserialport.{so,so.*} ../../third-party/runtime-libs/linux/x64
cd ..

#
Expand Down
14 changes: 9 additions & 5 deletions platforms/macos/arm64/external.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ LIBSERIALPORT_SHA=21b3dfe5f68c205be4086469335fd2fc2ce11ed2
LIBFRAMEUTIL_SHA=30048ca23d41ca0a8f7d5ab75d3f646a19a90182
SOCKPP_SHA=e6c4688a576d95f42dd7628cefe68092f6c5cd0f

NUM_PROCS=$(sysctl -n hw.ncpu)

echo "Building libraries..."
echo " CARGS_SHA: ${CARGS_SHA}"
echo " LIBSERIALPORT_SHA: ${LIBSERIALPORT_SHA}"
Expand All @@ -21,6 +19,12 @@ if [ -z "${BUILD_TYPE}" ]; then
BUILD_TYPE="Release"
fi

NUM_PROCS=$(sysctl -n hw.ncpu)

echo "Build type: ${BUILD_TYPE}"
echo "Procs: ${NUM_PROCS}"
echo ""

rm -rf external
mkdir external
cd external
Expand All @@ -41,7 +45,7 @@ cmake \
-B build
cmake --build build -- -j${NUM_PROCS}
cp include/cargs.h ../../third-party/include/
cp -a build/*.dylib ../../third-party/runtime-libs/macos/arm64/
cp build/libcargs.dylib ../../third-party/runtime-libs/macos/arm64/
cd ..

#
Expand All @@ -57,7 +61,7 @@ cp libserialport.h ../../third-party/include
./configure --host=aarch64-apple-darwin CFLAGS="-arch arm64" LDFLAGS="-Wl,-install_name,@rpath/libserialport.dylib"
make -j${NUM_PROCS}
cp .libs/libserialport.a ../../third-party/build-libs/macos/arm64
cp .libs/libserialport.dylib ../../third-party/runtime-libs/macos/arm64
cp -a .libs/libserialport.{dylib,*.dylib} ../../third-party/runtime-libs/macos/arm64
cd ..

#
Expand Down Expand Up @@ -88,5 +92,5 @@ cmake \
-B build
cmake --build build -- -j${NUM_PROCS}
cp -r include/sockpp ../../third-party/include/
cp -a build/*.dylib ../../third-party/runtime-libs/macos/arm64/
cp -a build/libsockpp.{dylib,*.dylib} ../../third-party/runtime-libs/macos/arm64/
cd ..
14 changes: 9 additions & 5 deletions platforms/macos/x64/external.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ LIBSERIALPORT_SHA=21b3dfe5f68c205be4086469335fd2fc2ce11ed2
LIBFRAMEUTIL_SHA=30048ca23d41ca0a8f7d5ab75d3f646a19a90182
SOCKPP_SHA=e6c4688a576d95f42dd7628cefe68092f6c5cd0f

NUM_PROCS=$(sysctl -n hw.ncpu)

echo "Building libraries..."
echo " CARGS_SHA: ${CARGS_SHA}"
echo " LIBSERIALPORT_SHA: ${LIBSERIALPORT_SHA}"
Expand All @@ -21,6 +19,12 @@ if [ -z "${BUILD_TYPE}" ]; then
BUILD_TYPE="Release"
fi

NUM_PROCS=$(sysctl -n hw.ncpu)

echo "Build type: ${BUILD_TYPE}"
echo "Procs: ${NUM_PROCS}"
echo ""

rm -rf external
mkdir external
cd external
Expand All @@ -41,7 +45,7 @@ cmake \
-B build
cmake --build build -- -j${NUM_PROCS}
cp include/cargs.h ../../third-party/include/
cp -a build/*.dylib ../../third-party/runtime-libs/macos/x64/
cp build/libcargs.dylib ../../third-party/runtime-libs/macos/x64/
cd ..

#
Expand All @@ -57,7 +61,7 @@ cp libserialport.h ../../third-party/include
./configure --host=x86_64-apple-darwin CFLAGS="-arch x86_64" LDFLAGS="-Wl,-install_name,@rpath/libserialport.dylib"
make -j${NUM_PROCS}
cp .libs/libserialport.a ../../third-party/build-libs/macos/x64
cp .libs/libserialport.dylib ../../third-party/runtime-libs/macos/x64
cp -a .libs/libserialport.{dylib,*.dylib} ../../third-party/runtime-libs/macos/x64
cd ..

#
Expand Down Expand Up @@ -88,5 +92,5 @@ cmake \
-B build
cmake --build build -- -j${NUM_PROCS}
cp -r include/sockpp ../../third-party/include/
cp -a build/*.dylib ../../third-party/runtime-libs/macos/x64/
cp -a build/libsockpp.{dylib,*.dylib} ../../third-party/runtime-libs/macos/x64/
cd ..
8 changes: 6 additions & 2 deletions platforms/tvos/arm64/external.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ set -e
LIBFRAMEUTIL_SHA=30048ca23d41ca0a8f7d5ab75d3f646a19a90182
SOCKPP_SHA=e6c4688a576d95f42dd7628cefe68092f6c5cd0f

NUM_PROCS=$(sysctl -n hw.ncpu)

echo "Building libraries..."
echo " LIBFRAMEUTIL_SHA: ${LIBFRAMEUTIL_SHA}"
echo " SOCKPP_SHA: ${SOCKPP_SHA}"
Expand All @@ -17,6 +15,12 @@ if [ -z "${BUILD_TYPE}" ]; then
BUILD_TYPE="Release"
fi

NUM_PROCS=$(sysctl -n hw.ncpu)

echo "Build type: ${BUILD_TYPE}"
echo "Procs: ${NUM_PROCS}"
echo ""

rm -rf external
mkdir external
cd external
Expand Down