public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Susi Lehtola <jussilehtola@fedoraproject.org>
To: git-commits@fedoraproject.org
Subject: [rpms/crest] f45: Update to 3.0.2.
Date: Wed, 28 Oct 2026 17:24:22 GMT	[thread overview]
Message-ID: <179320826238.1.1662348442950755010.rpms-crest-da50da50a23a@fedoraproject.org> (raw)

A new commit has been pushed.

Repo   : rpms/crest
Branch : f45
Commit : da50da50a23a162df45dae9e7462ab40ad6dfbdd
Author : Susi Lehtola <jussilehtola@fedoraproject.org>
Date   : 2026-10-28T16:31:41+00:00
Stats  : +241/-5 in 6 file(s)
URL    : https://src.fedoraproject.org/rpms/crest/c/da50da50a23a162df45dae9e7462ab40ad6dfbdd?branch=f45

Log:
Update to 3.0.2.

---
diff --git a/crest-3.0.2-enable-tests.patch b/crest-3.0.2-enable-tests.patch
new file mode 100644
index 0000000..0517909
--- /dev/null
+++ b/crest-3.0.2-enable-tests.patch
@@ -0,0 +1,127 @@
+--- a/meson.build
++++ b/meson.build
+@@ -79,5 +79,5 @@
+ 
+ 
+ 
+-# add the testsuite separate meson.build 
+-#subdir('testsuite') #has to be filled with tests, not availabel yet
++# add the testsuite separate meson.build
++subdir('test')
+--- a/test/test_gfn0.F90
++++ b/test/test_gfn0.F90
+@@ -42,7 +42,7 @@
+   subroutine test_compiled_gfn0(error)
+     type(error_type),allocatable,intent(out) :: error
+ #ifndef WITH_GFN0
+-    write (*,'("       ...")') 'gfn0 not compiled, expecting fail.'
++    write (*,'("       ... ",a)') 'gfn0 not compiled, expecting fail.'
+     allocate (error)
+ #endif
+   end subroutine test_compiled_gfn0
+--- a/test/test_gfn0occ.F90
++++ b/test/test_gfn0occ.F90
+@@ -40,7 +40,7 @@
+   subroutine test_compiled_gfn0(error)
+     type(error_type),allocatable,intent(out) :: error
+ #ifndef WITH_GFN0
+-    write (*,'("       ...")') 'gfn0 not compiled, expecting fail.'
++    write (*,'("       ... ",a)') 'gfn0 not compiled, expecting fail.'
+     allocate (error)
+ #endif
+   end subroutine test_compiled_gfn0
+--- a/test/test_gfnff.F90
++++ b/test/test_gfnff.F90
+@@ -41,7 +41,7 @@
+   subroutine test_compiled_gfnff(error)
+     type(error_type),allocatable,intent(out) :: error
+ #ifndef WITH_GFNFF
+-    write(*,'("       ...")') 'gfnff not compiled, expecting fail.'
++    write(*,'("       ... ",a)') 'gfnff not compiled, expecting fail.'
+     allocate (error)
+ #endif
+   end subroutine test_compiled_gfnff
+--- a/test/test_optimization.F90
++++ b/test/test_optimization.F90
+@@ -42,7 +42,7 @@
+   subroutine test_compiled_gfnff(error)
+     type(error_type),allocatable,intent(out) :: error
+ #ifndef WITH_GFNFF
+-    write(*,'("       ...")') 'gfnff not compiled, expecting fail.'
++    write(*,'("       ... ",a)') 'gfnff not compiled, expecting fail.'
+     allocate (error)
+ #endif
+   end subroutine test_compiled_gfnff
+--- a/test/test_tblite.F90
++++ b/test/test_tblite.F90
+@@ -44,7 +44,7 @@
+   subroutine test_compiled_tblite(error)
+     type(error_type),allocatable,intent(out) :: error
+ #ifndef WITH_TBLITE
+-    write(*,'("       ...")') 'tblite not compiled, expecting fail.'
++    write(*,'("       ... ",a)') 'tblite not compiled, expecting fail.'
+     allocate (error)
+ #endif
+   end subroutine test_compiled_tblite
+--- /dev/null
++++ b/test/meson.build
+@@ -0,0 +1,59 @@
++# This file is part of crest.
++# SPDX-Identifier: LGPL-3.0-or-later
++#
++# crest is free software: you can redistribute it and/or modify it under
++# the terms of the GNU Lesser General Public License as published by
++# the Free Software Foundation, either version 3 of the License, or
++# (at your option) any later version.
++#
++# crest is distributed in the hope that it will be useful,
++# but WITHOUT ANY WARRANTY; without even the implied warranty of
++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
++# GNU Lesser General Public License for more details.
++#
++# You should have received a copy of the GNU Lesser General Public License
++# along with crest.  If not, see <https://www.gnu.org/licenses/>.
++
++# Unit testing framework
++testdrive_dep = dependency(
++  'test-drive',
++  version: '>=0.4',
++  fallback: ['test-drive', 'testdrive_dep'],
++  default_options: ['default_library=static'],
++)
++
++# note: these must have the same name as in CMakeLists.txt
++tests = [
++  'tblite',
++  'gfnff',
++  'gfn0',
++  'gfn0occ',
++  'CN',
++  'optimization',
++]
++
++test_srcs = files(
++  'testmol.f90',
++  'helpers.f90',
++  'main.f90',
++)
++foreach t : tests
++  test_srcs += files('test_@0@.F90'.format(t))
++endforeach
++
++crest_tester = executable(
++  meson.project_name()+'-tester',
++  sources: test_srcs,
++  dependencies: [crest_dep, testdrive_dep],
++  link_language: 'fortran',
++)
++
++foreach t : tests
++  test(
++    t,
++    crest_tester,
++    args: [t],
++    suite: meson.project_name(),
++    timeout: 300,
++  )
++endforeach

diff --git a/crest-3.0.2-manpage.patch b/crest-3.0.2-manpage.patch
new file mode 100644
index 0000000..a6dc8ed
--- /dev/null
+++ b/crest-3.0.2-manpage.patch
@@ -0,0 +1,11 @@
+--- a/meson.build
++++ b/meson.build
+@@ -43,7 +43,7 @@
+ 
+ 
+ # Documentation
+-#subdir('docs')
++subdir('docs')
+ 
+ # Collect source of the project
+ prog = []

diff --git a/crest-3.0.2-no-git.patch b/crest-3.0.2-no-git.patch
new file mode 100644
index 0000000..4baae6d
--- /dev/null
+++ b/crest-3.0.2-no-git.patch
@@ -0,0 +1,33 @@
+--- a/config/meson.build
++++ b/config/meson.build
+@@ -263,23 +263,20 @@
+ ## ========================================= ##
+ ## populate the data for crest_metadata.fh
+ ## ========================================= ##  
++# NOTE: distributions build from release tarballs, i.e. outside of any git
++# checkout, so querying git here is at best useless and at worst picks up an
++# unrelated repository. Embedding the build date, user and host additionally
++# makes the build unreproducible. Use fixed placeholders instead.
+ commit = 'unknown commit'
+-git = find_program('git', required: false)
+-if git.found()
+-  git_commit = run_command(git, 'show', '-s', '--format=%h',check:true)
+-  if git_commit.returncode() == 0
+-    commit = git_commit.stdout().strip()
+-  endif
+-endif
+ # create configuration data
+ config = configuration_data({
+   'name': meson.project_name(),
+   'version': meson.project_version(),
+   'description': 'Conformer Rotamer Ensemble Sampling Tool',
+   'commit': commit,
+-  'date': run_command('date',check:true).stdout().     strip(),
+-  'author': run_command('id','-u','-n', check:true).stdout().strip(),
+-  'origin': run_command('hostname', check:true).stdout().strip(),
++  'date': 'unknown date',
++  'author': 'unknown',
++  'origin': 'unknown',
+   'fcid': fc.get_id(),
+   'fcver': fc.version(),
+   'ccid': cc.get_id(),

diff --git a/crest-3.0.2-no-static.patch b/crest-3.0.2-no-static.patch
new file mode 100644
index 0000000..15d42c3
--- /dev/null
+++ b/crest-3.0.2-no-static.patch
@@ -0,0 +1,27 @@
+--- a/meson.build
++++ b/meson.build
+@@ -23,8 +23,6 @@
+   default_options: [
+     'buildtype=debugoptimized',
+     'default_library=static',
+-    'c_link_args=-static',
+-    'fortran_link_args=-static',
+   ],
+ )
+ install = not (meson.is_subproject() and get_option('default_library') == 'static')
+--- a/config/meson.build
++++ b/config/meson.build
+@@ -75,11 +75,8 @@
+ ## ========================================= ##
+ ## build type option arguments
+ ## ========================================= ## 
+-if ( get_option('default_library') == 'static')
+-  message('Static linking selected')
+-  add_project_link_arguments('-static', language: 'fortran')
+-  add_project_link_arguments('-static', language: 'c') # icc will do linking
+-endif
++# NOTE: upstream forces fully static executables here ('-static'); distributions
++# link dynamically against the system libraries instead.
+ 
+ 
+ ## ========================================= ##

diff --git a/crest-3.0.2-no-subprojects.patch b/crest-3.0.2-no-subprojects.patch
new file mode 100644
index 0000000..8cc23e9
--- /dev/null
+++ b/crest-3.0.2-no-subprojects.patch
@@ -0,0 +1,18 @@
+--- a/src/calculator/gfnff_api.F90
++++ b/src/calculator/gfnff_api.F90
+@@ -162,6 +162,7 @@
+     integer,intent(in) :: nat
+     integer :: i
+     real(wp) :: sumsasa
++#ifdef WITH_GFNFF
+     if(allocated(ff_dat%solvation))then
+       if(allocated(ff_dat%solvation%sasa))then
+         sumsasa = 0.0_wp
+@@ -171,6 +172,7 @@
+         write(5454,*) sumsasa
+       endif
+     endif
++#endif
+   end subroutine gfnff_dump_sasa
+ !========================================================================================!
+ !========================================================================================!

diff --git a/crest.spec b/crest.spec
index 80a2a74..6e8e878 100644
--- a/crest.spec
+++ b/crest.spec
@@ -9,8 +9,8 @@
 %endif
 
 Name:           crest
-Version:        2.12
-Release:        13%{?dist}
+Version:        3.0.2
+Release:        1%{?dist}
 Summary:        Conformer-Rotamer Ensemble Sampling Tool: a driver for the xtb program
 # Automatically converted from old format: GPLv3+ - review is highly recommended.
 License:        GPL-3.0-or-later
@@ -19,12 +19,25 @@ Source0:        https://github.com/crest-lab/crest/archive/v%{version}/crest-%{v
 
 # Do not use "true" as a function name
 Patch0:         https://github.com/crest-lab/crest/pull/397.patch
+# Upstream forces a fully static executable, which does not work on Fedora
+Patch1:         crest-3.0.2-no-static.patch
+# gfnff_dump_sasa is not guarded by WITH_GFNFF, so it does not compile when the
+# GFN-FF subproject is disabled
+Patch2:         crest-3.0.2-no-subprojects.patch
+# Upstream disabled the man page build, but the sources are still shipped
+Patch3:         crest-3.0.2-manpage.patch
+# The unit tests are only wired up in the CMake build; add the missing meson
+# recipe, and fix the format statements in the "feature not compiled" stubs
+Patch4:         crest-3.0.2-enable-tests.patch
 
 BuildRequires:  gcc
 BuildRequires:  gcc-gfortran
 BuildRequires:  meson
 BuildRequires:  ninja-build
 BuildRequires:  %{blaslib}-devel
+BuildRequires:  toml-f-devel
+# For the unit tests
+BuildRequires:  test-drive-devel
 # To generate man pages
 BuildRequires:  rubygem-asciidoctor
 
@@ -58,11 +71,15 @@ The main publication for the CREST program can be found at
 Phys. Chem. Chem. Phys., 2020, 22, 7169-7192.
 
 %prep
-%setup -q
-%patch -P0 -p1 -b .notrue
+%autosetup -p1
 
 %build
-%meson -Dla_backend=custom -Dcustom_libraries=%{blaslib}%{blasvar}
+# tblite, gfn0, gfnff and lwoniom are not packaged in Fedora, and upstream only
+# ships them as git submodules, so the corresponding features are turned off.
+# toml-f is taken from the system.
+%meson -Dla_backend=custom -Dcustom_libraries=%{blaslib}%{blasvar} \
+    -DWITH_TBLITE=false -DWITH_GFN0=false -DWITH_GFNFF=false \
+    -DWITH_LWONIOM=false -DWITH_TOMLF=true
 %meson_build
 
 %install
@@ -78,6 +95,9 @@ Phys. Chem. Chem. Phys., 2020, 22, 7169-7192.
 %{_mandir}/man1/crest.1.*
 
 %changelog
+* Wed Oct 28 2026 Susi Lehtola <jussilehtola@fedoraproject.org> - 3.0.2-1
+- Update to 3.0.2.
+
 * Wed Jul 15 2026 Fedora Release Engineering <releng@fedoraproject.org> - 2.12-13
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_45_Mass_Rebuild
 

                 reply	other threads:[~2026-10-28 17:24 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=179320826238.1.1662348442950755010.rpms-crest-da50da50a23a@fedoraproject.org \
    --to=jussilehtola@fedoraproject.org \
    --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