Skip to content

add --bindir and --sysconfdir support #59

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 10, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions install-template.sh
Original file line number Diff line number Diff line change
@@ -615,6 +615,18 @@ install_components() {
# Decide the destination of the file
local _file_install_path="$_dest_prefix/$_file"

if echo "$_file" | grep "^etc/" > /dev/null
then
local _f="$(echo "$_file" | sed 's/^etc\///')"
_file_install_path="$CFG_SYSCONFDIR/$_f"
fi

if echo "$_file" | grep "^bin/" > /dev/null
then
local _f="$(echo "$_file" | sed 's/^bin\///')"
_file_install_path="$CFG_BINDIR/$_f"
fi

if echo "$_file" | grep "^lib/" > /dev/null
then
local _f="$(echo "$_file" | sed 's/^lib\///')"
@@ -854,6 +866,8 @@ fi
valopt without "" "comma-separated list of components to not install"
valopt components "" "comma-separated list of components to install"
flag list-components "list available components"
valopt sysconfdir "/etc" "install system configuration files"
valopt bindir "$CFG_DESTDIR_PREFIX/bin" "install binaries"
valopt libdir "$CFG_DESTDIR_PREFIX/lib" "install libraries"
valopt mandir "$CFG_DESTDIR_PREFIX/share/man" "install man pages in PATH"
# NB See the docdir handling in install_components for an explanation of this