mirror of
https://codeberg.org/kiss-community/repo
synced 2024-11-15 19:20:10 -07:00
cmake: build with cmake if available
This commit is contained in:
parent
969bd3897e
commit
3a36ae23fb
@ -1,10 +1,24 @@
|
|||||||
#!/bin/sh -e
|
#!/bin/sh -e
|
||||||
|
|
||||||
./configure \
|
# Use cmake to build cmake if installed.
|
||||||
--prefix=/usr
|
# This leads to a much faster build.
|
||||||
|
if kiss l cmake; then
|
||||||
|
cmake -B build \
|
||||||
|
-DCMAKE_INSTALL_PREFIX=/usr \
|
||||||
|
-DCMAKE_INSTALL_LIBDIR=/usr/lib \
|
||||||
|
-DCMAKE_SHARED_LIBS=True \
|
||||||
|
-DCMAKE_BUILD_TYPE=Release
|
||||||
|
|
||||||
make
|
cmake --build build
|
||||||
make DESTDIR="$1" install
|
DESTDIR="$1" cmake --install build
|
||||||
|
|
||||||
|
else
|
||||||
|
./configure \
|
||||||
|
--prefix=/usr
|
||||||
|
|
||||||
|
make
|
||||||
|
make DESTDIR="$1" install
|
||||||
|
fi
|
||||||
|
|
||||||
# Grab the package version.
|
# Grab the package version.
|
||||||
IFS=. read -r ver1 ver2 _ < "${0%/*}/version"
|
IFS=. read -r ver1 ver2 _ < "${0%/*}/version"
|
||||||
|
Loading…
Reference in New Issue
Block a user