website-build: use website from local git repository.
Before we needed to fetch the website from git because it was in a separate repository. Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> Acked-by: Adrien 'neox' Bourmault <neox@gnu.org>
This commit is contained in:
parent
399360485d
commit
20d122e94a
|
@ -19,12 +19,7 @@ DOMAIN := libreboot.at
|
|||
all: website.tar.gz
|
||||
|
||||
BUILD_OPTIONS :=
|
||||
GUIX_SHARE_OPTIONS :=
|
||||
|
||||
if WANT_LBWWW_PATH
|
||||
BUILD_OPTIONS += --with-lbwww-path $(LBWWW_PATH)
|
||||
GUIX_SHARE_OPTIONS += --share=`realpath $(LBWWW_PATH)`
|
||||
endif
|
||||
GUIX_SHARE_OPTIONS := --share=`realpath ../`
|
||||
|
||||
if WANT_UNTITLED_PATH
|
||||
BUILD_OPTIONS += --with-untitled-path $(UNTITLED_PATH)
|
||||
|
|
|
@ -17,9 +17,6 @@
|
|||
# For compatibility with sysexits.h (see man 3 sysexits.h for more details)
|
||||
EX_USAGE=64
|
||||
|
||||
lbwww_uri="https://git.savannah.gnu.org/git/gnuboot.git"
|
||||
lbwww_path=""
|
||||
|
||||
untitled_uri="https://notabug.org/untitled/untitled.git"
|
||||
untitled_path=""
|
||||
untitled_commit="e69c0d0748b8fc58d1548ea4249b93b1bbd2c6aa"
|
||||
|
@ -31,10 +28,6 @@ help()
|
|||
echo "Available options:"
|
||||
echo -e "\t-h, --help"
|
||||
echo -e "\t\tDisplay this help and exit."
|
||||
echo -e "\t--with-lbwww-path PATH"
|
||||
echo -e "\t\tUse a local lbwww directory from PATH\n" \
|
||||
"\t\tinstead of downloading the latest version from\n" \
|
||||
"\t\t${lbwww_uri}"
|
||||
echo -e "\t--with-untitled-path PATH"
|
||||
echo -e "\t\tUse a local untitled directory from PATH\n" \
|
||||
"\t\tinstead of downloading the latest version from\n" \
|
||||
|
@ -74,6 +67,16 @@ sync_repo()
|
|||
fi
|
||||
}
|
||||
|
||||
copy_website()
|
||||
{
|
||||
dst_path="$1"
|
||||
|
||||
rm -rf "${dst_path}"
|
||||
mkdir -p "${dst_path}"
|
||||
cp "../site.cfg" "${dst_path}"
|
||||
cp -a "../site/" "${dst_path}"
|
||||
}
|
||||
|
||||
help_missing_arg()
|
||||
{
|
||||
printf "Error: Argument of %s is missing.\n\n" "$1"
|
||||
|
@ -89,14 +92,6 @@ while [ "$i" -le $# ] ; do
|
|||
help
|
||||
exit 0
|
||||
;;
|
||||
--with-lbwww-path)
|
||||
if [ "$i" -ge $# ] ; then
|
||||
help_missing_arg "--with-lbwww-path"
|
||||
exit ${EX_USAGE}
|
||||
fi
|
||||
lbwww_path="$(eval echo \$$(expr $i + 1))"
|
||||
i="$(expr "$i" + 1)"
|
||||
;;
|
||||
--with-untitled-path)
|
||||
if [ "$i" -ge $# ] ; then
|
||||
help_missing_arg "--with-untitled-path"
|
||||
|
@ -118,8 +113,7 @@ set -e
|
|||
|
||||
sync_repo "untitled" \
|
||||
"${untitled_uri}" "${untitled_path}" "${untitled_commit}"
|
||||
sync_repo "untitled/www/lbwww" \
|
||||
"${lbwww_uri}" "${lbwww_path}" "origin/main"
|
||||
copy_website "untitled/www/lbwww/"
|
||||
|
||||
cd untitled
|
||||
./build sites lbwww
|
||||
|
|
|
@ -17,8 +17,6 @@ AC_INIT([gnuboot],[0.1],[gnuboot@gnu.org])
|
|||
AM_INIT_AUTOMAKE([foreign])
|
||||
AC_CONFIG_FILES([Makefile])
|
||||
|
||||
AC_SUBST([LBWWW_PATH], [])
|
||||
AC_SUBST([LBWWW_GIT_FOUND], [])
|
||||
AC_SUBST([RSYNC_DESTINATION], [])
|
||||
AC_SUBST([UNTITLED_PATH], [])
|
||||
AC_SUBST([UNTITLED_GIT_FOUND], [])
|
||||
|
@ -30,17 +28,6 @@ AC_ARG_ENABLE(guix,
|
|||
[guix="yes"])
|
||||
AM_CONDITIONAL( [WANT_GUIX], [test x"$guix" = x"yes"])
|
||||
|
||||
# --with-lbwww-path
|
||||
AC_ARG_WITH([lbwww-path],
|
||||
[AS_HELP_STRING([--with-lbwww-path=PATH],
|
||||
[Use a local lbwww directory from PATH instead of downloading
|
||||
the latest version from
|
||||
https://git.savannah.gnu.org/git/gnuboot.git])],
|
||||
[LBWWW_PATH=$withval],
|
||||
[])
|
||||
|
||||
AM_CONDITIONAL( [WANT_LBWWW_PATH], [test x"$LBWWW_PATH" != x""])
|
||||
|
||||
# --enable-lighttpd
|
||||
AC_ARG_ENABLE(lighttpd,
|
||||
[AS_HELP_STRING([--enable-lighttpd],
|
||||
|
@ -170,9 +157,6 @@ AS_IF([test x"$guix" = x"yes"],
|
|||
AC_OUTPUT
|
||||
AS_ECHO(["Configuration options:"])
|
||||
|
||||
AS_IF([test x"$LBWWW_PATH" != x""],
|
||||
[AS_ECHO([" LBWWW_PATH: $LBWWW_PATH"])])
|
||||
|
||||
AS_ECHO([" RSYNC_DESTINATION: $RSYNC_DESTINATION"])
|
||||
|
||||
AS_IF([test x"$UNTITLED_PATH" != x""],
|
||||
|
|
Loading…
Reference in New Issue