mirror of
https://github.com/fish-shell/fish-shell.git
synced 2024-11-25 09:39:52 +08:00
Use pkg-config variables
This allows all variables to be set properly when the prefix or datadir changes. The generated .pc file looks like this: prefix=/usr/local datadir=${prefix}/share completionsdir=${datadir}/fish/vendor_completions.d functionsdir=${datadir}/fish/vendor_functions.d confdir=${datadir}/fish/vendor_conf.d Name: fish Description: fish, the friendly interactive shell URL: https://fishshell.com/ Version: 3.1.0-402-g75ae172ba228-dirty Closes: https://bugs.archlinux.org/task/65904
This commit is contained in:
parent
6c3732b99f
commit
d9d3557fcf
|
@ -35,6 +35,7 @@
|
||||||
### For distributors and developers
|
### For distributors and developers
|
||||||
- fish source tarballs are now distributed using the XZ compression method (#5460).
|
- fish source tarballs are now distributed using the XZ compression method (#5460).
|
||||||
- Allow finishing builds on OS X <10.13.6 (previously builds would fail at the `codesign` step)
|
- Allow finishing builds on OS X <10.13.6 (previously builds would fail at the `codesign` step)
|
||||||
|
- The pkg-config file now uses pkg-config variables
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|
|
@ -24,16 +24,20 @@ set(configure_input
|
||||||
"This file was generated from a corresponding .in file.\
|
"This file was generated from a corresponding .in file.\
|
||||||
DO NOT MANUALLY EDIT THIS FILE!")
|
DO NOT MANUALLY EDIT THIS FILE!")
|
||||||
|
|
||||||
|
set(rel_completionsdir "fish/vendor_completions.d")
|
||||||
|
set(rel_functionsdir "fish/vendor_functions.d")
|
||||||
|
set(rel_confdir "fish/vendor_conf.d")
|
||||||
|
|
||||||
set(extra_completionsdir
|
set(extra_completionsdir
|
||||||
/usr/local/share/fish/vendor_completions.d
|
"/usr/local/share/${rel_completionsdir}"
|
||||||
CACHE STRING "Path for extra completions")
|
CACHE STRING "Path for extra completions")
|
||||||
|
|
||||||
set(extra_functionsdir
|
set(extra_functionsdir
|
||||||
/usr/local/share/fish/vendor_functions.d
|
"/usr/local/share/${rel_functionsdir}"
|
||||||
CACHE STRING "Path for extra functions")
|
CACHE STRING "Path for extra functions")
|
||||||
|
|
||||||
set(extra_confdir
|
set(extra_confdir
|
||||||
/usr/local/share/fish/vendor_conf.d
|
"/usr/local/share/${rel_confdir}"
|
||||||
CACHE STRING "Path for extra configuration")
|
CACHE STRING "Path for extra configuration")
|
||||||
|
|
||||||
# These are the man pages that go in system manpath; all manpages go in the fish-specific manpath.
|
# These are the man pages that go in system manpath; all manpages go in the fish-specific manpath.
|
||||||
|
@ -99,7 +103,7 @@ fish_create_dirs(${rel_datadir}/fish/vendor_completions.d ${rel_datadir}/fish/ve
|
||||||
${rel_datadir}/fish/vendor_conf.d)
|
${rel_datadir}/fish/vendor_conf.d)
|
||||||
|
|
||||||
fish_try_create_dirs(${rel_datadir}/pkgconfig)
|
fish_try_create_dirs(${rel_datadir}/pkgconfig)
|
||||||
configure_file(fish.pc.in fish.pc.noversion)
|
configure_file(fish.pc.in fish.pc.noversion @ONLY)
|
||||||
|
|
||||||
add_custom_command(OUTPUT fish.pc
|
add_custom_command(OUTPUT fish.pc
|
||||||
COMMAND sed '/Version/d' fish.pc.noversion > fish.pc
|
COMMAND sed '/Version/d' fish.pc.noversion > fish.pc
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
prefix=@prefix@
|
prefix=@prefix@
|
||||||
datadir=@datadir@
|
datadir=${prefix}/@rel_datadir@
|
||||||
completionsdir=@extra_completionsdir@
|
completionsdir=${datadir}/@rel_completionsdir@
|
||||||
functionsdir=@extra_functionsdir@
|
functionsdir=${datadir}/@rel_functionsdir@
|
||||||
confdir=@extra_confdir@
|
confdir=${datadir}/@rel_confdir@
|
||||||
|
|
||||||
Name: fish
|
Name: fish
|
||||||
Description: fish, the friendly interactive shell
|
Description: fish, the friendly interactive shell
|
||||||
|
|
Loading…
Reference in New Issue
Block a user