Sync with current production server

This commit is contained in:
Silvan Calarco 2023-08-07 12:33:15 +02:00
parent 801cd59eb2
commit 29bc94e68b
6 changed files with 24 additions and 49 deletions

View File

@ -1,7 +1,7 @@
#!/bin/bash
#
# Makedist automatic media build script
# Copyright (c) 2007-2022 by Silvan Calarco <silvan.calarco@mambasoft.it>
# Copyright (c) 2007-2023 by Silvan Calarco <silvan.calarco@mambasoft.it>
#
# Usage:
#
@ -88,7 +88,7 @@ function do_makedist() {
else
CMD_PREFIX=
fi
if [ "${DESTMILESTONE}" = "devel" -o "${DESTMILESTONE}" = "main" ]; then
if [ "${DESTMILESTONE}" = "rolling" -o "${DESTMILESTONE}" = "main" ]; then
MAKEDIST_TARGET=${DESTTARGET}
else
MAKEDIST_TARGET=${DESTTARGET}-${DESTMILESTONE}
@ -191,7 +191,7 @@ function do_makedist_and_html() {
echo "Error: do_makedist_and_html: invalid number of parameters; aborting."
exit 1
}
if [ "${MEDIUMMILESTONE}" != "devel" -a "${MEDIUMMILESTONE}" != "main" ]; then
if [ "${MEDIUMMILESTONE}" != "rolling" -a "${MEDIUMMILESTONE}" != "main" ]; then
SOURCEIMGFILEPREFIX="${MEDIUMTARGET}-${MEDIUMMILESTONE}"
DESTIMGFILEPREFIX="${MEDIUMTARGET}-${MEDIUMMILESTONE}"
else
@ -330,7 +330,7 @@ _EOF
chmod +r $DESTHTML
if [ "$DIST_CREATED" = "1" ]; then
# snapshots
if [ "$MEDIUMMILESTONE" != "devel" -a "$MEDIUMMILESTONE" != "main" ]; then
if [ "$MEDIUMMILESTONE" != "rolling" -a "$MEDIUMMILESTONE" != "main" ]; then
#temporary
makedist-announcement --rebuild-announcement --send-test-email -y ${MEDIUMMILESTONE} $PRODNAME
else
@ -355,8 +355,8 @@ for i in `seq 0 $ALLMEDIASLAST`; do
PLATFORM=${MEDIA_PLATFORM[i]}
SUBPLATFORM=${MEDIA_SUBPLATFORM[i]}
VARIANT=${MEDIA_VARIANT[i]}
DESTBASEDIR=${REPODIR_LOCAL}/${MEDIA_MILESTONE[i]}/media
DESTBASEURL=${REPODIR_URL}/${MEDIA_MILESTONE[i]}/media
DESTBASEDIR=${REPODIR_LOCAL}/media/${MEDIA_MILESTONE[i]}
DESTBASEURL=${REPODIR_URL}/media/${MEDIA_MILESTONE[i]}
unset PRODUCT_NAME
unset PRODUCT_NAME_OVERRIDE

View File

@ -1,6 +1,6 @@
# makedist Makefile
# Copyright (c) 2003-2023 by Silvan Calarco <silvan.calarco@mambasoft.it>
# Copyright (c) 2003-2004 by Davide Madrisan <davide.madrisan@gmail.com>
# Copyright (c) 2003-2022 by Silvan Calarco <silvan.calarco@mambasoft.it>
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
@ -10,9 +10,6 @@
include /var/makedist/.defs.inc
include ./VERSION
default_branch = devel
ftp_path = ftp://ftp.openmamba.org/pub/openmamba
# FIXME: obsolete, check and remove next time
initrd_dir = $(LOCALSTATEDIR)/initrd
@ -41,8 +38,7 @@ help:
echo
$(ALL_TARGETS): clean
@branch=$(BRANCH); test -z "$$branch" && branch=$(default_branch);\
./makedist.sh -t $@ $(initrd_dir) $$branch $(DEBUG)
./makedist.sh -t $@ $(initrd_dir) $(DEBUG)
clean:
@rm -fr $(initrd_dir)/modules/* $(initrd_dir)/install/* || true

View File

@ -45,7 +45,7 @@ fi
arch=$ARCH
[ $ARCH ] || {
arch=`uname -i`
arch=`uname -m`
[ "$arch" = "unknown" ] && {
echo "Error: can't determine the hardware platform; aborting."
exit 1

View File

@ -124,8 +124,8 @@ function initialize_root_dir() {
create_devices
# / to /usr symlinks
mkdir -p $MOUNTDIR/usr/{bin,sbin,lib}
#ln -s bin $MOUNTDIR/usr/sbin
mkdir -p $MOUNTDIR/usr/{bin,lib}
ln -s bin $MOUNTDIR/usr/sbin
ln -s usr/bin $MOUNTDIR/bin
ln -s usr/sbin $MOUNTDIR/sbin
ln -s usr/lib $MOUNTDIR/lib

View File

@ -1,7 +1,7 @@
#!/bin/bash
#
# makedist-announcement.sh - a makedist component which produces announcements
# Copyright (c) 2012-2014 by Silvan Calarco
# Copyright (c) 2012-2023 by Silvan Calarco
#
. /usr/share/makedist/VERSION
@ -69,7 +69,7 @@ else
MAKEDIST_TARGET=$distribution
buildinfourl=/var/ftp/pub/$distribution/distromatic/devel-makedist
pkginforep=$distversion-makedist
mediadistversion=snapshot
mediadistversion=$distversion
fi
. /etc/sysconfig/makedist
@ -261,7 +261,7 @@ mediumvariant=${MEDIA_VARIANT[i]}
webmediumdir=pub/$distribution/media/$distversion/$mediumname
mediumdir=/var/ftp/$webmediumdir
[ "$distversion" = "devel" ] && fallbackmediumdir=/var/ftp/pub/$distribution/media/milestone2/$mediumname
#[ "$distversion" = "devel" ] && fallbackmediumdir=/var/ftp/pub/$distribution/media/milestone2/$mediumname
if [ $mediumsubplatform ]; then
. /var/makedist/targets/$MAKEDIST_TARGET/platforms/$mediumsubplatform/settings.inc
@ -313,7 +313,7 @@ fi
# fi
#done
if [ "$distversion" = "devel" ]; then
if [ "$distversion" = "rolling" ]; then
version=`ls $mediumdir/en/latest-is-*.txt 2>/dev/null| sed "s/.*latest-is-\(.*\)\.txt/\1/"`
else
version=`ls $mediumdir/en/latest-is-$distversion-*.txt 2>/dev/null| sed "s/.*latest-is-$distversion-\(.*\)\.txt/\1/"`
@ -331,7 +331,7 @@ if [ ! -e $outputfile -o "$REBUILDANNOUNCEMENT" = "1" ]; then
IMG_ADD=""
fi
if [ "$distversion" != "devel" ]; then
if [ "$distversion" != "rolling" ]; then
echo "<h2>"$"$distribution ${MEDIA_NAME[i]} $version ($distversion) release announcement""</h2>" > $outputfile
echo "<div align=right><i><a href="http://$siteaddress">$sitedomain</a> - $announcementdate</i></div>" >> $outputfile
echo "<br><p>"$"The <b>$distversion $version</b> release of the $distribution <b>${MEDIA_NAME[i]}</b> distribution is available for download." >> $outputfile
@ -394,12 +394,12 @@ $distribution-$mediumname-$l-$mediadistversion-$version.${a}.${medium_suffix}</a
<li>"$"Updates level"": "$"bugfix"", "$"security"", "$"end-user applications""
<li>"$"Default updates channels"": milestone2, milestone2-updates, milestone2-games
" >> $outputfile
elif [ "$distversion" = "devel" ]; then
elif [ "$distversion" = "rolling" ]; then
echo "\
<li>"$"Release branch"": $distversion ("$"unstable"")
<li>"$"Release branch"": $distversion ("$"rolling"")
<li>"$"Planned maintenance"": "$"long term""
<li>"$"Updates level"": "$"rolling""
<li>"$"Updates default channels"": devel, devel-games
<li>"$"Updates default channels"": base
" >> $outputfile
fi
echo -n "</ul>" >> $outputfile
@ -482,23 +482,14 @@ _EOF
:<< _EOF
echo "<li><a href='http://$siteaddress/distribution/media/${MEDIA_NAME[i]}.html?lang=$outputlang'>\
"$"${MEDIA_NAME[i]} page at $siteaddress""</a>" >> $outputfile
if [ "$distversion" = "devel" ]; then
sitedistversion="development"
else
sitedistversion="$distversion"
fi
echo "<li><a href='http://$siteaddress/distribution/$sitedistversion.html?lang=$outputlang'>"$"$sitedistversion channels and packages""</a>" >> $outputfile
_EOF
echo "\
<li><a href='https://$siteaddress/$outputlang/'>"$"$distribution website""</a>\
<li><a href='https://$siteaddress/$outputlang/forum/'>"$"$distribution forum""</a>\
" >> $outputfile
echo -n "</div><hr><p><i>"$"Announcement automatically generated by"" makedist $makedist_version " >> $outputfile
if [ "$distversion" != "devel" -a "$ANNOUNCEMENTS_SIGNER" ]; then
if [ "$ANNOUNCEMENTS_SIGNER" ]; then
echo $"and signed off by"" $ANNOUNCEMENTS_SIGNER</i>" >> $outputfile
else
echo >> $outputfile
fi
#gpg --clearsign $outputfile > $outputfile.sig
@ -517,7 +508,7 @@ if [ "$SENDEMAIL" -o "$SENDTESTEMAIL" ]; then
if [ ! "$SENDADDRESSES" ]; then
if [ "$SENDTESTEMAIL" ]; then
SENDADDRESSES=$ANNOUNCEMENTS_EMAILS_TEST
elif [ "$distversion" = "devel" ]; then
elif [ "$distversion" = "rolling" ]; then
case $outputlang in
en) SENDADDRESSES="$ANNOUNCEMENTS_EMAILS_DEVEL_EN" ;;
it) SENDADDRESSES="$ANNOUNCEMENTS_EMAILS_DEVEL_IT" ;;
@ -532,7 +523,7 @@ if [ "$SENDEMAIL" -o "$SENDTESTEMAIL" ]; then
fi
fi
if [ "$distversion" != "devel" ]; then
if [ "$distversion" != "rolling" ]; then
SENDTITLE=$"Release announcement: $distribution $distversion ${MEDIA_NAME[i]} $version"
else
SENDTITLE=$"New snapshot: $distribution ${MEDIA_NAME[i]} $version ($distversion)"

View File

@ -2,7 +2,7 @@
#
# makedist.sh - Distribution media (CD/DVD/..) creator
#
# Copyright (c) 2003-2015 by Silvan Calarco <silvan.calarco@mambasoft.it>
# Copyright (c) 2003-2023 by Silvan Calarco <silvan.calarco@mambasoft.it>
# Copyright (c) 2003-2006 by Davide Madrisan <davide.madrisan@gmail.com>
#
# This program is free software; you can redistribute it and/or modify
@ -25,7 +25,6 @@ Copyright (c) 2003-2015 by Silvan Calarco <silvan.calarco@mambasoft.it>
Copyright (c) 2003-2005 by Davide Madrisan <davide.madrisan@gmail.com>
"
unset branch # can be 'stable', 'unstable', or 'devel'
makedist_me="${0##*/}"
UPDATE=none
@ -38,7 +37,7 @@ RPM2CPIO=rpm2cpio
function usage() {
echo "\
usage: $makedist_me [-y] [-u[=<opts>]] [-t target] bootcd initrd kernel branch
usage: $makedist_me [-y] [-u[=<opts>]] [-t target] bootcd initrd kernel
-y : switch to non interactive mode
-w : download only files and packages; do not create an ISO image
-t : build CD for specified target
@ -67,7 +66,6 @@ while test -n "$1" ; do
-h) usage; exit ;;
-v) echo "$copyleft"; exit ;;
*) if test -z "$INITRDDIR" ; then INITRDDIR=$1
elif test -z "$branch" ; then branch=$1
elif test -z "$DEBUG" ; then DEBUG=$1
elif test -z "$MEDIA" ; then MEDIA=$1
elif test -z "$PLATFORM" ; then PLATFORM=$1
@ -84,21 +82,11 @@ done
unset error
test -z "$INITRDDIR" && error=true
test "$UPDATE" != "none" -a -z "$branch" && error=true
test x$error = xtrue &&
{ echo "$makedist_me: missing parameter";
usage; { (exit 1); exit 1; }; }
case "$branch" in
stable) branch_dir="stable/current" ;;
unstable) branch_dir="unstable/current" ;;
devel) branch_dir="devel" ;;
*) echo "unknown branch ($branch)"
echo "valid choices are: 'stable', 'unstable', 'devel'"
exit 1 ;;
esac
case "$LANGUAGE" in
it*) LANGUAGE=it
COUNTRY=IT ;;