public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Jerry James <loganjerry@gmail.com>
To: git-commits@fedoraproject.org
Subject: [rpms/mathicgb] f44: Version 1.4
Date: Tue, 09 Jun 2026 22:32:46 GMT	[thread overview]
Message-ID: <178104436662.1.18190749998845570470.rpms-mathicgb-a86be458cf11@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : rpms/mathicgb
            Branch : f44
            Commit : a86be458cf1192dce8557a197c18b34eb4098945
            Author : Jerry James <loganjerry@gmail.com>
            Date   : 2026-06-09T15:50:56-06:00
            Stats  : +37/-30 in 2 file(s)
            URL    : https://src.fedoraproject.org/rpms/mathicgb/c/a86be458cf1192dce8557a197c18b34eb4098945?branch=f44

            Log:
            Version 1.4

- Use the cmake declarative buildsystem

---
diff --git a/mathicgb.spec b/mathicgb.spec
index 56667c0..6025564 100644
--- a/mathicgb.spec
+++ b/mathicgb.spec
@@ -1,5 +1,5 @@
 Name:           mathicgb
-Version:        1.3
+Version:        1.4
 Release:        %autorelease
 Summary:        Groebner basis computations
 
@@ -10,11 +10,14 @@ Source:         %{url}/archive/v%{version}/%{name}-%{version}.tar.gz
 
 # See https://fedoraproject.org/wiki/Changes/EncourageI686LeafRemoval
 ExcludeArch:    %{ix86}
+BuildSystem:    cmake
+BuildOption(conf): -DBUILD_SHARED_LIBS:BOOL=ON
+BuildOption(conf): -DBUILD_TESTING:BOOL=ON
+BuildOption(conf): -DCMAKE_SKIP_RPATH:BOOL=ON
+BuildOption(conf): -Dwith_tbb:BOOL=ON
 
+BuildRequires:  cmake(GTest)
 BuildRequires:  gcc-c++
-BuildRequires:  libtool
-BuildRequires:  make
-BuildRequires:  pkgconfig(gtest)
 BuildRequires:  pkgconfig(mathic)
 BuildRequires:  pkgconfig(tbb)
 
@@ -40,38 +43,42 @@ Library interface to mathicgb.
 %prep
 %autosetup
 
-%conf
-# Fix end-of-line encoding
-sed -i.orig 's/\r//' doc/description.txt
-touch -r doc/description.txt.orig doc/description.txt
-rm -f doc/description.txt.orig
+# Fix the installation directory
+sed -i 's, lib, ${LIB_INSTALL_DIR},' CMakeLists.txt
 
-# Fix the URL in the pkgconfig file
-sed -i 's/broune/Macaulay2/' build/autotools/mathicgb.pc.in
-
-# Upstream doesn't generate the configure script
-autoreconf -fi
+# Add an soname
+sed -e '/compile_options/iset_target_properties(mathicgb PROPERTIES VERSION 0.0.4 SOVERSION 0)' \
+    -i src/CMakeLists.txt
 
-%build
-export GTEST_PATH=%{_prefix}
-%configure --disable-static --enable-shared --with-gtest=yes
+%build -p
+export LD_LIBRARY_PATH=$PWD/%{_vpath_builddir}/src
 
-# Get rid of undesirable hardcoded rpaths; workaround libtool reordering
-# -Wl,--as-needed after all the libraries.
-sed -e 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' \
-    -e 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' \
-    -e 's|CC=.g..|& -Wl,--as-needed|' \
-    -i libtool
-sed -i 's|g++$|& -Wl,--as-needed|' Makefile
+%install -a
+# These files are not installed by cmake
+cp -p src/mathicgb.h %{buildroot}%{_includedir}
 
-%make_build
+# Move the man page to the right directory
+mkdir -p %{buildroot}%{_mandir}/man1
+mv %{buildroot}%{_mandir}/mgb.1 %{buildroot}%{_mandir}/man1
 
-%install
-%make_install
+# Install the pkgconfig file for backwards compatibility
+# Fix the URL in the pkgconfig file
+mkdir -p %{buildroot}%{_libdir}/pkgconfig
+sed -e 's,@prefix@,%{_prefix},' \
+    -e 's,@exec_prefix@,%{_prefix},' \
+    -e 's,@libdir@,%{_libdir},' \
+    -e 's,@includedir@,%{_includedir},' \
+    -e 's,@PACKAGE_VERSION@,%{version},' \
+    -e 's,broune,Macaulay2,' \
+    build/autotools/mathicgb.pc.in \
+    > %{buildroot}%{_libdir}/pkgconfig/%{name}.pc
+
+# We install these files in a different place
+rm -fr %{buildroot}%{_prefix}/licenses %{buildroot}%{_mandir}/mgb.1
 
 %check
-export LD_LIBRARY_PATH=$PWD/.libs
-make check
+export LD_LIBRARY_PATH=$PWD/%{_vpath_builddir}/src
+%{_vpath_builddir}/src/mathicgb-unit-tests
 
 %files
 %doc README.md doc/description.txt doc/slides.pdf

diff --git a/sources b/sources
index 7cb5f0c..124a871 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-SHA512 (mathicgb-1.3.tar.gz) = 04d85c8b86be8a1e35357128e9b7b7d5cc7f9110ebbd1ebf085978f134a36a1e61e7cf73dcf9be9fbe99b7b411dc2ef448bf1160f5cffbd7ef4c5286ce3af5d9
+SHA512 (mathicgb-1.4.tar.gz) = 2ac1a54b1d3de0f588149dfc8f8b34ff53df3bcbb6bd8dfa46c4054350e030fa9235e885f0e3ab395055fe5e2ed9568a26848a5e4458f50358f2486e15c4cbd0

                 reply	other threads:[~2026-06-09 22:32 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=178104436662.1.18190749998845570470.rpms-mathicgb-a86be458cf11@fedoraproject.org \
    --to=loganjerry@gmail.com \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox