Skip to content

Commit daff079

Browse files
authored
Merge pull request #59 from Keruspe/master
add --bindir and --sysconfdir support
2 parents b787d33 + 524a564 commit daff079

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

install-template.sh

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -615,6 +615,18 @@ install_components() {
615615
# Decide the destination of the file
616616
local _file_install_path="$_dest_prefix/$_file"
617617

618+
if echo "$_file" | grep "^etc/" > /dev/null
619+
then
620+
local _f="$(echo "$_file" | sed 's/^etc\///')"
621+
_file_install_path="$CFG_SYSCONFDIR/$_f"
622+
fi
623+
624+
if echo "$_file" | grep "^bin/" > /dev/null
625+
then
626+
local _f="$(echo "$_file" | sed 's/^bin\///')"
627+
_file_install_path="$CFG_BINDIR/$_f"
628+
fi
629+
618630
if echo "$_file" | grep "^lib/" > /dev/null
619631
then
620632
local _f="$(echo "$_file" | sed 's/^lib\///')"
@@ -854,6 +866,8 @@ fi
854866
valopt without "" "comma-separated list of components to not install"
855867
valopt components "" "comma-separated list of components to install"
856868
flag list-components "list available components"
869+
valopt sysconfdir "/etc" "install system configuration files"
870+
valopt bindir "$CFG_DESTDIR_PREFIX/bin" "install binaries"
857871
valopt libdir "$CFG_DESTDIR_PREFIX/lib" "install libraries"
858872
valopt mandir "$CFG_DESTDIR_PREFIX/share/man" "install man pages in PATH"
859873
# NB See the docdir handling in install_components for an explanation of this

0 commit comments

Comments
 (0)