gnu: pcsxr: Wrap with GSETTINGS_SCHEMA_DIR path variable.

Without setting this path variable, gtk+ must be installed in the user's
profile for pcsxr's GUI to work.

* gnu/packages/emulators.scm (pcsxr)[arguments]: Add 'wrap-program' phase and
return #t from 'cd-subdir' and 'fix-cdio-lookup' phases.
This commit is contained in:
Kei Kebreau 2020-01-26 19:01:00 -05:00
parent 4144eb195c
commit 1ef71f5225
No known key found for this signature in database
GPG key ID: E6A5EE3C19467A0D

View file

@ -1478,12 +1478,22 @@ (define-public pcsxr
#:phases
(modify-phases %standard-phases
(add-after 'unpack 'cd-subdir
(lambda _ (chdir "pcsxr")))
(lambda _ (chdir "pcsxr") #t))
(add-before 'configure 'fix-cdio-lookup
(lambda* (#:key inputs #:allow-other-keys)
(substitute* "cmake/FindCdio.cmake"
(("/usr/include/cdio")
(string-append (assoc-ref inputs "libcdio") "/include/cdio"))))))))
(string-append (assoc-ref inputs "libcdio") "/include/cdio")))
#t))
(add-after 'install 'wrap-program
(lambda* (#:key inputs outputs #:allow-other-keys)
(wrap-program (string-append (assoc-ref outputs "out")
"/bin/pcsxr")
;; For GtkFileChooserDialog.
`("GSETTINGS_SCHEMA_DIR" =
(,(string-append (assoc-ref inputs "gtk+")
"/share/glib-2.0/schemas"))))
#t)))))
(native-inputs
`(("pkg-config" ,pkg-config)
("intltool" ,intltool)