#10224 closed enhancement (fixed)
(newstyle) packages for saclib 2.2.6 and qepcadB.1.69
Reported by:  bgoodri  Owned by:  tbd 

Priority:  major  Milestone:  sage6.8 
Component:  packages: optional  Keywords:  qepcad 
Cc:  jason, cwitty, jondo  Merged in:  
Authors:  Thierry Monteil  Reviewers:  Jeroen Demeyer, Matthias Koeppe, Dima Pasechnik 
Report Upstream:  N/A  Work issues:  
Branch:  4c26982 (Commits, GitHub, GitLab)  Commit:  
Dependencies:  Stopgaps: 
Description (last modified by )
There exists a new upstream versions of saclib and qepcad that compile on 64 bit machines at https://www.usna.edu/CS/qepcadweb/INSTALL/IQ.html
Sources:
 http://www.usna.edu/CS/qepcadweb/INSTALL/saclib2.2.6.tar.gz
 http://www.usna.edu/CS/qepcadweb/INSTALL/qepcadB.1.69.tar.gz
Copy both tarballs into your $SAGE_ROOT/upstream
directory and rename saclib2.2.6.tar.gz
to saclib2.2.6.tar.gz
There could be some improvements to the QEPCAD interface, but it would probably be better for me to open separate tickets and base them on the updated spkg.
Another thing that would be good to include is Chris Brown's SLFQ program
https://www.usna.edu/CS/qepcadweb/SLFQ/Home.html
which calls QEPCAD B. I have gotten SLFQ to build outside of sage with a couple of patches, but I have not actually gotten it to work yet.
Change History (50)
comment:1 Changed 10 years ago by
 Cc cwitty added
 Component changed from optional packages to experimental package
 Description modified (diff)
 Milestone changed from sage4.6.1 to sage4.6.2
 Status changed from new to needs_info
comment:2 Changed 10 years ago by
comment:3 Changed 8 years ago by
If this ever wants to leave experimental, it will need some changes. See for instance this sagesupport thread, where it seems some of the install scripts are tcsh (?!?), and #11933 confirms it doesn't build everywhere. The spkginstall will need work, too  there is no checking whether saclib even builds correctly before going on!
This spkg link does still work for now, though, which is good!
comment:4 Changed 8 years ago by
 Milestone changed from sage5.11 to sage5.12
comment:5 Changed 7 years ago by
 Milestone changed from sage6.1 to sage6.2
comment:6 Changed 7 years ago by
 Milestone changed from sage6.2 to sage6.3
comment:7 Changed 7 years ago by
 Cc jondo added
 Description modified (diff)
Updated the links in the description.
comment:8 Changed 7 years ago by
 Keywords qepcad added
comment:9 Changed 7 years ago by
 Milestone changed from sage6.3 to sage6.4
comment:10 Changed 7 years ago by
Note that http://trac.sagemath.org/ticket/16642 and https://groups.google.com/forum/#!topic/sagesupport/X6U8FxnNuzU continue to confirm this optional package does not compile everywhere...
comment:11 Changed 6 years ago by
 Description modified (diff)
I again updated the links to the QEPCAD pages.
comment:12 Changed 6 years ago by
There's a fork of qepcad with a CMakebased build system here: https://github.com/PetterS/qepcad
Still does not compile on Mac OS X because of gnulibcisms such as using "ieee754.h"
(sagesh) mkoeppe@d245:qepcad$ cmake .  The C compiler identification is GNU 4.9.2  The CXX compiler identification is GNU 4.9.2  Checking whether C compiler has isysroot  Checking whether C compiler has isysroot  yes  Checking whether C compiler supports OSX deployment target flag  Checking whether C compiler supports OSX deployment target flag  yes  Check for working C compiler: /Users/mkoeppe/s/sage/sage6.5/local/bin/gcc  Check for working C compiler: /Users/mkoeppe/s/sage/sage6.5/local/bin/gcc  works  Detecting C compiler ABI info  Detecting C compiler ABI info  done  Detecting C compile features  Detecting C compile features  done  Checking whether CXX compiler has isysroot  Checking whether CXX compiler has isysroot  yes  Checking whether CXX compiler supports OSX deployment target flag  Checking whether CXX compiler supports OSX deployment target flag  yes  Check for working CXX compiler: /Users/mkoeppe/s/sage/sage6.5/local/bin/g++  Check for working CXX compiler: /Users/mkoeppe/s/sage/sage6.5/local/bin/g++  works  Detecting CXX compiler ABI info  Detecting CXX compiler ABI info  done  Detecting CXX compile features  Detecting CXX compile features  done  No build type specified; defaulting to CMAKE_BUILD_TYPE=Release.  Configuring done  Generating done  Build files have been written to: /Users/mkoeppe/s/qepcad (sagesh) mkoeppe@d245:qepcad$ make Scanning dependencies of target saclib [ 0%] Building C object CMakeFiles/saclib.dir/saclib/src/AADV.c.o In file included from /Users/mkoeppe/s/qepcad/saclib/include/saclib.h:11:0, from /Users/mkoeppe/s/qepcad/saclib/src/AADV.c:13: /Users/mkoeppe/s/qepcad/saclib/include/hfloats.h:23:21: fatal error: ieee754.h: No such file or directory #include <ieee754.h> ^ compilation terminated. make[2]: *** [CMakeFiles/saclib.dir/saclib/src/AADV.c.o] Error 1 make[1]: *** [CMakeFiles/saclib.dir/all] Error 2 make: *** [all] Error 2
comment:13 Changed 6 years ago by
 Description modified (diff)
 Milestone changed from sage6.4 to sage6.7
 Status changed from needs_info to needs_work
 Summary changed from upgrading qepcad1.50.spkg to 1.54 to upgrading qepcad1.50.spkg to 1.69
comment:14 Changed 6 years ago by
 Branch set to u/tmonteil/saclib_2_2_6_qepcad_B_1_69
comment:15 Changed 6 years ago by
 Commit set to 5fc251ec297bb925929b6eb7f8307399175bb8be
 Component changed from packages: experimental to packages: optional
 Description modified (diff)
 Priority changed from minor to major
 Status changed from needs_work to needs_review
 Summary changed from upgrading qepcad1.50.spkg to 1.69 to (newstyle) packages for saclib 2.2.6 and qepcadB.1.69
 Type changed from task to enhancement
I made two (newstyle) packages for latest saclib and qepcad, see the branch. According to saclib2.2.6/sysdep
, this should build on linuxX86
, linuxX86_64
, macosX86
, macosX86_64
, solarisSparc
. The packages work well on my Debian/jessie/65bits. Let's see if you can let it work on mac (i cannot test myself). I updated instructions on the ticket description.
New commits:
3b5ecbf  #10224 : saclib 2.2.6 package.

5fc251e  #10224 : qepcad B.1.69 package.

comment:16 followup: ↓ 19 Changed 6 years ago by
Quick fix for nonGNU find on Mac OS X:
diff git a/build/pkgs/qepcad/spkginstall b/build/pkgs/qepcad/spkginstall index 01f850e..1f7566b 100755  a/build/pkgs/qepcad/spkginstall +++ b/build/pkgs/qepcad/spkginstall @@ 42,7 +42,7 @@ fi # install binaries to the Sage tree find name *.a exec cp {} $SAGE_LOCAL/lib/ +find . name *.a exec cp {} $SAGE_LOCAL/lib/ \; cp source/qepcad $SAGE_LOCAL/bin/ cp bin/qepcad.help $SAGE_LOCAL/bin/ cp ../sageqepcad $SAGE_LOCAL/bin/
Unfortunately it segfaults:
(sagesh) mkoeppe@d100:sagedevelop$ qepcad Segmentation fault: 11
Only the help screen works:
(sagesh) mkoeppe@d100:sagedevelop$ qepcad h usage: qepcad [h] [noecho] [+N<numcells>] QEPCAD B v1.69 is a program for studying Cylindrical Algebraic Decomposition (CAD). It constructs CADs from an input formula and variable order, and provides many commands for getting info out of the CAD, including construction of simple equivalent Tarski formulas. Options h : Help information noecho : Turns off echoing of input Saclib options +N<numcells> : Sets garbage collected space to <numcells>. Default is 2000000.
comment:17 Changed 6 years ago by
 Commit changed from 5fc251ec297bb925929b6eb7f8307399175bb8be to 3e9b14f86e96565f5b26a2f3b0e9a3b1efbb95d8
Branch pushed to git repo; I updated commit sha1. New commits:
3e9b14f  #10224 : fix for nonGNU find on Mac OS X (comment 16).

comment:18 Changed 6 years ago by
 Commit changed from 3e9b14f86e96565f5b26a2f3b0e9a3b1efbb95d8 to 12ecf56c516bf1c3eb4e66b170e2d407e56cac55
Branch pushed to git repo; I updated commit sha1. New commits:
12ecf56  #10224 : fix variable name in sageqepcad.

comment:19 in reply to: ↑ 16 Changed 6 years ago by
Replying to mkoeppe:
Quick fix for nonGNU find on Mac OS X:
Done.
Unfortunately it segfaults:
Could you try again with the new branch and the sageqepcad
command instead of qepcad
?
comment:20 Changed 6 years ago by
Could you also try from Sage if you get the following behaviour:
sage: var('a,b,c,d,x,y,z') (a, b, c, d, x, y, z) sage: qf = qepcad_formula sage: ellipse = 3*x^2 + 2*x*y + y^2  x + y  7 sage: F = qf.exists(y, ellipse == 0); F (E y)[3 x^2 + 2 x y + y^2  x + y  7 = 0] sage: qepcad(F) 8 x^2  8 x  29 <= 0
comment:21 Changed 6 years ago by
 Status changed from needs_review to needs_work
There are also some failed (but correct) doctests to fix.
comment:22 Changed 6 years ago by
 Commit changed from 12ecf56c516bf1c3eb4e66b170e2d407e56cac55 to 2e32ee1595e879a31c632f93630e3660e6ba1838
Branch pushed to git repo; I updated commit sha1. New commits:
2e32ee1  #10224 : fix broken doctests.

comment:23 Changed 6 years ago by
 Status changed from needs_work to needs_review
The following should also work:
sage t optional=sage,qepcad $SAGE_ROOT/src/sage/interfaces/qepcad.py
comment:24 Changed 6 years ago by
 Commit changed from 2e32ee1595e879a31c632f93630e3660e6ba1838 to 000773df6a54f0f0ef2e67121a265837bcddf0db
Branch pushed to git repo; I updated commit sha1. New commits:
000773d  #10224 : fix version.

comment:25 Changed 6 years ago by
Works for me now! Thanks very much for working on this!
sage t optional=sage,qepcad $SAGE_ROOT/src/sage/interfaces/qepcad.py too few successful tests, not using stored timings Running doctests with ID 2015062517271709f49200. Git branch: t/10224/saclib_2_2_6_qepcad_B_1_69 Using optional=qepcad,sage Doctesting 1 file. sage t src/sage/interfaces/qepcad.py [317 tests, 4.58 s]  All tests passed! 
comment:26 Changed 6 years ago by
Great!
comment:27 Changed 6 years ago by
Helloooooooooooo,
Just leaving a note here that if you create a newstyle package that replaces an oldstyle package (it seems to be the case for qepcad?) then somebody should ask Harald to remove the oldstyle package from the "optional/" folder on the mirrors, and move it to the "archive/" folder instead.
Otherwise we will be having consistency problems at some point.
Thanks,
Nathann
comment:28 followup: ↓ 29 Changed 6 years ago by
on a 32bit machine I get:
./sage tp long optional=gcc,lidia,mpir,normaliz,python2,sage,scons,qepcad src/sage/interfaces/qepcad.py Running doctests with ID 201506301143274a2e1119. Git branch: qep Using optional=gcc,lidia,mpir,normaliz,python2,qepcad,sage,scons Doctesting 1 file using 4 threads. sage t long warnlong 73.3 src/sage/interfaces/qepcad.py ********************************************************************** File "src/sage/interfaces/qepcad.py", line 98, in sage.interfaces.qepcad Failed example: qepcad(F) # optional  qepcad Expected: x^2  3 <= 0 /\ 8 x^2  8 x  29 <= 0 /\ 8 x^4  26 x^2  4 x + 13 >= 0 /\ [ 8 x^4  26 x^2  4 x + 13 = 0 \/ x^2  3 = 0 \/ 8 x^2  8 x  29 = 0 ] Got: 8 x^2  8 x  29 <= 0 /\ x^2  3 <= 0 /\ 8 x^4  26 x^2  4 x + 13 >= 0 /\ [ 8 x^4  26 x^2  4 x + 13 = 0 \/ x^2  3 = 0 \/ 8 x^2  8 x  29 = 0 ] ********************************************************************** 1 item had failures: 1 of 60 in sage.interfaces.qepcad [317 tests, 1 failure, 3.25 s]  sage t long warnlong 73.3 src/sage/interfaces/qepcad.py # 1 doctest failed  Total time for all tests: 23.2 seconds cpu time: 1.5 seconds cumulative wall time: 3.2 seconds
i.e. the inequalities might come up in a different order.
comment:29 in reply to: ↑ 28 ; followups: ↓ 31 ↓ 36 Changed 6 years ago by
Replying to dimpase:
on a 32bit machine I get:
[...]i.e. the inequalities might come up in a different order.
I propose to add a "not tested" flag to those examples in order not to pollute the tutorial, and then add tests that transforms the string to a set of substrings so that we can test equality. Does it makes sense ?
comment:30 followup: ↓ 32 Changed 6 years ago by
 Commit changed from 000773df6a54f0f0ef2e67121a265837bcddf0db to 0535b3a228e65609f6ecd85837af2eb999b73280
comment:31 in reply to: ↑ 29 Changed 6 years ago by
comment:32 in reply to: ↑ 30 ; followup: ↓ 33 Changed 6 years ago by
comment:33 in reply to: ↑ 32 Changed 6 years ago by
Replying to dimpase:
why are
# optional  qepcad
useless?
I meant: among the occurrences of # optional  qepcad
i removed the uselesses, that is the one for which the tests can be run without qepcad
installed.
Typically, the calls to qepcad_formula
do only create some srtings, they not require qepcad
to be installed. Only the calls to the qepcad
command require qepcad
to be installed.
comment:34 Changed 6 years ago by
To get convinced that they were not needed, just run the doctests without qepcad
installed.
comment:35 Changed 6 years ago by
 Milestone changed from sage6.7 to sage6.8
 Status changed from needs_review to positive_review
LGTM
comment:36 in reply to: ↑ 29 Changed 6 years ago by
Replying to tmonteil:
I propose to add a "not tested" flag to those examples in order not to pollute the tutorial, and then add tests that transforms the string to a set of substrings so that we can test equality. Does it makes sense ?
Better use # random
instead of # not tested
if you want to run the tests but not check the output.
comment:37 Changed 6 years ago by
 Status changed from positive_review to needs_work
Also reviewer name is missing...
comment:38 followup: ↓ 44 Changed 6 years ago by
OK, I'd be happy to give a positive review once the change proposed by Jeroen is done.
comment:39 Changed 6 years ago by
Replying to jdemeyer:
Better use
# random
instead of# not tested
if you want to run the tests but not check the output.
Actually, the tests tagged # not tested
are run in the TESTS:
section that follows the EXAMPLE:
section where it appears, but there, the output is sent to a function that makes a set of atoms so that the difference of ordering (that seems arch dependent) is taken into account. So, be both have meaningful userfriendly examples and the doctest are still executed and partially checked. Hence, if i replace # not tested
with # random
in the EXAMPLE:
section, those tests will be run twice and take longer. I do not mind doing this, but i do not see the point since any test is already run at least once. Tell me.
comment:40 followup: ↓ 43 Changed 6 years ago by
OK, I see your point.
One reason to still have # random
is to make it more explicit that the output of the test is random. When a test says "not tested", it is not clear why it is not tested. At the very least, write something like # not tested (random order)
.
How much time do those tests take? If we're talking about a few seconds, then I would just use # random
.
And the reviewer name is still missing.
comment:41 Changed 6 years ago by
 Reviewers set to Jeroen Demeyer, Matthias Koeppe, Dima Pasechnik
comment:42 Changed 6 years ago by
 Commit changed from 0535b3a228e65609f6ecd85837af2eb999b73280 to e0b1caf1004eac2d3de2139c357c356925dc07e2
Branch pushed to git repo; I updated commit sha1. New commits:
e0b1caf  #10224 : make explicit why some examples are not tested (random order).

comment:43 in reply to: ↑ 40 Changed 6 years ago by
 Status changed from needs_work to needs_review
Replying to jdemeyer:
At the very least, write something like
# not tested (random order)
.
I like this alternative, both explicit and not redundant.
comment:44 in reply to: ↑ 38 Changed 6 years ago by
Replying to dimpase:
OK, I'd be happy to give a positive review once the change proposed by Jeroen is done.
So  it is done and can be positive reviewed? (I don't really follow what is going on here, but I will add these packages to SageMathCell when they are ready.)
comment:45 Changed 6 years ago by
trying this with the latest beta, and seeing that one needs to set "make j1" in order to build qepcad successfully. At least for me...
comment:46 Changed 6 years ago by
 Branch changed from u/tmonteil/saclib_2_2_6_qepcad_B_1_69 to public/10224
 Commit changed from e0b1caf1004eac2d3de2139c357c356925dc07e2 to 4c26982db224d191dc3793edd54cd4ed77a8407c
 Status changed from needs_review to positive_review
added one more commit to indicate the latter issue in SPKG.txt
comment:47 Changed 6 years ago by
 Branch changed from public/10224 to 4c26982db224d191dc3793edd54cd4ed77a8407c
 Resolution set to fixed
 Status changed from positive_review to closed
comment:48 followup: ↓ 49 Changed 6 years ago by
 Commit 4c26982db224d191dc3793edd54cd4ed77a8407c deleted
Given that it fails consistently with "make j2" and most likely parallel building is enabled, shouldn't the build script enforce "make j1" rather than mention it somewhere?..
comment:49 in reply to: ↑ 48 Changed 5 years ago by
comment:50 Changed 5 years ago by
This issue's component is packages: optional
. Currently the package is 'experimental'.
In order to promote it to 'optional', it needs to build on all supported systems. Is this already the case?
Works fine for me. (Ubuntu 10.10)
But did you make a Mercurial update of your changes? If I build your package I get:
Created package qepcad1.54.p0.spkg.
SPKG.txt: Good
Btw: Version 1.55 is out, perhaps try to use the new source.
Regards, Stefan