Skip to content

Commit

Permalink
sagemathgh-39119: build/pkgs/ccache: Update to 4.10.2
Browse files Browse the repository at this point in the history
    
I also modified `sdh_cmake` slightly, because inputting `.` and `..`
together issued a warning.

Resolves sagemath#35872.
    
URL: sagemath#39119
Reported by: gmou3
Reviewer(s): gmou3, Kwankyu Lee
  • Loading branch information
Release Manager committed Dec 18, 2024
2 parents 50a161c + 02273ef commit c6759ef
Show file tree
Hide file tree
Showing 17 changed files with 66 additions and 76 deletions.
13 changes: 6 additions & 7 deletions build/bin/sage-dist-helpers
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,9 @@
#
# - sdh_cmake [...]
#
# Runs `cmake` in the current directory with the given arguments, as well as
# additional arguments passed to cmake (assuming packages are using the
# GNUInstallDirs module) so that `CMAKE_INSTALL_PREFIX` and
# `CMAKE_INSTALL_LIBDIR` are set correctly.
# Runs `cmake` with the given arguments, as well as additional arguments
# (assuming packages are using the GNUInstallDirs module) so that
# `CMAKE_INSTALL_PREFIX` and `CMAKE_INSTALL_LIBDIR` are set correctly.
#
# - sdh_install [-T] SRC [SRC...] DEST
#
Expand Down Expand Up @@ -416,9 +415,9 @@ sdh_pip_uninstall() {

sdh_cmake() {
echo "Configuring $PKG_NAME with cmake"
cmake . -DCMAKE_INSTALL_PREFIX="${SAGE_INST_LOCAL}" \
-DCMAKE_INSTALL_LIBDIR=lib \
"$@"
cmake -DCMAKE_INSTALL_PREFIX="${SAGE_INST_LOCAL}" \
-DCMAKE_INSTALL_LIBDIR=lib \
"$@"
if [ $? -ne 0 ]; then
if [ -f "$(pwd)/CMakeFiles/CMakeOutput.log" ]; then
sdh_die <<_EOF_
Expand Down
2 changes: 1 addition & 1 deletion build/pkgs/bliss/spkg-install.in
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ if [ "$UNAME" = "Darwin" ]; then
export LDFLAGS
fi
cd src
sdh_cmake -DUSE_GMP=OFF -DCMAKE_VERBOSE_MAKEFILE=ON
sdh_cmake -DUSE_GMP=OFF -DCMAKE_VERBOSE_MAKEFILE=ON .
sdh_make
sdh_make_install
7 changes: 4 additions & 3 deletions build/pkgs/ccache/checksums.ini
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
tarball=ccache-VERSION.tar.bz2
sha1=3653e0765f01697c449f7026c479fbd9526323a7
sha256=fa9d7f38367431bc86b19ad107d709ca7ecf1574fdacca01698bdf0a47cd8567
tarball=ccache-VERSION.tar.xz
sha1=cff97f7592f5042eb43cb54a6d12a1ce7e49da62
sha256=c0b85ddfc1a3e77b105ec9ada2d24aad617fa0b447c6a94d55890972810f0f5a
upstream_url=https://github.com/ccache/ccache/releases/download/vVERSION/ccache-VERSION.tar.xz
2 changes: 1 addition & 1 deletion build/pkgs/ccache/dependencies
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
zlib
cmake xz

----------
All lines of this file are ignored except the first.
1 change: 1 addition & 0 deletions build/pkgs/ccache/distros/arch.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ccache
2 changes: 1 addition & 1 deletion build/pkgs/ccache/package-version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.3.4
4.10.2
15 changes: 0 additions & 15 deletions build/pkgs/ccache/patches/01-apple-gcc-id.patch

This file was deleted.

14 changes: 7 additions & 7 deletions build/pkgs/ccache/spkg-install.in
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
cd src

# Use newer version of config.guess and config.sub (see Issue #23710)
cp "$SAGE_ROOT"/config/config.* .

export CPPFLAGS="-I$SAGE_LOCAL/include $CPPFLAGS"
sdh_configure
mkdir build
cd build
sdh_cmake -DCMAKE_BUILD_TYPE=Release \
-DENABLE_TESTING=OFF \
-DREDIS_STORAGE_BACKEND=OFF \
..
sdh_make
sdh_make_install


set -e

mkdir -p "$SAGE_LOCAL/libexec/ccache"
Expand All @@ -21,4 +21,4 @@ ln -sf ../../bin/ccache "$SAGE_LOCAL/libexec/ccache/clang++"

# Copy a reasonable default configuration for Sage
# (cache size of 4G and compression enabled)
cp -p ../ccache.conf "$SAGE_LOCAL/etc"
cp -p ../../ccache.conf "$SAGE_LOCAL/etc"
3 changes: 2 additions & 1 deletion build/pkgs/dsdp/spkg-install.in
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ sdh_cmake -DCMAKE_BUILD_TYPE=Release \
-DBUILD_SHARED_LIBS=ON \
-DBLA_VENDOR=OpenBLAS \
-DBLAS_LIBRARIES="$(pkg-config --libs blas)" \
-DLAPACK_LIBRARIES="$(pkg-config --libs lapack)"
-DLAPACK_LIBRARIES="$(pkg-config --libs lapack)" \
.
sdh_make
sdh_make_install
1 change: 1 addition & 0 deletions build/pkgs/primecount/spkg-install.in
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ sdh_cmake -DCMAKE_VERBOSE_MAKEFILE=ON \
-DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=BOTH \
-DCMAKE_INSTALL_PREFIX=$SAGE_LOCAL \
-DWITH_POPCNT=OFF \
. \
&& sdh_make_install
}

Expand Down
3 changes: 2 additions & 1 deletion build/pkgs/primesieve/spkg-install.in
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ sdh_cmake -DCMAKE_VERBOSE_MAKEFILE=ON \
-DBUILD_STATIC_LIBS=OFF \
-DBUILD_SHARED_LIBS=ON \
-DBUILD_TESTS=ON \
${EXTRA_OPTS}
${EXTRA_OPTS} \
.

sdh_make_install
3 changes: 2 additions & 1 deletion build/pkgs/qhull/spkg-install.in
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
cd src/

sdh_cmake -DCMAKE_VERBOSE_MAKEFILE=ON \
-DLIB_INSTALL_DIR="${SAGE_LOCAL}"/lib
-DLIB_INSTALL_DIR="${SAGE_LOCAL}"/lib \
.

sdh_make

Expand Down
22 changes: 11 additions & 11 deletions build/pkgs/scip/spkg-install.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@ cd src
mkdir build
cd build
sdh_cmake -DCMAKE_INSTALL_LIBDIR=lib \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DCMAKE_BUILD_WITH_INSTALL_NAME_DIR=ON \
-DGMP_DIR="${SAGE_GMP_PREFIX}" \
-DReadline_ROOT_DIR=$(pkg-config --variable=prefix readline) \
-DHistory_ROOT_DIR=$(pkg-config --variable=prefix readline) \
-DIPOPT=off \
-DPAPILO=on -DPAPILO_DIR="${SAGE_LOCAL}" \
-DZIMPL=off \
-DAMPL=off \
-DSYM=bliss \
..
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DCMAKE_BUILD_WITH_INSTALL_NAME_DIR=ON \
-DGMP_DIR="${SAGE_GMP_PREFIX}" \
-DReadline_ROOT_DIR=$(pkg-config --variable=prefix readline) \
-DHistory_ROOT_DIR=$(pkg-config --variable=prefix readline) \
-DIPOPT=off \
-DPAPILO=on -DPAPILO_DIR="${SAGE_LOCAL}" \
-DZIMPL=off \
-DAMPL=off \
-DSYM=bliss \
..
sdh_make
sdh_make_install
18 changes: 9 additions & 9 deletions build/pkgs/scip_sdp/spkg-install.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ cd src
mkdir build
cd build
sdh_cmake -DCMAKE_INSTALL_LIBDIR=lib \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DCMAKE_BUILD_WITH_INSTALL_NAME_DIR=ON \
-DBLA_VENDOR=OpenBLAS \
-DBLAS_LIBRARIES="$(pkg-config --libs blas)" \
-DLAPACK_LIBRARIES="$(pkg-config --libs lapack)" \
-DSCIP_DIR="${SAGE_LOCAL}" \
-DSYM=bliss \
-DSDPS=dsdp \
..
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DCMAKE_BUILD_WITH_INSTALL_NAME_DIR=ON \
-DBLA_VENDOR=OpenBLAS \
-DBLAS_LIBRARIES="$(pkg-config --libs blas)" \
-DLAPACK_LIBRARIES="$(pkg-config --libs lapack)" \
-DSCIP_DIR="${SAGE_LOCAL}" \
-DSYM=bliss \
-DSDPS=dsdp \
..
sdh_make
sdh_make_install
5 changes: 3 additions & 2 deletions build/pkgs/suitesparse/spkg-install.in
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ echo "Configuring suitesparse"
# Hopefully these sill be normalised in the future.
# * SUITESPARSE_INCLUDEDIR_POSTFIX sets the subfolder in which to install headers.
# It default to "suitesparse" if not defined, which currently breaks dependencies.
# * SUITESPARSE_USE_FORTRAN make sure the fortran interface is off. There is trouble when
# * SUITESPARSE_USE_FORTRAN make sure the fortran interface is off. There is trouble when
# gcc and gfortran version are not matching.
# * SUITESPARSE_ENABLE_PROJECTS semi column separated list of the desired packages. Default is
# all the packages in the suitesparse tarball.
Expand All @@ -16,6 +16,7 @@ sdh_cmake -DCMAKE_VERBOSE_MAKEFILE=ON \
-DNSTATIC=ON \
-DSUITESPARSE_USE_FORTRAN=OFF \
-DSUITESPARSE_INCLUDEDIR_POSTFIX="" \
-DSUITESPARSE_ENABLE_PROJECTS="suitesparse_config;amd;camd;ccolamd;colamd;cholmod;umfpack"
-DSUITESPARSE_ENABLE_PROJECTS="suitesparse_config;amd;camd;ccolamd;colamd;cholmod;umfpack" \
.

sdh_make_install
24 changes: 12 additions & 12 deletions build/pkgs/symengine/spkg-install.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@ cd src
mkdir build
cd build
sdh_cmake -DCMAKE_PREFIX_PATH="$SAGE_LOCAL" \
-DWITH_SYMENGINE_THREAD_SAFE=yes \
-DWITH_ECM=yes \
-DWITH_FLINT=yes \
-DWITH_ARB=yes \
-DWITH_MPFR=yes \
-DWITH_MPC=yes \
-DWITH_LLVM=no \
-DINTEGER_CLASS="flint" \
-DBUILD_BENCHMARKS=no \
-DBUILD_SHARED_LIBS=yes \
-DBUILD_TESTS=yes \
..
-DWITH_SYMENGINE_THREAD_SAFE=yes \
-DWITH_ECM=yes \
-DWITH_FLINT=yes \
-DWITH_ARB=yes \
-DWITH_MPFR=yes \
-DWITH_MPC=yes \
-DWITH_LLVM=no \
-DINTEGER_CLASS="flint" \
-DBUILD_BENCHMARKS=no \
-DBUILD_SHARED_LIBS=yes \
-DBUILD_TESTS=yes \
..

sdh_make
sdh_make install
7 changes: 3 additions & 4 deletions src/doc/en/developer/packaging.rst
Original file line number Diff line number Diff line change
Expand Up @@ -497,10 +497,9 @@ should not need to add it yourself.
The following are also available, but rarely used.
- ``sdh_cmake [...]``: Runs ``cmake`` in the current directory with
the given arguments, as well as additional arguments passed to
cmake (assuming packages are using the GNUInstallDirs module) so
that ``CMAKE_INSTALL_PREFIX`` and ``CMAKE_INSTALL_LIBDIR`` are set
- ``sdh_cmake [...]``: Runs ``cmake`` with the given arguments, as well as
additional arguments (assuming packages are using the GNUInstallDirs module)
so that ``CMAKE_INSTALL_PREFIX`` and ``CMAKE_INSTALL_LIBDIR`` are set
correctly.
- ``sdh_preload_lib EXECUTABLE SONAME``: (Linux only -- no-op on other
Expand Down

0 comments on commit c6759ef

Please sign in to comment.