[Debian-science-sagemath] Fwd: sagemath_7.4-1_amd64.changes is NEW

Ximin Luo infinity0 at debian.org
Sat Dec 17 12:32:00 UTC 2016


Jerome BENOIT:
> [..]
> 
> No need, the ideal wish is already patched. It was patched by the Debian maintainer himself (me):
> Sorry I forgot this part of the story; and I should document further this feature (I am agree).
> The concerned patch is d/p/upstream-system_wide.patch [1]. Details can be found in the header
> of the path. The involved environment variable is SYMPOW_CACHEDIR :
> 
> Assuming that the user has a HOME, let launch the sample script:
> 
> 	$ /usr/share/doc/sympow/examples/samples.sh
> 
> Data are put in $HOME/.sympow
> 
> Now, assuming some /scratch space, let do:
> 
> $ mkdir -p /scratch/$USR/sympow
> $ SYMPOW_CACHEDIR=/scratch/$USR/sympow /usr/share/doc/sympow/examples/samples.sh
> 
> Now data are put in /scratch/$USR/sympow .
> 
> [..]
> 
> 
> At the time of writing the patch, I guessed that HOME does always exist.
> This is my major mistake.
> 
> So, the issue solved.
> 
> Having said that, I am on my way to see how I can improve the visibility of this patched
> material.
> 

Ah, yes I didn't notice.

It would be good if sympow could automatically create SYMPOW_CACHEDIR if it doesn't exist. Otherwise, I would have to add this logic to Sage, which seems a bit unclean.

It already creates it for the default value ~/.sympow, but not when SYMPOW_CACHEDIR is different:

# creates ~/.sympow/ automatically
$ rm -rf ~/.sympow/
$ sympow  
sympow 1.023 RELEASE (Debian 1.023-7)  (c) Mark Watkins --- see README and COPYING for details
^C
130

# doesn't create SYMPOW_CACHEDIR=xxx automatically
$ HOME=/sbuild-nonexistent SYMPOW_CACHEDIR=$PWD/sympow sympow
sympow 1.023 RELEASE (Debian 1.023-7)  (c) Mark Watkins --- see README and COPYING for details
**ERROR** cache directory /home/infinity0/var/lib/sage/sympow does not exist
255
$ mkdir sympow
$ HOME=/sbuild-nonexistent SYMPOW_CACHEDIR=$PWD/sympow sympow
sympow 1.023 RELEASE (Debian 1.023-7)  (c) Mark Watkins --- see README and COPYING for details
^C
130

X

-- 
GPG: ed25519/56034877E1F87C35
GPG: rsa4096/1318EFAC5FBBDBCE
https://github.com/infinity0/pubkeys.git



More information about the Debian-science-sagemath mailing list