Been meaning to work on packaging factory-gftables for awhile, but kept putting it off. :) Macaulay2 (and other factory consumers I'd imagine) would be happier if factory-gftables were available. They're pregenerated @ http://www.mathematik.uni-kl.de/ftp/pub/Math/Singular/Factory/factory-gftables.tar.gz I'd venture we'd want to make a factory-gftables.noarch subpkg Alternatively, and possibly better now that I think about it, would you prefer that I simply package factory-gftables content separately from Singular? (it *is* static content, not sure how often we'd ever want to rebuild it...)
I am fine with it being split from Singular. Directory location should be easy to correct with a symlink, but not sure about actual file names, so, feel free to do it the way Macaulay2 expects.
can you elaborate, its not clear to me what you'd prefer: 1. build factory-gftables subpkg from Singuar.spec 2. build factory-gftables separate from Singular ??
OK, wierd, Singular seems to have it's own copies (generated at build time?) and in a slightly different layout: /usr/lib64/Singular/LIB/gftables taking a closer look
OK, it's... a little silly, but, factory seems to expect these in the form: /usr/share/factory/gftables/gftables.x.y and Singular (includes them already in its tarball) in the form: %{_libdir}/Singular/LIB/gftables/z where z = x^y So, it should be theoretically possible to share this data programmatically. I'll have to think a bit on how best to do it.
Created attachment 751371 [details] .spec patch to implement factory-gftables.noarch subpkg First try, how's this look to you?
You probably need to test it a bit, because there is code like this factory/gfops.cc: if (gftable_dir) { [...] } else { #ifndef SINGULAR sprintf( buffer, GFTABLEDIR "/gftable.%d.%d", p, n ); gffilename = buffer; inputfile = fopen( buffer, "r" ); #else sprintf( buffer, "gftables/%d", q ); gffilename = buffer; inputfile = feFopen( buffer, "r" ); #endif } GFTABLEDIR can be redefined (again need to check). But as I understand it, you will just pass some path matching "GFTABLEDIR" under /usr/share. The proper approach should be to tell Singular and libfac to also use it. Well, I believe your patch should be good enough, but I did not actually fool proof test it :-)
config.h:#define GFTABLEDIR "/usr/share/factory/gftables" OK, I'll commit, and see how things go.
* Tue May 21 2013 Rex Dieter <rdieter> - 3.1.5-6 - factory-gftables.noarch subpkg (#965655)