public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Cristian Le <git@lecris.dev>
To: git-commits@fedoraproject.org
Subject: [rpms/mctc-lib] rawhide: Switch to using CMake build system and minor cleanup
Date: Mon, 27 Jul 2026 13:23:58 GMT	[thread overview]
Message-ID: <178515863868.1.9978167905210607149.rpms-mctc-lib-5f98774bfbd0@fedoraproject.org> (raw)

A new commit has been pushed.

Repo   : rpms/mctc-lib
Branch : rawhide
Commit : 5f98774bfbd041661544e44d4631065c702a3cee
Author : Cristian Le <git@lecris.dev>
Date   : 2026-07-27T15:04:17+02:00
Stats  : +26/-17 in 1 file(s)
URL    : https://src.fedoraproject.org/rpms/mctc-lib/c/5f98774bfbd041661544e44d4631065c702a3cee?branch=rawhide

Log:
Switch to using CMake build system and minor cleanup

---
diff --git a/mctc-lib.spec b/mctc-lib.spec
index 3f4820a..f64d310 100644
--- a/mctc-lib.spec
+++ b/mctc-lib.spec
@@ -1,3 +1,5 @@
+%global soversion 0
+
 Name:           mctc-lib
 Version:        0.5.2
 Release:        %autorelease
@@ -6,12 +8,10 @@ License:        Apache-2.0
 URL:            https://grimme-lab.github.io/mctc-lib/
 Source0:        https://github.com/grimme-lab/mctc-lib/archive/v%{version}/%{name}-%{version}.tar.gz
 
-BuildRequires:  python3-devel
 BuildRequires:  gcc-gfortran
-BuildRequires:  meson
-BuildRequires:  ninja-build
-BuildRequires:  pkgconfig(jonquil)
-BuildRequires:  pkgconfig(toml-f)
+BuildRequires:  cmake
+BuildRequires:  cmake(jonquil)
+BuildRequires:  cmake(toml-f)
 # For docs
 BuildRequires:  rubygem-asciidoctor
 
@@ -32,31 +32,40 @@ developing applications that use %{name}.
 %prep
 %autosetup -p1
 
+
+%conf
+# TODO: Account for absolute path CMAKE_INSTALL_INCLUDEDIR so we can use %%{_fmoddir}
+%cmake \
+  -DCMAKE_INSTALL_INCLUDEDIR:PATH=%{_lib}/gfortran/modules \
+  -Dmctc-lib-module-dir:STRING=mctc-lib \
+  -DMCTCLIB_WITH_OpenMP:BOOL=ON \
+  -DMCTCLIB_WITH_JSON:BOOL=ON
+
+
 %build
-%meson
-%meson_build
+%cmake_build
+
 
 %install
-%meson_install
-# Remove static libraries
-rm -f %{buildroot}%{_libdir}/*.a
+%cmake_install
+
+
+%check
+%ctest
 
-# Move module files
-mkdir -p %{buildroot}%{_fmoddir}
-mv %{buildroot}%{_includedir}/mctc-lib/*/*.mod %{buildroot}%{_fmoddir}
-rm -rf %{buildroot}%{_includedir}/mctc-lib/
 
 %files
 %license LICENSE
 %doc README.md
 %{_bindir}/mctc-convert
-%{_mandir}/man1/mctc-convert.1*
-%{_libdir}/libmctc-lib*.so.0*
+%{_libdir}/libmctc-lib.so.%{soversion}{,.*}
 
 %files devel
-%{_fmoddir}/mctc_*.mod
+%{_fmoddir}/mctc-lib/
+%{_libdir}/cmake/mctc-lib/
 %{_libdir}/pkgconfig/mctc-lib.pc
 %{_libdir}/libmctc-lib.so
 
+
 %changelog
 %autochangelog

                 reply	other threads:[~2026-07-27 13:23 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=178515863868.1.9978167905210607149.rpms-mctc-lib-5f98774bfbd0@fedoraproject.org \
    --to=git@lecris.dev \
    --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