Corrections git man pages
[hvlinux.git] / stage2 / cis-openssh
index 148ca8d..c418771 100755 (executable)
@@ -1,4 +1,6 @@
 #!/bin/sh
+set -o errexit
+
 # First argument of this script is the package name
 
 # Reading system configuration informations, functions and package versions.
@@ -7,37 +9,38 @@ source ../functions
 source ../packages-list
 
 # Applying patches (if any)
-apply_patches ${1} &&
+apply_patches ${1}
 
-install -v -m700 -d /var/lib/sshd &&
-chown -v root:sys /var/lib/sshd &&
+install -v -m700 -d /var/lib/sshd
+chown -v root:sys /var/lib/sshd
 
-hv_groupadd sshd &&
-hv_useradd -c sshd-privsep -d /var/lib/sshd -g sshd -s /bin/false sshd &&
+hv_groupadd sshd
+hv_useradd -c sshd-privsep -d /var/lib/sshd -g sshd -s /bin/false sshd
 
-cd ${LFS_TMP}/${1}-build &&
+cd ${LFS_TMP}/${1}-build
 ../${1}/configure \
     --prefix=/usr \
     --sysconfdir=/etc/ssh \
+    --datadir=/usr/share/sshd \
+    --with-pam \
     --libexecdir=/usr/lib/openssh \
     --with-md5-passwords \
-    --with-privsep-path=/var/lib/sshd &&
-make -j ${MAKEJOBS} &&
-make -j ${MAKEJOBS} install &&
+    --with-privsep-path=/var/lib/sshd
+make -j ${MAKEJOBS}
+make -j ${MAKEJOBS} install
 
-cd ${LFS_TMP}/${1} &&
-install -v -m755 -d /usr/share/doc/${1} &&
+cd ${LFS_TMP}/${1}
+install -v -m755 -d /usr/share/doc/${1}
 install -v -m644 INSTALL LICENCE OVERVIEW README* WARNING.RNG \
-    /usr/share/doc/${1} &&
+    /usr/share/doc/${1}
 
 # Disabling root logins
-sed -i -e "s!^#PermitRootLogin.*!PermitRootLogin no!g" /etc/ssh/sshd_config &&
+sed -i -e "s!^#PermitRootLogin.*!PermitRootLogin no!g" /etc/ssh/sshd_config
 
 # Enabling X11 forwarding
-sed -i -e "s!^#X11Forwarding.*!X11Forwarding yes!g" /etc/ssh/sshd_config &&
+sed -i -e "s!^#X11Forwarding.*!X11Forwarding yes!g" /etc/ssh/sshd_config
 
 # Setting MaxAuthTries to 1
 sed -i -e "s!^#MaxAuthTries.*!MaxAuthTries 1!g" /etc/ssh/sshd_config
 
-# Return last error
 exit $?