summaryrefslogtreecommitdiff
path: root/astro/setiathome/pkg-install
diff options
context:
space:
mode:
authorStefan Bethke <stb@FreeBSD.org>1999-04-22 12:24:25 +0000
committerStefan Bethke <stb@FreeBSD.org>1999-04-22 12:24:25 +0000
commitfb34d55ddd3a5ee85bf9deb1aeac6da69b632a7c (patch)
treef4b28efd77f8d1ec64501f4e1d133e3896d9b774 /astro/setiathome/pkg-install
parentBetter check for OS version, cleanup. (diff)
Allow for automatich package building
Reinstate the EXTRACT_ variables. They are needed.
Notes
Notes: svn path=/head/; revision=18080
Diffstat (limited to 'astro/setiathome/pkg-install')
-rw-r--r--astro/setiathome/pkg-install25
1 files changed, 17 insertions, 8 deletions
diff --git a/astro/setiathome/pkg-install b/astro/setiathome/pkg-install
index 714e9eaf9960..adb539464788 100644
--- a/astro/setiathome/pkg-install
+++ b/astro/setiathome/pkg-install
@@ -34,10 +34,22 @@ case \$1 in
;;
stop)
killall setiathome
+ ;;
+ register)
+ mkdir -p \${DBDIR}
+ chown \${USER} \${DBDIR}
+ chmod 755 \${DBDIR}
+
+ su -m nobody -c "cd \${DBDIR} && \${PREFIX}/bin/setiathome -login"
+ ;;
esac
EOF
chmod +x ${RCD}
+ if [ -n "${PACKAGE_BUILDING}" ]; then
+ exit 0
+ fi
+
echo "**** SETI@home requires a working directory for temporary files and"
echo " a brief registration process."
echo " Would you like to set up a working directory in ${DBDIR},"
@@ -47,20 +59,17 @@ EOF
echo ""
if [ "$a" = "N" -o "$a" = "n" ]; then
echo ""
- echo "Please set up the working directory yourself. See setiathome(1)"
- echo "for details."
+ echo "Please set up the working directory yourself. You can use"
+ echo "${RCD} register"
+ echo "to do so. See setiathome(1) for details."
exit 0
fi
- mkdir -p ${DBDIR}
- chown ${USER} ${DBDIR}
- chmod 755 ${DBDIR}
-
- su -m nobody -c "cd ${DBDIR} && ${PKG_PREFIX}/bin/setiathome -login"
+ ${RCD} register
if [ ! -f ${DBDIR}/user_info.txt ]; then
echo "unable to start setiathome: it seems registration or login failed."
- exit 72
+ exit 0
fi
${RCD} start >/dev/null
echo