blob: bff4157ce7b82fedcc5d6c9777a5ebd9b7608004 (
about) (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
|
{
stdenv,
lib,
fetchurl,
}:
stdenv.mkDerivation rec {
pname = "nauty";
version = "2.8.9";
src = fetchurl {
url = "https://pallini.di.uniroma1.it/nauty${
builtins.replaceStrings [ "." ] [ "_" ] version
}.tar.gz";
sha256 = "sha256-yXq0K/SHlqhqWYvOPpJpBHyisywU/CPgcgiiRP5SxO4=";
};
outputs = [
"out"
"dev"
];
# HACK: starting from 2.8.9, the makefile tries to copy .libs/*.a files unconditionally
dontDisableStatic = true;
configureFlags = [
# Prevent nauty from sniffing some cpu features. While those are very
# widely available, it can lead to nasty bugs when they are not available:
# https://groups.google.com/forum/#!topic/sage-packaging/Pe4SRDNYlhA
"--enable-generic" # don't use -march=native
"--${if stdenv.hostPlatform.sse4_2Support then "enable" else "disable"}-popcnt"
"--${if stdenv.hostPlatform.sse4_aSupport then "enable" else "disable"}-clz"
];
installPhase = ''
mkdir -p "$out"/{bin,share/doc/nauty} "$dev"/{lib,include/nauty}
find . -type f -perm -111 \! -name '*.*' \! -name configure -exec cp '{}' "$out/bin" \;
cp [Rr][Ee][Aa][Dd]* COPYRIGHT This* [Cc]hange* "$out/share/doc/nauty"
cp *.h "$dev/include/nauty"
for i in *.a; do
cp "$i" "$dev/lib/lib$i";
done
'';
checkTarget = "checks";
meta = with lib; {
description = "Programs for computing automorphism groups of graphs and digraphs";
license = licenses.asl20;
maintainers = teams.sage.members;
platforms = platforms.unix;
# I'm not sure if the filename will remain the same for future changelog or
# if it will track changes to minor releases. Lets see. Better than nothing
# in any case.
changelog = "https://pallini.di.uniroma1.it/changes24-28.txt";
homepage = "https://pallini.di.uniroma1.it/";
};
}
|