2022-08-31 16:27:46 +00:00
|
|
|
#!/bin/bash
|
|
|
|
LINUX_DIRECTORY=$(pwd)
|
2022-11-11 23:18:46 +00:00
|
|
|
JSONCPP_TAG=1.7.4
|
2022-11-11 16:54:38 +00:00
|
|
|
mkdir -p build
|
2022-08-31 16:27:46 +00:00
|
|
|
|
|
|
|
# Build JsonCPP
|
2022-11-11 23:18:46 +00:00
|
|
|
cd build || exit 1
|
2022-11-11 16:54:38 +00:00
|
|
|
if ! [ -x "$(command -v git)" ]; then
|
|
|
|
echo 'Error: git is not installed.' >&2
|
|
|
|
exit 1
|
|
|
|
fi
|
2022-11-11 23:18:46 +00:00
|
|
|
git -C jsoncpp pull origin $JSONCPP_TAG || git clone https://github.com/open-source-parsers/jsoncpp.git jsoncpp
|
|
|
|
cd jsoncpp || exit 1
|
|
|
|
git checkout $JSONCPP_TAG
|
2022-11-11 16:54:38 +00:00
|
|
|
mkdir -p build
|
2022-11-11 23:18:46 +00:00
|
|
|
cd build || exit 1
|
2022-09-01 04:29:33 +00:00
|
|
|
cmake -DCMAKE_BUILD_TYPE=release -DBUILD_STATIC_LIBS=ON -DBUILD_SHARED_LIBS=ON -DARCHIVE_INSTALL_DIR=. -G "Unix Makefiles" ..
|
2022-11-11 16:54:38 +00:00
|
|
|
make -j"$(nproc)"
|
2022-08-31 16:27:46 +00:00
|
|
|
|
2022-11-11 23:18:46 +00:00
|
|
|
cd "$LINUX_DIRECTORY" || exit 1
|
2022-08-31 16:27:46 +00:00
|
|
|
# Build libSecret
|
2022-09-01 04:29:33 +00:00
|
|
|
# sudo apt install meson libgirepository1.0-dev valac xsltproc gi-docgen docbook-xsl
|
2022-09-01 08:51:06 +00:00
|
|
|
# sudo apt install python3-pip
|
2022-11-28 16:59:23 +00:00
|
|
|
#pip3 install --user meson markdown tomli --upgrade
|
2022-08-31 16:27:46 +00:00
|
|
|
# pip3 install --user gi-docgen
|
2022-11-11 23:18:46 +00:00
|
|
|
cd build || exit 1
|
2022-11-11 16:54:38 +00:00
|
|
|
git -C libsecret pull || git clone https://gitlab.gnome.org/GNOME/libsecret.git libsecret
|
2022-11-11 23:18:46 +00:00
|
|
|
cd libsecret || exit 1
|
2022-11-11 16:54:38 +00:00
|
|
|
if ! [ -x "$(command -v meson)" ]; then
|
|
|
|
echo 'Error: meson is not installed.' >&2
|
|
|
|
exit 1
|
|
|
|
fi
|
2022-08-31 16:27:46 +00:00
|
|
|
meson _build
|
2022-11-11 16:54:38 +00:00
|
|
|
if ! [ -x "$(command -v ninja)" ]; then
|
|
|
|
echo 'Error: ninja is not installed.' >&2
|
|
|
|
exit 1
|
|
|
|
fi
|
2022-08-31 16:27:46 +00:00
|
|
|
ninja -C _build
|