polymake 3.2 visulization error

Questions and problems about using polymake go here.

Moderator: Moderators

beew
Posts: 23
Joined: 13 Aug 2015, 20:41

polymake 3.2 visulization error

Postby beew » 18 Feb 2018, 09:02

For example, when I type the command

cube(3)->VISUAL;

polymake throws the error
sh: 0: Illegal option -D

Polymake3.2r2, OS is Ubuntu 16.04

Thanks

User avatar
gawrilow
Main Author
Posts: 311
Joined: 25 Dec 2010, 17:40

Re: polymake 3.2 visulization error

Postby gawrilow » 18 Feb 2018, 22:58

Looks like you haven't configured anything suitable for displaying pictures.
Please set $Verbose::external=1; and repeat your command, then watch for debugging output.
Also try show_unconfigured; and get an idea of what could be missing.

beew
Posts: 23
Joined: 13 Aug 2015, 20:41

Re: polymake 3.2 visulization error

Postby beew » 18 Feb 2018, 23:32

Might have something to do with this https://platformadmin.com/blogs/paul/20 ... h-to-bash/

From
https://wiki.ubuntu.com/DashAsBinSh

I added the line SHELL=/bin/bash to the top of the make file, but then ninja failed with

Code: Select all

FAILED: /usr/bin/perl /home/beew/Downloads/polymake-3.2/support/install.pl --root /home/beew/Downloads/polymake-3.2 --buildroot /home/beew/Downloads/polymake-3.2/build --config /home/beew/Downloads/polymake-3.2/build/config.ninja --mode Opt --xs /home/beew/Downloads/polymake-3.2/build/Opt/perlx/5.22.1/x86_64-linux-gnu-thread-multi/auto/Polymake/Ext/Ext.so --callable /home/beew/Downloads/polymake-3.2/build/Opt/perlx/5.22.1/x86_64-linux-gnu-thread-multi/libpolymake.so.3.2 /home/beew/Downloads/polymake-3.2/build/Opt/perlx/5.22.1/x86_64-linux-gnu-thread-multi/libpolymake.so --fakelibs /home/beew/Downloads/polymake-3.2/build/Opt/lib/callable/libpolymake-apps-rt.so.3.2 /home/beew/Downloads/polymake-3.2/build/Opt/lib/callable/libpolymake-apps-rt.so /home/beew/Downloads/polymake-3.2/build/Opt/lib/callable/libpolymake-apps.so.3.2 /home/beew/Downloads/polymake-3.2/build/Opt/lib/callable/libpolymake-apps.so mkdir /usr/local/share/polymake/demo: Permission denied at /home/beew/Downloads/polymake-3.2/support/install.pl line 480. ninja: build stopped: subcommand failed

beew
Posts: 23
Joined: 13 Aug 2015, 20:41

Re: polymake 3.2 visulization error

Postby beew » 18 Feb 2018, 23:35

Hi, am I doing something wrong?

Code: Select all

polytope > set $Verbose::external=1; polymake: ERROR: Can't locate object method "set" via package "0" (perhaps you forgot to load "0"?)

User avatar
gawrilow
Main Author
Posts: 311
Joined: 25 Dec 2010, 17:40

Re: polymake 3.2 visulization error

Postby gawrilow » 18 Feb 2018, 23:43

Remove the word "set" from the input, it's just a plain assignment to a variable.

User avatar
gawrilow
Main Author
Posts: 311
Joined: 25 Dec 2010, 17:40

Re: polymake 3.2 visulization error

Postby gawrilow » 18 Feb 2018, 23:48

Might have something to do with this https://platformadmin.com/blogs/paul/20 ... h-to-bash/ ...
mkdir /usr/local/share/polymake/demo: Permission denied at /home/beew/Downloads/polymake-3.2/support/install.pl line 480.
ninja: build stopped: subcommand failed[/code]
You seem to have no write permission in /usr/local/share or /usr/local/share/polymake, the latter might belong to an older installation. First remove it completely to avoid mixing different versions together, it rarely brings luck. /usr/local/ usually belongs root, you might need sudo for the install command. Your choice of shell should not play any role in this affair.

beew
Posts: 23
Joined: 13 Aug 2015, 20:41

Re: polymake 3.2 visulization error

Postby beew » 18 Feb 2018, 23:51

Code: Select all

polytope > $Verbose::external=1; polytope > cube(3)->VISUAL; polymake: starting -Djava.library.path=/usr/local/share/polymake/resources/java/jni -Dpolymake.userdir=/home/bernard/.polymake -cp /usr/local/share/polymake/resources/java/jars/polymake_java.jar:/usr/local/share/polymake/resources/java/jars/polymake_jreality.jar:/usr/local/share/polymake/resources/java/jars/jReality-backends-share.jar:/usr/local/share/polymake/resources/java/jars/jReality-core.jar:/usr/local/share/polymake/resources/java/jars/jReality-io.jar:/usr/local/share/polymake/resources/java/jars/jReality-jogl.jar:/usr/local/share/polymake/resources/java/jars/jReality-plugin.jar:/usr/local/share/polymake/resources/java/jars/jReality-proxies.jar:/usr/local/share/polymake/resources/java/jars/jReality-soft.jar:/usr/local/share/polymake/resources/java/jars/jReality-swing.jar:/usr/local/share/polymake/resources/java/jars/jReality-tools.jar:/usr/local/share/polymake/resources/java/jars/jReality-ui.jar:/usr/local/share/polymake/resources/java/jars/jreality/beans.jar:/usr/local/share/polymake/resources/java/jars/jreality/bsh.jar:/usr/local/share/polymake/resources/java/jars/jreality/colorpicker.jar:/usr/local/share/polymake/resources/java/jars/jreality/hidapi-1.1-javadoc.jar:/usr/local/share/polymake/resources/java/jars/jreality/hidapi-1.1.jar:/usr/local/share/polymake/resources/java/jars/jreality/itextpdf-5.3.2.jar:/usr/local/share/polymake/resources/java/jars/jreality/jacknativeclient.jar:/usr/local/share/polymake/resources/java/jars/jreality/janino.jar:/usr/local/share/polymake/resources/java/jars/jreality/jinput.jar:/usr/local/share/polymake/resources/java/jars/jreality/jrworkspace.jar:/usr/local/share/polymake/resources/java/jars/jreality/jterm.jar:/usr/local/share/polymake/resources/java/jars/jreality/jython-standalone-2.5.4-rc1.jar:/usr/local/share/polymake/resources/java/jars/jreality/NetUtil.jar:/usr/local/share/polymake/resources/java/jars/jreality/numericalMethods.jar:/usr/local/share/polymake/resources/java/jars/jreality/smrj-app.jar:/usr/local/share/polymake/resources/java/jars/jreality/smrj-client.jar:/usr/local/share/polymake/resources/java/jars/jreality/smrj.jar:/usr/local/share/polymake/resources/java/jars/jreality/vrpn.jar:/usr/local/share/polymake/resources/java/jars/jreality/xmlpull-1.1.3.1.jar:/usr/local/share/polymake/resources/java/jars/jreality/xpp3_min-1.1.4c.jar:/usr/local/share/polymake/resources/java/jars/jreality/xstream-1.4.7.jar de.tuberlin.polymake.common.SelectorThread 30000 -nl polymake_java 2>/dev/null sh: 0: Illegal option -D

User avatar
gawrilow
Main Author
Posts: 311
Joined: 25 Dec 2010, 17:40

Re: polymake 3.2 visulization error

Postby gawrilow » 19 Feb 2018, 00:01

polymake tries to start jreality but the path to java command is empty. Probably this is a consequence of your incomplete installation stopped because of lacking write permissions. First fix that, then start polymake --reconfigure (just once, not every time). The visualization with jreality should work then. Alternatively, you can use the web browser based visualization not requiring java:

Code: Select all

threejs(cube(3)->VISUAL);
But in any case you should get a clean and full installation, otherwise you'll keep getting new problems all the time.

beew
Posts: 23
Joined: 13 Aug 2015, 20:41

Re: polymake 3.2 visulization error

Postby beew » 19 Feb 2018, 00:24

I always started with a clean slate by removing the previous install.

I don't think the write permission has anything to do with the original problem since in my first run I use

Code: Select all

ninja -C build/Opt
without the install and then used checkinstall separately (don't want make install and like to dump files all over my file system, checkinstall creates a .deb file that is easy to keep track and clean up by apt)

P.S. did this again with SHELL=/bin/bash on line1 of make file, still same error

beew
Posts: 23
Joined: 13 Aug 2015, 20:41

Re: polymake 3.2 visulization error

Postby beew » 19 Feb 2018, 00:54

Tried again

with

Code: Select all

./configure ninja -C build/Opt -j8 sudo ninja -C build/Opt install
Without modifying anything.
Still same error.


Return to “Helpdesk”

cron