Bug 258237 - math/nauty: Update to 27r3
Summary: math/nauty: Update to 27r3
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Yuri Victorovich
URL:
Keywords:
Depends on:
Blocks: 258106
  Show dependency treegraph
 
Reported: 2021-09-03 05:04 UTC by Yuri Victorovich
Modified: 2021-09-20 21:36 UTC (History)
3 users (show)

See Also:
moritz: maintainer-feedback+


Attachments
patch-27r3-not-yet-released (8.28 KB, patch)
2021-09-03 19:47 UTC, Yuri Victorovich
no flags Details | Diff
patch-27r3-not-yet-released (6.17 KB, patch)
2021-09-03 19:50 UTC, Yuri Victorovich
no flags Details | Diff
patch (6.62 KB, patch)
2021-09-05 16:02 UTC, Yuri Victorovich
yuri: maintainer-approval? (moritz)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yuri Victorovich freebsd_committer 2021-09-03 05:04:07 UTC
I attempted to create a patch to update to 27r2 but, sadly, I discovered too many problems with 27r2.

It has the 'install' instruction now, but here is the list of problems that I've just sent to the upstream author Brandan McKay:
> 1. The header file schreier.h isn't installed. The library nautyW1.a has functions declared there which are unusable without this header installed.
> 2. The header nautycliquer.h isn't installed. Same situation, functions declared there are defined in static libraries.
> 3. The header traces.h isn't installed. Same situation.
> 4. It's better to install all Nauty headers into a dedicated subdirectory $prefix/include/nauty. This way $prefix/include, which is typically already very crowded, doesn't get mode crowded than it needs to be.
> 5. Static libraries that you install don't have the "lib" prefix. Virtually all static libraries in $prefix/lib have the "lib" prefix.
> 6. The 'install' target doesn't respect the DESTDIR variable. DESTDIR is a GNU standard (see here https://www.gnu.org/prep/standards/html_node/DESTDIR.html) Every install instruction should install under $DESTDIR$PREFIX/... to be staging-friendly.
> 
> Are multiple libraries (lib/nauty.a lib/nauty1.a lib/nautyL.a lib/nautyL1.a lib/nautyW.a lib/nautyW1.a) necessary? The documentation https://pallini.di.uniroma1.it/Guide.html doesn't mention them.


I hope that he would solve these issues and would make another release.
Comment 1 Philipp Ost 2021-09-03 19:20:35 UTC
There are two other issues:

- libnauty.so currently does not have a SONAME:

$ objdump -p /usr/local/lib/libnauty.so | grep SONAME
$

This causes stage-qa to complain every time anything is linked against it.

- The nauty makefile currently has `-march=native` hardcoded in its CFLAGS. This might be high level nitpicking, but if we follow the Porter's Handbook we should either remove it or make it an option.
Comment 2 Yuri Victorovich freebsd_committer 2021-09-03 19:42:15 UTC
(In reply to Philipp Ost from comment #1)

> The nauty makefile currently has `-march=native` hardcoded in its CFLAGS.

I fixed this in my upcoming patch.

> libnauty.so currently does not have a SONAME

I will add this too.


Thanks!
Comment 3 Yuri Victorovich freebsd_committer 2021-09-03 19:42:36 UTC
They are going to release 27r3 soon.
Comment 4 Yuri Victorovich freebsd_committer 2021-09-03 19:47:56 UTC
Created attachment 227651 [details]
patch-27r3-not-yet-released

Attaching approximate patch for 27r3 that isn't yet released.
Comment 5 Yuri Victorovich freebsd_committer 2021-09-03 19:50:18 UTC
Created attachment 227652 [details]
patch-27r3-not-yet-released
Comment 6 Yuri Victorovich freebsd_committer 2021-09-05 16:02:04 UTC
Created attachment 227686 [details]
patch

Patch for 27r3 is attached.

Major changes in the port:
* 'install' target is now supported by the project
* flavor libraries libnauty{flavor}.{a,so} are now installed
* headers that were missing are now installed
* -fPIC is now used only for shared libraries, not for static ones
* .pc files are added by the project and installed
* Native options are now off by default with the option NATIVE enabling them
Comment 7 Moritz Schmitt 2021-09-06 06:52:54 UTC
Thanks for all your work. Since I'm currently very busy with other things I will need a couple of days to properly review it.
Comment 8 Philipp Ost 2021-09-06 15:13:27 UTC
(In reply to Yuri Victorovich from comment #6)

Why did you change the COMMENT line?
Comment 9 Yuri Victorovich freebsd_committer 2021-09-06 16:36:15 UTC
(In reply to Philipp Ost from comment #8)

> Why did you change the COMMENT line?

Because when I've sent the patch that adds ,pc files to the author, he changed the 'Description' field from "automorphisms" to "automorphism". Both variants are correct grammatically, but that's his preference.
Comment 10 Yuri Victorovich freebsd_committer 2021-09-12 18:14:04 UTC
Moritz,


If you have any questions - I'd be happy to answer them.


Yuri
Comment 11 Moritz Schmitt 2021-09-19 14:49:50 UTC
I finally got around to have a look. Sorry it took such a long time and thanks for your patience.

Your patch looks fine to me. Please submit.
Comment 12 Yuri Victorovich freebsd_committer 2021-09-20 21:35:25 UTC
Committed, thanks.
Comment 13 commit-hook freebsd_committer 2021-09-20 21:36:20 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=ec6283ede7159ec215da3944c9b790b4efdaab6e

commit ec6283ede7159ec215da3944c9b790b4efdaab6e
Author:     Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2021-09-20 21:31:13 +0000
Commit:     Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2021-09-20 21:34:21 +0000

    math/nauty: Update 27r1 -> 27r3

    PR:             258237
    Approved by:    moritz@schmi.tt (maintainer)

 math/casadi/Makefile                     |  2 +-
 math/cbc/Makefile                        |  2 +-
 math/couenne/Makefile                    |  9 +++--
 math/disco/Makefile                      |  1 +
 math/libnormaliz/Makefile                |  1 +
 math/nauty/Makefile                      | 66 ++++++++++++++++++++------------
 math/nauty/distinfo                      |  6 +--
 math/nauty/files/patch-makefile.in (new) | 13 +++++++
 math/nauty/pkg-plist                     | 26 +++++++++++++
 math/or-tools/Makefile                   |  1 +
 math/polymake/Makefile                   |  2 +-
 math/sage/Makefile                       |  2 +-
 12 files changed, 95 insertions(+), 36 deletions(-)