@@ -8433,22 +8433,25 @@ (define-public scilab
(base32 "0phg9pn24yw98hbh475ik84dnikf1225b2knh7qbhdbdx6fm2d57"))))
(build-system gnu-build-system)
(native-inputs (list pkg-config gfortran))
- (inputs (list libxml2
+ (inputs (list arpack-ng
+ coreutils-minimal
+ curl
+ fftw
+ gettext-minimal
+ grep
+ hdf5-1.8
+ lapack
+ libxml2
+ libx11
+ matio
+ openblas
`(,pcre "bin")
`(,pcre "out")
readline
- hdf5-1.8
- curl
- openblas
- lapack
- arpack-ng
- fftw
- gettext-minimal
+ sed
suitesparse-3
tcl
- tk
- libx11
- matio))
+ tk))
(arguments
`(#:tests? #f
#:configure-flags
@@ -8484,10 +8487,6 @@ (define-public scilab
,#~(modify-phases %standard-phases
(add-before 'build 'pre-build
(lambda _
- ;; Fix scilab script.
- (substitute* "bin/scilab"
- (("\\/bin\\/ls")
- (which "ls")))
;; Fix core.start.
(substitute* "modules/core/etc/core.start"
(("'SCI/modules")
@@ -8519,7 +8518,22 @@ (define-public scilab
(("if \\(array_size > 0\\)")
"if (*array_size > 0)"))
;; Set SCIHOME to /tmp before macros compilation.
- (setenv "SCIHOME" "/tmp"))))))
+ (setenv "SCIHOME" "/tmp")))
+ (add-after 'install 'hardcode-script-inputs
+ (lambda _
+ (substitute* (string-append #$output "/bin/scilab")
+ (("grep")
+ (search-inputs-file #$inputs "/bin/grep"))
+ ((" sed ") ; some "sed" strings are not binaries invocations
+ (string-append " " (search-inputs-file #$inputs "/bin/sed") " "))
+ (("/bin/ls")
+ (search-inputs-file #$inputs "/bin/ls"))
+ (("uname")
+ (search-inputs-file #$inputs "/bin/uname"))
+ (("dirname")
+ (search-inputs-file #$inputs "/bin/dirname"))
+ (("basename")
+ (search-inputs-file #$inputs "/bin/basename"))))))))
(home-page "https://scilab.org")
(synopsis "Software for engineers and scientists")
(description "This package provides the non-graphical version of the Scilab