Compare commits
94 Commits
Author | SHA1 | Date | |
---|---|---|---|
4f12cc4969 | |||
1da0a6d971 | |||
a66a8f8029 | |||
2dd4d2632d | |||
6dd2bb37bc | |||
79c00b9f50 | |||
f4dbf4b5c2 | |||
13e52f18d5 | |||
1979751f33 | |||
ed2de4963a | |||
ae9e5c3be5 | |||
457d02194c | |||
7107f7884f | |||
159432b669 | |||
c73ba35d74 | |||
2d950512e4 | |||
30e8c88970 | |||
eff79c5bf8 | |||
e6ee8dbd5b | |||
9643cf4103 | |||
bb64fe0188 | |||
1617e30950 | |||
f0eaac941b | |||
c0b7304aa4 | |||
7a268ce0c8 | |||
49a1ed773b | |||
99ab1fe252 | |||
112abc68c6 | |||
f2bb820de8 | |||
0f96bedecd | |||
70548ea687 | |||
67497d1d4f | |||
50d38312db | |||
82ab9d49c9 | |||
24f57a4cd4 | |||
0c9f7b442e | |||
03d939419c | |||
ea9bd6e623 | |||
6fc6b0bda6 | |||
2979f8d61b | |||
25b48ad735 | |||
5df925c70b | |||
34796d0b38 | |||
9076297743 | |||
49f415f364 | |||
bdc9145d01 | |||
49bda1c6c3 | |||
82337b4343 | |||
9ab269e0f7 | |||
d73319d4ea | |||
aee7f737b1 | |||
14d27be655 | |||
f5d91a52fc | |||
ecc3ed74a2 | |||
dd9fb71c1b | |||
094174a2b6 | |||
a939e6217a | |||
10b3f8eff0 | |||
4cf07b63e5 | |||
0669999e60 | |||
a6bcf08a21 | |||
77cfdacce8 | |||
1815ade013 | |||
374848a5a0 | |||
c35c462647 | |||
ea17d50b69 | |||
ef98426c64 | |||
cbe63c0c85 | |||
ee91237d64 | |||
0febe8f777 | |||
fd294840b1 | |||
aeec210b02 | |||
24f394ce84 | |||
becb15708b | |||
0e2960e708 | |||
92a3d43064 | |||
16b2ff1ce9 | |||
07e9b8a75d | |||
56923432c9 | |||
74876ce852 | |||
272860e5fe | |||
c0f51ea3ac | |||
dc7de5b07c | |||
641029e7ec | |||
9cfdccccc0 | |||
19233fce7d | |||
dd369356c5 | |||
0315d1a69d | |||
8751a555bc | |||
d7fa8c819b | |||
d99d231b47 | |||
8fa299b2f2 | |||
e0f9129ac5 | |||
2b8d183d22 |
21
Makefile
21
Makefile
@ -1,5 +1,5 @@
|
||||
# Makefile for autodist
|
||||
# Copyright (C) 2006-2009 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
# Copyright (C) 2006-2014 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
#
|
||||
PACKAGE = autodist
|
||||
|
||||
@ -47,6 +47,7 @@ install-dirs:
|
||||
@$(INSTALL_DIR) $(DESTDIR)$(sysconfdir)/cron.hourly
|
||||
@$(INSTALL_DIR) $(DESTDIR)$(sysconfdir)/cron.daily
|
||||
@$(INSTALL_DIR) $(DESTDIR)$(sysconfdir)/sysconfig
|
||||
@$(INSTALL_DIR) $(DESTDIR)$(sysconfdir)/logrotate.d
|
||||
@$(INSTALL_DIR) $(DESTDIR)$(bindir)
|
||||
@$(INSTALL_DIR) $(DESTDIR)$(sbindir)
|
||||
@$(INSTALL_DIR) $(DESTDIR)$(cgidir)
|
||||
@ -69,7 +70,9 @@ install-programs:
|
||||
@$(INSTALL_SCRIPT) autodist $(DESTDIR)$(bindir)/autodist
|
||||
@$(INSTALL_SCRIPT) autodist-tool $(DESTDIR)$(bindir)/autodist-tool
|
||||
@$(INSTALL_SCRIPT) autoport $(DESTDIR)$(bindir)/autoport
|
||||
@$(INSTALL_SCRIPT) automaint $(DESTDIR)$(sbindir)/automaint
|
||||
@$(INSTALL_SCRIPT) autoport-chroot $(DESTDIR)$(sbindir)/autoport-chroot
|
||||
@$(INSTALL_SCRIPT) autodist-repository $(DESTDIR)$(sbindir)/autodist-repository
|
||||
@$(INSTALL_SCRIPT) autodist-upstream-updates $(DESTDIR)$(sbindir)/autodist-upstream-updates
|
||||
@$(INSTALL_SCRIPT) autoport-fix-environment $(DESTDIR)$(bindir)/autoport-fix-environment
|
||||
@$(INSTALL_SCRIPT) etc/autodist/scripts/* $(DESTDIR)$(configdir)/scripts/
|
||||
@ -83,29 +86,21 @@ install-programs:
|
||||
|
||||
install-data:
|
||||
@$(INSTALL_DATA) etc/autodist/config $(DESTDIR)$(configdir)/config
|
||||
@$(INSTALL_DATA) etc/autodist/distdb $(DESTDIR)$(configdir)/distdb
|
||||
@$(INSTALL_DATA) etc/autodist/distdb.i586 $(DESTDIR)$(configdir)/distdb.i586
|
||||
@$(INSTALL_DATA) etc/autodist/distdb.arm $(DESTDIR)$(configdir)/distdb.arm
|
||||
@$(INSTALL_DATA) etc/autodist/distdb.x86_64 $(DESTDIR)$(configdir)/distdb.x86_64
|
||||
@$(INSTALL_DATA) etc/autodist/distdb.ppc $(DESTDIR)$(configdir)/distdb.ppc
|
||||
@$(INSTALL_DATA) etc/autodist/legacy $(DESTDIR)$(configdir)/legacy
|
||||
@$(INSTALL_DATA) etc/autodist/unstage $(DESTDIR)$(configdir)/unstage
|
||||
@$(INSTALL_DATA) etc/autodist/unstage.i586 $(DESTDIR)$(configdir)/unstage.i586
|
||||
@$(INSTALL_DATA) etc/autodist/unstage.arm $(DESTDIR)$(configdir)/unstage.arm
|
||||
@$(INSTALL_DATA) etc/autodist/unstage.x86_64 $(DESTDIR)$(configdir)/unstage.x86_64
|
||||
@$(INSTALL_DATA) etc/autodist/unstage.ppc $(DESTDIR)$(configdir)/unstage.ppc
|
||||
@$(INSTALL_DATA) etc/autodist/distdb.d/*.db $(DESTDIR)$(configdir)/distdb.d/
|
||||
@$(INSTALL_DATA) etc/autodist/blacklist $(DESTDIR)$(configdir)/blacklist
|
||||
@$(INSTALL_DATA) etc/autodist/distdb.d/* $(DESTDIR)$(configdir)/distdb.d/
|
||||
@$(INSTALL_DATA) etc/sudoers.d/autoport $(DESTDIR)$(sysconfdir)/sudoers.d/autoport
|
||||
@$(INSTALL_DATA) webbuild/webbuild-sudoers $(DESTDIR)$(sysconfdir)/sudoers.d/webbuild
|
||||
@$(INSTALL_DATA) webbuild/webbuild-admin $(DESTDIR)$(localstatedir)/webbuild/users/admin.conf
|
||||
@$(INSTALL_SCRIPT) etc/sysconfig/autoport $(DESTDIR)$(sysconfdir)/sysconfig/autoport
|
||||
@$(INSTALL_SCRIPT) etc/cron.hourly/60-autodist-update $(DESTDIR)$(sysconfdir)/cron.hourly/
|
||||
@$(INSTALL_SCRIPT) etc/cron.hourly/65-autoport-native $(DESTDIR)$(sysconfdir)/cron.hourly/
|
||||
@$(INSTALL_SCRIPT) etc/cron.hourly/66-autoport-chroot $(DESTDIR)$(sysconfdir)/cron.hourly/
|
||||
@$(INSTALL_SCRIPT) etc/cron.daily/40-autodist-cleanold $(DESTDIR)$(sysconfdir)/cron.daily/
|
||||
@$(INSTALL_SCRIPT) etc/cron.daily/40-autodist-upstream-updates $(DESTDIR)$(sysconfdir)/cron.daily/
|
||||
@$(INSTALL_SCRIPT) etc/logrotate.d/webbuild $(DESTDIR)$(sysconfdir)/logrotate.d/webbuild
|
||||
@$(INSTALL_DATA) autospec-conf $(DESTDIR)$(pck_statedir)/.autospec
|
||||
@$(INSTALL_DATA) autodist-bashrc $(DESTDIR)$(pck_statedir)/.bashrc
|
||||
@$(INSTALL_DATA) autodist-bash_profile $(DESTDIR)$(pck_statedir)/.bash_profile
|
||||
@touch $(DESTDIR)$(pck_statedir)/template/autoupdate/auto.success
|
||||
@touch $(DESTDIR)$(pck_statedir)/template/autoupdate/auto.skip
|
||||
|
||||
|
262
autodist
262
autodist
@ -1,11 +1,11 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Autodist -- batch build tool for RPM based distributions
|
||||
# Copyright (C) 2006-2013 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
# Copyright (C) 2006-2014 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
#
|
||||
# Released under the terms of the GNU GPL release 3 license
|
||||
#
|
||||
VERSION=0.9.6
|
||||
VERSION=0.9.12
|
||||
me=(${0##*/} $VERSION "Sat Aug 20 2010")
|
||||
exec 3>`readlink /proc/self/fd/0`
|
||||
|
||||
@ -46,6 +46,7 @@ ${me[0]} ${me[1]}
|
||||
1: skip current job on error
|
||||
2: abort on error""
|
||||
--arch "$"Build packages for specified target architecture""
|
||||
--user user "$"Pass calling user name for Webbuild social messages""
|
||||
|
||||
job "$"Job specification in the form pkg#version, job#version, job/pkg#version, examples:
|
||||
glibc#2.11.1
|
||||
@ -56,21 +57,17 @@ ${me[0]} ${me[1]}
|
||||
|
||||
}
|
||||
|
||||
function fetch_repository_list() {
|
||||
local REPOLIST=$1
|
||||
|
||||
if [ -r ${LOCAL_REPS_BASE_DIR}/$REPOLIST ]; then
|
||||
echo ${LOCAL_REPS_BASE_DIR}/$REPOLIST
|
||||
function fetch_repository_file() {
|
||||
local REPOFILE=$1
|
||||
if [ -r ${LOCAL_REPS_BASE_DIR}/$REPOFILE ]; then
|
||||
echo ${LOCAL_REPS_BASE_DIR}/$REPOFILE
|
||||
return 0
|
||||
else
|
||||
if [ ! -r $USERCONFDIR/$REPOLIST -o "`find $USERCONFDIR/$REPOLIST -mmin +60 2>/dev/null`" ]; then
|
||||
mkdir -p `dirname $USERCONFDIR/$REPOLIST`
|
||||
curl -s $REPS_BASE_URL/$REPOLIST -o $USERCONFDIR/$REPOLIST || {
|
||||
echo "Error: unable to fetch $REPS_BASE_DIR/$REPOLIST"
|
||||
exit 1
|
||||
}
|
||||
if [ ! -r $USERCONFDIR/$REPOFILE -o "`find $USERCONFDIR/$REPOFILE -mmin +60 2>/dev/null`" ]; then
|
||||
mkdir -p `dirname $USERCONFDIR/$REPOFILE`
|
||||
curl -f -L -s $REPS_BASE_URL/$REPOFILE -o $USERCONFDIR/$REPOFILE || return 1
|
||||
fi
|
||||
echo $USERCONFDIR/$REPOLIST
|
||||
echo $USERCONFDIR/$REPOFILE
|
||||
return 0
|
||||
fi
|
||||
}
|
||||
@ -129,7 +126,6 @@ for ((i=1; i<=$#; i++)); do
|
||||
exit 1
|
||||
}
|
||||
}
|
||||
|
||||
;;
|
||||
-c|--cleanlogs) do_cleanlogs=1 ;;
|
||||
-h|--help) usage
|
||||
@ -159,32 +155,39 @@ for ((i=1; i<=$#; i++)); do
|
||||
;;
|
||||
--server) let i+=1
|
||||
[ "${!i}" ] || {
|
||||
echo "Error: server parameter not given, aborting."
|
||||
echo "Error: --server parameter not given, aborting."
|
||||
exit 1
|
||||
}
|
||||
SEND_SERVER="${!i}"
|
||||
;;
|
||||
--repository) let i+=1
|
||||
[ "${!i}" ] || {
|
||||
echo "Error: repository parameter not given, aborting."
|
||||
echo "Error: --repository parameter not given, aborting."
|
||||
exit 1
|
||||
}
|
||||
AUTODIST_REPOSITORY="${!i}"
|
||||
;;
|
||||
--severity) let i+=1
|
||||
[ "${!i}" ] || {
|
||||
echo "Error: severity parameter not given, aborting."
|
||||
echo "Error: --severity parameter not given, aborting."
|
||||
exit 1
|
||||
}
|
||||
SEVERITY=${!i}
|
||||
;;
|
||||
--arch) let i+=1
|
||||
[ "${!i}" ] || {
|
||||
echo "Error: arch parameter not given, aborting."
|
||||
echo "Error: --arch parameter not given, aborting."
|
||||
exit 1
|
||||
}
|
||||
TARGETARCH=${!i}
|
||||
;;
|
||||
--user) let i+=1
|
||||
[ "${!i}" ] || {
|
||||
echo "Error: --user parameter not given, aborting."
|
||||
exit 1
|
||||
}
|
||||
WEBBUILD_USER_CMDLINE="${!i}"
|
||||
;;
|
||||
-*) if [ "${!i}" = "--" ]; then
|
||||
AUTOSPEC_ARGS_MODE=1
|
||||
elif [ "$AUTOSPEC_ARGS_MODE" ]; then
|
||||
@ -213,12 +216,6 @@ done
|
||||
[ "$SEND_SERVER" ] || SEND_SERVER=$AUTODIST_REPOSITORY
|
||||
|
||||
SEND_SERVER_CMD="--server $SEND_SERVER"
|
||||
AUTOUPDATEDIR=${LOCAL_REPS_BASE_DIR}/$AUTODIST_REPOSITORY/autoupdate/
|
||||
|
||||
[ -r $AUTOUPDATEDIR ] || {
|
||||
AUTOUPDATEDIR=$USERCONFDIR/$AUTODIST_REPOSITORY/autoupdate
|
||||
mkdir -p $AUTOUPDATEDIR
|
||||
}
|
||||
|
||||
# perform arch names conversions
|
||||
case $BUILDARCH in
|
||||
@ -229,34 +226,6 @@ case $TARGETARCH in
|
||||
i386|i486|i686) TARGETARCH=i586 ;;
|
||||
esac
|
||||
|
||||
SOURCESDIR=$AUTOUPDATEDIR/sources/
|
||||
SUCCESSLISTDIR=$AUTOUPDATEDIR
|
||||
SKIPPEDLISTDIR=$AUTOUPDATEDIR
|
||||
|
||||
SRCPKGLIST=`fetch_repository_list $AUTODIST_REPOSITORY/srcpkglist`
|
||||
[ "$AUTODIST_DELAYED_REPOSITORY" ] && SRCPKGLIST_DELAYED=`fetch_repository_list $AUTODIST_DELAYED_REPOSITORY/srcpkglist`
|
||||
|
||||
BUILDSLIST=`fetch_repository_list distromatic/$AUTODIST_REPOSITORY/builds-$TARGETARCH`
|
||||
[ "$AUTODIST_DELAYED_REPOSITORY" ] && BUILDSLIST_DELAYED=`fetch_repository_list distromatic/$AUTODIST_DELAYED_REPOSITORY/builds-$TARGETARCH`
|
||||
|
||||
[ -e "$DISTDB" ] || {
|
||||
echo "ERROR: missing distdb file $DISTDB; aborting."
|
||||
exit 1
|
||||
}
|
||||
|
||||
[ -e $LOGBASEDIR ] || {
|
||||
mkdir -p $LOGBASEDIR/prepare/{ok,failed}
|
||||
mkdir -p $LOGBASEDIR/update/{ok,failed}
|
||||
mkdir -p $LOGBASEDIR/build/{ok,failed}
|
||||
mkdir -p $LOGBASEDIR/install/{ok,failed}
|
||||
mkdir -p $LOGBASEDIR/send/{ok,failed}
|
||||
}
|
||||
|
||||
#[ "$PACKAGE" ] || {
|
||||
# echo "ERROR: missing target; aborting."
|
||||
# usage
|
||||
# exit 1
|
||||
#}
|
||||
|
||||
# for webbuild message
|
||||
function cgi_encodevar() {
|
||||
@ -520,7 +489,7 @@ function launch_pkgs_loop() {
|
||||
JOB_ARGS="$JOB_ARGS$DEFINES_STRING"
|
||||
|
||||
[ "$patch_operation" = "buildinstall" ] && patch_operation=build
|
||||
[ "$patch_operation" = "autoupdate" ] && patch_operation=update
|
||||
[ "$patch_operation" = "autoupdate" -o "$patch_operation" = "rebuild" ] && patch_operation=update
|
||||
|
||||
# launch loop for each package
|
||||
for pkg in ${JOB_PKGS[*]}; do
|
||||
@ -543,12 +512,12 @@ function launch_pkgs_loop() {
|
||||
rm -f ${LOGDIR}/failed/${LOGFILE_PKG_NAME}-${LOGFILE_SUFFIX}
|
||||
|
||||
case $operation in
|
||||
autoupdate|update|build|buildinstall)
|
||||
autoupdate|update|build|rebuild|buildinstall)
|
||||
[ -e $spec_dir/$pkg.spec ] || {
|
||||
case $SEVERITY in
|
||||
0) ;;
|
||||
1) echo "!! Error: spec filename must be the same as package name or invalid job name; skipping $pkg package."
|
||||
[ "$do_autobuild" ] && autobuild_log $pkg $operation failed $JOB_NAME $LOGDIR/failed/${LOGFILE_PKG_NAME}
|
||||
[ "$do_autobuild" ] && autobuild_log $pkg $operation 240 $JOB_NAME $LOGDIR/failed/${LOGFILE_PKG_NAME}
|
||||
continue ;;
|
||||
*) echo "!! Error: spec filename must be the same as package name or invalid job name; aborting."
|
||||
exit 1 ;;
|
||||
@ -565,7 +534,7 @@ function launch_pkgs_loop() {
|
||||
case $SEVERITY in
|
||||
0) ;;
|
||||
1) echo "%! Error: could not apply patch to specfile; skipping $pkg package."
|
||||
[ "$do_autobuild" ] && autobuild_log $pkg $operation failed $JOB_NAME $LOGDIR/failed/${LOGFILE_PKG_NAME}
|
||||
[ "$do_autobuild" ] && autobuild_log $pkg $operation 241 $JOB_NAME $LOGDIR/failed/${LOGFILE_PKG_NAME}
|
||||
ret=1
|
||||
continue ;;
|
||||
*) echo "!! Error: could not apply patch to specfile; aborting."
|
||||
@ -756,7 +725,7 @@ function launch_pkgs_loop() {
|
||||
}
|
||||
mv $LOGFILE_PKG $LOGDIR/failed/
|
||||
echo "?= See $LOGDIR/failed/${LOGFILE_PKG_NAME}"
|
||||
[ "$do_autobuild" ] && autobuild_log $pkg $operation failed $JOB_NAME $LOGDIR/failed/${LOGFILE_PKG_NAME}
|
||||
[ "$do_autobuild" ] && autobuild_log $pkg $operation $ret $JOB_NAME $LOGDIR/failed/${LOGFILE_PKG_NAME}
|
||||
case $operation in
|
||||
autoupdate|update)
|
||||
;;
|
||||
@ -836,8 +805,13 @@ function launch_pkgs_loop() {
|
||||
# send operation: check for --norpm (source send) to avoid sending notification twice
|
||||
[ "$WEBBUILD_URL" -a "$WEBBUILD_USER" ] && {
|
||||
SPEC_VERSION=`grep -m1 "^Version:" $spec_dir/$pkg.spec | sed "s|Version:[[:space:]]*||"`
|
||||
curl -s "$WEBBUILD_URL?REQUEST=message&USER=$WEBBUILD_USER&SECRET=$WEBBUILD_SECRET&USER_EMAIL=$WEBBUILD_EMAIL&\
|
||||
MESSAGE=`cgi_encodevar \"sent <b>$pkg $SPEC_VERSION</b> for ${TARGETARCH} to <b>$SEND_SERVER</b>\"`" >/dev/null
|
||||
if [ "$WEBBUILD_USER_CMDLINE" ]; then
|
||||
curl -s "$WEBBUILD_URL?REQUEST=message&USER=$WEBBUILD_USER&SECRET=$WEBBUILD_SECRET&USER_EMAIL=$WEBBUILD_EMAIL&\
|
||||
MESSAGE=`cgi_encodevar \"(invoked by $WEBBUILD_USER_CMDLINE) sent <b>$pkg $SPEC_VERSION-$SPEC_RELEASE</b> for ${TARGETARCH} to <b>$SEND_SERVER</b>\"`" >/dev/null
|
||||
else
|
||||
curl -s "$WEBBUILD_URL?REQUEST=message&USER=$WEBBUILD_USER&SECRET=$WEBBUILD_SECRET&USER_EMAIL=$WEBBUILD_EMAIL&\
|
||||
MESSAGE=`cgi_encodevar \"sent <b>$pkg $SPEC_VERSION-$SPEC_RELEASE</b> for ${TARGETARCH} to <b>$SEND_SERVER</b>\"`" >/dev/null
|
||||
fi
|
||||
}
|
||||
fi
|
||||
;;
|
||||
@ -868,10 +842,32 @@ function log_date() {
|
||||
echo -n `LANG=C date +%Y%m%d@%H%M%S`
|
||||
}
|
||||
|
||||
DISTDBFILES="$DISTDB"
|
||||
[ -e $DISTDB.$TARGETARCH ] && DISTDBFILES="$DISTDBFILES $DISTDB.$TARGETARCH"
|
||||
[ -e ~/.autodist/distdb ] && DISTDBFILES="$DISTDBFILES ~/.autodist/distdb"
|
||||
[ -e ~/.autodist/distdb.$TARGETARCH ] && DISTDBFILES="$DISTDBFILES ~/.autodist/distdb.$TARGETARCH"
|
||||
[ -e $LOGBASEDIR ] || {
|
||||
mkdir -p $LOGBASEDIR/prepare/{ok,failed}
|
||||
mkdir -p $LOGBASEDIR/update/{ok,failed}
|
||||
mkdir -p $LOGBASEDIR/build/{ok,failed}
|
||||
mkdir -p $LOGBASEDIR/install/{ok,failed}
|
||||
mkdir -p $LOGBASEDIR/send/{ok,failed}
|
||||
}
|
||||
|
||||
#
|
||||
# Main
|
||||
#
|
||||
|
||||
DISTDBFILES=
|
||||
|
||||
DISTDB=`fetch_repository_file ${AUTODIST_REPOSITORY/-*}/distdb`
|
||||
[ "$DISTDB" ] && DISTDBFILES="$DISTDB"
|
||||
|
||||
DISTDBARCH=`fetch_repository_file ${AUTODIST_REPOSITORY/-*}/distdb.$TARGETARCH`
|
||||
if [ "$DISTDBARCH" ]; then
|
||||
DISTDBFILES="$DISTDBFILES $DISTDBARCH"
|
||||
fi
|
||||
|
||||
if [ ! "$DISTDBFILES" ]; then
|
||||
[ -e $SYSCONFDIR/distdb ] && DISTDBFILES="$SYSCONFDIR/distdb"
|
||||
[ -e $SYSCONFDIR/distdb.$TARGETARCH ] && DISTDBFILES="$DISTDBFILES $SYSCONFDIR/distdb.$TARGETARCH"
|
||||
fi
|
||||
|
||||
if [ "$do_listjobs" ]; then
|
||||
for f in $DISTDBFILES; do
|
||||
@ -919,6 +915,30 @@ for a in $LOGBASEDIR/{,prepare/{,ok,failed},update/{,ok,failed},build/{,ok,faile
|
||||
|
||||
done
|
||||
|
||||
AUTOUPDATEDIR=${LOCAL_REPS_BASE_DIR}/$AUTODIST_REPOSITORY/autoupdate/
|
||||
[ -r $AUTOUPDATEDIR ] || {
|
||||
AUTOUPDATEDIR=$USERCONFDIR/$AUTODIST_REPOSITORY/autoupdate
|
||||
mkdir -p $AUTOUPDATEDIR
|
||||
}
|
||||
|
||||
SOURCESDIR=$AUTOUPDATEDIR/sources/
|
||||
SUCCESSLISTDIR=$AUTOUPDATEDIR
|
||||
SKIPPEDLISTDIR=$AUTOUPDATEDIR
|
||||
|
||||
SRCPKGLIST=`fetch_repository_file $AUTODIST_REPOSITORY/srcpkglist`
|
||||
[ $? -eq 0 ] || echo "Warning: unable to fetch $SRCPKGLIST">&2
|
||||
|
||||
[ "$AUTODIST_DELAYED_REPOSITORY" ] && SRCPKGLIST_DELAYED=`fetch_repository_file $AUTODIST_DELAYED_REPOSITORY/srcpkglist`
|
||||
[ $? -eq 0 ] || echo "Warning: unable to fetch $SRCPKGLIST_DELAYED">&2
|
||||
|
||||
BUILDSLIST=`fetch_repository_file distromatic/$AUTODIST_REPOSITORY/builds-$TARGETARCH`
|
||||
[ "$AUTODIST_DELAYED_REPOSITORY" ] && BUILDSLIST_DELAYED=`fetch_repository_file distromatic/$AUTODIST_DELAYED_REPOSITORY/builds-$TARGETARCH`
|
||||
[ $? -eq 0 ] || echo "Warning: unable to fetch $BUILDSLIST">&2
|
||||
|
||||
LEGACYLIST=`fetch_repository_file ${AUTODIST_REPOSITORY/-*}/legacy`
|
||||
[ "$LEGACYLIST" ] || LEGACYLIST=$SYSCONFDIR/legacy
|
||||
[ $? -eq 0 ] || echo "Warning: unable to fetch $LEGACYLIST">&2
|
||||
|
||||
echo "%% Autodist started with PID $$ @ `LANG=C date`"
|
||||
|
||||
# autobuild: add jobs ordered by oldest builds
|
||||
@ -948,6 +968,7 @@ if [ "$do_autobuild" = "1" ]; then
|
||||
SKIPPEDCOUNT=0
|
||||
BLACKLISTCOUNT=0
|
||||
SUCCESSLISTCOUNT=0
|
||||
REBUILDOLDCOUNT=0
|
||||
|
||||
> $pkgtmpfile
|
||||
|
||||
@ -971,29 +992,37 @@ if [ "$do_autobuild" = "1" ]; then
|
||||
continue
|
||||
}
|
||||
|
||||
# check skippedlist (but ignore for scheduled updates)
|
||||
if [ "${VERSION:0:1}" != "+" ]; then
|
||||
SKIPPEDLINE=`awk '{ print $1" "$2 }' $SKIPPEDLISTDIR/*.skip | grep -m1 "^$PKGNAME "`
|
||||
if [ "$SKIPPEDLINE" ]; then
|
||||
set -- $SKIPPEDLINE
|
||||
SKIPPEDTIME=$2
|
||||
SKIPPEDDAYS=`expr \( $DATE_NOW - $SKIPPEDTIME \) / 86400`
|
||||
if [ "$SKIPPEDDAYS" -le "$AUTOBUILD_SKIP_DAYS" ]; then
|
||||
SKIPPEDCOUNT=`expr $SKIPPEDCOUNT + 1`
|
||||
#echo "?= Package $PKGNAME has been in the skippedlist for $SKIPPEDDAYS days; skipping"
|
||||
continue
|
||||
else
|
||||
sed -i "/^$PKGNAME /d" $SKIPPEDLISTDIR/*.skip
|
||||
if [ $REBUILDOLDCOUNT -lt $AUTODIST_REBUILDOLD_MAX -a $BUILDDATE -ge $AUTODIST_REBUILDOLD_FROMDATE ]; then
|
||||
# rebuilt oldest packages
|
||||
REBUILDOLDCOUNT=$(($REBUILDOLDCOUNT + 1))
|
||||
VERSION=+0
|
||||
else
|
||||
# check skippedlist (but ignore for scheduled updates)
|
||||
SKIPPEDLINE=`awk '{ print $1" "$2 }' $SKIPPEDLISTDIR/*.skip | grep -m1 "^$PKGNAME "`
|
||||
if [ "$SKIPPEDLINE" ]; then
|
||||
set -- $SKIPPEDLINE
|
||||
SKIPPEDTIME=$2
|
||||
SKIPPEDDAYS=`expr \( $DATE_NOW - $SKIPPEDTIME \) / 86400`
|
||||
if [ "$SKIPPEDDAYS" -le "$AUTOBUILD_SKIP_DAYS" ]; then
|
||||
SKIPPEDCOUNT=`expr $SKIPPEDCOUNT + 1`
|
||||
#echo "?= Package $PKGNAME has been in the skippedlist for $SKIPPEDDAYS days; skipping"
|
||||
continue
|
||||
else
|
||||
sed -i "/^$PKGNAME /d" $SKIPPEDLISTDIR/*.skip
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
# check legacylist
|
||||
awk '{ print $1 }' $LEGACYLIST | grep "^$PKGNAME$" >/dev/null && {
|
||||
echo "?= Job $PKGNAME is in the legacy list; skipping automatic update"
|
||||
echo "$PKGNAME $DATE_NOW 100" >> $SKIPPEDLISTDIR/auto.skip
|
||||
continue
|
||||
}
|
||||
if [ "${VERSION:0:1}" != "+" ]; then
|
||||
# check legacylist
|
||||
awk '{ print $1 }' $LEGACYLIST | grep "^$PKGNAME$" >/dev/null && {
|
||||
echo "?= Job $PKGNAME is in the legacy list; skipping automatic update"
|
||||
echo "$PKGNAME $DATE_NOW 100" >> $SKIPPEDLISTDIR/auto.skip
|
||||
continue
|
||||
}
|
||||
fi
|
||||
|
||||
# manually or from lists scheduled jobs
|
||||
if [ "${VERSION:0:1}" == "+" -a "$VERSION" != "+0" ]; then
|
||||
@ -1045,7 +1074,7 @@ if [ "$do_autobuild" = "1" ]; then
|
||||
fi
|
||||
done < $srctmpfile
|
||||
|
||||
echo "%% Total pkgs: $PKGCOUNT, skipped list: $SKIPPEDCOUNT, blacklist: $BLACKLISTCOUNT, success list: $SUCCESSLISTCOUNT, last build date: $BUILDDATE"
|
||||
echo "%% Total pkgs: $PKGCOUNT, skipped list: $SKIPPEDCOUNT, blacklist: $BLACKLISTCOUNT, success list: $SUCCESSLISTCOUNT, rebuild-old list: $REBUILDOLDCOUNT, last build date: $BUILDDATE"
|
||||
while read line; do
|
||||
set -- $line
|
||||
PKGNAME=${1}
|
||||
@ -1112,8 +1141,8 @@ for JOB_NUM in `seq 1 ${#JOBNAME[*]}`; do
|
||||
}
|
||||
if [ ! "$do_update" -a "$do_autobuild" = "1" ]; then
|
||||
[ "${AUTOSPEC_ARGS/--changelog}" = "${AUTOSPEC_ARGS}" ] &&
|
||||
AUTOSPEC_ARGS="$AUTOSPEC_ARGS --changelog \"automatic rebuild by autodist\""
|
||||
launch_pkgs_loop rebuild "$AUTOSPEC_ARGS" || {
|
||||
AUTOSPEC_CHANGELOG="--changelog \"automatic rebuild by autodist\"" || AUTOSPEC_CHANGELOG=
|
||||
launch_pkgs_loop rebuild "$AUTOSPEC_ARGS $AUTOSPEC_CHANGELOG" || {
|
||||
case $SEVERITY in
|
||||
0) ;;
|
||||
1) echo "%! Error during package update for rebuild; skipping $JOB_NAME job."
|
||||
@ -1133,17 +1162,19 @@ for JOB_NUM in `seq 1 ${#JOBNAME[*]}`; do
|
||||
echo "%% "`log_date`" Starting UPDATE operation" > $LOGFILE
|
||||
|
||||
if [ "${JOB_VER:0:1}" != "+" -o "${JOB_VER}" = "+0" ]; then
|
||||
# --force-update \
|
||||
# check legacylist
|
||||
awk '{ print $1 }' $LEGACYLIST | grep "^$JOB_NAME$" >/dev/null && {
|
||||
echo "?= Job $JOB_NAME is in the legacy list; forcing rebuild"
|
||||
ret=1
|
||||
} || {
|
||||
[ "${AUTOSPEC_ARGS/--changelog}" = "${AUTOSPEC_ARGS}" ] &&
|
||||
AUTOSPEC_ARGS="$AUTOSPEC_ARGS --changelog \"automatic update by autodist\""
|
||||
launch_pkgs_loop autoupdate "$AUTOSPEC_ARGS $SEND_FORCE"
|
||||
ret=$?
|
||||
}
|
||||
ret=1
|
||||
# don't update when --rebuild is passed
|
||||
if [ ! "$rebuild_packages" ]; then
|
||||
# check legacylist
|
||||
awk '{ print $1 }' $LEGACYLIST | grep "^$JOB_NAME$" >/dev/null && {
|
||||
echo "?= Job $JOB_NAME is in the legacy list; forcing rebuild"
|
||||
} || {
|
||||
[ "${AUTOSPEC_ARGS/--changelog}" = "${AUTOSPEC_ARGS}" ] &&
|
||||
AUTOSPEC_CHANGELOG="--changelog \"automatic update by autodist\"" || AUTOSPEC_CHANGELOG
|
||||
launch_pkgs_loop autoupdate "$AUTOSPEC_ARGS $AUTOSPEC_CHANGELOG $SEND_FORCE"
|
||||
ret=$?
|
||||
}
|
||||
fi
|
||||
if [ $ret != 0 ]; then
|
||||
if [ ! "$rebuild_packages" -a "${JOB_VER}" != "+0" ]; then
|
||||
[ $ret -ge 2 -a "$do_autobuild" ] && {
|
||||
@ -1161,8 +1192,8 @@ for JOB_NUM in `seq 1 ${#JOBNAME[*]}`; do
|
||||
else
|
||||
echo "%% Rebuilding package(s)"
|
||||
[ "${AUTOSPEC_ARGS/--changelog}" = "${AUTOSPEC_ARGS}" ] &&
|
||||
AUTOSPEC_ARGS="$AUTOSPEC_ARGS --changelog \"automatic rebuild by autodist\""
|
||||
launch_pkgs_loop rebuild "$AUTOSPEC_ARGS" || {
|
||||
AUTOSPEC_CHANGELOG="--changelog \"automatic rebuild by autodist\"" || AUTOSPEC_CHANGELOG=
|
||||
launch_pkgs_loop rebuild "$AUTOSPEC_ARGS $AUTOSPEC_CHANGELOG" || {
|
||||
case $SEVERITY in
|
||||
0) ;;
|
||||
1) echo "%! Error during package update for rebuild; skipping $JOB_NAME job."
|
||||
@ -1184,8 +1215,8 @@ for JOB_NUM in `seq 1 ${#JOBNAME[*]}`; do
|
||||
echo "%% Updating to version ${JOB_VER:1}"
|
||||
# WARNING: JOB_VER must be passed to launch_pkgs_loop as the first string in the second parameter
|
||||
[ "${AUTOSPEC_ARGS/--changelog}" = "${AUTOSPEC_ARGS}" ] &&
|
||||
AUTOSPEC_ARGS="$AUTOSPEC_ARGS --changelog \"automatic version update by autodist\""
|
||||
launch_pkgs_loop update "${JOB_VER:1} $AUTOSPEC_ARGS $SEND_FORCE" || {
|
||||
AUTOSPEC_CHANGELOG="--changelog \"automatic version update by autodist\"" || AUTOSPEC_CHANGELOG=
|
||||
launch_pkgs_loop update "${JOB_VER:1} $AUTOSPEC_ARGS $AUTOSPEC_CHANGELOG $SEND_FORCE" || {
|
||||
if [ ! "$rebuild_packages" ]; then
|
||||
case $SEVERITY in
|
||||
0) ;;
|
||||
@ -1197,8 +1228,8 @@ for JOB_NUM in `seq 1 ${#JOBNAME[*]}`; do
|
||||
esac
|
||||
else
|
||||
[ "${AUTOSPEC_ARGS/--changelog}" = "${AUTOSPEC_ARGS}" ] &&
|
||||
AUTOSPEC_ARGS="$AUTOSPEC_ARGS --changelog \"automatic rebuild by autodist\""
|
||||
launch_pkgs_loop rebuild "$AUTOSPEC_ARGS" || {
|
||||
AUTOSPEC_CHANGELOG="--changelog \"automatic rebuild by autodist\"" || AUTOSPEC_CHANGELOG=
|
||||
launch_pkgs_loop rebuild "$AUTOSPEC_ARGS $AUTOSPEC_CHANGELOG" || {
|
||||
case $SEVERITY in
|
||||
0) ;;
|
||||
1) echo "%! Error during package update for rebuild; skipping $JOB_NAME job."
|
||||
@ -1263,9 +1294,11 @@ for JOB_NUM in `seq 1 ${#JOBNAME[*]}`; do
|
||||
exit 1 ;;
|
||||
esac
|
||||
}
|
||||
echo "== sending source rpms"
|
||||
launch_pkgs_loop send "$AUTOSPEC_ARGS --norpm $SEND_SERVER_CMD"
|
||||
if [ $? -gt 0 ]; then
|
||||
# avoid calling autospec with --nosrpm --norpm (not working as expected and not useful)
|
||||
if [ "${AUTOSPEC_ARGS/--nosrpm}" = "$AUTOSPEC_ARGS" ]; then
|
||||
echo "== sending source rpms"
|
||||
launch_pkgs_loop send "$AUTOSPEC_ARGS --norpm $SEND_SERVER_CMD"
|
||||
if [ $? -gt 0 ]; then
|
||||
case $SEVERITY in
|
||||
0) ;;
|
||||
1) echo "%! Error sending sources; skipping $JOB_NAME job."
|
||||
@ -1273,15 +1306,16 @@ for JOB_NUM in `seq 1 ${#JOBNAME[*]}`; do
|
||||
*) echo "!! Error sending sources; aborting."
|
||||
exit 1 ;;
|
||||
esac
|
||||
else
|
||||
# archive patches
|
||||
if [ "$do_autobuild" ]; then
|
||||
[ -e $AUTOUPDATEDIR/spec-patches-update/$JOB_NAME.spec.patch ] && \
|
||||
mv $AUTOUPDATEDIR/spec-patches-update/$JOB_NAME.spec.patch \
|
||||
$AUTOUPDATEDIR/spec-patches-update/old/${JOB_NAME}.spec.${DATE_NOW}.patch
|
||||
[ -e $AUTOUPDATEDIR/spec-patches-build/$JOB_NAME.spec.patch ] && \
|
||||
mv $AUTOUPDATEDIR/spec-patches-build/${JOB_NAME}.spec.${DATE_NOW}.patch \
|
||||
$AUTOUPDATEDIR/spec-patches-build/old/${JOB_NAME}.spec.${DATE_NOW}.patch
|
||||
else
|
||||
# archive patches
|
||||
if [ "$do_autobuild" ]; then
|
||||
[ -e $AUTOUPDATEDIR/spec-patches-update/$JOB_NAME.spec.patch ] && \
|
||||
mv $AUTOUPDATEDIR/spec-patches-update/$JOB_NAME.spec.patch \
|
||||
$AUTOUPDATEDIR/spec-patches-update/old/${JOB_NAME}.spec.${DATE_NOW}.patch
|
||||
[ -e $AUTOUPDATEDIR/spec-patches-build/$JOB_NAME.spec.patch ] && \
|
||||
mv $AUTOUPDATEDIR/spec-patches-build/${JOB_NAME}.spec.${DATE_NOW}.patch \
|
||||
$AUTOUPDATEDIR/spec-patches-build/old/${JOB_NAME}.spec.${DATE_NOW}.patch
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
14
autodist-bash_profile
Normal file
14
autodist-bash_profile
Normal file
@ -0,0 +1,14 @@
|
||||
# .bash_profile
|
||||
|
||||
# Get the aliases and functions
|
||||
if [ -f ~/.bashrc ]; then
|
||||
. ~/.bashrc
|
||||
fi
|
||||
|
||||
# User specific environment and startup programs
|
||||
if [ -d $HOME/bin ]; then
|
||||
PATH=$PATH:$HOME/bin
|
||||
fi
|
||||
export PATH
|
||||
|
||||
unset USERNAME
|
8
autodist-bashrc
Normal file
8
autodist-bashrc
Normal file
@ -0,0 +1,8 @@
|
||||
# .bashrc
|
||||
|
||||
# User specific aliases and functions
|
||||
|
||||
# Source global definitions
|
||||
if [ -f /etc/bashrc ]; then
|
||||
. /etc/bashrc
|
||||
fi
|
98
autodist-cgi
98
autodist-cgi
@ -4,6 +4,7 @@
|
||||
|
||||
NUM=`echo "$QUERY_STRING" | sed -n 's/^.*NUM=\([^&]*\).*$/\1/p' | sed "s/%20/ /g"`
|
||||
HOST=`echo "$QUERY_STRING" | sed -n 's/^.*HOST=\([^&]*\).*$/\1/p' | sed "s/%20/ /g"`
|
||||
REP=`echo "$QUERY_STRING" | sed -n 's/^.*REP=\([^&]*\).*$/\1/p' | sed "s/%20/ /g"`
|
||||
AS_HOST=`echo "$QUERY_STRING" | sed -n 's/^.*AS_HOST=\([^&]*\).*$/\1/p' | sed "s/%20/ /g"`
|
||||
SHOWLOG=`echo "$QUERY_STRING" | sed -n 's/^.*SHOWLOG=\([^&]*\).*$/\1/p' | sed "s/%20/ /g"`
|
||||
SHOWINDEX=`echo "$QUERY_STRING" | sed -n 's/^.*SHOWINDEX=\([^&]*\).*$/\1/p' | sed "s/%20/ /g"`
|
||||
@ -49,15 +50,17 @@ if [ "$SHOWINDEX" ]; then
|
||||
[ "${AUTOPORT_ARCH[$i]}" ] || continue
|
||||
[ "${AUTOPORT_DISABLE[$i]}" -a "${AUTOPORT_DISABLE[$i]}" != "0" ] && continue
|
||||
|
||||
RNUM=-1
|
||||
for r in ${AUTOPORT_REPOSITORIES[$i]}; do
|
||||
RNUM=`expr $RNUM + 1`
|
||||
if [ "${AUTOPORT_UPDATE[$i]}" ]; then
|
||||
echo "<a href=\"?NUM=$i$HOST_ADD\">$r(${AUTOPORT_ARCH[$i]})</a> "
|
||||
echo "<a href=\"?NUM=$i&REP=$RNUM$HOST_ADD\">$r(${AUTOPORT_ARCH[$i]})</a> "
|
||||
elif [ "${AUTOPORT_CHROOT[$i]}" ]; then
|
||||
echo "<a href=\"?NUM=$i$HOST_ADD\">$r(${AUTOPORT_ARCH[$i]})</a> "
|
||||
echo "<a href=\"?NUM=$i&REP=$RNUM$HOST_ADD\">$r(${AUTOPORT_ARCH[$i]})</a> "
|
||||
elif [ "${AUTOPORT_NATIVE[$i]}" ]; then
|
||||
echo "<a href=\"?NUM=$i$HOST_ADD\">$r(${AUTOPORT_ARCH[$i]})</a> "
|
||||
echo "<a href=\"?NUM=$i&REP=$RNUM$HOST_ADD\">$r(${AUTOPORT_ARCH[$i]})</a> "
|
||||
elif [ "${AUTOPORT_CROSS[$i]}" ]; then
|
||||
echo "<a href=\"?NUM=$i$HOST_ADD\">$r(${AUTOPORT_CROSS[$i]};${AUTOPORT_ARCH[$i]})</a> "
|
||||
echo "<a href=\"?NUM=$i&REP=$RNUM$HOST_ADD\">$r(${AUTOPORT_CROSS[$i]};${AUTOPORT_ARCH[$i]})</a> "
|
||||
fi
|
||||
done
|
||||
done
|
||||
@ -66,7 +69,7 @@ if [ "$SHOWINDEX" ]; then
|
||||
elif [ "$AS_HOST" = "0" ]; then
|
||||
echo "Show: [<a href=\"?NUM=\">All hosts</a>] [<a href=\"?SHOWLOG=monitor\">Build hosts monitor</a>]<br>"
|
||||
for h in `seq 0 ${#AUTOPORT_CGI_HOST[*]}`; do
|
||||
curl "${AUTOPORT_CGI_HOST[$h]}?AS_HOST=$h&SHOWINDEX=1" 2>/dev/null
|
||||
curl --connect-timeout 20 "${AUTOPORT_CGI_HOST[$h]}?AS_HOST=$h&SHOWINDEX=1" 2>/dev/null
|
||||
done
|
||||
echo "<hr>"
|
||||
fi
|
||||
@ -74,13 +77,13 @@ fi
|
||||
[ ! "$SHOWLOG" -a "$HOST" = "$AS_HOST" ] && echo "<h2>Host: `hostname -s` (`uname -m`, kernel `uname -r`)</h2>"
|
||||
|
||||
if [ "$SHOWLOG" -a "$HOST" != "$AS_HOST" ]; then
|
||||
curl "${AUTOPORT_CGI_HOST[$HOST]}?AS_HOST=$HOST&SHOWLOG=$SHOWLOG&NUM=$NUM&LOG=$LOG" 2>/dev/null
|
||||
curl "${AUTOPORT_CGI_HOST[$HOST]}?AS_HOST=$HOST&SHOWLOG=$SHOWLOG&NUM=$NUM&REP=$REP&LOG=$LOG" 2>/dev/null
|
||||
else
|
||||
|
||||
for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
if [ "$SHOWLOG" = "monitor" ]; then
|
||||
echo "<h2>Build hosts monitor</h2>"
|
||||
icecream-monitor localhost listcs | \
|
||||
icecream-monitor $ICECREAM_MONITOR_HOST listcs | \
|
||||
while read line; do
|
||||
[ "${line:0:8}" = "200 done" ] && printon=
|
||||
if [ "$printon" ]; then
|
||||
@ -96,12 +99,15 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
RELOADTIME=15000
|
||||
break
|
||||
fi
|
||||
RNUM=-1
|
||||
for r in ${AUTOPORT_REPOSITORIES[$i]}; do
|
||||
[ "${AUTOPORT_ARCH[$i]}" ] || continue
|
||||
[ "${AUTOPORT_DISABLE[$i]}" -a "${AUTOPORT_DISABLE[$i]}" != "0" ] && continue
|
||||
|
||||
RNUM=`expr $RNUM + 1`
|
||||
LOGDIR=`environment_logdir $i`
|
||||
AUTOPORTLOGDIR=`environment_autoport_logdir $i`
|
||||
ENVROOTDIR=`environment_rootdir $i`
|
||||
|
||||
if [ "${AUTOPORT_UPDATE[$i]}" ]; then
|
||||
LOGFILE="$LOGDIR/autodist.log"
|
||||
LASTLOGFILE="$LOGDIR/autodist-last.log"
|
||||
@ -113,8 +119,8 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
AUTODISTLOGFILE="$AUTOPORTLOGDIR/${AUTOPORT_ARCH[$i]}/$r-current.log"
|
||||
AUTODISTSTATEFILE="$AUTOPORTLOGDIR/autoport-$r-current"
|
||||
elif [ "${AUTOPORT_NATIVE[$i]}" ]; then
|
||||
LOGFILE="$LOGDIR/autoport-native-$r-${AUTOPORT_ARCH[$i]}.log"
|
||||
LASTLOGFILE="$LOGDIR/log/autoport-native-$r-${AUTOPORT_ARCH[$i]}-last.log"
|
||||
LOGFILE="/var/autodist/log/autoport-native-$r-${AUTOPORT_ARCH[$i]}.log"
|
||||
LASTLOGFILE="/var/autodist/log/log/autoport-native-$r-${AUTOPORT_ARCH[$i]}-last.log"
|
||||
AUTODISTLOGFILE="$AUTOPORTLOGDIR/${AUTOPORT_ARCH[$i]}/$r-current.log"
|
||||
AUTODISTSTATEFILE="$AUTOPORTLOGDIR/autoport-$r-current"
|
||||
elif [ "${AUTOPORT_CROSS[$i]}" ]; then
|
||||
@ -124,8 +130,8 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
continue
|
||||
fi
|
||||
if [ "$SHOWLOG" ]; then
|
||||
if [ "$HOST" = "$AS_HOST" -a "$NUM" = "$i" ]; then
|
||||
echo -n "<h2>$SHOWLOG log in "
|
||||
if [ "$HOST" = "$AS_HOST" -a "$NUM" = "$i" -a "$REP" = "$RNUM" ]; then
|
||||
echo -n "<p><h2>$SHOWLOG log in "
|
||||
if [ "${AUTOPORT_UPDATE[$i]}" ]; then
|
||||
echo -n "update"
|
||||
elif [ "${AUTOPORT_CHROOT[$i]}" ]; then
|
||||
@ -149,22 +155,20 @@ _EOF
|
||||
cat $LOGFILE | parse_build_output
|
||||
elif [ "$SHOWLOG" = "last" ]; then
|
||||
cat $LASTLOGFILE | parse_build_output
|
||||
LASTLOGDETAILS=`tail $LASTLOGFILE | grep "See .* for details" | sed "s|.*See \(.*\) for details.*|\1|"`
|
||||
cat $ENVROOTDIR/$LASTLOGDETAILS | parse_build_output
|
||||
else
|
||||
# Security check
|
||||
[ "${SHOWLOG/\/\.}" != "${SHOWLOG}" ] && continue
|
||||
if [ "${AUTOPORT_CHROOT[$i]}" ]; then
|
||||
BUILDLOGDIR="$LOGDIR"
|
||||
elif [ "${AUTOPORT_NATIVE[$i]}" -o "${AUTOPORT_UPDATE[$i]}" ]; then
|
||||
BUILDLOGDIR="/var/autodist/log/"
|
||||
fi
|
||||
BUILDLOGDIR="$LOGDIR"
|
||||
if [ "${SHOWLOG/\/ok\/}" != "${SHOWLOG}" -o "${SHOWLOG/\failed\/}" != "${SHOWLOG}" ]; then
|
||||
SHOWLOGPKG=${SHOWLOG/*\/}
|
||||
[ "${SHOWLOGPKG}" ] || continue
|
||||
echo "<table style=\"color:black\"><tr><td colspan=3>Last ${SHOWLOGPKG} logs:</td>"
|
||||
for t in prepare update build install send; do
|
||||
echo -n "<tr><td>$t:</td><td>"
|
||||
[ -e ${BUILDLOGDIR}${t}/ok/${SHOWLOGPKG} ] && echo -n "<td><a style=\"color:green;text-decoration:none\" target=_autodist href=\"?NUM=$i$HOST_ADD&SHOWLOG=${t}/ok/${SHOWLOGPKG}\">OK</a></td>" || echo "<td></td>"
|
||||
[ -e ${BUILDLOGDIR}${t}/failed/${SHOWLOGPKG} ] && echo -n "<td><a style=\"color:green;text-decoration:none\" target=_autodist href=\"?NUM=$i$HOST_ADD&SHOWLOG=${t}/failed/${SHOWLOGPKG}\">FAILED</a></td>" || echo "<td></td>"
|
||||
[ -e ${BUILDLOGDIR}${t}/ok/${SHOWLOGPKG} ] && echo -n "<td><a style=\"color:green;text-decoration:none\" target=_autodist href=\"?NUM=$i&REP=$RNUM$HOST_ADD&SHOWLOG=${t}/ok/${SHOWLOGPKG}\">OK</a></td>" || echo "<td></td>"
|
||||
[ -e ${BUILDLOGDIR}${t}/failed/${SHOWLOGPKG} ] && echo -n "<td><a style=\"color:green;text-decoration:none\" target=_autodist href=\"?NUM=$i&REP=$RNUM$HOST_ADD&SHOWLOG=${t}/failed/${SHOWLOGPKG}\">FAILED</a></td>" || echo "<td></td>"
|
||||
echo "</tr>"
|
||||
done
|
||||
echo "</table>"
|
||||
@ -184,7 +188,7 @@ _EOF
|
||||
fi
|
||||
echo -n "</pre></code>"
|
||||
echo -n "</div></div>"
|
||||
break
|
||||
# break
|
||||
fi
|
||||
[ "${AUTOPORT_UPDATE[$i]}" ] && break
|
||||
elif [ ! "$SHOWLOG" ]; then
|
||||
@ -192,29 +196,29 @@ _EOF
|
||||
[[ "$NUM" && "$NUM" != "$i" ]] && continue
|
||||
[[ "$HOST" = "$AS_HOST" ]] || continue
|
||||
if [ "${AUTOPORT_UPDATE[$i]}" ]; then
|
||||
echo "<b>* <a target=_autodist href=\"?NUM=$i&HOST=$AS_HOST\">$r</a>(${AUTOPORT_ARCH[$i]}) (type:autodist update)"
|
||||
echo " [ <a target=_autodist href=\"?SHOWLOG=current&NUM=$i$HOST_ADD\">log</a> <a target=_autodist href=\"?SHOWLOG=last&NUM=$i$HOST_ADD\">last</a> ]</b>"
|
||||
echo "<b>* <a target=_autodist href=\"?NUM=$i&REP=$RNUM&HOST=$AS_HOST\">$r</a>(${AUTOPORT_ARCH[$i]}) (type:autodist update)"
|
||||
echo " [ <a target=_autodist href=\"?SHOWLOG=current&NUM=$i&REP=$RNUM$HOST_ADD\">log</a> <a target=_autodist href=\"?SHOWLOG=last&NUM=$i&REP=$RNUM$HOST_ADD\">last</a> ]</b>"
|
||||
fi
|
||||
|
||||
if [ "${AUTOPORT_CHROOT[$i]}" ]; then
|
||||
echo "<b>* <a target=_autodist href=\"?NUM=$i&HOST=$AS_HOST\">$r</a>(${AUTOPORT_ARCH[$i]}) (type:chroot autoport</a> chroot:${AUTOPORT_CHROOT[$i]})"
|
||||
echo " [ <a target=_autodist href=\"?SHOWLOG=current&NUM=$i$HOST_ADD\">log</a> <a target=_autodist href=\"?SHOWLOG=last&NUM=$i$HOST_ADD\">last</a> ]</b>"
|
||||
echo "<b>* <a target=_autodist href=\"?NUM=$i&REP=$RNUM&HOST=$AS_HOST\">$r</a>(${AUTOPORT_ARCH[$i]}) (type:chroot autoport</a> chroot:${AUTOPORT_CHROOT[$i]})"
|
||||
echo " [ <a target=_autodist href=\"?SHOWLOG=current&NUM=$i&REP=$RNUM$HOST_ADD\">log</a> <a target=_autodist href=\"?SHOWLOG=last&NUM=$i&REP=$RNUM$HOST_ADD\">last</a> ]</b>"
|
||||
fi
|
||||
|
||||
if [ "${AUTOPORT_NATIVE[$i]}" ]; then
|
||||
echo "<b>* <a target=_autodist href=\"?NUM=$i&HOST=$AS_HOST\">$r</a>(${AUTOPORT_ARCH[$i]}) (type:native autoport)"
|
||||
echo " [ <a target=_autodist href=\"?SHOWLOG=current&NUM=$i$HOST_ADD\">log</a> <a target=_autodist href=\"?SHOWLOG=last&NUM=$i$HOST_ADD\">last</a> ]</b>"
|
||||
echo "<b>* <a target=_autodist href=\"?NUM=$i&REP=$RNUM&HOST=$AS_HOST\">$r</a>(${AUTOPORT_ARCH[$i]}) (type:native autoport)"
|
||||
echo " [ <a target=_autodist href=\"?SHOWLOG=current&NUM=$i&REP=$RNUM$HOST_ADD\">log</a> <a target=_autodist href=\"?SHOWLOG=last&NUM=$i&REP=$RNUM$HOST_ADD\">last</a> ]</b>"
|
||||
fi
|
||||
|
||||
if [ "${AUTOPORT_CROSS[$i]}" ]; then
|
||||
echo "<b>* <a target=_autodist href=\"?NUM=$i&HOST=$AS_HOST\">cross-platform</a> autoport (arch:${AUTOPORT_CROSS[$i]})</b>"
|
||||
echo " [ <a target=_autodist href=\"?SHOWLOG=current&NUM=$i$HOST_ADD\">last</a> ]</b>"
|
||||
echo "<b>* <a target=_autodist href=\"?NUM=$i&REP=$RNUM&HOST=$AS_HOST\">cross-platform</a> autoport (arch:${AUTOPORT_CROSS[$i]})</b>"
|
||||
echo " [ <a target=_autodist href=\"?SHOWLOG=current&NUM=$i&REP=$RNUM$HOST_ADD\">last</a> ]</b>"
|
||||
fi
|
||||
cat << _EOF
|
||||
<div class=downloadbox align=center>
|
||||
<div align=left style="background-color: white; height: 250px; width: 850px; overflow: auto; font-size: 8pt; border:1px solid #2b6600; margin: 4px; padding:4; background-color: #e0f2d0;">
|
||||
_EOF
|
||||
echo "<pre>"
|
||||
echo -n "<pre style='margin:1px'>"
|
||||
unset BUILDNOWIDX BUILDLOG BUILDNOW BUILDNOWSTATUS SCHEDULED STARTTIME AUTODIST_PID ENDTIME
|
||||
if [ "${AUTOPORT_UPDATE[$i]}" ]; then
|
||||
BUILDNOWIDX=0
|
||||
@ -235,7 +239,7 @@ _EOF
|
||||
BUILDNOW[$BUILDNOWIDX]="$1"
|
||||
[ "$4" ] && BUILDLOG[$BUILDNOWIDX]="${BUILDLOG[$BUILDNOWIDX]} `echo $4 | sed "s|.*autodist/log/||"`"
|
||||
# BUILDLOG[$BUILDNOWIDX]="${BUILDLOG[$BUILDNOWIDX]} $2/$3/$1.i586"
|
||||
BUILDNOWSTATUS[$BUILDNOWIDX]=
|
||||
BUILDNOWSTATUS[$BUILDNOWIDX]=$3
|
||||
BUILDNOWIDX=`expr $BUILDNOWIDX + 1`
|
||||
done < $STATEFILE
|
||||
else
|
||||
@ -266,7 +270,7 @@ _EOF
|
||||
BUILDLOG[$BUILDNOWIDX]="${BUILDLOG[$BUILDNOWIDX]} $CURRLOGFILE"
|
||||
fi
|
||||
# BUILDLOG[$BUILDNOWIDX]="${BUILDLOG[$BUILDNOWIDX]} $2/$3/$1.i586"
|
||||
BUILDNOWSTATUS[$BUILDNOWIDX]=
|
||||
BUILDNOWSTATUS[$BUILDNOWIDX]=$3
|
||||
BUILDNOWIDX=`expr $BUILDNOWIDX + 1`
|
||||
done < $AUTODISTSTATEFILE
|
||||
for p in `dirname $LOGFILE`/current.*; do
|
||||
@ -293,9 +297,9 @@ _EOF
|
||||
else
|
||||
WEBBUILD_APPEND="&LOGSTATUSOK=false"
|
||||
fi
|
||||
echo -n "<a target=_webbuild href=\"/distribution/webbuild.php?REQUEST=autobuildedit&ENVIRONMENT=$i&PACKAGE=$JOBNAME&LOGTYPE=$OPERATIONNAME${WEBBUILD_APPEND}\"><b>$JOBNAME</b></a>: "
|
||||
echo -n "<a target=_webbuild href=\"$AUTOPORT_WEBBUILD_HOST?REQUEST=autobuildedit&ENVIRONMENT=$i&PACKAGE=$JOBNAME&LOGTYPE=$OPERATIONNAME${WEBBUILD_APPEND}\"><b>$JOBNAME</b></a>: "
|
||||
else
|
||||
echo -n "<a target=_webbuild href=\"/distribution/webbuild.php?ENVIRONMENT=$i&PACKAGE=$JOBNAME\"><b>$JOBNAME</b></a>: "
|
||||
echo -n "<a target=_webbuild href=\"$AUTOPORT_WEBBUILD_HOST?ENVIRONMENT=$i&PACKAGE=$JOBNAME\"><b>$JOBNAME</b></a>: "
|
||||
fi
|
||||
fi
|
||||
rowcnt=0
|
||||
@ -306,17 +310,28 @@ _EOF
|
||||
# echo
|
||||
# rowcnt=0
|
||||
# fi
|
||||
case $OPERATIONNAME-$OPERATIONSTATUS in
|
||||
case $OPERATIONNAME-$OPERATIONSTATUS in
|
||||
build-ok|send-ok|install-ok|retryinstall-ok)
|
||||
echo -n "<a target=_autodist href=\"?SHOWLOG=$l&NUM=$i$HOST_ADD\">$OPERATIONNAME:$OPERATIONSTATUS</a>"
|
||||
echo -n "<a target=_autodist href=\"?SHOWLOG=$l&NUM=$i&REP=$RNUM$HOST_ADD\">$OPERATIONNAME:$OPERATIONSTATUS</a>"
|
||||
;;
|
||||
*-failed)
|
||||
echo -n "<a target=_autodist href=\"?SHOWLOG=$l&NUM=$i$HOST_ADD\"><font color=red>$OPERATIONNAME:$OPERATIONSTATUS</font></a>"
|
||||
update-failed|autoupdate-failed)
|
||||
if [ "${BUILDNOWSTATUS[$b]}" = "4" ]; then
|
||||
echo -n "<a target=_autodist href=\"?SHOWLOG=$l&NUM=$i&REP=$RNUM$HOST_ADD\"><font color=green>$OPERATIONNAME:up-to-date</font></a>"
|
||||
elif [ "${BUILDNOWSTATUS[$b]}" = "3" ]; then
|
||||
echo -n "<a target=_autodist href=\"?SHOWLOG=$l&NUM=$i&REP=$RNUM$HOST_ADD\"><font color=darkgoldenrod>$OPERATIONNAME:unknown</font></a>"
|
||||
elif [ "${BUILDNOWSTATUS[$b]}" = "2" ]; then
|
||||
echo -n "<a target=_autodist href=\"?SHOWLOG=$l&NUM=$i&REP=$RNUM$HOST_ADD\"><font color=darkgoldenrod>$OPERATIONNAME:newer</font></a>"
|
||||
else
|
||||
echo -n "<a target=_autodist href=\"?SHOWLOG=$l&NUM=$i&REP=$RNUM$HOST_ADD\"><font color=red>$OPERATIONNAME:$OPERATIONSTATUS</font></a>"
|
||||
fi
|
||||
;;
|
||||
*) echo -n "<a target=_autodist href=\"?SHOWLOG=$l&NUM=$i$HOST_ADD\"><font color=black>$OPERATIONNAME:$OPERATIONSTATUS</font></a>"
|
||||
*-ok) echo -n "<a target=_autodist href=\"?SHOWLOG=$l&NUM=$i&REP=$RNUM$HOST_ADD\"><font color=black>$OPERATIONNAME:$OPERATIONSTATUS</font></a>"
|
||||
;;
|
||||
*)
|
||||
echo -n "<a target=_autodist href=\"?SHOWLOG=$l&NUM=$i&REP=$RNUM$HOST_ADD\"><font color=red>$OPERATIONNAME:$OPERATIONSTATUS</font></a>"
|
||||
;;
|
||||
esac
|
||||
# [ "$SUBJOBNAME" != "$JOBNAME" ] && echo -en "(<a href=\"/distribution/webbuild.php?ENVIRONMENT=$i&PACKAGE=$SUBJOBNAME\" target=\"webbuild\">$SUBJOBNAME</a>)"
|
||||
# [ "$SUBJOBNAME" != "$JOBNAME" ] && echo -en "(<a href=\"$AUTOPORT_WEBBUILD_HOST?ENVIRONMENT=$i&PACKAGE=$SUBJOBNAME\" target=\"webbuild\">$SUBJOBNAME</a>)"
|
||||
echo -n " "
|
||||
rowcnt=`expr $rowcnt + 1`
|
||||
done
|
||||
@ -324,14 +339,13 @@ _EOF
|
||||
if [[ $b -eq $BUILDNOWIDX-1 && ! "$ENDTIME" ]]; then
|
||||
echo -n "<font color=green>${BUILDOPERATION[$b]}(in progress...)</font>"
|
||||
fi
|
||||
[ "${BUILDNOWSTATUS[$b]}" ] && echo -n "<i>(${BUILDNOWSTATUS[$b]})</i>"
|
||||
LASTJOBNAME=$JOBNAME
|
||||
done
|
||||
[ "$LASTJOBNAME" ] && echo
|
||||
if [ "$ENDTIME" ]; then
|
||||
echo "<b>End:</b> $ENDTIME"
|
||||
elif [ "$AUTODIST_PID" ]; then
|
||||
echo "<b>End: <a target=_autodist href=\"?SHOWLOG=current.$AUTODIST_PID&NUM=$i$HOST_ADD\">in progress</a></b>"
|
||||
echo "<b>End: <a target=_autodist href=\"?SHOWLOG=current.$AUTODIST_PID&NUM=$i&REP=$RNUM$HOST_ADD\">in progress</a></b>"
|
||||
fi
|
||||
echo
|
||||
# grep -v "^=" $LOGFILE | tail -n "$LINES" | sed "s|.*\r||"
|
||||
@ -345,7 +359,7 @@ done
|
||||
if [ "$AS_HOST" = "0" -a ! "$SHOWLOG" ]; then
|
||||
for h in `seq 1 ${#AUTOPORT_CGI_HOST[*]}`; do
|
||||
if [ "$NUM" -a "$HOST" = "$h" ]; then
|
||||
curl "${AUTOPORT_CGI_HOST[$h]}?AS_HOST=$h&LINES=$LINES&NUM=$NUM&HOST=$HOST" 2>/dev/null
|
||||
curl "${AUTOPORT_CGI_HOST[$h]}?AS_HOST=$h&LINES=$LINES&NUM=$NUM&REP=$RNUM&HOST=$HOST" 2>/dev/null
|
||||
elif [ ! "$NUM" ]; then
|
||||
curl "${AUTOPORT_CGI_HOST[$h]}?AS_HOST=$h&LINES=$LINES" 2>/dev/null
|
||||
fi
|
||||
|
1029
autodist-repository
Executable file
1029
autodist-repository
Executable file
File diff suppressed because it is too large
Load Diff
@ -24,16 +24,6 @@ XORG_RELEASE=current
|
||||
done
|
||||
}
|
||||
|
||||
[ -r $PKGLIST_FILE ] || {
|
||||
echo "Error: file $PKGLIST_FILE cannot be read; aborting." >&2
|
||||
exit 1
|
||||
}
|
||||
|
||||
[ -r $ALIASES_DB ] || {
|
||||
echo "Error: file $ALIASES_DB cannot be read; aborting." >&2
|
||||
exit 1
|
||||
}
|
||||
|
||||
function usage()
|
||||
{
|
||||
echo "openmamba-upstream-updates - finds upstream packages updates from different internet resources"
|
||||
@ -43,6 +33,7 @@ function usage()
|
||||
echo
|
||||
echo " -h: generate distromatic HTML output"
|
||||
echo " -m: report missing packages only"
|
||||
echo " -s: skip fetching and parsing upstream updates"
|
||||
echo " -u: output not up-to-date packages only"
|
||||
echo " -q: produces quite output"
|
||||
echo " -r repository: specify the distromatic base (default: devel)"
|
||||
@ -78,13 +69,13 @@ function version_compare()
|
||||
A=$1
|
||||
B=$2
|
||||
|
||||
if [[ ${1} =~ "^[0-9]+$" && ${2} =~ "^[0-9]+$" ]]; then
|
||||
if [ ${A/[a-zA-Z_]*} -gt ${B/[a-zA-Z_]*} ]; then
|
||||
if [[ ${1} =~ ^[0-9]+$ && ${2} =~ ^[0-9]+$ ]]; then
|
||||
if [ $((10#${A/[a-zA-Z_]*})) -gt $((10#${B/[a-zA-Z_]*})) ]; then
|
||||
return 1
|
||||
elif [ ${A/[a-zA-Z_]*} -lt ${B/[a-zA-Z_]*} ]; then
|
||||
elif [ $((10#${A/[a-zA-Z_]*})) -lt $((10#${B/[a-zA-Z_]*})) ]; then
|
||||
return 2
|
||||
fi
|
||||
else
|
||||
else
|
||||
if [[ "$A" > "$B" ]]; then
|
||||
return 1
|
||||
elif [[ "$A" < "$B" ]]; then
|
||||
@ -132,6 +123,7 @@ while [ "$1" ]; do
|
||||
else
|
||||
missing_only=1
|
||||
fi ;;
|
||||
-s) skip_parsing=1 ;;
|
||||
-u) needupdate_only=1 ;;
|
||||
-r) [ "$2" ] || {
|
||||
echo "Error: option -r requires repository name as parameter"
|
||||
@ -166,116 +158,142 @@ UPDATES_DB=$CACHE_DIR/upstream-updates
|
||||
ALIASES_DB=$CACHE_DIR/aliases
|
||||
MANUALVER_DB=$CACHE_DIR/manualver
|
||||
|
||||
tmpfile=`mktemp -q -t autodist-upstream-updates.XXXXXXXX`
|
||||
buildstmp=`mktemp -q -t autodist-upstream-updates.XXXXXXXX`
|
||||
tail -n+2 $BUILDS_FILE > $buildstmp
|
||||
[ -s $PKGLIST_FILE ] || {
|
||||
echo "Error: file $PKGLIST_FILE is missing or empty; aborting." >&2
|
||||
exit 1
|
||||
}
|
||||
|
||||
# parse Arch Linux package list
|
||||
[ "$quiet" ] || echo -n "Parsing Arch Linux packages list..." >&2
|
||||
#for page in `seq 1 45`; do
|
||||
for rep in core community extra; do
|
||||
# SOURCEURL="https://www.archlinux.org/packages/?page=$page&sort=-last_update&q=&arch=i686&maintainer=&flagged="
|
||||
SOURCEURL="http://lug.mtu.edu/archlinux/$rep/os/i686/"
|
||||
curl -s "$SOURCEURL" | \
|
||||
grep ".pkg." | grep -v ".sig\"" | \
|
||||
while read line; do
|
||||
line=`echo $line | sed "s|.*href=\"\([^\"]*\)\">.*|\1|"`
|
||||
pkg=`echo $line | sed "s|\(.*\)-[^-]*-[^-]*-[^-]*|\1|"`
|
||||
ver=`echo $line | sed "s|.*-\([^-]*\)-[^-]*-[^-]*|\1|"`
|
||||
alias=`grep "^$pkg " $ALIASES_DB`
|
||||
[ "$alias" ] || alias=`grep "^lib$pkg " $ALIASES_DB`
|
||||
[ "$alias" ] && pkgalias=${alias/* /} || pkgalias=$pkg
|
||||
line=`grep -i "^$pkgalias:" $buildstmp || grep -i "^lib$pkgalias:" $buildstmp || grep -i " $pkgalias[^-_A-Za-z0-9]" $buildstmp`
|
||||
if [ "$line" ]; then
|
||||
[ "$pkg" != "$pkgalias" ] && alias=$pkgalias || alias=
|
||||
[ "$pkg" -a "$ver" ] && {
|
||||
echo "$pkg $ver $SOURCEURL ${alias}" >> $tmpfile
|
||||
}
|
||||
fi
|
||||
done
|
||||
done
|
||||
rm -f $buildstmp
|
||||
[ -r $ALIASES_DB ] || {
|
||||
echo "Error: file $ALIASES_DB cannot be read; aborting." >&2
|
||||
exit 1
|
||||
}
|
||||
|
||||
parse_arch_linux() {
|
||||
# parse Arch Linux package list
|
||||
[ "$quiet" ] || echo -n "Parsing Arch Linux packages list..." >&2
|
||||
#for page in `seq 1 45`; do
|
||||
for rep in core community extra; do
|
||||
# SOURCEURL="https://www.archlinux.org/packages/?page=$page&sort=-last_update&q=&arch=i686&maintainer=&flagged="
|
||||
SOURCEURL="http://lug.mtu.edu/archlinux/$rep/os/i686/"
|
||||
curl -L -s "$SOURCEURL" | \
|
||||
grep ".pkg." | grep -v ".sig\"" | \
|
||||
while read line; do
|
||||
line=`echo $line | sed "s|.*href=\"\([^\"]*\)\">.*|\1|"`
|
||||
pkg=`echo $line | sed "s|\(.*\)-[^-]*-[^-]*-[^-]*|\1|"`
|
||||
ver=`echo $line | sed "s|.*-\([^-]*\)-[^-]*-[^-]*|\1|;s|.*%3a||"`
|
||||
alias=`grep "^$pkg " $ALIASES_DB`
|
||||
|
||||
# parse X.org stable packages list
|
||||
[ "$quiet" ] || echo "Parsing X.org release ftp directory..." >&2
|
||||
SOURCEURL="ftp://ftp.x.org/pub/$XORG_RELEASE/src/everything/"
|
||||
curl -s $SOURCEURL -l | sed "s|\.tar\..*||" | sort -u |
|
||||
while read line; do
|
||||
if [ "$line" ]; then
|
||||
ver=`echo $line | sed "s|.*-||"`
|
||||
pkg="${line/-$ver}"
|
||||
alias=`grep "^$pkg " $ALIASES_DB`
|
||||
if [ ! "$alias" -a "${pkg:0:5}" == "xf86-" ]; then
|
||||
alias="$pkg xorg-drv-${pkg/xf86-}"
|
||||
else
|
||||
[ "$alias" ] || alias=`grep "^lib$pkg " $ALIASES_DB`
|
||||
fi
|
||||
[ "$pkg" -a "$ver" ] && echo "$pkg $ver $SOURCEURL ${alias/* /}" >> $tmpfile
|
||||
fi
|
||||
done
|
||||
[ "$alias" ] && pkgalias=${alias/* /} || pkgalias=$pkg
|
||||
line=`grep -i "^$pkgalias:" $buildstmp || grep -i "^lib$pkgalias:" $buildstmp || grep -i " $pkgalias[^-_A-Za-z0-9]" $buildstmp`
|
||||
if [ "$line" ]; then
|
||||
[ "$pkg" != "$pkgalias" ] && alias=$pkgalias || alias=
|
||||
[ "$pkg" -a "$ver" ] && {
|
||||
echo "$pkg $ver $SOURCEURL ${alias}" >> $tmpfile
|
||||
}
|
||||
fi
|
||||
done
|
||||
done
|
||||
rm -f $buildstmp
|
||||
}
|
||||
|
||||
# parse Gnome stable packages list
|
||||
[ "$quiet" ] || echo "Parsing GNOME stable versions file..." >&2
|
||||
for f in versions-stable versions-stable-extras; do
|
||||
SOURCEURL="http://people.gnome.org/~vuntz/tmp/versions/$f"
|
||||
curl -s $SOURCEURL | grep -v "^#" |
|
||||
parse_xorg() {
|
||||
# parse X.org stable packages list
|
||||
[ "$quiet" ] || echo "Parsing X.org release ftp directory..." >&2
|
||||
SOURCEURL="ftp://ftp.x.org/pub/$XORG_RELEASE/src/everything/"
|
||||
curl -L -s $SOURCEURL -l | sed "s|\.tar\..*||" | sort -u |
|
||||
while read line; do
|
||||
if [ "$line" ]; then
|
||||
IFS=":"
|
||||
set -- $line
|
||||
pkg="$2"
|
||||
ver="$3"
|
||||
ver=`echo $line | sed "s|.*-||"`
|
||||
pkg="${line/-$ver}"
|
||||
alias=`grep "^$pkg " $ALIASES_DB`
|
||||
[ "$alias" ] || alias=`grep "^lib$pkg " $ALIASES_DB`
|
||||
if [ ! "$alias" -a "${pkg:0:5}" == "xf86-" ]; then
|
||||
alias="$pkg xorg-drv-${pkg/xf86-}"
|
||||
else
|
||||
[ "$alias" ] || alias=`grep "^lib$pkg " $ALIASES_DB`
|
||||
fi
|
||||
[ "$pkg" -a "$ver" ] && echo "$pkg $ver $SOURCEURL ${alias/* /}" >> $tmpfile
|
||||
fi
|
||||
done
|
||||
done
|
||||
}
|
||||
|
||||
# parse distrowatch.com packages list
|
||||
[ "$quiet" ] || echo "Parsing Distrowatch packages list..." >&2
|
||||
SOURCEURL="http://distrowatch.com/packages.php"
|
||||
lynx -width 300 -dump $SOURCEURL |
|
||||
while read line; do
|
||||
[ "`echo $line | grep "Package Version Note"`" ] && start_print=1
|
||||
[ "`echo $line | grep "____________________"`" ] && unset start_print
|
||||
[ "$start_print" ] && {
|
||||
set -- $line
|
||||
pkg="${1/\[*\]/}"
|
||||
ver="${2/\[*\]/}"
|
||||
alias=`grep "^$pkg " $ALIASES_DB`
|
||||
[ "$pkg" != "chromium" ] && \
|
||||
echo "$pkg $ver $SOURCEURL ${alias/* /}" >> $tmpfile
|
||||
}
|
||||
done
|
||||
|
||||
cat $tmpfile | sort -uf > $UPDATES_DB.tmp
|
||||
rm -f $tmpfile
|
||||
|
||||
> $UPDATES_DB
|
||||
unset lastpkg
|
||||
while read pkg ver upsource alias; do
|
||||
# skip updates to unstable versions
|
||||
unset found_beta
|
||||
for b in alpha beta rc "~"; do
|
||||
[ "${ver/$b}" != "${ver}" ] && found_beta=1
|
||||
parse_gnome() {
|
||||
# parse Gnome stable packages list
|
||||
[ "$quiet" ] || echo "Parsing GNOME stable versions file..." >&2
|
||||
for f in versions-stable versions-stable-extras; do
|
||||
SOURCEURL="https://people.gnome.org/~vuntz/tmp/versions/$f"
|
||||
curl -s -L $SOURCEURL | grep -v "^#" |
|
||||
while read line; do
|
||||
if [ "$line" ]; then
|
||||
IFS=":"
|
||||
set -- $line
|
||||
pkg="$2"
|
||||
ver="$3"
|
||||
alias=`grep "^$pkg " $ALIASES_DB`
|
||||
[ "$alias" ] || alias=`grep "^lib$pkg " $ALIASES_DB`
|
||||
[ "$pkg" -a "$ver" ] && echo "$pkg $ver $SOURCEURL ${alias/* /}" >> $tmpfile
|
||||
fi
|
||||
done
|
||||
done
|
||||
[ "$found_beta" ] && continue
|
||||
if [ "$pkg" = "$lastpkg" ]; then
|
||||
}
|
||||
|
||||
parse_distromatic() {
|
||||
# parse distrowatch.com packages list
|
||||
[ "$quiet" ] || echo "Parsing Distrowatch packages list..." >&2
|
||||
SOURCEURL="http://distrowatch.com/packages.php"
|
||||
lynx -width 300 -dump $SOURCEURL |
|
||||
while read line; do
|
||||
[ "`echo $line | grep "Package Version Note"`" ] && start_print=1
|
||||
[ "`echo $line | grep "____________________"`" ] && unset start_print
|
||||
[ "$start_print" ] && {
|
||||
set -- $line
|
||||
pkg="${1/\[*\]/}"
|
||||
ver="${2/\[*\]/}"
|
||||
alias=`grep "^$pkg " $ALIASES_DB`
|
||||
[ "$pkg" != "chromium" ] && \
|
||||
echo "$pkg $ver $SOURCEURL ${alias/* /}" >> $tmpfile
|
||||
}
|
||||
done
|
||||
}
|
||||
|
||||
if [ ! "$skip_parsing" ]; then
|
||||
tmpfile=`mktemp -q -t autodist-upstream-updates.XXXXXXXX`
|
||||
buildstmp=`mktemp -q -t autodist-upstream-updates.XXXXXXXX`
|
||||
tail -n+2 $BUILDS_FILE > $buildstmp
|
||||
|
||||
parse_arch_linux
|
||||
parse_xorg
|
||||
parse_gnome
|
||||
parse_distromatic
|
||||
|
||||
cat $tmpfile | sort -uf > $UPDATES_DB.tmp
|
||||
rm -f $tmpfile
|
||||
|
||||
> $UPDATES_DB
|
||||
unset lastpkg
|
||||
while read pkg ver upsource alias; do
|
||||
# skip updates to unstable versions
|
||||
unset found_beta
|
||||
for b in alpha beta rc "~"; do
|
||||
[ "${ver/$b}" != "${ver}" ] && found_beta=1
|
||||
done
|
||||
[ "$found_beta" ] && continue
|
||||
if [ "$pkg" = "$lastpkg" ]; then
|
||||
# echo "Warning: duplicate found: $pkg lastver: $lastver ver: $ver" >&2
|
||||
version_find_bigger $lastver $ver
|
||||
vercmp=$?
|
||||
if [ $vercmp -eq 2 ]; then
|
||||
sed -i "/^$lastpkg $lastver /d" $UPDATES_DB
|
||||
version_find_bigger $lastver $ver
|
||||
vercmp=$?
|
||||
if [ $vercmp -eq 2 ]; then
|
||||
sed -i "/^$lastpkg $lastver /d" $UPDATES_DB
|
||||
echo "$pkg $ver $upsource $alias" >> $UPDATES_DB
|
||||
fi
|
||||
else
|
||||
echo "$pkg $ver $upsource $alias" >> $UPDATES_DB
|
||||
fi
|
||||
else
|
||||
echo "$pkg $ver $upsource $alias" >> $UPDATES_DB
|
||||
fi
|
||||
lastpkg=$pkg
|
||||
lastver=$ver
|
||||
done < $UPDATES_DB.tmp
|
||||
rm -f $UPDATES_DB.tmp
|
||||
lastpkg=$pkg
|
||||
lastver=$ver
|
||||
done < $UPDATES_DB.tmp
|
||||
rm -f $UPDATES_DB.tmp
|
||||
fi
|
||||
|
||||
> $UPDATES_DB.missing
|
||||
> $BUILDLIST_FILE
|
||||
@ -284,7 +302,7 @@ while read pkg ver upsource alias; do
|
||||
unset pkgline
|
||||
unset found_manual
|
||||
unset found_alias
|
||||
pkgline=`grep "^$pkg " $MANUALVER_DB` && found_manual=1
|
||||
pkgline=`grep -i "^$pkg " $MANUALVER_DB` && found_manual=1
|
||||
if [ ! "$found_manual" ]; then
|
||||
if [ "$alias" ]; then
|
||||
get_job_vector $alias
|
||||
@ -311,6 +329,7 @@ while read pkg ver upsource alias; do
|
||||
pkgrep=$4
|
||||
version_find_bigger $pkgver ${ver/-/.}
|
||||
vercmp=$?
|
||||
#echo "$pkgname - version_find_bigger $pkgver ${ver/-/.} result=$vercmp"
|
||||
[ "${vercmp}" != "2" -a "$needupdate_only" ] && continue
|
||||
[ "$found_manual" ] && pkgname=$3
|
||||
[ "$found_alias" -o "$found_manual" ] && nameadd="$pkg" || unset nameadd
|
||||
|
273
automaint
Executable file
273
automaint
Executable file
@ -0,0 +1,273 @@
|
||||
#!/bin/bash
|
||||
# automaint -- batch automatic maintainance tool of the autodist suite
|
||||
# Copyright (C) 2013-2014 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
#
|
||||
# Released under the terms of the GNU GPL release 3 license
|
||||
#
|
||||
VERSION=0.9.7
|
||||
# First in vector is base arch
|
||||
ARCHS=(i586 arm x86_64)
|
||||
|
||||
. /etc/autodist/config
|
||||
|
||||
me=(${0##*/} $VERSION "Sat Mar 20 2011")
|
||||
|
||||
function usage() {
|
||||
echo "\
|
||||
${me[0]} ${me[1]}
|
||||
"$"Copyright (C) 2013 Silvan Calarco <silvan.calarco@mambasoft.it>""
|
||||
"$"Released under the terms of the GNU GPL v3 license"
|
||||
echo "
|
||||
"$"Batch automatic maintainance tool of the autodist suite.""
|
||||
|
||||
"$"Usage"":
|
||||
$me [-s repository -d repository ] [-p repository] [-h] [-v]
|
||||
|
||||
-d repository "$"Main destination repository
|
||||
-p repository "$"Port repository
|
||||
-s repository "$"Automatic/Staging builds source repository
|
||||
|
||||
-h "$"Show this help and exit
|
||||
-t "$"Test mode (no change will be made)
|
||||
-v "$"Verbose output
|
||||
"
|
||||
|
||||
}
|
||||
|
||||
# for webbuild message
|
||||
function cgi_encodevar() {
|
||||
local string="${1}"
|
||||
local strlen=${#string}
|
||||
local encoded=""
|
||||
|
||||
for (( pos=0 ; pos<strlen ; pos++ )); do
|
||||
c=${string:$pos:1}
|
||||
case "$c" in
|
||||
[-_.~a-zA-Z0-9] ) o="${c}" ;;
|
||||
* ) printf -v o '%%%02x' "'$c"
|
||||
esac
|
||||
encoded+="${o}"
|
||||
done
|
||||
echo "${encoded}" # You can either set a return variable (FASTER)
|
||||
# REPLY="${encoded}" #+or echo the result (EASIER)... or both... :p
|
||||
}
|
||||
|
||||
# get_pkg_buildinfo - uses distromatic generated build file for
|
||||
# getting information on the repository
|
||||
#
|
||||
# $1: distromatic files base url for repository
|
||||
# $2: architecture
|
||||
# $3: pkg name
|
||||
function get_pkg_buildinfo() {
|
||||
|
||||
local pkg i a local_arch local_distromatic
|
||||
|
||||
[ $1 ] && local_distromatic=$1 || exit 1
|
||||
[ $2 ] && local_arch=$2 || exit 1
|
||||
[ $3 ] && pkg=$3
|
||||
|
||||
if [ ! "$pkg" ]; then
|
||||
[ -e $local_distromatic/builds-${local_arch}.sh ] && . $local_distromatic/builds-${local_arch}.sh
|
||||
return 0
|
||||
fi
|
||||
|
||||
pkg_archs=();
|
||||
for a in ${archs[*]}; do
|
||||
[ "$a" = "${local_arch}" ] && continue
|
||||
pkg_header=();
|
||||
DISTROMATIC_BUILD_FILE=$local_distromatic/builds-$a.sh
|
||||
[ -e $DISTROMATIC_BUILD_FILE ] && . $DISTROMATIC_BUILD_FILE
|
||||
[ ${pkg_header[0]} ] && pkg_archs=(${pkg_archs[*]} $a)
|
||||
done
|
||||
|
||||
pkg_header=();
|
||||
pkg_builds=();
|
||||
pkg_obsoletes=();
|
||||
pkg_list=();
|
||||
|
||||
DISTROMATIC_BUILD_FILE=$local_distromatic/builds-${local_arch}.sh
|
||||
[ -e $DISTROMATIC_BUILD_FILE ] && . $DISTROMATIC_BUILD_FILE
|
||||
[ ${pkg_header[0]} ] && pkg_archs=(${pkg_archs[*]} ${local_arch})
|
||||
|
||||
# {
|
||||
# echo "Error: missing distromatic generated file $DISTROMATIC_BUILD_FILE; aborting."
|
||||
# return;
|
||||
# }
|
||||
# . $DISTROMATIC_BUILD_FILE
|
||||
|
||||
for i in ${pkg_list[*]}; do
|
||||
if [ "$i" == "${pkg_header[0]}" ]; then
|
||||
pkg_name=${pkg_header[0]};
|
||||
# Note: pkg_arch reported in builds file is just last arch source was
|
||||
# built for, so we use repository arch instead
|
||||
pkg_arch=${pkg_header[1]};
|
||||
[ "$pkg_arch" = "noarch" ] || pkg_arch=${local_arch}
|
||||
pkg_version=${pkg_header[2]};
|
||||
pkg_release=${pkg_header[3]};
|
||||
pkg_group=${pkg_header[4]};
|
||||
pkg_license=${pkg_header[5]};
|
||||
pkg_size=${pkg_header[6]};
|
||||
pkg_buildtime=${pkg_header[7]};
|
||||
pkg_altrep=${pkg_header[8]};
|
||||
pkg_repository=${pkg_header[9]};
|
||||
return 0
|
||||
fi
|
||||
done
|
||||
unset pkg_name pkg_arch pkg_version pkg_release \
|
||||
pkg_group pkg_license pkg_size pkg_buildtime pkg_altrep pkg_repository
|
||||
|
||||
return 1
|
||||
}
|
||||
|
||||
[ $# -gt 0 ] || { usage ; exit 1; }
|
||||
|
||||
for ((i=1; i<=$#; i++)); do
|
||||
case ${!i} in
|
||||
-s) shift
|
||||
SOURCE_REPOSITORY="${!i}"
|
||||
;;
|
||||
-d) shift
|
||||
DEST_REPOSITORY="${!i}"
|
||||
;;
|
||||
-p) shift
|
||||
PORT_REPOSITORY="${!i}"
|
||||
;;
|
||||
-t) TESTMODE=1
|
||||
;;
|
||||
-v) VERBOSE=1
|
||||
;;
|
||||
-h|--help)
|
||||
usage
|
||||
exit 0
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
[ "$SOURCE_REPOSITORY" -a "$DEST_REPOSITORY" ] || { usage; exit 1; }
|
||||
|
||||
[ "$SOURCE_REPOSITORY" = "$DEST_REPOSITORY" ] && {
|
||||
echo "ERROR: source and destination repository cannot be the same; aborting."
|
||||
exit 1
|
||||
}
|
||||
|
||||
[ "$TESTMODE" ] && echo "** TEST MODE enabled: no changes will be made **"
|
||||
|
||||
for a in `seq 1 ${#ARCHS[*]}`; do
|
||||
. $LOCAL_REPS_BASE_DIR/distromatic/$SOURCE_REPOSITORY/builds-${ARCHS[$a-1]}.sh
|
||||
pkglist[$a-1]="${pkg_list[*]}"
|
||||
warningslist[$a-1]="${warnings_list[*]}"
|
||||
needportlist[$a-1]="${needport_list[*]}"
|
||||
done
|
||||
|
||||
tmpfile=`mktemp -q -t $me.XXXXXXXX` || {
|
||||
echo "ERROR: cannot create temporary files." >&2
|
||||
exit 1
|
||||
}
|
||||
|
||||
for a in `seq 1 ${#ARCHS[*]}`; do
|
||||
echo -n "${pkglist[$a-1]} " >> $tmpfile
|
||||
done
|
||||
allpkgs="`cat $tmpfile | xargs -n 1 | sort -u | xargs`"
|
||||
rm -f $tmpfile
|
||||
|
||||
for p in ${allpkgs}; do
|
||||
pkgcontinue=
|
||||
needsport=
|
||||
for w in ${warningslist[*]}; do
|
||||
[ "$p" = "$w" ] && { pkgcontinue=1; break; }
|
||||
done
|
||||
[ "$pkgcontinue" ] && continue
|
||||
|
||||
for a in `seq 1 ${#ARCHS[*]}`; do
|
||||
get_pkg_buildinfo $LOCAL_REPS_BASE_DIR/distromatic/$DEST_REPOSITORY ${ARCHS[$a-1]} $p
|
||||
if [ "$pkg_name" ]; then
|
||||
spkg_version=$pkg_version
|
||||
spkg_release=$pkg_release
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
[ "$pkg_name" ] || {
|
||||
echo "$p: not present in $DEST_REPOSITORY; skipping."
|
||||
continue
|
||||
}
|
||||
|
||||
[ "$VERBOSE" ] && echo "$p: old release in $DEST_REPOSITORY is $spkg_version-$spkg_release"
|
||||
|
||||
for o in ${needportlist[*]}; do
|
||||
[ "$p" = "$o" ] && { needsport=1; break; }
|
||||
done
|
||||
[ "$needsport" -a ! "$PORT_REPOSITORY" ] && continue
|
||||
|
||||
for a in `seq 1 ${#ARCHS[*]}`; do
|
||||
get_pkg_buildinfo $LOCAL_REPS_BASE_DIR/distromatic/$SOURCE_REPOSITORY ${ARCHS[$a-1]} $p
|
||||
[ "$pkg_name" ] && break
|
||||
done
|
||||
|
||||
[ "$pkg_name" ] || {
|
||||
echo "$p: not present in $SOURCE_REPOSITORY; skipping."
|
||||
continue
|
||||
}
|
||||
|
||||
[ "$VERBOSE" ] && echo "$p: new release in $SOURCE_REPOSITORY is $pkg_version-$pkg_release"
|
||||
|
||||
if [ "$pkg_version" = "$spkg_version" ]; then
|
||||
if [ "$pkg_release" = "$spkg_release" ]; then
|
||||
echo "$p: same release as upstream; skipping."
|
||||
continue
|
||||
fi
|
||||
update_type="release"
|
||||
else
|
||||
OIFS=$IFS
|
||||
IFS='.'
|
||||
read -ra SVER <<< "$spkg_version"
|
||||
read -ra VER <<< "$pkg_version"
|
||||
IFS=$OIFS
|
||||
dotdiff=`expr ${#VER[*]} - ${#SVER[*]}`
|
||||
for i in `seq 1 ${#SVER[*]}`; do
|
||||
[ "${SVER[i-1]}" != "${VER[i-1]}" ] && break
|
||||
done
|
||||
if [ "$i" = "${#SVER[*]}" -a $dotdiff -eq 0 ]; then
|
||||
# e.g. SVER=0.11.3 -> VER=0.11.4
|
||||
if [[ 64#${VER[i-1]} -gt 64#89 && 64#${SVER[i-1]} -lt 64#80 ]]; then
|
||||
[ "$VERBOSE" ] && echo "$p: dubious beta upgrade from ${SVER[i-1]} to ${VER[i-1]}; skipping."
|
||||
continue
|
||||
fi
|
||||
update_type="minor"
|
||||
elif [ $dotdiff -lt 0 ]; then
|
||||
[ "$VERBOSE" ] && echo "$p: newer version has less dots than older ${#VER[*]} < ${#SVER[*]}; skipping."
|
||||
continue
|
||||
elif [ "$i" != "${#SVER[*]}" ]; then
|
||||
# e.g. SVER=0.11 -> VER=1.0
|
||||
[ "$VERBOSE" ] && echo "$p: not a minor version update at position $i/${#SVER[*]}: ${SVER[i-1]} != ${VER[i-1]}; skipping."
|
||||
continue
|
||||
elif [ "${SVER[i-1]}" = "${VER[i-1]}" -a $dotdiff -ge 1 ]; then
|
||||
# e.g. SVER=0.11.2 -> VER=0.11.2.3
|
||||
update_type="minor"
|
||||
else
|
||||
echo "$p: UNEXPECTED CASE - CHECK CODE; skipping."
|
||||
continue
|
||||
fi
|
||||
fi
|
||||
if [ "$needsport" ]; then
|
||||
echo "$p: importing from $SOURCE_REPOSITORY to $PORT_REPOSITORY ($pkg_version-$pkg_release -> $spkg_version-$spkg_release)"
|
||||
if [ ! "$TESTMODE" ]; then
|
||||
autodist-repository import $SOURCE_REPOSITORY $p -d $PORT_REPOSITORY -y >/dev/null
|
||||
if [ $? -eq 0 -a "$WEBBUILD_URL" -a "$WEBBUILD_USER" ]; then
|
||||
curl -s "$WEBBUILD_URL?REQUEST=message&USER=$WEBBUILD_USER&SECRET=${WEBBUILD_SECRET}&USER_EMAIL=$WEBBUILD_EMAIL&\
|
||||
MESSAGE=`cgi_encodevar \"imported <b>$p</b> from <b>$SOURCE_REPOSITORY</b> to <b>$PORT_REPOSITORY</b> for porting\"`" >/dev/null
|
||||
fi
|
||||
fi
|
||||
else
|
||||
echo "$p: importing from $SOURCE_REPOSITORY to $DEST_REPOSITORY ($pkg_version-$pkg_release -> $spkg_version-$spkg_release; update type: $update_type)"
|
||||
if [ ! "$TESTMODE" ]; then
|
||||
autodist-repository import $SOURCE_REPOSITORY $p -d $DEST_REPOSITORY -y >/dev/null
|
||||
if [ $? -eq 0 -a "$WEBBUILD_URL" -a "$WEBBUILD_USER" ]; then
|
||||
curl -s "$WEBBUILD_URL?REQUEST=message&USER=$WEBBUILD_USER&SECRET=${WEBBUILD_SECRET}&USER_EMAIL=$WEBBUILD_EMAIL&\
|
||||
MESSAGE=`cgi_encodevar \"imported <b>$p</b> from <b>$SOURCE_REPOSITORY</b> to <b>$DEST_REPOSITORY</b>\"`" >/dev/null
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
||||
exit 0
|
145
autoport
145
autoport
@ -1,10 +1,11 @@
|
||||
#!/bin/bash
|
||||
# autoport -- batch cross-build tool based on autodist
|
||||
# Copyright (C) 2011-2012 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
# Copyright (C) 2011-2014 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
#
|
||||
# Released under the terms of the GNU GPL release 3 license
|
||||
#
|
||||
VERSION=0.9.6
|
||||
VERSION=0.9.13
|
||||
|
||||
BASE_ARCH=i586
|
||||
BASE_REPOSITORY=devel
|
||||
PORT_REPOSITORY=devel
|
||||
@ -37,6 +38,7 @@ ${me[0]} ${me[1]}
|
||||
-u changelog "$"Rebuild packages with given changelog
|
||||
-v "$"More verbose output
|
||||
-x "$"Operate in cross build mode
|
||||
--user user "$"Pass calling user name for Webbuild social messages""
|
||||
|
||||
arch "$"Target architecture
|
||||
job "$"Job specification for autodist""
|
||||
@ -86,7 +88,7 @@ function get_pkg_srcinfo() {
|
||||
[ $2 ] && pkg=$2 || return 1
|
||||
|
||||
[ -e $local_distromatic/srcpkglist ] || return 2
|
||||
|
||||
|
||||
pkg_line=`grep "^$pkg " $local_distromatic/srcpkglist`
|
||||
[ "$pkg_line" ] || return 3
|
||||
|
||||
@ -99,7 +101,6 @@ function get_pkg_srcinfo() {
|
||||
src_epoch=$5
|
||||
src_release=$6
|
||||
src_milestone=`echo $src_release | sed "s|[0-9.]*\(.*\)|\1|"`
|
||||
|
||||
}
|
||||
|
||||
# get_pkg_buildinfo - uses distromatic generated build file for
|
||||
@ -198,18 +199,18 @@ function find_requirements() {
|
||||
local OUTFILE=$1
|
||||
|
||||
if [ "`grep " is needed by " $OUTFILE`" ]; then
|
||||
grep " is needed by " $OUTFILE | awk '{ print $1 }' | sort -u > $tf1
|
||||
grep " is needed by " $OUTFILE | awk '{ print $1 }' | tr -d \' > $tf1
|
||||
elif [ "`grep " matches no packages" $OUTFILE`" ]; then
|
||||
grep " matches no packages" $OUTFILE | awk '{ print $2 }' | tr -d \' | sort -u > $tf1
|
||||
grep " matches no packages" $OUTFILE | awk '{ print $2 }' | tr -d \' | sed "s|@.*||" > $tf1
|
||||
elif [ "`grep " no package provides " $OUTFILE`" ]; then
|
||||
grep " no package provides " $OUTFILE | sed "s|.* no package provides ||" | sort -u > $tf1
|
||||
grep " no package provides " $OUTFILE | sed "s|.* no package provides ||" > $tf1
|
||||
fi
|
||||
|
||||
[ `stat -c %s $tf1` -gt 0 ] && {
|
||||
echo -n " | missing requirements: "
|
||||
> $tf
|
||||
cat $tf1 | while read line; do
|
||||
REQ=`find_source_by_provide $PORT_REPOSITORY $line`
|
||||
sort -u $tf1 | while read line; do
|
||||
REQ=`find_source_by_provide $PORT_REPOSITORY ${line}`
|
||||
[ "$REQ" ] && \
|
||||
echo "${REQ}" >> $tf || \
|
||||
echo -n "$line(unresolved) "
|
||||
@ -230,12 +231,31 @@ function find_requirements() {
|
||||
return 0
|
||||
}
|
||||
|
||||
fetch_repfiles() {
|
||||
local u
|
||||
|
||||
curl -f -L -s ${REPS_BASE_URL}/$PORT_REPOSITORY/srcpkglist -o $DATADIR/$PORT_REPOSITORY/srcpkglist ||
|
||||
echo "Warning: unable to fetch ${REPS_BASE_URL}/$PORT_REPOSITORY/srcpkglist"
|
||||
curl -f -L -s $PORT_REPOSITORY_DISTROMATIC_URL/sources-$BASE_ARCH -o $DATADIR/$PORT_REPOSITORY/sources-$BASE_ARCH ||
|
||||
echo "Warning: unable to fetch $PORT_REPOSITORY_DISTROMATIC_URL/sources-$BASE_ARCH"
|
||||
curl -f -L -s $PORT_REPOSITORY_DISTROMATIC_URL/builds-$TARGET_ARCH.sh -o $DATADIR/$PORT_REPOSITORY/builds-$TARGET_ARCH.sh ||
|
||||
echo "Error: unable to fetch $PORT_REPOSITORY_DISTROMATIC_URL/builds-$TARGET_ARCH.sh"
|
||||
for u in ${AUTOPORT_UNSTAGE_ARCHS}; do
|
||||
[ "$u" = "$TARGET_ARCH" ] && {
|
||||
rm -f $DATADIR/$PORT_REPOSITORY/unstage.$TARGET_ARCH
|
||||
return
|
||||
}
|
||||
done
|
||||
curl -f -L -s ${REPS_BASE_URL}/${PORT_REPOSITORY/-*}/unstage.$TARGET_ARCH -o $DATADIR/$PORT_REPOSITORY/unstage.$TARGET_ARCH ||
|
||||
echo "Error: unable to fetch ${REPS_BASE_URL}/${PORT_REPOSITORY/-*}/unstage.$TARGET_ARCH"
|
||||
}
|
||||
|
||||
[ $# -gt 0 ] || { usage ; exit 1; }
|
||||
|
||||
BUILD_ARCH=`uname -i`
|
||||
|
||||
case $BUILD_ARCH in
|
||||
i386|i486|i686) BUILD_ARCH=i586 ;;
|
||||
i386|i486|i686) BUILD_ARCH=i586; BASE_ARCH=x86_64 ;;
|
||||
arm*) BUILD_ARCH=arm ;;
|
||||
esac
|
||||
|
||||
@ -272,6 +292,13 @@ for ((i=1; i<=$#; i++)); do
|
||||
TARGET_ARCHS="`echo ${!i} | tr , ' '`"
|
||||
CROSS_MODE=1
|
||||
;;
|
||||
--user) let i+=1
|
||||
[ "${!i}" ] || {
|
||||
echo "Error: --user parameter not given, aborting."
|
||||
exit 1
|
||||
}
|
||||
WEBBUILD_USER_CMDLINE="${!i}"
|
||||
;;
|
||||
-h|--help)
|
||||
usage
|
||||
exit 0
|
||||
@ -322,46 +349,57 @@ for TARGET_ARCH in ${TARGET_ARCHS}; do
|
||||
BUILD_CPU=`echo $BUILD_PLATFORM | cut -d- -f1`
|
||||
TARGET_PLATFORM=`rpm --target $TARGET_ARCH --eval %{_target_platform}`
|
||||
TARGET_CPU=`echo $TARGET_PLATFORM | cut -d- -f1`
|
||||
SPECDIR=`rpm --eval %{_specdir}`
|
||||
eval `autospec --eval spec_dir | tail -n1`
|
||||
if [ "$spec_dir" ]; then
|
||||
SPECDIR=$spec_dir
|
||||
else
|
||||
SPECDIR=`rpm --eval %{_specdir}`
|
||||
fi
|
||||
|
||||
echo "Build platform is $BUILD_PLATFORM"
|
||||
echo "Target platform is $TARGET_PLATFORM"
|
||||
echo "Port repository is $PORT_REPOSITORY"
|
||||
echo "Release repository is $DEST_REPOSITORY"
|
||||
|
||||
curl -s ${REPS_BASE_URL}/$PORT_REPOSITORY/srcpkglist -o $DATADIR/$PORT_REPOSITORY/srcpkglist ||
|
||||
echo "Warning: unable to fetch ${REPS_BASE_URL}/$PORT_REPOSITORY/srcpkglist"
|
||||
curl -s $PORT_REPOSITORY_DISTROMATIC_URL/sources-$BASE_ARCH -o $DATADIR/$PORT_REPOSITORY/sources-$BASE_ARCH ||
|
||||
echo "Warning: unable to fetch $PORT_REPOSITORY_DISTROMATIC_URL/sources-$BASE_ARCH"
|
||||
# rm -f $DATADIR/$PORT_REPOSITORY/sources-$BASE_ARCH
|
||||
# curl -s $PORT_REPOSITORY_DISTROMATIC_URL/sources-$TARGET_CPU -o $DATADIR/$PORT_REPOSITORY/sources-$TARGET_CPU ||
|
||||
# echo "Warning: unable to fetch $PORT_REPOSITORY_DISTROMATIC_URL/sources-$TARGET_CPU"
|
||||
|
||||
# old files cleanup
|
||||
rm -f $DATADIR/$PORT_REPOSITORY/sources-$TARGET_CPU
|
||||
# curl -s $PORT_REPOSITORY_DISTROMATIC_URL/builds-$BASE_ARCH.sh -o $DATADIR/$PORT_REPOSITORY/builds-$BASE_ARCH.sh ||
|
||||
# echo "Error: unable to fetch $PORT_REPOSITORY_DISTROMATIC_URL/builds-$BASE_ARCH.sh"
|
||||
rm -f $DATADIR/$PORT_REPOSITORY/builds-$BASE_ARCH.sh
|
||||
|
||||
curl -s $PORT_REPOSITORY_DISTROMATIC_URL/builds-$TARGET_ARCH.sh -o $DATADIR/$PORT_REPOSITORY/builds-$TARGET_ARCH.sh ||
|
||||
echo "Error: unable to fetch $PORT_REPOSITORY_DISTROMATIC_URL/builds-$TARGET_ARCH.sh"
|
||||
|
||||
fetch_repfiles
|
||||
|
||||
if [ "$BATCH_MODE" ]; then
|
||||
[ "${JOB[*]}" ] && {
|
||||
echo "Error: no jobs allowed in batch mode; aborting."
|
||||
exit 1
|
||||
}
|
||||
# curl -s $BASE_REPOSITORY_DISTROMATIC_URL/builds-$BASE_ARCH.sh -o $DATADIR/$BASE_REPOSITORY/builds-$BASE_ARCH.sh ||
|
||||
# echo "Error: unable to fetch $BASE_REPOSITORY_DISTROMATIC_URL/builds-$BASE_ARCH.sh"
|
||||
# old files cleanup
|
||||
rm -f $DATADIR/$BASE_REPOSITORY/builds-$BASE_ARCH.sh
|
||||
# curl -s $BASE_REPOSITORY_DISTROMATIC_URL/builds-$TARGET_ARCH.sh -o $DATADIR/$BASE_REPOSITORY/builds-$TARGET_ARCH.sh ||
|
||||
# echo "Error: unable to fetch $BASE_REPOSITORY_DISTROMATIC_URL/builds-$TARGET_ARCH.sh"
|
||||
rm -f $DATADIR/$BASE_REPOSITORY/builds-$TARGET_ARCH.sh
|
||||
|
||||
get_pkg_buildinfo $DATADIR/$PORT_REPOSITORY $TARGET_ARCH
|
||||
port_pkg_list=${pkg_list[*]}
|
||||
echo "Packages to port: ${needport_list[*]}"
|
||||
for p in ${needport_list[*]}; do
|
||||
JOB=(${JOB[*]} $p)
|
||||
done
|
||||
|
||||
if [ "$REBUILD_MILESTONE" ]; then
|
||||
for p in ${port_pkg_list}; do
|
||||
get_pkg_buildinfo $DATADIR/$PORT_REPOSITORY $TARGET_ARCH $p
|
||||
target_pkg_name=$pkg_name
|
||||
target_pkg_ver=$pkg_version
|
||||
target_pkg_rel=$pkg_release
|
||||
target_pkg_milestone=`echo $target_pkg_rel | sed "s|[0-9.]*\(.*\)|\1|"`
|
||||
if [ "$target_pkg_milestone" != "$REBUILD_MILESTONE" ]; then
|
||||
JOB=(${JOB[*]} $p)
|
||||
fi
|
||||
done
|
||||
echo "Packages to rebuild: ${JOB[*]}"
|
||||
else
|
||||
echo "Packages to port: ${needport_list[*]}"
|
||||
for p in ${needport_list[*]}; do
|
||||
JOB=(${JOB[*]} $p)
|
||||
done
|
||||
fi
|
||||
|
||||
[ -e $DATADIR/autoport-$PORT_REPOSITORY-current ] && \
|
||||
mv $DATADIR/autoport-$PORT_REPOSITORY-current $DATADIR/autoport-$PORT_REPOSITORY-last
|
||||
fi
|
||||
@ -388,6 +426,7 @@ for TARGET_ARCH in ${TARGET_ARCHS}; do
|
||||
|
||||
while [ "${JOB[*]}" ]; do
|
||||
step=`expr $step + 1`
|
||||
[ $step -gt 1 ] && fetch_repfiles
|
||||
[ "$BATCH_MODE" -a $step -gt $AUTOPORT_MAX_STEPS ] && {
|
||||
echo "Maximum steps count reached for batch mode; exiting. See $logfile for details."
|
||||
break
|
||||
@ -403,9 +442,15 @@ for TARGET_ARCH in ${TARGET_ARCHS}; do
|
||||
JOB_FAILED=()
|
||||
JOB_CANTINSTALL_OLD=(${JOB_CANTINSTALL[*]})
|
||||
for JOB_NUM in `seq 1 ${#JOB[*]}`; do
|
||||
JOB_CURRENT=${JOB[$JOB_NUM-1]}
|
||||
if [ "`grep "^${JOB_CURRENT}$" /etc/autodist/unstage 2>/dev/null`" -o \
|
||||
"`grep "^${JOB_CURRENT}$" /etc/autodist/unstage.${TARGET_ARCH} 2>/dev/null`" ]; then
|
||||
JOB_CURRENT=${JOB[$JOB_NUM-1]/\#*}
|
||||
if [ "${JOB_CURRENT}" != "${JOB[$JOB_NUM-1]}" ]; then
|
||||
JOB_CURRENT_VERSION=${JOB[$JOB_NUM-1]/*\#}
|
||||
else
|
||||
JOB_CURRENT_VERSION=
|
||||
fi
|
||||
if [ ! -s $DATADIR/$PORT_REPOSITORY/unstage.${TARGET_ARCH} -o \
|
||||
"`grep "^${JOB_CURRENT}$" /etc/autodist/unstage.${TARGET_ARCH} 2>/dev/null`" -o \
|
||||
"`grep "^${JOB_CURRENT}$" $DATADIR/$PORT_REPOSITORY/unstage.${TARGET_ARCH} 2>/dev/null`" ]; then
|
||||
echo -n "^ $JOB_CURRENT: "
|
||||
STAGEOPTS=
|
||||
else
|
||||
@ -429,7 +474,18 @@ for TARGET_ARCH in ${TARGET_ARCHS}; do
|
||||
JOB_FAILED=(${JOB_FAILED[*]} $JOB_CURRENT)
|
||||
continue
|
||||
fi
|
||||
get_pkg_srcinfo $DATADIR/$PORT_REPOSITORY ${JOB_CURRENT}
|
||||
get_pkg_srcinfo $DATADIR/$PORT_REPOSITORY ${JOB_CURRENT} || {
|
||||
echo "< (FAILED) [error $? in get_pkg_srcinfo]"
|
||||
JOB_FAILED=(${JOB_FAILED[*]} $JOB_CURRENT)
|
||||
continue
|
||||
}
|
||||
if [ "$JOB_CURRENT_VERSION" -a \
|
||||
"$JOB_CURRENT_VERSION" != "$src_version" -a \
|
||||
"$JOB_CURRENT_VERSION" != "$src_version-$src_release" ]; then
|
||||
echo "< (FAILED) [wrong version $src_version-$src_release != $JOB_CURRENT_VERSION]"
|
||||
JOB_FAILED=(${JOB_FAILED[*]} $JOB_CURRENT)
|
||||
continue
|
||||
fi
|
||||
|
||||
DONT_PREPARE_THIS=
|
||||
for p in ${JOB_CMDLINE[*]}; do
|
||||
@ -464,9 +520,8 @@ for TARGET_ARCH in ${TARGET_ARCHS}; do
|
||||
if [ "$REBUILD_MODE" = "1" ]; then
|
||||
echo -n "update"
|
||||
[ "$VERBOSE_MODE" ] && echo "
|
||||
%% COMMAND: LANG=C LC_ALL=C autodist -u -r ${JOB_CURRENT} --severity 2 -- $STAGEOPTS --changelog \"$REBUILD_CHANGELOG\""
|
||||
LANG=C LC_ALL=C autodist -u -r ${JOB_CURRENT} --severity 2 -- $STAGEOPTS --changelog \"$REBUILD_CHANGELOG\" &>$tmpfile
|
||||
cat $tmpfile >> $logfile
|
||||
%% COMMAND: LANG=C LC_ALL=C autodist -u --rebuild -r ${JOB_CURRENT} --severity 2 -- $STAGEOPTS --changelog \"$REBUILD_CHANGELOG\""
|
||||
LANG=C LC_ALL=C autodist -u --rebuild -r ${JOB_CURRENT} --severity 2 -- $STAGEOPTS --changelog \"$REBUILD_CHANGELOG\" &>$tmpfile
|
||||
[ $? -gt 0 ] && {
|
||||
echo "(FAILED) "
|
||||
autoport_log ${JOB_CURRENT} update failed $tmpfile
|
||||
@ -495,9 +550,10 @@ for TARGET_ARCH in ${TARGET_ARCHS}; do
|
||||
echo "(FAILED) [can't get repository information for this package]"
|
||||
continue
|
||||
}
|
||||
[ "$VERBOSE_MODE" ] && echo "
|
||||
%% COMMAND: LANG=C LC_ALL=C autospec -u ${JOB_CURRENT} -a4 --rebuild --changelog \"$REBUILD_MILESTONE milestone rebuild\""
|
||||
# FIXME: should be implemented in autodist
|
||||
LANG=C LC_ALL=C autospec -u ${JOB_CURRENT} -a4 ${src_version} ${src_numrelease}${REBUILD_MILESTONE} \
|
||||
--changelog "$REBUILD_MILESTONE milestone rebuild" &>$tmpfile
|
||||
LANG=C LC_ALL=C autospec -u ${JOB_CURRENT} -a4 --rebuild --changelog "$REBUILD_MILESTONE milestone rebuild" &>$tmpfile
|
||||
[ $? -gt 0 ] && {
|
||||
if [ "$VERBOSE_MODE" ]; then
|
||||
echo
|
||||
@ -560,8 +616,13 @@ for TARGET_ARCH in ${TARGET_ARCHS}; do
|
||||
echo -n "(OK) "
|
||||
autoport_log ${JOB_CURRENT} port ok $tmpfile
|
||||
if [ "$WEBBUILD_URL" -a "$WEBBUILD_USER" ]; then
|
||||
curl -s "$WEBBUILD_URL?REQUEST=message&USER=$WEBBUILD_USER&SECRET=$WEBBUILD_SECRET&USER_EMAIL=$WEBBUILD_EMAIL&\
|
||||
if [ "$WEBBUILD_USER_CMDLINE" ]; then
|
||||
curl -s "$WEBBUILD_URL?REQUEST=message&USER=$WEBBUILD_USER&SECRET=$WEBBUILD_SECRET&USER_EMAIL=$WEBBUILD_EMAIL&\
|
||||
MESSAGE=`cgi_encodevar \"(invoked by $WEBBUILD_USER_CMDLINE) ported <b>$JOB_CURRENT</b> to <b>$TARGET_ARCH</b> and sent it to <b>$src_repository</b>\"`" >/dev/null
|
||||
else
|
||||
curl -s "$WEBBUILD_URL?REQUEST=message&USER=$WEBBUILD_USER&SECRET=$WEBBUILD_SECRET&USER_EMAIL=$WEBBUILD_EMAIL&\
|
||||
MESSAGE=`cgi_encodevar \"ported <b>$JOB_CURRENT</b> to <b>$TARGET_ARCH</b> and sent it to <b>$src_repository</b>\"`" >/dev/null
|
||||
fi
|
||||
fi
|
||||
}
|
||||
echo -n "install"
|
||||
@ -604,8 +665,8 @@ MESSAGE=`cgi_encodevar \"ported <b>$JOB_CURRENT</b> to <b>$TARGET_ARCH</b> and s
|
||||
JOB_CANTINSTALL=()
|
||||
for JOB_NUM in `seq 1 ${#JOB_CANTINSTALL_OLD[*]}`; do
|
||||
JOB_CURRENT=${JOB_CANTINSTALL_OLD[$JOB_NUM-1]}
|
||||
if [ "`grep "^${JOB_CURRENT}$" /etc/autodist/unstage 2>/dev/null`" -o \
|
||||
"`grep "^${JOB_CURRENT}$" /etc/autodist/unstage.${TARGET_ARCH} 2>/dev/null`" ]; then
|
||||
if [ "`grep "^${JOB_CURRENT}$" /etc/autodist/unstage.${TARGET_ARCH} 2>/dev/null`" -o \
|
||||
"`grep "^${JOB_CURRENT}$" $DATADIR/$PORT_REPOSITORY/unstage.$TARGET_ARCH 2>/dev/null`" ]; then
|
||||
echo -n "$JOB_CURRENT: "
|
||||
STAGEOPTS=
|
||||
else
|
||||
|
@ -41,10 +41,14 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
$CMD_PREFIX /usr/sbin/chroot /var/autoport/${AUTOPORT_CHROOT[$i]} su -l $SU_APPEND ${AUTOPORT_CHROOT_USER[$i]} -c "${CHROOT_COMMAND}"
|
||||
else
|
||||
echo "Entering ${AUTOPORT_CHROOT[$i]} autoport chroot environment"
|
||||
hostname=`hostname`
|
||||
grep $hostname /var/autoport/${AUTOPORT_CHROOT[$i]}/etc/hosts >/dev/null || {
|
||||
sed -i "s|\(^127.0.0.1[[:space:]]*\)|\1$hostname |" /var/autoport/${AUTOPORT_CHROOT[$i]}/etc/hosts
|
||||
}
|
||||
[ -e /var/autoport/${AUTOPORT_CHROOT[$i]}/etc/profile.d/autoport.sh ] || {
|
||||
echo "PS1='[\u@${AUTOPORT_CHROOT[$i]} \W]\$ '" > /var/autoport/${AUTOPORT_CHROOT[$i]}/etc/profile.d/autoport.sh
|
||||
}
|
||||
$CMD_PREFIX /usr/sbin/chroot /var/autoport/${AUTOPORT_CHROOT[$i]} su -l $SU_APPEND ${AUTOPORT_CHROOT_USER[$i]}
|
||||
$CMD_PREFIX /usr/sbin/chroot /var/autoport/${AUTOPORT_CHROOT[$i]} su -l $SU_APPEND ${AUTOPORT_CHROOT_USER[$i]}
|
||||
fi
|
||||
exit 0
|
||||
done
|
||||
|
@ -1,14 +1,15 @@
|
||||
# Global configuration file for autodist
|
||||
#
|
||||
AUTODIST_ARCHS=(i586 x86_64 arm)
|
||||
REPS_BASE_URL=http://www.openmamba.org/pub/openmamba
|
||||
LOCAL_REPS_BASE_DIR=/var/ftp/pub/openmamba
|
||||
SEND_SERVER=devel-autodist
|
||||
GNOME_VER=3.4
|
||||
#WEBBUILD_URL=http://localhost/cgi-bin/webbuild
|
||||
#WEBBUILD_USER=
|
||||
#WEBBUILD_EMAIL=
|
||||
#WEBBUILD_SECRET=
|
||||
WEBBUILD_STATEDIR=/var/webbuild
|
||||
WEBBUILD_DISTROQUERY_URL="http://www.openmamba.org/cgi-bin/distroquery"
|
||||
AUTOBUILD_MAXNUM=200
|
||||
AUTOBUILD_DATEFROM=20060601
|
||||
AUTOBUILD_SKIP_DAYS=28
|
||||
@ -16,6 +17,36 @@ AUTOBUILD_SUCCESS_DAYS=3
|
||||
AUTODIST_REPOSITORY=devel-autodist
|
||||
AUTODIST_DELAYED_REPOSITORY=devel-future
|
||||
AUTODIST_REPOSITORIES=(devel devel-games devel-makedist devel-kernel devel-xorg devel-kde4 devel-autodist)
|
||||
AUTOPORT_UNSTAGE_ARCHS="i586"
|
||||
AUTOPORT_STAGEVARS="--define stage1=1"
|
||||
AUTOPORT_MAX_STEPS=10
|
||||
#RPMDIR=/usr/src/RPM
|
||||
AUTODIST_REBUILDOLD_MAX=20
|
||||
AUTODIST_REBUILDOLD_FROMDATE=20090101
|
||||
#
|
||||
# Set to disable autodist-repository and use local list
|
||||
#
|
||||
WEBBUILD_REPOSITORIES=(devel devel-games devel-kernel devel-kde4 devel-xorg devel-gnome devel-makedist \
|
||||
devel-java devel-misc devel-autodist devel-future devel-past \
|
||||
milestone1 milestone1-updates milestone1-games milestone1-1.1 milestone1-makedist \
|
||||
milestone2 milestone2-games milestone2-updates milestone2-kernel milestone2-kde4 \
|
||||
milestone2-xorg milestone2-makedist milestone2-java \
|
||||
devel-contrib devel-silvan devel-stefano devel-aleph0 devel-skiver devel-fabiog devel-gil \
|
||||
devel-distservers devel-the_packagizers devel-ercolinux \
|
||||
devel-contrib-java devel-michiamophil milestone1-java milestone1-contrib)
|
||||
#
|
||||
# Set to enable autodist-repository (you also need to disable WEBBUILD_REPOSITORIES above)
|
||||
#
|
||||
#AUTODIST_REPOSITORIES_LOCAL_REPS=(devel devel-games devel-kernel devel-kde4 devel-xorg devel-gnome devel-makedist \
|
||||
# devel-java devel-misc devel-autodist devel-future devel-past devel-embedded devel-silvan \
|
||||
# milestone3 milestone3-games milestone3-updates milestone3-makedist \
|
||||
# milestone2 milestone2-games milestone2-updates milestone2-kernel milestone2-kde4 \
|
||||
# milestone2-xorg milestone2-makedist milestone2-java milestone2-kernel-next \
|
||||
# milestone1 milestone1-updates milestone1-games milestone1-1.1 milestone1-makedist)
|
||||
#AUTODIST_REPOSITORIES_REMOTE_REPS=(devel-contrib devel-stefano devel-aleph0 devel-skiver devel-fabiog devel-gil \
|
||||
# devel-distservers devel-the_packagizers devel-ercolinux \
|
||||
# devel-contrib-java devel-michiamophil milestone1-java milestone1-contrib)
|
||||
#AUTODIST_REPOSITORIES_TRANSITIONAL_REP=devel-makedist
|
||||
#AUTODIST_REPOSITORIES_REMOTE_FTPUSER=
|
||||
#AUTODIST_REPOSITORIES_REMOTE_FTPPASS=
|
||||
#AUTODIST_REPOSITORIES_REMOTE_FTP=
|
||||
|
@ -1,213 +0,0 @@
|
||||
# openmamba autodist build jobs database - architecture independent
|
||||
#
|
||||
# Copyright (c) 2006-2012 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
# Released under the terms of the GNU GPL version 3 license
|
||||
#
|
||||
|
||||
xorg_drv_video_all=(
|
||||
xorg-drv-video-apm,xorg-drv-video-ark,xorg-drv-video-ast,xorg-drv-video-ati,\
|
||||
xorg-drv-video-chips,xorg-drv-video-cirrus,xorg-drv-video-dummy,xorg-drv-video-fbdev,\
|
||||
xorg-drv-video-geode,xorg-drv-video-glint,xorg-drv-video-i128,xorg-drv-video-i740,\
|
||||
xorg-drv-video-intel,xorg-drv-video-mach64,xorg-drv-video-mga,xorg-drv-video-neomagic,\
|
||||
xorg-drv-video-newport,xorg-drv-video-nouveau,xorg-drv-video-nv,xorg-drv-video-openchrome,\
|
||||
xorg-drv-video-r128,xorg-drv-video-radeonhd,xorg-drv-video-rendition,xorg-drv-video-s3,\
|
||||
xorg-drv-video-s3virge,xorg-drv-video-savage,xorg-drv-video-siliconmotion,xorg-drv-video-sis,\
|
||||
xorg-drv-video-trident,xorg-drv-video-tseng,xorg-drv-video-v4l,\
|
||||
xorg-drv-video-vesa,xorg-drv-video-vmware,xorg-drv-video-voodoo,xorg-drv-video-xgixp,\
|
||||
xorg-drv-video
|
||||
%continue_on_error
|
||||
1
|
||||
)
|
||||
#xorg-drv-video-sisusb,
|
||||
|
||||
xorg_drv_input=(
|
||||
xorg-drv-input-acecad,xorg-drv-input-aiptek,xorg-drv-input-elographics,\
|
||||
xorg-drv-input-evdev,xorg-drv-input-fpit,xorg-drv-input-hyperpen,xorg-drv-input-joystick,\
|
||||
xorg-drv-input-keyboard,xorg-drv-input-mouse,xorg-drv-input-mutouch,xorg-drv-input-penmount,\
|
||||
xorg-drv-input-synaptics,xorg-drv-input-tslib,xorg-drv-input-vmmouse,xorg-drv-input-void,\
|
||||
xorg-drv-input
|
||||
%continue_on_error
|
||||
1
|
||||
)
|
||||
|
||||
abiword=(
|
||||
abiword,abiword-docs
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
|
||||
compiz=(
|
||||
compiz,compiz-bcop,compiz-plugins-extra,compiz-plugins-main,libcompizconfig,compizconfig-backend-kconfig4,\
|
||||
compizconfig-simple-settings-manager,emerald
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
# compiz-bcop,compizconfig-backend-kconfig,compizconfig-settings-manager,compizconfig-backend-gconf
|
||||
|
||||
compiz09=(
|
||||
compiz-core,libcompizconfig,python-compizconfig,compizconfig-backend-kconfig4,compiz-fusion-plugins-main,compiz-fusion-plugins-extra
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
|
||||
#curl=(
|
||||
#curl
|
||||
#%build_and_install
|
||||
#1
|
||||
#)
|
||||
|
||||
evolution=(
|
||||
libevolution-data-server,evolution
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
#,evolution-exchange
|
||||
|
||||
#ekiga=(
|
||||
#libpt,libopal,ekiga
|
||||
#%build_and_install
|
||||
#1
|
||||
#)
|
||||
|
||||
#gobby=(
|
||||
#obby,gobby
|
||||
#%build_and_install
|
||||
#1
|
||||
#)
|
||||
|
||||
kde3=(
|
||||
kdelibs,kdebase,kdeadmin,kdeutils,kdenetwork,kdeaccessibility,kdepim,kdegames,kdegraphics,kdemultimedia,kdeaddons,kdenetwork,\
|
||||
kdesdk,kdetoys,kdebindings,kdewebdev,kdeedu,kdeartwork,kde-i18n
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
|
||||
kde4=(
|
||||
kdelibs,kdepimlibs,oxygen-icons,nepomuk-core,kde-runtime,kactivities,kde-workspace,kde-wallpapers,kde-baseapps,\
|
||||
nepomuk-widgets,kdepim4,kdepim-runtime,kdeadmin,kdenetwork4,kdetoys,kdesdk,libkdcraw,libkexiv2,kdeartwork,marble,\
|
||||
kdeplasma-addons,kde-l10n,blinken,libkipi,gwenview,libkdeedu,analitza,cantor,kalgebra,kalzium,kamera,\
|
||||
kanagram,kate,kbruch,kcolorchooser,kdegraphics-strigi-analyzer,kgamma,kgeography,khangman,kig,kiten,\
|
||||
klettres,kmplot,kolourpaint,konsole,kruler,ksnapshot,kstars,libksane,\
|
||||
okular,smokegen,smokeqt,smokekde,svgpart,rocs,kwordquiz,kturtle,ktouch,qtruby,korundum,\
|
||||
kross-interpreters,PyKDE4,perl-Qt4,perl-KDE,kdegraphics-thumbnailers,ksaneplugin,parley,step,\
|
||||
ark,filelight,kcalc,kcharselect,kdf,kfloppy,kgpg,kremotecontrol,ktimer,kwallet,sweeper,\
|
||||
jovie,kmousetool,kmouth,qyoto,kaccessible,kdegraphics-mobipocket,\
|
||||
libkcddb,libkcompactdisc,audiocd-kio,kscd,dragon,kmix,juk,print-manager,kdewebdev,\
|
||||
bomber
|
||||
%build_and_install,%continue_on_error
|
||||
1,1
|
||||
)
|
||||
# kdegames
|
||||
|
||||
kde49=(
|
||||
kdelibs,kdepimlibs,oxygen-icons,nepomuk-core,kde-runtime,kactivities,kde-workspace,kde-wallpapers,kde-baseapps,kdepim4,\
|
||||
kdepim-runtime,kdeadmin,kdenetwork4,kdetoys,kdesdk,libkdcraw,libkexiv2,kdeartwork,marble,\
|
||||
kdeplasma-addons,kde-l10n,blinken,cantor,libkipi,gwenview,libkdeedu,analitza,kalgebra,kalzium,kamera,\
|
||||
kanagram,kate,kbruch,kcolorchooser,kdegraphics-strigi-analyzer,kgamma,kgeography,khangman,kig,kiten,\
|
||||
klettres,kmplot,kolourpaint,konsole,kruler,ksnapshot,kstars,libksane,\
|
||||
okular,smokegen,smokeqt,smokekde,svgpart,rocs,kwordquiz,kturtle,ktouch,qtruby,korundum,\
|
||||
kross-interpreters,PyKDE4,perl-Qt4,perl-KDE,kdegraphics-thumbnailers,ksaneplugin,parley,step,\
|
||||
ark,filelight,kcalc,kcharselect,kdf,kfloppy,kgpg,kremotecontrol,ktimer,kwallet,sweeper,\
|
||||
jovie,kmousetool,kmouth,qyoto,kaccessible,kdegraphics-mobipocket,\
|
||||
libkcddb,libkcompactdisc,audiocd-kio,kscd,dragon,kmix,juk,printer-applet,kdegames
|
||||
%build_and_install,%continue_on_error
|
||||
1,1
|
||||
)
|
||||
|
||||
kde48=(
|
||||
kdelibs,kdepimlibs,oxygen-icons,kde-runtime,kactivities,kde-workspace,kde-wallpapers,kde-baseapps,kdepim4,\
|
||||
kdepim-runtime,kdeadmin,kdemultimedia,kdenetwork4,kdeartwork,kdegames,kdetoys,kdesdk,marble,\
|
||||
kdeplasma-addons,kde-l10n,blinken,cantor,gwenview,libkdeedu,kalgebra,kalzium,kamera,\
|
||||
kanagram,kate,kbruch,kcolorchooser,kdegraphics-strigi-analyzer,kgamma,kgeography,khangman,kig,kiten,\
|
||||
klettres,kmplot,kolourpaint,konsole,kruler,ksnapshot,kstars,libkdcraw,libkexiv2,libkipi,libksane,\
|
||||
okular,smokegen,smokeqt,smokekde,svgpart,rocs,kwordquiz,kturtle,ktouch,qtruby,korundum,\
|
||||
kross-interpreters,PyKDE4,perl-Qt4,perl-KDE,kdegraphics-thumbnailers,ksaneplugin,parley,step,\
|
||||
ark,filelight,kcalc,kcharselect,kdf,kfloppy,kgpg,kremotecontrol,ktimer,kwallet,sweeper,\
|
||||
analitza,jovie,kmousetool,kmouth,qyoto,kaccessible,ksecrets,printer-applet,kdegraphics-mobipocket
|
||||
%build_and_install,%continue_on_error
|
||||
1,1
|
||||
)
|
||||
|
||||
xfce4=(
|
||||
libxfce4util,libxfce4ui,xfce4-appfinder,xfce4-dev-tools,xfce4-panel,xfce4-session,xfce4-settings,xfconf,xfdesktop,xfwm4
|
||||
%build_and_install,%continue_on_error
|
||||
1,1
|
||||
)
|
||||
|
||||
alsa=(
|
||||
libalsa,libalsa-plugins,alsa-utils,alsa-tools,python-alsa
|
||||
%build_and_install,%continue_on_error
|
||||
1,1
|
||||
)
|
||||
#,alsa-driver
|
||||
|
||||
apache_tomcat=(
|
||||
apache-tomcat-dbcp,apache-tomcat
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
|
||||
netbeans=(
|
||||
netbeans-platform,netbeans
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
|
||||
firefox=(
|
||||
xulrunner,firefox
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
|
||||
xfce=(
|
||||
libxfce4util,xfconf,libxfcegui4,libxfce4ui,xfce-utils,xfce4-appfinder,xfce4-panel,xfce4-session,xfdesktop,xfwm4
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
#xfce4-mixer,xfprint,orage,xfwm4-themes,libxfce4menu
|
||||
|
||||
FlightGear=(
|
||||
libSimGear,FlightGear
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
|
||||
valknut=(
|
||||
libdc,valknut
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
|
||||
# use for major release update (e.g. 2.24 -> 2.26)
|
||||
gnome=(
|
||||
libgnome,libsoup,libgweather,librsvg,libwnck,libgdl,gnome-desktop,python-gnome-desktop,libeel,gnome-icon-theme,gnome-menus,\
|
||||
libgnome-panel,anjuta,zenity,metacity,nautilus,brasero,cheese,evince,gconf-editor,gedit,gedit-plugins
|
||||
%build_and_install,%continue_on_error
|
||||
1,1
|
||||
)
|
||||
|
||||
fwbuilder=(
|
||||
libfwbuilder,fwbuilder
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
|
||||
koffice=(
|
||||
koffice
|
||||
%build_and_install
|
||||
1
|
||||
)
|
||||
#,koffice-i18n
|
||||
|
||||
python_numpy=(
|
||||
python-numpy
|
||||
with_pyver
|
||||
-
|
||||
3
|
||||
)
|
||||
|
||||
shorewall=(
|
||||
shorewall-core,shorewall
|
||||
%build_and_install
|
||||
1
|
||||
)
|
@ -1,81 +0,0 @@
|
||||
# openmamba autodist build jobs database
|
||||
#
|
||||
# Copyright (c) 2006-2010 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
# Released under the terms of the GNU GPL version 3 license
|
||||
#
|
||||
|
||||
#
|
||||
# XTC 1 (Cross Toolchain)
|
||||
#
|
||||
# build native binutils (gcc needed, so it's not a stage1 build)
|
||||
# and cross platform binutils
|
||||
#
|
||||
binutils=(
|
||||
binutils
|
||||
cross_target_cpu,_target_platform
|
||||
arm,arm-openmamba-linux-gnueabi
|
||||
avr,avr
|
||||
)
|
||||
|
||||
glibc=(
|
||||
glibc
|
||||
cross_target_cpu,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER,build_doc,build_profile,build_selinux
|
||||
arm,-,-,mamba-arm,3.2,0,0,0
|
||||
)
|
||||
|
||||
kernel=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
arm,mamba-arm
|
||||
)
|
||||
|
||||
linux_firmware=(
|
||||
linux-firmware
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
arm,mamba-arm,3.4
|
||||
)
|
||||
|
||||
pam=(
|
||||
pam
|
||||
bootstrap
|
||||
1
|
||||
)
|
||||
|
||||
rpm=(
|
||||
rpm
|
||||
bootstrap
|
||||
1
|
||||
)
|
||||
|
||||
klibc=(
|
||||
klibc
|
||||
KERNEL_VER
|
||||
2.6.33mamba-arm
|
||||
)
|
||||
|
||||
gcc=(
|
||||
gcc
|
||||
cross_target_cpu,_target_platform,disable_java,disable_gjdoc
|
||||
arm,arm-openmamba-linux-gnueabi,-,1
|
||||
avr,avr,1,-
|
||||
)
|
||||
|
||||
udev=(
|
||||
udev
|
||||
%build_and_install
|
||||
0
|
||||
)
|
||||
|
||||
libcec=(
|
||||
libcec
|
||||
_with_raspberrypi
|
||||
-
|
||||
1
|
||||
)
|
||||
|
||||
xbmc=(
|
||||
xbmc
|
||||
_with_raspberrypi
|
||||
-
|
||||
1
|
||||
)
|
@ -1,385 +0,0 @@
|
||||
# openmamba autodist build jobs database for i586 platform
|
||||
#
|
||||
# Copyright (c) 2006-2010 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
# Released under the terms of the GNU GPL version 3 license
|
||||
#
|
||||
|
||||
#
|
||||
# XTC 1 (Cross Toolchain)
|
||||
#
|
||||
# build native binutils (gcc needed, so it's not a stage1 build)
|
||||
# and cross platform binutils
|
||||
#
|
||||
binutils=(
|
||||
binutils
|
||||
cross_target_cpu,_target_platform
|
||||
i586,i586-openmamba-linux-gnu
|
||||
arm,arm-openmamba-linux-gnueabi
|
||||
avr,avr
|
||||
x86_64,x86_64-openmamba-linux-gnu
|
||||
ppc,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 2
|
||||
#
|
||||
# glibc stage1: build headers only
|
||||
glibc_stage1=(
|
||||
glibc
|
||||
cross_target_cpu,stage1,_target_platform,KERNEL_TARGET,KERNEL_VER
|
||||
i586,1,i586-openmamba-linux-gnu,mamba,-
|
||||
arm,1,arm-openmamba-linux-gnueabi,mamba-arm,2.6.33
|
||||
ppc,1,ppc-openmamba-linux-gnu,mamba-ppc,2.6.33
|
||||
x86_64,1,x86_64-openmamba-linux-gnu,mamba-x86_64,-
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 3
|
||||
#
|
||||
gcc_stage1=(
|
||||
gcc
|
||||
cross_target_cpu,stage1,_target_platform
|
||||
arm,1,arm-openmamba-linux-gnueabi
|
||||
i586,1,i586-openmamba-linux-gnu
|
||||
ppc,1,ppc-openmamba-linux-gnu
|
||||
x86_64,1,x86_64-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 4
|
||||
#
|
||||
glibc_stage2=(
|
||||
glibc
|
||||
cross_target_cpu,stage2,bigendian,softfloat,_target_platform,KERNEL_TARGET,KERNEL_VER
|
||||
arm,1,-,-,arm-openmamba-linux-gnueabi,mamba-arm,2.6.33
|
||||
i586,1,-,-,i586-openmamba-linux-gnu,mamba,-
|
||||
ppc,1,-,-,ppc-openmamba-linux-gnu,mamba,-
|
||||
x86_64,1,-,-,x86_64-openmamba-linux-gnu,mamba-x86_64,-
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 5
|
||||
#
|
||||
gcc=(
|
||||
gcc
|
||||
cross_target_cpu,_target_platform,disable_java
|
||||
i586,i586-openmamba-linux-gnu,-
|
||||
arm,arm-openmamba-linux-gnueabi,1
|
||||
x86_64,x86_64-openmamba-linux-gnu,1
|
||||
ppc,ppc-openmamba-linux-gnu,1
|
||||
avr,avr,1
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 6
|
||||
#
|
||||
glibc=(
|
||||
glibc
|
||||
target,cross_target_cpu,multilib,_target_platform,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
-,i586,-,i586-openmamba-linux-gnu,-,-,mamba,-
|
||||
-,x86_64,-,x86_64-openmamba-linux-gnu,-,-,mamba-x86_64,-
|
||||
-,arm,-,arm-openmamba-linux-gnueabi,-,-,mamba-arm,-
|
||||
-,ppc,-,ppc-openmamba-linux-gnu,-,-,mamba-ppc,2.6.33
|
||||
x86_64,i586,1,i586-openmamba-linux-gnu,-,-,mamba-x86_64,-
|
||||
)
|
||||
|
||||
# XTC 7
|
||||
cross_environment=(
|
||||
cross-environment
|
||||
cross_target_cpu,autodist_crossonly,_target_platform
|
||||
i586,1,i586-openmamba-linux-gnu
|
||||
arm,1,arm-openmamba-linux-gnueabi
|
||||
ppc,1,ppc-openmamba-linux-gnu
|
||||
x86_64,1,x86_64-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
glibc_arm=(
|
||||
glibc
|
||||
cross_target_cpu,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
arm,-,-,mamba-arm,-
|
||||
)
|
||||
|
||||
glibc_multilib=(
|
||||
glibc
|
||||
target,cross_target_cpu,multilib,_target_platform,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
x86_64,i586,1,x86_64-openmamba-linux-gnu,-,-,mamba-x86_64,-
|
||||
)
|
||||
|
||||
glibc_cross_multilib=(
|
||||
glibc
|
||||
target,cross_target_cpu,multilib,_target_platform,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
-,i586,1,x86_64-openmamba-linux-gnu,-,-,mamba-x86_64,-
|
||||
)
|
||||
|
||||
gcc_cross=(
|
||||
gcc
|
||||
cross_target_cpu,_target_platform,disable_java
|
||||
x86_64,x86_64-openmamba-linux-gnu,1
|
||||
arm,arm-openmamba-linux-gnueabi,1
|
||||
ppc,ppc-openmamba-linux-gnu,1
|
||||
avr,avr,1
|
||||
)
|
||||
|
||||
glibc_cross=(
|
||||
glibc
|
||||
target,cross_target_cpu,multilib,_target_platform,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
-,x86_64,-,x86_64-openmamba-linux-gnu,-,-,mamba-x86_64,-
|
||||
-,arm,-,arm-openmamba-linux-gnueabi,-,-,mamba-arm,-
|
||||
-,ppc,-,ppc-openmamba-linux-gnu,-,-,mamba-ppc,2.6.33
|
||||
x86_64,i586,1,i586-openmamba-linux-gnu,-,-,mamba-x86_64,-
|
||||
)
|
||||
|
||||
pkg_config=(
|
||||
pkg-config
|
||||
cross_target_cpu,_target_platform
|
||||
i586,i586-openmamba-linux-gnu
|
||||
x86_64,x86_64-openmamba-linux-gnu
|
||||
arm,arm-openmamba-linux-gnueabi
|
||||
ppc,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
gcc_uclibc=(
|
||||
gcc
|
||||
cross_target_cpu,_target_platform,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
arm,arm-linux-uclibc,-,-,mamba-arm,2.6.33
|
||||
)
|
||||
|
||||
dietlibc=(
|
||||
dietlibc
|
||||
cross_target_cpu
|
||||
i586
|
||||
arm
|
||||
)
|
||||
|
||||
gcc34=(
|
||||
gcc34
|
||||
cross_target_cpu
|
||||
i586
|
||||
ppc
|
||||
)
|
||||
|
||||
klibc=(
|
||||
klibc
|
||||
cross_target_cpu,_target_platform,KERNEL_TARGET,KERNEL_VER
|
||||
-,-,-
|
||||
ppc,ppc-openmamba-linux-gnu,mamba-ppc,-
|
||||
x86_64,x86_64-openmamba-linux-gnu,3mamba-x86_64,-
|
||||
arm,arm-openmamba-linux-gnueabi,mamba-arm,-
|
||||
)
|
||||
|
||||
#
|
||||
# arm cross toolchain
|
||||
#
|
||||
binutils_arm=(
|
||||
binutils
|
||||
cross_target_cpu,_target_platform
|
||||
arm,arm-openmamba-linux-gnueabi
|
||||
)
|
||||
|
||||
|
||||
#
|
||||
# ppc cross toolchain
|
||||
#
|
||||
binutils_ppc=(
|
||||
binutils
|
||||
cross_target_cpu,_target_platform
|
||||
ppc,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
glibc_ppc_stage1=(
|
||||
glibc
|
||||
cross_target_cpu,stage1,_target_platform,KERNEL_TARGET,KERNEL_VER
|
||||
ppc,1,ppc-openmamba-linux-gnu,mamba,-
|
||||
)
|
||||
|
||||
gcc_ppc_stage1=(
|
||||
gcc
|
||||
cross_target_cpu,stage1,_target_platform
|
||||
ppc,1,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
glibc_ppc_stage2=(
|
||||
glibc
|
||||
cross_target_cpu,stage2,bigendian,softfloat,_target_platform,KERNEL_TARGET,KERNEL_VER
|
||||
ppc,1,-,-,ppc-openmamba-linux-gnu,mamba-ppc,2.6.33
|
||||
)
|
||||
|
||||
gcc_ppc=(
|
||||
gcc
|
||||
cross_target_cpu,_target_platform
|
||||
ppc,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
glibc_ppc=(
|
||||
glibc
|
||||
cross_target_cpu,_target_platform,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
ppc,ppc-openmamba-linux-gnu,-,-,mamba-ppc,2.6.33
|
||||
)
|
||||
|
||||
#
|
||||
# KERNEL
|
||||
#
|
||||
|
||||
kernel=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
i586,mamba
|
||||
i586,mamba-64GB
|
||||
i586,mamba-rt
|
||||
i586,mamba-64GB-rt
|
||||
arm,mamba-arm
|
||||
)
|
||||
#arm,mamba-arm-kirkwood
|
||||
#x86_64,mamba-x86_64
|
||||
|
||||
kernel_37=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
i586,mamba
|
||||
i586,mamba-64GB
|
||||
arm,mamba-arm
|
||||
arm,mamba-arm-kirkwood
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
|
||||
kernel_34=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
i586,mamba
|
||||
i586,mamba-64GB
|
||||
arm,mamba-arm
|
||||
arm,mamba-arm-kirkwood
|
||||
x86_64,mamba-x86_64
|
||||
i586,mamba-rt
|
||||
i586,mamba-64GB-rt
|
||||
)
|
||||
|
||||
kernel_arm_kirkwood=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
arm,mamba-arm-kirkwood
|
||||
)
|
||||
|
||||
kernel_milestone2=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
i586,mamba
|
||||
i586,mamba-64GB
|
||||
arm,mamba-arm
|
||||
)
|
||||
|
||||
kernel_rt=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
i586,mamba-rt
|
||||
)
|
||||
|
||||
kernel_64GB=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
i586,mamba-64GB
|
||||
)
|
||||
|
||||
kernel_64GB_rt=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
i586,mamba-64GB-rt
|
||||
)
|
||||
|
||||
kernel_x86_64=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
|
||||
kernel_packages=(
|
||||
hsfmodem,slmodem,compat-wireless,alsa-driver,ndiswrapper,VirtualBox-kernel,\
|
||||
broadcom-sta,stk11xx,cm2020,r8101
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
i586,mamba,-
|
||||
i586,mamba-64GB,-
|
||||
i586,mamba-rt,-
|
||||
i586,mamba-64GB-rt,-
|
||||
)
|
||||
#lirc
|
||||
|
||||
kernel_packages_37=(
|
||||
hsfmodem,slmodem,compat-wireless,alsa-driver,ati-driver,ndiswrapper,NVIDIA,VirtualBox-kernel,\
|
||||
broadcom-sta,stk11xx,cm2020,r8101
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
i586,mamba,3.7
|
||||
i586,mamba-64GB,3.7
|
||||
)
|
||||
#i586,mamba-rt,3.7
|
||||
#i586,mamba-64GB-rt,3.7
|
||||
|
||||
kernel_packages_36=(
|
||||
hsfmodem,slmodem,compat-wireless,alsa-driver,ati-driver,ndiswrapper,NVIDIA,VirtualBox-kernel,\
|
||||
broadcom-sta,stk11xx,cm2020,r8101
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
i586,mamba,3.6
|
||||
i586,mamba-64GB,3.6
|
||||
i586,mamba-rt,3.6
|
||||
i586,mamba-64GB-rt,3.6
|
||||
)
|
||||
#lirc
|
||||
|
||||
kernel_packages_34=(
|
||||
hsfmodem,slmodem,compat-wireless,alsa-driver,ati-driver,ndiswrapper,NVIDIA,VirtualBox-kernel,\
|
||||
broadcom-sta,stk11xx,cm2020,r8101
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
i586,mamba,3.4
|
||||
i586,mamba-64GB,3.4
|
||||
i586,mamba-rt,3.4
|
||||
i586,mamba-64GB-rt,3.4
|
||||
)
|
||||
#lirc
|
||||
|
||||
kernel_packages_32=(
|
||||
hsfmodem,slmodem,compat-wireless,alsa-driver,ati-driver,lirc,ndiswrapper,NVIDIA,NVIDIA_71xx,NVIDIA_96xx,NVIDIA_173xx,VirtualBox-kernel,\
|
||||
broadcom-sta,stk11xx,cm2020,r8101
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
i586,mamba,3.2
|
||||
i586,mamba-64GB,3.2
|
||||
)
|
||||
|
||||
kernel_packages_30=(
|
||||
hsfmodem,slmodem,compat-wireless,alsa-driver,ati-driver,lirc,ndiswrapper,NVIDIA,NVIDIA_71xx,NVIDIA_96xx,NVIDIA_173xx,VirtualBox,\
|
||||
broadcom-sta,atheros-81,drbd,rtl8192se
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
i586,mamba,3.0
|
||||
i586,mamba-64GB,3.0
|
||||
)
|
||||
|
||||
kernel_hannspad=(
|
||||
kernel-hannspad
|
||||
target
|
||||
arm
|
||||
)
|
||||
|
||||
kernel_iconia=(
|
||||
kernel-iconia
|
||||
target
|
||||
arm
|
||||
)
|
||||
|
||||
kernel_iconia_altgcc=(
|
||||
kernel-iconia
|
||||
target,_target_platform
|
||||
arm,arm-none-linux-gnueabi
|
||||
)
|
||||
|
||||
linux_firmware=(
|
||||
linux-firmware
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
i586,mamba,3.4
|
||||
)
|
||||
|
||||
NVIDIA=(
|
||||
NVIDIA
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
i586,mamba,-
|
||||
i586,mamba-64GB,-
|
||||
i586,mamba-rt
|
||||
i586,mamba-64GB-rt
|
||||
)
|
@ -1,267 +0,0 @@
|
||||
# openmamba autodist build jobs database
|
||||
#
|
||||
# Copyright (c) 2006-2010 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
# Released under the terms of the GNU GPL version 3 license
|
||||
#
|
||||
|
||||
# XTC 1 (Cross Toolchain)
|
||||
cross_environment=(
|
||||
cross-environment
|
||||
cross_target_cpu,autodist_crossonly,_target_platform
|
||||
x86_64,1,x86_64-openmamba-linux-gnu
|
||||
i586,1,i586-openmamba-linux-gnu
|
||||
arm,1,arm-openmamba-linux-gnueabi
|
||||
ppc,1,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 2
|
||||
#
|
||||
# build native binutils (gcc needed, so it's not a stage1 build)
|
||||
# and cross platform binutils
|
||||
#
|
||||
binutils=(
|
||||
binutils
|
||||
cross_target_cpu,_target_platform
|
||||
x86_64,x86_64-openmamba-linux-gnu
|
||||
i586,i586-openmamba-linux-gnu
|
||||
arm,arm-openmamba-linux-gnueabi
|
||||
ppc,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 3
|
||||
#
|
||||
# glibc stage1: build headers only
|
||||
glibc_stage1=(
|
||||
glibc
|
||||
cross_target_cpu,stage1,_target_platform,KERNEL_TARGET,KERNEL_VER
|
||||
x86_64,1,x86_64-openmamba-linux-gnu,mamba-x86_64,-
|
||||
arm,1,arm-openmamba-linux-gnueabi,mamba-arm,2.6.33
|
||||
i586,1,i586-openmamba-linux-gnu,mamba,-
|
||||
ppc,1,ppc-openmamba-linux-gnu,mamba,-
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 4
|
||||
#
|
||||
gcc_stage1=(
|
||||
gcc
|
||||
cross_target_cpu,stage1,_target_platform
|
||||
x86_64,1,x86_64-openmamba-linux-gnu
|
||||
arm,1,arm-openmamba-linux-gnueabi
|
||||
i586,1,i586-openmamba-linux-gnu
|
||||
ppc,1,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 5
|
||||
#
|
||||
glibc_stage2=(
|
||||
glibc
|
||||
cross_target_cpu,stage2,bigendian,softfloat,_target_platform,KERNEL_TARGET,KERNEL_VER
|
||||
x86_64,1,-,-,x86_64-openmamba-linux-gnu,mamba-x86_64,-
|
||||
arm,1,-,-,arm-openmamba-linux-gnueabi,mamba-arm,2.6.33
|
||||
i586,1,-,-,i586-openmamba-linux-gnu,mamba,-
|
||||
ppc,1,-,-,ppc-openmamba-linux-gnu,mamba,-
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 6
|
||||
#
|
||||
gcc=(
|
||||
gcc
|
||||
cross_target_cpu,_target_platform
|
||||
x86_64,x86_64-openmamba-linux-gnu
|
||||
arm,arm-openmamba-linux-gnueabi
|
||||
i586,i586-openmamba-linux-gnu
|
||||
ppc,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 7
|
||||
#
|
||||
glibc=(
|
||||
glibc
|
||||
cross_target_cpu,_target_platform,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
ppc,ppc-openmamba-linux-gnu,-,-,mamba-ppc,2.6.33
|
||||
x86_64,x86_64-openmamba-linux-gnu,-,-,mamba-x86_64,-
|
||||
i586,i586-openmamba-linux-gnu,-,-,mamba,-
|
||||
arm,arm-openmamba-linux-gnueabi,-,-,mamba-arm,2.6.33
|
||||
)
|
||||
|
||||
gcc_uclibc=(
|
||||
gcc
|
||||
cross_target_cpu,_target_platform,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
arm,arm-linux-uclibc,-,-,mamba-arm,2.6.33
|
||||
)
|
||||
|
||||
dietlibc=(
|
||||
dietlibc
|
||||
cross_target_cpu
|
||||
ppc
|
||||
x86_64
|
||||
i586
|
||||
arm
|
||||
)
|
||||
|
||||
gcc34=(
|
||||
gcc34
|
||||
cross_target_cpu
|
||||
ppc
|
||||
x86_64
|
||||
i586
|
||||
ppc
|
||||
)
|
||||
|
||||
#klibc=(
|
||||
#klibc
|
||||
#cross_target_cpu,_target_platform,KERNEL_VER
|
||||
#-,-,-
|
||||
#ppc,ppc-openmamba-linux-gnueabi,2.6.33mamba-ppc
|
||||
#)
|
||||
|
||||
kernel=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
kernel_new=(
|
||||
kernel
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
ppc,mamba-ppc,2.6.33
|
||||
)
|
||||
|
||||
kernel_extra=(
|
||||
kernel-extramodules
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
kernel_packages=(
|
||||
hsfmodem,compat-wireless,ati-driver,NVIDIA,NVIDIA_71xx,NVIDIA_96xx,NVIDIA_173xx,broadcom-sta
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
ppc,mamba-ppc,-
|
||||
)
|
||||
# slmodem, alsa-driver, lirc,VirtualBox, ndiswrapper, alsa-driver
|
||||
|
||||
kernel_packages_new=(
|
||||
hsfmodem,compat-wireless,ati-driver,NVIDIA,NVIDIA_71xx,NVIDIA_96xx,NVIDIA_173xx,broadcom-sta
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
ppc,mamba-ppc,2.6.33
|
||||
)
|
||||
|
||||
NVIDIA_all=(
|
||||
NVIDIA,NVIDIA_71xx,NVIDIA_96xx,NVIDIA_173xx
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
alsa_driver=(
|
||||
alsa-driver
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
ati_driver=(
|
||||
ati-driver
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
broadcom_sta=(
|
||||
broadcom-sta
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
kernel_extramodules=(
|
||||
kernel-extramodules
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
kernel_nongpl=(
|
||||
kernel-nongpl
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
kernel_wireless_backport=(
|
||||
kernel-wireless-backport
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
lirc=(
|
||||
lirc
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
ndiswrapper=(
|
||||
ndiswrapper
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
NVIDIA=(
|
||||
NVIDIA
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
VirtualBox=(
|
||||
VirtualBox
|
||||
target,KERNEL_TARGET
|
||||
ppc,mamba-ppc
|
||||
)
|
||||
|
||||
glibc=(
|
||||
glibc
|
||||
cross_target_cpu,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
ppc,-,-,mamba-ppc,2.6.33
|
||||
)
|
||||
|
||||
gcc=(
|
||||
gcc
|
||||
cross_target_cpu
|
||||
ppc
|
||||
)
|
||||
|
||||
binutils=(
|
||||
binutils
|
||||
cross_target_cpu
|
||||
ppc
|
||||
)
|
||||
|
||||
pam=(
|
||||
pam
|
||||
bootstrap
|
||||
1
|
||||
)
|
||||
|
||||
rpm=(
|
||||
rpm
|
||||
bootstrap
|
||||
1
|
||||
)
|
||||
|
||||
klibc=(
|
||||
klibc
|
||||
KERNEL_VER
|
||||
2.6.33mamba-ppc
|
||||
)
|
||||
|
||||
emacs=(
|
||||
emacs
|
||||
bootstrap
|
||||
1
|
||||
)
|
||||
|
||||
gcc=(
|
||||
gcc
|
||||
disable_jack,disable_java,disable_gjdoc
|
||||
1,1,1
|
||||
)
|
@ -1,281 +0,0 @@
|
||||
# openmamba autodist build jobs database
|
||||
#
|
||||
# Copyright (c) 2006-2010 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
# Released under the terms of the GNU GPL version 3 license
|
||||
#
|
||||
|
||||
# XTC 1 (Cross Toolchain)
|
||||
cross_environment=(
|
||||
cross-environment
|
||||
cross_target_cpu,autodist_crossonly,_target_platform
|
||||
x86_64,1,x86_64-openmamba-linux-gnu
|
||||
i586,1,i586-openmamba-linux-gnu
|
||||
arm,1,arm-openmamba-linux-gnueabi
|
||||
ppc,1,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 2
|
||||
#
|
||||
# build native binutils (gcc needed, so it's not a stage1 build)
|
||||
# and cross platform binutils
|
||||
#
|
||||
binutils=(
|
||||
binutils
|
||||
cross_target_cpu,_target_platform
|
||||
x86_64,x86_64-openmamba-linux-gnu
|
||||
i586,i586-openmamba-linux-gnu
|
||||
arm,arm-openmamba-linux-gnueabi
|
||||
ppc,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 3
|
||||
#
|
||||
# glibc stage1: build headers only
|
||||
glibc_stage1=(
|
||||
glibc
|
||||
cross_target_cpu,stage1,_target_platform,KERNEL_TARGET,KERNEL_VER
|
||||
x86_64,1,x86_64-openmamba-linux-gnu,mamba-x86_64,-
|
||||
arm,1,arm-openmamba-linux-gnueabi,mamba-arm,2.6.33
|
||||
i586,1,i586-openmamba-linux-gnu,mamba,-
|
||||
ppc,1,ppc-openmamba-linux-gnu,mamba,-
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 4
|
||||
#
|
||||
gcc_stage1=(
|
||||
gcc
|
||||
cross_target_cpu,stage1,_target_platform
|
||||
x86_64,1,x86_64-openmamba-linux-gnu
|
||||
arm,1,arm-openmamba-linux-gnueabi
|
||||
i586,1,i586-openmamba-linux-gnu
|
||||
ppc,1,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 5
|
||||
#
|
||||
glibc_stage2=(
|
||||
glibc
|
||||
cross_target_cpu,stage2,bigendian,softfloat,_target_platform,KERNEL_TARGET,KERNEL_VER
|
||||
x86_64,1,-,-,x86_64-openmamba-linux-gnu,mamba-x86_64,-
|
||||
arm,1,-,-,arm-openmamba-linux-gnueabi,mamba-arm,2.6.33
|
||||
i586,1,-,-,i586-openmamba-linux-gnu,mamba,-
|
||||
ppc,1,-,-,ppc-openmamba-linux-gnu,mamba,-
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 6
|
||||
#
|
||||
gcc=(
|
||||
gcc
|
||||
cross_target_cpu,_target_platform
|
||||
x86_64,x86_64-openmamba-linux-gnu
|
||||
arm,arm-openmamba-linux-gnueabi
|
||||
i586,i586-openmamba-linux-gnu
|
||||
ppc,ppc-openmamba-linux-gnu
|
||||
)
|
||||
|
||||
#
|
||||
# XTC 7
|
||||
#
|
||||
glibc=(
|
||||
glibc
|
||||
cross_target_cpu,_target_platform,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
x86_64,x86_64-openmamba-linux-gnu,-,-,mamba-x86_64,-
|
||||
i586,i586-openmamba-linux-gnu,-,-,mamba,-
|
||||
arm,arm-openmamba-linux-gnueabi,-,-,mamba-arm,2.6.33
|
||||
)
|
||||
|
||||
gcc_uclibc=(
|
||||
gcc
|
||||
cross_target_cpu,_target_platform,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER
|
||||
arm,arm-linux-uclibc,-,-,mamba-arm,2.6.33
|
||||
)
|
||||
|
||||
dietlibc=(
|
||||
dietlibc
|
||||
cross_target_cpu
|
||||
x86_64
|
||||
i586
|
||||
arm
|
||||
)
|
||||
|
||||
gcc34=(
|
||||
gcc34
|
||||
cross_target_cpu
|
||||
x86_64
|
||||
i586
|
||||
ppc
|
||||
)
|
||||
|
||||
#
|
||||
# KERNEL
|
||||
#
|
||||
kernel=(
|
||||
kernel
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
linux_firmware=(
|
||||
linux-firmware
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
x86_64,mamba-x86_64,-
|
||||
)
|
||||
|
||||
kernel_extra=(
|
||||
kernel-extramodules
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
kernel_packages=(
|
||||
VirtualBox-kernel
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
x86_64,mamba-x86_64,-
|
||||
)
|
||||
#hsfmodem,compat-wireless,ati-driver,NVIDIA,NVIDIA_71xx,NVIDIA_96xx,NVIDIA_173xx,broadcom-sta
|
||||
# slmodem, alsa-driver, lirc,VirtualBox, ndiswrapper, alsa-driver
|
||||
|
||||
kernel_packages_36=(
|
||||
VirtualBox-kernel,NVIDIA
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
x86_64,mamba-x86_64,3.6
|
||||
)
|
||||
|
||||
kernel_packages_34=(
|
||||
VirtualBox-kernel,NVIDIA
|
||||
target,KERNEL_TARGET,KERNEL_VER
|
||||
x86_64,mamba-x86_64,3.4
|
||||
)
|
||||
|
||||
#kernelxen_packages=(
|
||||
#alsa-driver,hsfmodem,compat-wireless,ati-driver,ndiswrapper,broadcom-sta
|
||||
#target,KERNEL_TARGET,KERNEL_VER
|
||||
#x86_64,mamba-xen,-
|
||||
#)
|
||||
|
||||
#NVIDIA_all=(
|
||||
#NVIDIA,NVIDIA_71xx,NVIDIA_96xx,NVIDIA_173xx
|
||||
#target,KERNEL_TARGET,KERNEL_VER
|
||||
#x86_64,mamba-x86_64
|
||||
#)
|
||||
##x86_64,mamba-xen
|
||||
|
||||
alsa_driver=(
|
||||
alsa-driver
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
ati_driver=(
|
||||
ati-driver
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
broadcom_sta=(
|
||||
broadcom-sta
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
kernel_extramodules=(
|
||||
kernel-extramodules
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
kernel_nongpl=(
|
||||
kernel-nongpl
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
kernel_wireless_backport=(
|
||||
kernel-wireless-backport
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
broadcom_sta=(
|
||||
broadcom-sta
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
lirc=(
|
||||
lirc
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
ndiswrapper=(
|
||||
ndiswrapper
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
NVIDIA=(
|
||||
NVIDIA
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
VirtualBox_kernel=(
|
||||
VirtualBox-kernel
|
||||
target,KERNEL_TARGET
|
||||
x86_64,mamba-x86_64
|
||||
)
|
||||
#x86_64,mamba-xen
|
||||
|
||||
glibc=(
|
||||
glibc
|
||||
cross_target_cpu,bigendian,softfloat,KERNEL_TARGET,KERNEL_VER,multilib
|
||||
x86_64,-,-,mamba-x86_64,-,-
|
||||
)
|
||||
|
||||
binutils=(
|
||||
binutils
|
||||
cross_target_cpu
|
||||
x86_64
|
||||
)
|
||||
|
||||
pam=(
|
||||
pam
|
||||
bootstrap
|
||||
1
|
||||
)
|
||||
|
||||
rpm=(
|
||||
rpm
|
||||
bootstrap
|
||||
1
|
||||
)
|
||||
|
||||
gcc=(
|
||||
gcc
|
||||
cross_target_cpu,_target_platform,disable_jack,disable_gjdoc,disable_java
|
||||
x86_64,x86_64-openmamba-linux-gnu,1,0,0
|
||||
)
|
||||
|
||||
apache_ant=(
|
||||
apache-ant
|
||||
stage2
|
||||
1
|
||||
)
|
@ -1,129 +0,0 @@
|
||||
kdebase
|
||||
kdewebdev
|
||||
grub
|
||||
libsqlite2
|
||||
libglade1
|
||||
openssl097
|
||||
gnupg
|
||||
kannel
|
||||
ftp
|
||||
nrg2iso
|
||||
ddrescue
|
||||
db42
|
||||
gcc34
|
||||
ftpsync
|
||||
libglib1
|
||||
gcc33
|
||||
libxml
|
||||
libtool1
|
||||
openldap22
|
||||
python24
|
||||
postgresql7
|
||||
PyQt
|
||||
libcares1
|
||||
libraw13941
|
||||
net-snmp5
|
||||
libmtp7
|
||||
gambas
|
||||
libgda2
|
||||
libmusicbrainz2
|
||||
libpng2
|
||||
libXaw8
|
||||
icu38
|
||||
mysql5
|
||||
libreadline5
|
||||
libxcb-xlib
|
||||
autoconf2.13
|
||||
python
|
||||
libflac11
|
||||
libdc1394_control
|
||||
automake1.10
|
||||
libusb0
|
||||
xorg-drv-input
|
||||
libeigen
|
||||
libgtk1
|
||||
java-junit3
|
||||
lm_sensors2
|
||||
kernel-extramodules
|
||||
kernel-nongpl-nvidia
|
||||
kernel-nongpl-fglrx
|
||||
kernel-nongpl
|
||||
automake1.6
|
||||
libjpeg6b
|
||||
kernel-nongpl-fglrx
|
||||
kernel-nongpl-nvidia
|
||||
db47
|
||||
arts
|
||||
kdegraphics
|
||||
synaptic
|
||||
libjpeg7
|
||||
kdevelop
|
||||
libgda
|
||||
objectweb-asm1
|
||||
objectweb-asm2
|
||||
apache-tomcat5
|
||||
java-junit381
|
||||
jakarta-commons-lang24
|
||||
openssl098
|
||||
libpng12
|
||||
java-servletapi4
|
||||
tcltk84
|
||||
make381
|
||||
lilo
|
||||
rpm516
|
||||
ffmpeg052
|
||||
rpm5
|
||||
libpoppler6
|
||||
x264-84
|
||||
db51
|
||||
kde-i18n
|
||||
libwpg01
|
||||
libwps01
|
||||
libwpd08
|
||||
db52
|
||||
glade-3
|
||||
goocanvas
|
||||
libnl1
|
||||
moagg
|
||||
apache-commons-digester18
|
||||
x264-116
|
||||
libcdio12
|
||||
udev173
|
||||
libtiff3
|
||||
libpcre0
|
||||
libcdio12
|
||||
libpoppler12
|
||||
libaudiofile0
|
||||
libxcb-util1
|
||||
parted2
|
||||
libguile1
|
||||
libgnutls2
|
||||
libgdbm3
|
||||
farstream1
|
||||
gst-plugins-base010
|
||||
gst-plugins-good010
|
||||
gst-plugins-bad010
|
||||
gst-plugins-ugly010
|
||||
gstreamer010
|
||||
lua51
|
||||
libwebkit-gtk
|
||||
libgraphite2_11
|
||||
goocanvas
|
||||
libdirectfb5
|
||||
libtasn1_3
|
||||
kdelibs3
|
||||
goocanvas
|
||||
libraptor
|
||||
python
|
||||
liblcms
|
||||
libpng14
|
||||
xmlgraphics-commons14
|
||||
pygobject2
|
||||
ImageMagick5
|
||||
automake1.12
|
||||
libpcap0
|
||||
htmlunit1
|
||||
libimobiledevice3
|
||||
libilmbase1
|
||||
libgif4
|
||||
libmpc2
|
@ -1 +0,0 @@
|
||||
gcc
|
@ -1,41 +0,0 @@
|
||||
libatk
|
||||
libgtk
|
||||
libpango
|
||||
tcltk
|
||||
dbus
|
||||
libgsf
|
||||
python
|
||||
glib
|
||||
libnfsidmap
|
||||
ghostscript
|
||||
liblcms
|
||||
ImageMagick4
|
||||
ImageMagick
|
||||
gcc
|
||||
libtiff
|
||||
libtiff3
|
||||
libcairo
|
||||
gtk-doc
|
||||
libpoppler
|
||||
libpoppler12
|
||||
gettext
|
||||
libXext
|
||||
gnokii
|
||||
kdegames
|
||||
soprano
|
||||
autoconf
|
||||
libidn
|
||||
libcanberra
|
||||
libxml2
|
||||
libcaca
|
||||
libproxy
|
||||
libphonon
|
||||
xmms2
|
||||
libalsa-plugins
|
||||
gutenprint
|
||||
gpm
|
||||
emacs
|
||||
groff
|
||||
graphviz
|
||||
python26
|
||||
python27
|
@ -1,28 +0,0 @@
|
||||
tcltk
|
||||
libxml2
|
||||
libpango
|
||||
libatk
|
||||
gettext
|
||||
libnfsidmap
|
||||
libXext
|
||||
libidn
|
||||
libtiff
|
||||
liblcms
|
||||
python
|
||||
glib
|
||||
libcanberra
|
||||
avahi
|
||||
gpm
|
||||
emacs
|
||||
groff
|
||||
soprano
|
||||
livecd-tools
|
||||
tracker
|
||||
graphviz
|
||||
PackageKit
|
||||
apache-ant
|
||||
libpeas
|
||||
libalsa-plugins
|
||||
libproxy
|
||||
python26
|
||||
python27
|
@ -22,12 +22,12 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
find /var/autoport/$a/tmp/ -maxdepth 1 -ctime +25 -exec rm -rf {} \;
|
||||
elif [ "${AUTOPORT_UPDATE[$i]}" ]; then
|
||||
clean /var/autodist ${AUTOPORT_ARCH[$i]}
|
||||
find /var/tmp/autodist/ -maxdepth 1 -ctime +25 -exec rm -rf {} \;
|
||||
find /var/autodist-tmp/ -maxdepth 1 -ctime +25 -exec rm -rf {} \;
|
||||
elif [ "${AUTOPORT_NATIVE[$i]}" -a "${AUTOPORT_CHROOT_USER[$i]}" ]; then
|
||||
WORKINGHOME=`getent passwd ${AUTOPORT_CHROOT_USER[$i]} | cut -d: -f6`
|
||||
if [ -e $WORKINGHOME ]; then
|
||||
clean $WORKINGHOME ${AUTOPORT_ARCH[$i]}
|
||||
fi
|
||||
find /var/tmp/autodist/ -maxdepth 1 -ctime +25 -exec rm -rf {} \;
|
||||
find /var/autodist-tmp/ -maxdepth 1 -ctime +25 -exec rm -rf {} \;
|
||||
fi
|
||||
done
|
||||
|
@ -1,16 +1,20 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# autodist-upstream-updates daily cron script
|
||||
# (c) 2008-2012 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
# (c) 2008-2014 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
#
|
||||
. /etc/autodist/config
|
||||
REPOSITORY=devel
|
||||
/usr/sbin/autodist-upstream-updates -q -h -u -r $REPOSITORY > $LOCAL_REPS_BASE_DIR/distromatic/$REPOSITORY/_popular.html
|
||||
. /etc/sysconfig/autoport
|
||||
|
||||
REPOSITORY=milestone1-1.1
|
||||
/usr/sbin/autodist-upstream-updates -q -h -u -r $REPOSITORY > $LOCAL_REPS_BASE_DIR/distromatic/$REPOSITORY/_popular.html
|
||||
if [ ! "$AUTOPORT_UPDATE_NO_DISTROMATIC" ]; then
|
||||
REPOSITORY=devel
|
||||
/usr/sbin/autodist-upstream-updates -q -h -u -r $REPOSITORY > $LOCAL_REPS_BASE_DIR/distromatic/$REPOSITORY/_popular.html
|
||||
|
||||
REPOSITORY=milestone2
|
||||
/usr/sbin/autodist-upstream-updates -q -h -u -r $REPOSITORY > $LOCAL_REPS_BASE_DIR/distromatic/$REPOSITORY/_popular.html
|
||||
REPOSITORY=milestone1-1.1
|
||||
/usr/sbin/autodist-upstream-updates -q -h -u -r $REPOSITORY > $LOCAL_REPS_BASE_DIR/distromatic/$REPOSITORY/_popular.html
|
||||
|
||||
REPOSITORY=milestone2
|
||||
/usr/sbin/autodist-upstream-updates -q -h -u -r $REPOSITORY > $LOCAL_REPS_BASE_DIR/distromatic/$REPOSITORY/_popular.html
|
||||
fi
|
||||
|
||||
exit 0
|
||||
|
@ -7,6 +7,12 @@
|
||||
. /etc/sysconfig/autoport
|
||||
|
||||
ME=`basename $0`
|
||||
|
||||
# FIXME: parametrize automaint call
|
||||
if [ ! "$AUTOPORT_UPDATE_NO_AUTOMAINT" ]; then
|
||||
automaint -s devel-autodist -d devel -p devel-makedist
|
||||
fi
|
||||
|
||||
[ "$$" == "`pidof -x $ME`" -o "$$" == "`pidof -x 60-autodist-update`" ] || {
|
||||
# echo "Warning: $ME script already running; exiting."
|
||||
exit 0
|
||||
@ -47,8 +53,10 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
REPLASTLOGFILE=$LOCAL_REPS_BASE_DIR/$r/autodist-last.log
|
||||
|
||||
if [ "${AUTOPORT_UPDATE[$i]}" ]; then
|
||||
pid_check
|
||||
distromatic -q -t $DISTROMATIC_REPOSITORY --gensrcpkglist > $LOCAL_REPS_BASE_DIR/$DISTROMATIC_REPOSITORY/srcpkglist
|
||||
if [ ! "$AUTOPORT_UPDATE_NO_DISTROMATIC" ]; then
|
||||
pid_check
|
||||
distromatic -q -t $DISTROMATIC_REPOSITORY --gensrcpkglist > $LOCAL_REPS_BASE_DIR/$DISTROMATIC_REPOSITORY/srcpkglist 2>/dev/null
|
||||
fi
|
||||
|
||||
pid_check
|
||||
autodist-upstream-updates -q -h -u -r $DISTROMATIC_REPOSITORY -o $r \
|
||||
|
@ -53,23 +53,6 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
echo "+ Autoport start at `date`" > $LOGFILE
|
||||
echo "============================================" >> $LOGFILE
|
||||
|
||||
# if [ "${AUTOPORT_CHROOT[$i]}" ]; then
|
||||
# a=${AUTOPORT_CHROOT[$i]}
|
||||
# # sudo mount -o bind /proc /var/autoport/$a/proc
|
||||
# [[ "`/usr/bin/tty`" != "not a tty" ]] && echo "Updating packages in $a chroot environment"
|
||||
# echo "= Updating packages in $a chroot environment..." >> $LOGFILE
|
||||
# LANG=C /usr/sbin/chroot /var/autoport/$a smart update --quiet > /dev/null
|
||||
# LANG=C /usr/sbin/chroot /var/autoport/$a smart upgrade -y >> $LOGFILE
|
||||
# echo "= Working on $r($a) in chroot mode..." >> $LOGFILE
|
||||
# [[ "`/usr/bin/tty`" != "not a tty" ]] && echo "Working on $r($a) in chroot mode" >> $LOGFILE
|
||||
# # disable service restarts
|
||||
# mv /var/autoport/$a/sbin/service /var/autoport/$a/sbin/service.autoport
|
||||
# ln -s /bin/true /var/autoport/$a/sbin/service
|
||||
# $CMD_PREFIX /usr/sbin/chroot /var/autoport/$a su -l ${AUTOPORT_CHROOT_USER[$i]} -c "autoport -b -r $r" >> $LOGFILE
|
||||
# mv /var/autoport/$a/sbin/service.autoport /var/autoport/$a/sbin/service
|
||||
# cat /var/autoport/$a/home/${AUTOPORT_CHROOT_USER[$i]}/.autoport/${AUTOPORT_ARCH[$i]}/$r-current.log >> $LOGFILE
|
||||
# fi
|
||||
|
||||
if [ "${AUTOPORT_NATIVE[$i]}" ]; then
|
||||
a=${AUTOPORT_ARCH[$i]}
|
||||
[[ "`/usr/bin/tty`" != "not a tty" ]] && echo "Updating packages in $a native environment"
|
||||
@ -78,7 +61,8 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
LANG=C smart upgrade -y >> $LOGFILE
|
||||
echo "= Working on $r($a) in native mode" >> $LOGFILE
|
||||
su -l ${AUTOPORT_CHROOT_USER[$i]} -c "$CMD_PREFIX autoport -b -r $r" >> $LOGFILE
|
||||
cat /var/autodist/.autoport/$a/$r-current.log >> $LOGFILE
|
||||
AUTODIST_HOME=`getent passwd ${AUTOPORT_CHROOT_USER[$i]} | cut -d: -f6`
|
||||
cat $AUTODIST_HOME/.autoport/$a/$r-current.log >> $LOGFILE
|
||||
fi
|
||||
|
||||
# if [ "${AUTOPORT_CROSS[$i]}" ]; then
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# openmamba-autobuild-autoport daily cron script
|
||||
# (c) 2008-2012 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
# (c) 2008-2014 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
#
|
||||
#. /etc/sysconfig/openmamba-central
|
||||
. /etc/sysconfig/autoport
|
||||
@ -44,6 +44,7 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
#echo "= Updating packages in ${AUTOPORT_CHROOT[$i]} chroot environment..." >> $LOGFILE
|
||||
LANG=C /usr/sbin/chroot /var/autoport/${AUTOPORT_CHROOT[$i]} smart update --quiet > /dev/null
|
||||
LANG=C /usr/sbin/chroot /var/autoport/${AUTOPORT_CHROOT[$i]} smart upgrade -y > /dev/null
|
||||
[ "${AUTOPORT_CHROOT_ICECREAM[$i]}" ] && LANG=C /usr/sbin/chroot /var/autoport/${AUTOPORT_CHROOT[$i]} /etc/init.d/icecream start
|
||||
fi
|
||||
|
||||
for r in ${AUTOPORT_REPOSITORIES[$i]}; do
|
||||
@ -71,10 +72,12 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
if [ "${AUTOPORT_CHROOT[$i]}" ]; then
|
||||
echo "= Working on $r(${AUTOPORT_CHROOT[$i]}) in chroot mode..." >> $LOGFILE
|
||||
[[ "`/usr/bin/tty`" != "not a tty" ]] && echo "Working on $r(${AUTOPORT_CHROOT[$i]}) in chroot mode" >> $LOGFILE
|
||||
#echo "DEBUG: $CMD_PREFIX /usr/sbin/chroot /var/autoport/${AUTOPORT_CHROOT[$i]} su -l ${AUTOPORT_CHROOT_USER[$i]} -c \"autoport -b -r $r\"" >> $LOGFILE
|
||||
$CMD_PREFIX /usr/sbin/chroot /var/autoport/${AUTOPORT_CHROOT[$i]} su -l ${AUTOPORT_CHROOT_USER[$i]} -c "autoport -b -r $r" >> $LOGFILE
|
||||
cat /var/autoport/${AUTOPORT_CHROOT[$i]}/home/${AUTOPORT_CHROOT_USER[$i]}/.autoport/${AUTOPORT_ARCH[$i]}/$r-current.log >> $LOGFILE
|
||||
#echo "DEBUG: cat /var/autoport/${AUTOPORT_CHROOT[$i]}/home/${AUTOPORT_CHROOT_USER[$i]}/.autoport/${AUTOPORT_ARCH[$i]}/$r-current.log" >> $LOGFILE
|
||||
if [ "${AUTOPORT_CHROOT[$i]}" = "autodist" ]; then
|
||||
cat /var/autoport/${AUTOPORT_CHROOT[$i]}/var/autodist/.autoport/${AUTOPORT_ARCH[$i]}/$r-current.log >> $LOGFILE
|
||||
else
|
||||
cat /var/autoport/${AUTOPORT_CHROOT[$i]}/home/${AUTOPORT_CHROOT_USER[$i]}/.autoport/${AUTOPORT_ARCH[$i]}/$r-current.log >> $LOGFILE
|
||||
fi
|
||||
fi
|
||||
|
||||
# if [ "${AUTOPORT_NATIVE[$i]}" ]; then
|
||||
@ -101,7 +104,8 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
done
|
||||
|
||||
if [ "${AUTOPORT_CHROOT[$i]}" ]; then
|
||||
mv /var/autoport/${AUTOPORT_CHROOT[$i]}/sbin/service.autoport /var/autoport/${AUTOPORT_CHROOT[$i]}/sbin/service
|
||||
mv /var/autoport/${AUTOPORT_CHROOT[$i]}/sbin/service.autoport /var/autoport/${AUTOPORT_CHROOT[$i]}/sbin/service
|
||||
[ "${AUTOPORT_CHROOT_ICECREAM[$i]}" ] && LANG=C /usr/sbin/chroot /var/autoport/${AUTOPORT_CHROOT[$i]} /etc/init.d/icecream stop
|
||||
fi
|
||||
|
||||
done
|
||||
|
8
etc/logrotate.d/webbuild
Normal file
8
etc/logrotate.d/webbuild
Normal file
@ -0,0 +1,8 @@
|
||||
/var/webbuild/access_log {
|
||||
monthly
|
||||
rotate 12
|
||||
copytruncate
|
||||
compress
|
||||
notifempty
|
||||
missingok
|
||||
}
|
@ -2,22 +2,43 @@
|
||||
# autoport global configuration
|
||||
#
|
||||
local_ftp=/var/ftp/pub/openmamba/
|
||||
|
||||
#AUTOBUILDS_STATUS_URL="http://www.openmamba.org/distribution/autobuilds.html"
|
||||
#AUTOPORT_ENABLE=1
|
||||
#AUTOPORT_CGI_HOST=(http://localhost/cgi-bin/autodist http://arm-sdk/cgi-bin/autodist)
|
||||
# Disabled by default because they would require local repository
|
||||
AUTOPORT_UPDATE_NO_AUTOMAINT=1
|
||||
AUTOPORT_UPDATE_NO_DISTROMATIC=1
|
||||
#AUTOPORT_CGI_HOST=(http://localhost/cgi-bin/autodist)
|
||||
#AUTOPORT_WEBBUILD_HOST=http://localhost/webbuild.html
|
||||
#ICECREAM_MONITOR_HOST=localhost
|
||||
|
||||
AUTOPORT_DEVEL_IMPORT_REPOSITORIES="devel-makedist devel devel-games devel-autodist devel-gnome \
|
||||
devel-kde4 devel-xorg devel-kernel devel-misc devel-java devel-future devel-past devel-contrib devel-contrib-java"
|
||||
|
||||
AUTOPORT_DEVEL_RELEASE_REPOSITORIES="milestone2-makedist milestone2-kernel milestone2-kernel-next"
|
||||
|
||||
AUTOPORT_MILESTONE2_IMPORT_REPOSITORIES="milestone2-makedist milestone2-updates milestone2-kernel \
|
||||
milestone2-kde4 milestone2-xorg milestone2-kernel-next milestone2"
|
||||
|
||||
#AUTOPORT_ARCH[0]=x86_64
|
||||
#AUTOPORT_DISABLE[0]=
|
||||
#AUTOPORT_CHROOT[0]=devel-x86_64
|
||||
#AUTOPORT_CHROOT_USER[0]=sdk
|
||||
#AUTOPORT_CHROOT_ICECREAM[0]=1
|
||||
#AUTOPORT_CROSS[0]=
|
||||
#AUTOPORT_NATIVE[0]=
|
||||
#AUTOPORT_REPOSITORIES[0]="devel-makedist"
|
||||
#AUTOPORT_BASE_REPOSITORY[0]="devel-makedist"
|
||||
#AUTOPORT_IMPORT_REPOSITORIES[0]="$AUTOPORT_DEVEL_IMPORT_REPOSITORIES"
|
||||
|
||||
#AUTOPORT_ARCH[1]=i586
|
||||
#AUTOPORT_DISABLE[1]=
|
||||
#AUTOPORT_CHROOT[1]=milestone2-i586
|
||||
#AUTOPORT_CHROOT_USER[1]=sdk
|
||||
#AUTOPORT_CHROOT_ICECREAM[1]=1
|
||||
#AUTOPORT_CROSS[1]=
|
||||
#AUTOPORT_NATIVE[1]=
|
||||
#AUTOPORT_BASE_REPOSITORY[0]="devel-autodist"
|
||||
#AUTOPORT_REPOSITORIES[1]="milestone2-makedist"
|
||||
AUTOPORT_CGI_HOST=(http://localhost/cgi-bin/autodist http://192.168.0.100/cgi-bin/autodist)
|
||||
#AUTOPORT_BASE_REPOSITORY[0]="milestone2-makedist"
|
||||
#AUTOPORT_IMPORT_REPOSITORIES[0]="$AUTOPORT_DEVEL_IMPORT_REPOSITORIES"
|
||||
|
69
webbuild/html/autobuilds.html
Normal file
69
webbuild/html/autobuilds.html
Normal file
@ -0,0 +1,69 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html><head>
|
||||
<meta content="text/html; charset=utf-8" http-equiv="content-type">
|
||||
|
||||
<link rel="shortcut icon" type="image/x-icon" href="/images/webbuild.ico" />
|
||||
<!-- styles needed by jScrollPane -->
|
||||
<link type="text/css" href="/scripts/jquery.jscrollpane.css" rel="stylesheet" media="all" >
|
||||
<!-- latest jQuery direct from google's CDN -->
|
||||
<script type="text/javascript" src="/scripts/jquery.js"></script>
|
||||
<!-- the mousewheel plugin - optional to provide mousewheel support -->
|
||||
<script type="text/javascript" src="/scripts/jquery.mousewheel.js"></script>
|
||||
<!-- the jScrollPane script -->
|
||||
<script type="text/javascript" src="/scripts/jquery.jscrollpane.min.js"></script>
|
||||
<link rel="stylesheet" type="text/css" href="/styles/webbuild.css">
|
||||
<script type="text/javascript" src="/scripts/socialbox.js"></script>
|
||||
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
var lastupdate = 0;
|
||||
var reloadtime = 0;
|
||||
|
||||
function ajax_getvalues() {
|
||||
var url = window.location.protocol+"//"+window.location.hostname+"/cgi-bin/autodist?FORMAT=xml&"+window.location.href.replace(/.*\?/,"");
|
||||
if (window.XMLHttpRequest)
|
||||
xmlhttp = new XMLHttpRequest();
|
||||
else if (window.ActiveXObject)
|
||||
xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
|
||||
else
|
||||
return;
|
||||
document.getElementById("noajax_msg").innerHTML = "";
|
||||
xmlhttp.onreadystatechange = function() {
|
||||
if (xmlhttp.readyState != 4)
|
||||
return;
|
||||
var xmldoc = xmlhttp.responseXML.documentElement;
|
||||
document.getElementById("output").innerHTML = xmldoc.getElementsByTagName("output")[0].childNodes[0].nodeValue;
|
||||
reloadtime = xmldoc.getElementsByTagName("reloadtime")[0].childNodes[0].nodeValue;
|
||||
lastupdate = (+new Date());
|
||||
setTimeout("ajax_getvalues()", reloadtime);
|
||||
}
|
||||
xmlhttp.open("GET", url, true);
|
||||
xmlhttp.send(null);
|
||||
}
|
||||
//-->
|
||||
</script>
|
||||
</head><body>
|
||||
<div id=container style="position:relative;width:894px;height:auto;top:0;left:0;margin-left:auto;margin-right:auto;">
|
||||
<table width="100%"><tr><td>
|
||||
<tr><td valign="middle">
|
||||
<table align="center"><tr>
|
||||
<td colspan=2><img src="/images/webbuild.png" alt="build automatici">
|
||||
<b>- Autodist - Build automatici</b>
|
||||
</td>
|
||||
</tr></table>
|
||||
</td></tr>
|
||||
<tr><td>
|
||||
<div id="noajax_msg"><p>Il supporto per AJAX non è abilitato nel tuo browser. L'aggiornamento live non sarà disponibile, premi Ricarica per aggiornare la pagina.</p></div>
|
||||
<span id="output">Caricamento in corso, attendere...</span>
|
||||
<script>
|
||||
ajax_getvalues("");
|
||||
$("#output").mousemove(function(event) {
|
||||
lastupdatetime = (+new Date()) - lastupdate; // milliseconds since last update
|
||||
// var msg = "called " + lastupdatetime + "ms ago";
|
||||
if (lastupdatetime > reloadtime) { lastupdate = lastupdatetime; ajax_getvalues(); }
|
||||
});
|
||||
</script>
|
||||
</td></tr>
|
||||
</table>
|
||||
</div>
|
||||
</body></html>
|
BIN
webbuild/html/images/inprogress.gif
Normal file
BIN
webbuild/html/images/inprogress.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 537 B |
BIN
webbuild/html/images/webbuild.ico
Normal file
BIN
webbuild/html/images/webbuild.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.1 KiB |
@ -1,5 +1,11 @@
|
||||
var url = "/cgi-bin/webbuild"
|
||||
|
||||
/*function socialbox_refresh_times() {
|
||||
socialbox_refresh_times(false);
|
||||
}*/
|
||||
|
||||
var socialbox_fullrefresh_count = 0;
|
||||
|
||||
function socialbox_refresh_times() {
|
||||
var times = document.getElementsByName("socialtime");
|
||||
var datenow = new Date();
|
||||
@ -12,20 +18,28 @@ function socialbox_refresh_times() {
|
||||
var socialtime = times[i].attributes[1].value;
|
||||
}
|
||||
var timeago = utcnow - socialtime;
|
||||
var daysago = parseInt(timeago / 86400);
|
||||
var hoursago = parseInt(timeago / 3600 % 24);
|
||||
var minutesago = parseInt(timeago / 60 % 60);
|
||||
var secondsago = parseInt(timeago % 60);
|
||||
times[i].innerHTML = "(";
|
||||
if (daysago > 1) times[i].innerHTML += daysago + " days";
|
||||
else if (daysago == 1) times[i].innerHTML += "1 day, " + hoursago + " hours";
|
||||
else if (hoursago > 1) times[i].innerHTML += hoursago + " hours";
|
||||
else if (hoursago == 1) times[i].innerHTML += "1 hour, " + minutesago + " minutes";
|
||||
else if (minutesago > 1) times[i].innerHTML += minutesago + " minutes";
|
||||
else if (minutesago == 1) times[i].innerHTML += "1 minute, " + secondsago + " seconds";
|
||||
else times[i].innerHTML += secondsago + " seconds";
|
||||
times[i].innerHTML += " ago) ";
|
||||
if ((times[i].innerHTML == "") ||
|
||||
(timeago <= 120) || // update every 15 secs if < 2 min
|
||||
(timeago <= 7200 && (socialbox_fullrefresh_count % 4 == 0)) || // update every minute if < 120 min
|
||||
(timeago <= 86400 && (socialbox_fullrefresh_count % 120 == 0)) || // update every thirty minutes if < 1 day
|
||||
(socialbox_fullrefresh_count >= 240)) // else update all every hour
|
||||
{
|
||||
var daysago = parseInt(timeago / 86400);
|
||||
var hoursago = parseInt(timeago / 3600 % 24);
|
||||
var minutesago = parseInt(timeago / 60 % 60);
|
||||
var secondsago = parseInt(timeago % 60);
|
||||
times[i].innerHTML = "(";
|
||||
if (daysago > 1) times[i].innerHTML += daysago + " days";
|
||||
else if (daysago == 1) times[i].innerHTML += "1 day, " + hoursago + " hours";
|
||||
else if (hoursago > 1) times[i].innerHTML += hoursago + " hours";
|
||||
else if (hoursago == 1) times[i].innerHTML += "1 hour, " + minutesago + " minutes";
|
||||
else if (minutesago > 1) times[i].innerHTML += minutesago + " minutes";
|
||||
else if (minutesago == 1) times[i].innerHTML += "1 minute, " + secondsago + " seconds";
|
||||
else times[i].innerHTML += secondsago + " seconds";
|
||||
times[i].innerHTML += " ago) ";
|
||||
}
|
||||
}
|
||||
if (socialbox_fullrefresh_count++ >= 240) socialbox_fullrefresh_count = 0;
|
||||
}
|
||||
|
||||
var socialbox_interval = null;
|
||||
@ -33,7 +47,6 @@ var socialbox_reloadtime = 15000;
|
||||
|
||||
function ajax_getvalues_refresh(request,user,user_email,secret) {
|
||||
var fromid = 0;
|
||||
//alert("refresh");
|
||||
if (socialbox_interval != null) {
|
||||
clearInterval(socialbox_interval);
|
||||
}
|
||||
@ -72,6 +85,7 @@ function ajax_getvalues_refresh(request,user,user_email,secret) {
|
||||
}
|
||||
if (xmldoc.getElementsByTagName("processes")[0] != undefined) {
|
||||
document.getElementById("processes").innerHTML = xmldoc.getElementsByTagName("processes")[0].childNodes[0].nodeValue;
|
||||
$(function() { $('.scroll-pane3').jScrollPane({scrollbarWidth:10}); });
|
||||
}
|
||||
$(function() { $('.scroll-pane').jScrollPane({scrollbarWidth:10}); });
|
||||
// lastupdate = (+new Date());
|
||||
|
@ -31,33 +31,96 @@ function checkEnter(event) {
|
||||
return false;
|
||||
}
|
||||
|
||||
function checkMinLength(st,len) {
|
||||
if (st.length >= len) return true;
|
||||
return false;
|
||||
return false;
|
||||
}
|
||||
|
||||
function suggestSpecName(url) {
|
||||
var version="";
|
||||
var url=document.getElementById("speccreateurl").value;
|
||||
if (url.indexOf('&') > 0) url=url.substring(0,url.indexOf('&')+1);
|
||||
var filename=url.substring(url.lastIndexOf('/')+1);
|
||||
if (filename.indexOf('.') > 0) filename=filename.substring(0,filename.indexOf('.'));
|
||||
if (filename.lastIndexOf('-') > 0) {
|
||||
var version=filename.substring(filename.lastIndexOf('-')+1);
|
||||
filename=filename.substring(0,filename.lastIndexOf('-')).toLowerCase();
|
||||
if (url.indexOf('?') > 0) url=url.substring(0,url.indexOf('?'));
|
||||
var specname=url.substring(url.lastIndexOf('/')+1);
|
||||
var extension;
|
||||
while (i=specname.lastIndexOf('.')) {
|
||||
e=specname.substring(i);
|
||||
if (e != ".tar" && e != ".gz" && e != ".zip" && e != ".bz2" &&
|
||||
e != ".xz" && e != ".tgz" && e != ".zip" && e != ".src" &&
|
||||
e != ".orig" && e != ".gem" ) break;
|
||||
extension=specname.substring(i+1);
|
||||
specname=specname.substring(0,i);
|
||||
}
|
||||
i=specname.lastIndexOf('_');
|
||||
e=specname.substring(i);
|
||||
if (e == "_src" || e == "_orig") specname=specname.substring(0,i);
|
||||
i=specname.lastIndexOf('-');
|
||||
e=specname.substring(i);
|
||||
if (e == "-src" || e == "-orig") specname=specname.substring(0,i);
|
||||
if (specname.lastIndexOf('-') > 0) {
|
||||
version=specname.substring(specname.lastIndexOf('-')+1);
|
||||
specname=specname.substring(0,specname.lastIndexOf('-'));
|
||||
} else if (specname.lastIndexOf('_') > 0) {
|
||||
version=specname.substring(specname.lastIndexOf('_')+1);
|
||||
specname=specname.substring(0,specname.lastIndexOf('_'));
|
||||
}
|
||||
document.getElementById("speccreateurl").value=url;
|
||||
document.getElementById("speccreatename").value=filename;
|
||||
document.getElementById("speccreateversion").value=version;
|
||||
if (filename) {
|
||||
if (url.search("cpan.org") >= 0) {
|
||||
specname="perl-"+specname;
|
||||
} else if (url.search("haskell.org") >= 0) {
|
||||
specname="ghc-"+specname;
|
||||
} else if (extension == "gem") {
|
||||
specname="ruby-"+specname;
|
||||
} else {
|
||||
specname=specname.toLowerCase();
|
||||
}
|
||||
if ((url.search("git://") >= 0) || (url.indexOf(".git", url.length - 4) != -1)) {
|
||||
document.getElementById("speccreategitbranch").disabled=false;
|
||||
} else {
|
||||
document.getElementById("speccreategitbranch").disabled=true;
|
||||
document.getElementById("speccreateversion").value=version;
|
||||
}
|
||||
if (url.indexOf(".git", url.length - 4) != -1) {
|
||||
document.getElementById("speccreategitbranch").value="master";
|
||||
specname=specname.substring(0,specname.lastIndexOf('.git'));
|
||||
}
|
||||
document.getElementById("speccreatename").value=specname;
|
||||
if (url) {
|
||||
document.getElementById("speccreatename").disabled=false;
|
||||
document.getElementById("speccreateversion").disabled=false;
|
||||
document.getElementById("speccreatetype").disabled=false;
|
||||
document.getElementById("speccreatebutton").disabled=false;
|
||||
} else {
|
||||
document.getElementById("speccreatename").disabled=true;
|
||||
document.getElementById("speccreateversion").disabled=true;
|
||||
document.getElementById("speccreatetype").disabled=true;
|
||||
document.getElementById("speccreatebutton").disabled=true;
|
||||
}
|
||||
if (filename.search("perl-") >= 0) {
|
||||
if (extension == "gem") {
|
||||
for (var j=0;j<document.getElementById("speccreatetype").length;j++) {
|
||||
if (document.getElementById("speccreatetype").options[j].value == "ruby")
|
||||
document.getElementById("speccreatetype").options[j].selected=true;
|
||||
};
|
||||
} else if (specname.search("perl-") >= 0) {
|
||||
for (var j=0;j<document.getElementById("speccreatetype").length;j++) {
|
||||
if (document.getElementById("speccreatetype").options[j].value == "perl")
|
||||
document.getElementById("speccreatetype").options[j].selected=true;
|
||||
};
|
||||
} else if (filename.search("python-") >= 0) {
|
||||
} else if ((specname.search("python-") >= 0) || (specname.substring(0,2) == "py")) {
|
||||
for (var j=0;j<document.getElementById("speccreatetype").length;j++) {
|
||||
if (document.getElementById("speccreatetype").options[j].value == "python")
|
||||
document.getElementById("speccreatetype").options[j].selected=true;
|
||||
};
|
||||
} else if (specname.substring(0,4) == "ghc-") {
|
||||
for (var j=0;j<document.getElementById("speccreatetype").length;j++) {
|
||||
if (document.getElementById("speccreatetype").options[j].value == "ghc")
|
||||
document.getElementById("speccreatetype").options[j].selected=true;
|
||||
};
|
||||
} else if (url.search("kde.org") >= 0) {
|
||||
for (var j=0;j<document.getElementById("speccreatetype").length;j++) {
|
||||
if (document.getElementById("speccreatetype").options[j].value == "kde4")
|
||||
document.getElementById("speccreatetype").options[j].selected=true;
|
||||
};
|
||||
} else {
|
||||
for (var j=0;j<document.getElementById("speccreatetype").length;j++) {
|
||||
if (document.getElementById("speccreatetype").options[j].value == "library")
|
||||
@ -79,3 +142,227 @@ function replaceHTML(el, html) {
|
||||
to the new element, which can be used to restore variable references. */
|
||||
return newEl;
|
||||
};
|
||||
|
||||
function getDownload(request) {
|
||||
var url = "/cgi-bin/webbuild"
|
||||
|
||||
if (request != "")
|
||||
request=request+"&USER="+user+"&USER_EMAIL="+user_email+"&SECRET="+encodeURIComponent(secret);
|
||||
else
|
||||
request="USER="+user+"&USER_EMAIL="+user_email+"&SECRET="+encodeURIComponent(secret);
|
||||
|
||||
url = url + "?" + request;
|
||||
|
||||
// var hiddenIFrameID = 'hiddenDownloader', iframe = document.getElementById(hiddenIFrameID);
|
||||
// if (iframe == null) {
|
||||
iframe = document.createElement('iframe');
|
||||
// iframe.id = hiddenIFrameID;
|
||||
iframe.style.display = 'none';
|
||||
// }
|
||||
iframe.src = url;
|
||||
document.body.appendChild(iframe);
|
||||
}
|
||||
|
||||
// ajaxFileUpload
|
||||
|
||||
jQuery.extend({
|
||||
|
||||
|
||||
createUploadIframe: function(id, uri)
|
||||
{
|
||||
//create frame
|
||||
var frameId = 'jUploadFrame' + id;
|
||||
var iframeHtml = '<iframe id="' + frameId + '" name="' + frameId + '" style="position:absolute; top:-9999px; left:-9999px"';
|
||||
if(window.ActiveXObject)
|
||||
{
|
||||
if(typeof uri== 'boolean'){
|
||||
iframeHtml += ' src="' + 'javascript:false' + '"';
|
||||
|
||||
}
|
||||
else if(typeof uri== 'string'){
|
||||
iframeHtml += ' src="' + uri + '"';
|
||||
|
||||
}
|
||||
}
|
||||
iframeHtml += ' />';
|
||||
jQuery(iframeHtml).appendTo(document.body);
|
||||
|
||||
return jQuery('#' + frameId).get(0);
|
||||
},
|
||||
createUploadForm: function(id, fileElementId, data)
|
||||
{
|
||||
//create form
|
||||
var formId = 'jUploadForm' + id;
|
||||
var fileId = 'jUploadFile' + id;
|
||||
var form = jQuery('<form action="" method="POST" name="' + formId + '" id="' + formId + '" enctype="multipart/form-data"></form>');
|
||||
if(data)
|
||||
{
|
||||
for(var i in data)
|
||||
{
|
||||
jQuery('<input type="hidden" name="' + i + '" value="' + data[i] + '" />').appendTo(form);
|
||||
}
|
||||
}
|
||||
var oldElement = jQuery('#' + fileElementId);
|
||||
var newElement = jQuery(oldElement).clone();
|
||||
jQuery(oldElement).attr('id', fileId);
|
||||
jQuery(oldElement).before(newElement);
|
||||
jQuery(oldElement).appendTo(form);
|
||||
|
||||
|
||||
|
||||
//set attributes
|
||||
jQuery(form).css('position', 'absolute');
|
||||
jQuery(form).css('top', '-1200px');
|
||||
jQuery(form).css('left', '-1200px');
|
||||
jQuery(form).appendTo('body');
|
||||
return form;
|
||||
},
|
||||
|
||||
ajaxFileUpload: function(s) {
|
||||
// TODO introduce global settings, allowing the client to modify them for all requests, not only timeout
|
||||
s = jQuery.extend({}, jQuery.ajaxSettings, s);
|
||||
var id = new Date().getTime()
|
||||
var form = jQuery.createUploadForm(id, s.fileElementId, (typeof(s.data)=='undefined'?false:s.data));
|
||||
var io = jQuery.createUploadIframe(id, s.secureuri);
|
||||
var frameId = 'jUploadFrame' + id;
|
||||
var formId = 'jUploadForm' + id;
|
||||
// Watch for a new set of requests
|
||||
if ( s.global && ! jQuery.active++ )
|
||||
{
|
||||
jQuery.event.trigger( "ajaxStart" );
|
||||
}
|
||||
var requestDone = false;
|
||||
// Create the request object
|
||||
var xml = {}
|
||||
if ( s.global )
|
||||
jQuery.event.trigger("ajaxSend", [xml, s]);
|
||||
// Wait for a response to come back
|
||||
var uploadCallback = function(isTimeout)
|
||||
{
|
||||
var io = document.getElementById(frameId);
|
||||
try
|
||||
{
|
||||
if(io.contentWindow)
|
||||
{
|
||||
xml.responseText = io.contentWindow.document.body?io.contentWindow.document.body.innerHTML:null;
|
||||
xml.responseXML = io.contentWindow.document.XMLDocument?io.contentWindow.document.XMLDocument:io.contentWindow.document;
|
||||
|
||||
}else if(io.contentDocument)
|
||||
{
|
||||
xml.responseText = io.contentDocument.document.body?io.contentDocument.document.body.innerHTML:null;
|
||||
xml.responseXML = io.contentDocument.document.XMLDocument?io.contentDocument.document.XMLDocument:io.contentDocument.document;
|
||||
}
|
||||
}catch(e)
|
||||
{
|
||||
jQuery.handleError(s, xml, null, e);
|
||||
}
|
||||
if ( xml || isTimeout == "timeout")
|
||||
{
|
||||
requestDone = true;
|
||||
var status;
|
||||
try {
|
||||
status = isTimeout != "timeout" ? "success" : "error";
|
||||
// Make sure that the request was successful or notmodified
|
||||
if ( status != "error" )
|
||||
{
|
||||
// process the data (runs the xml through httpData regardless of callback)
|
||||
var data = jQuery.uploadHttpData( xml, s.dataType );
|
||||
// If a local callback was specified, fire it and pass it the data
|
||||
if ( s.success )
|
||||
s.success( data, status );
|
||||
|
||||
// Fire the global callback
|
||||
if( s.global )
|
||||
jQuery.event.trigger( "ajaxSuccess", [xml, s] );
|
||||
} else
|
||||
jQuery.handleError(s, xml, status);
|
||||
} catch(e)
|
||||
{
|
||||
status = "error";
|
||||
jQuery.handleError(s, xml, status, e);
|
||||
}
|
||||
|
||||
// The request was completed
|
||||
if( s.global )
|
||||
jQuery.event.trigger( "ajaxComplete", [xml, s] );
|
||||
|
||||
// Handle the global AJAX counter
|
||||
if ( s.global && ! --jQuery.active )
|
||||
jQuery.event.trigger( "ajaxStop" );
|
||||
|
||||
// Process result
|
||||
if ( s.complete )
|
||||
s.complete(xml, status);
|
||||
|
||||
jQuery(io).unbind()
|
||||
|
||||
setTimeout(function()
|
||||
{ try
|
||||
{
|
||||
jQuery(io).remove();
|
||||
jQuery(form).remove();
|
||||
|
||||
} catch(e)
|
||||
{
|
||||
jQuery.handleError(s, xml, null, e);
|
||||
}
|
||||
|
||||
}, 100)
|
||||
|
||||
xml = null
|
||||
|
||||
}
|
||||
}
|
||||
// Timeout checker
|
||||
if ( s.timeout > 0 )
|
||||
{
|
||||
setTimeout(function(){
|
||||
// Check to see if the request is still happening
|
||||
if( !requestDone ) uploadCallback( "timeout" );
|
||||
}, s.timeout);
|
||||
}
|
||||
try
|
||||
{
|
||||
|
||||
var form = jQuery('#' + formId);
|
||||
jQuery(form).attr('action', s.url);
|
||||
jQuery(form).attr('method', 'POST');
|
||||
jQuery(form).attr('target', frameId);
|
||||
if(form.encoding)
|
||||
{
|
||||
jQuery(form).attr('encoding', 'multipart/form-data');
|
||||
}
|
||||
else
|
||||
{
|
||||
jQuery(form).attr('enctype', 'multipart/form-data');
|
||||
}
|
||||
jQuery(form).submit();
|
||||
|
||||
} catch(e)
|
||||
{
|
||||
jQuery.handleError(s, xml, null, e);
|
||||
}
|
||||
|
||||
jQuery('#' + frameId).load(uploadCallback );
|
||||
return {abort: function () {}};
|
||||
|
||||
},
|
||||
|
||||
uploadHttpData: function( r, type ) {
|
||||
var data = !type;
|
||||
data = type == "xml" || data ? r.responseXML : r.responseText;
|
||||
// If the type is "script", eval it in global context
|
||||
if ( type == "script" )
|
||||
jQuery.globalEval( data );
|
||||
// Get the JavaScript object, if JSON is used.
|
||||
if ( type == "json" )
|
||||
eval( "data = " + data );
|
||||
// evaluate scripts within html
|
||||
if ( type == "html" )
|
||||
jQuery("<div>").html(data).evalScripts();
|
||||
|
||||
return data;
|
||||
}
|
||||
})
|
||||
|
||||
// end ajaxFileUpload
|
||||
|
@ -113,6 +113,46 @@ input[type="checkbox"] {
|
||||
z-index:20;
|
||||
}
|
||||
|
||||
.windowcontainer {
|
||||
text-align:center;
|
||||
position:fixed;
|
||||
z-index:10 !important;
|
||||
height:100%;
|
||||
width:100%;
|
||||
left:0;
|
||||
top:0;
|
||||
}
|
||||
|
||||
.windowopaquebackground {
|
||||
text-align:center;
|
||||
position:fixed;
|
||||
z-index:10 !important;
|
||||
height:100%;
|
||||
width:100%;
|
||||
left:0;
|
||||
top:0;
|
||||
background-color:black;
|
||||
filter: alpha(opacity=75);
|
||||
-khtml-opacity:0.75;
|
||||
-webkit-opacity:0.75;
|
||||
-moz-opacity:0.75;
|
||||
opacity:0.75;
|
||||
}
|
||||
|
||||
.windowbox {
|
||||
display:inline-block;
|
||||
position:relative;
|
||||
font-size:10pt;
|
||||
padding:5px;
|
||||
margin:100px;
|
||||
margin-right:auto;
|
||||
margin-left:auto;
|
||||
width:auto;
|
||||
background-color:white;
|
||||
border:2px solid #2b6600;
|
||||
z-index:15;
|
||||
}
|
||||
|
||||
.multiselect {
|
||||
font-size:8pt;
|
||||
border:0px;
|
||||
@ -138,14 +178,6 @@ input[type="checkbox"] {
|
||||
border:1px solid #2b6600;
|
||||
}
|
||||
|
||||
.scroll-pane {
|
||||
background-color: #e0f2d0;
|
||||
height:130px;
|
||||
width:200px;
|
||||
overflow:auto;
|
||||
float:right;
|
||||
}
|
||||
|
||||
.searchbox {
|
||||
position:relative;
|
||||
display:block;
|
||||
@ -188,14 +220,23 @@ input[type="checkbox"] {
|
||||
background-color:white;
|
||||
}
|
||||
|
||||
.processes {
|
||||
width:680px;
|
||||
font-size:7pt;
|
||||
.socialbox {
|
||||
float:right;
|
||||
font-size:8pt;
|
||||
padding:0px;
|
||||
height:130px;
|
||||
line-height: 100%;
|
||||
border:1px solid #2b6600;
|
||||
}
|
||||
|
||||
.processes {
|
||||
float:left;
|
||||
font-size:7pt;
|
||||
padding:0px;
|
||||
height:130px;
|
||||
line-height: 130%;
|
||||
margin-bottom: 2px;
|
||||
border:1px solid #2b6600;
|
||||
padding:2px;
|
||||
margin:0;
|
||||
margin-bottom:2px;
|
||||
background-color:#E0F2D0;
|
||||
}
|
||||
|
||||
.notes {
|
||||
@ -236,22 +277,25 @@ input[type="checkbox"] {
|
||||
.matrix {
|
||||
width:100%;
|
||||
height:100%;
|
||||
word-wrap: break-word;
|
||||
overflow:auto;
|
||||
font-size:7pt;
|
||||
border:1px solid #2b6600;
|
||||
padding:2px;
|
||||
margin:0;
|
||||
// border:1px solid #2b6600;
|
||||
padding-right:-2px;
|
||||
padding-bottom:-2px;
|
||||
margin-left:2px;
|
||||
margin-bottom:2px;
|
||||
// background-color:#e0f2d0;
|
||||
-moz-column-count: 2;
|
||||
/* -moz-column-count: 2;
|
||||
-moz-column-gap: 1.5em;
|
||||
-moz-column-rule: none;
|
||||
-webkit-column-count: 2;
|
||||
-webkit-column-gap: 1.5em;
|
||||
-webkit-column-rule: none;
|
||||
/* future proof */
|
||||
/ future proof
|
||||
column-count: 2;
|
||||
column-gap: 1.5em;
|
||||
column-rule: none;
|
||||
column-rule: none;*/
|
||||
}
|
||||
|
||||
.CodeMirror {
|
||||
@ -271,17 +315,12 @@ input[type="checkbox"] {
|
||||
background: #2b6600;
|
||||
}
|
||||
|
||||
.scroll-pane-h {
|
||||
height:272px;
|
||||
width:400px;
|
||||
overflow:auto;
|
||||
white-space:nowrap;
|
||||
}
|
||||
|
||||
.scroll-pane-v {
|
||||
height:272px;
|
||||
width:400px;
|
||||
.scroll-pane {
|
||||
background-color: #e0f2d0;
|
||||
height:130px;
|
||||
width:200px;
|
||||
overflow:auto;
|
||||
float:right;
|
||||
}
|
||||
|
||||
.scroll-pane1 {
|
||||
@ -296,3 +335,25 @@ input[type="checkbox"] {
|
||||
width:390px;
|
||||
overflow:auto;
|
||||
}
|
||||
|
||||
.scroll-pane3 {
|
||||
background-color: #e0f2d0;
|
||||
height:130px;
|
||||
width:685px;
|
||||
overflow:auto;
|
||||
float:right;
|
||||
}
|
||||
|
||||
.scroll-pane3-h {
|
||||
height:272px;
|
||||
width:400px;
|
||||
overflow:auto;
|
||||
white-space:nowrap;
|
||||
}
|
||||
|
||||
.scroll-pane3-v {
|
||||
height:272px;
|
||||
width:400px;
|
||||
overflow:auto;
|
||||
}
|
||||
|
||||
|
@ -1,6 +1,8 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html><head>
|
||||
<meta content="text/html; charset=utf-8" http-equiv="content-type">
|
||||
|
||||
<link rel="shortcut icon" type="image/x-icon" href="/images/webbuild.ico" />
|
||||
<!-- styles needed by jScrollPane -->
|
||||
<link type="text/css" href="/scripts/jquery.jscrollpane.css" rel="stylesheet" media="all" >
|
||||
<!-- latest jQuery direct from google's CDN -->
|
||||
@ -100,6 +102,7 @@ function ajax_getvalues(request,confirm) {
|
||||
secret=getCookie("webbuild-secret");
|
||||
if (!secret) secret="";
|
||||
}
|
||||
|
||||
if (confirm) {
|
||||
document.getElementById("status").innerHTML =
|
||||
'<div class=screencontainer><div class=opaquebackground></div>'+
|
||||
@ -108,12 +111,6 @@ function ajax_getvalues(request,confirm) {
|
||||
return;
|
||||
}
|
||||
document.getElementById("webbuildform").disabled = true;
|
||||
document.getElementById("status").innerHTML =
|
||||
'<div class=opaquebackground>'+
|
||||
'<div style="text-align:left;color:white;position:absolute;left:0;top:0;" id=matrix class=matrix></div>'+
|
||||
'<div style="position:absolute;left:50%;top:50%;"><img src="/images/wait.gif" title="Attendi..."</div>'+
|
||||
'<div style="position:fixed;left:95%;top:95%;color:red;"><a href="javascript:clearid(\'status\');">[x] Close</a></div>'+
|
||||
'</div>';
|
||||
|
||||
if (request != "")
|
||||
request=request+"&USER="+user+"&USER_EMAIL="+user_email+"&SECRET="+encodeURIComponent(secret);
|
||||
@ -129,23 +126,34 @@ function ajax_getvalues(request,confirm) {
|
||||
return;
|
||||
document.getElementById("noajax_msg").innerHTML = "";
|
||||
|
||||
document.getElementById("status").innerHTML =
|
||||
'<div class=opaquebackground>'+
|
||||
'<div style="text-align:left;color:white;position:absolute;left:0;top:0;" id=matrix class=matrix></div>'+
|
||||
'<div style="position:absolute;left:50%;top:50%;"><img src="/images/wait.gif" title="Attendi..."</div>'+
|
||||
'<div style="position:fixed;left:95%;top:95%;color:red;"><a href="javascript:clearid(\'status\');">[x] Close</a></div>'+
|
||||
'</div>';
|
||||
|
||||
xmlhttp.onreadystatechange = function() {
|
||||
if (xmlhttp.readyState != 4)
|
||||
if (xmlhttp.readyState < 4)
|
||||
return;
|
||||
if (xmlhttp.responseXML == undefined) {
|
||||
if (xmlhttp.responseXML == undefined && xmlhttp.responseText == undefined) {
|
||||
document.getElementById("status").innerHTML = "";
|
||||
document.getElementById("output").innerHTML = "ERROR: there was a network connection problem.";
|
||||
document.getElementById("output").innerHTML = "ERROR: there was a network connection problem." + xmlhttp.readyState + " " + xmlhttp.status;
|
||||
xmlhttp.abort();
|
||||
return;
|
||||
}
|
||||
var xmldoc = xmlhttp.responseXML.documentElement;
|
||||
if (xmldoc == undefined) {
|
||||
return;
|
||||
}
|
||||
var nodes = xmldoc.childNodes;
|
||||
for (var i = 0; i < nodes.length; i++) {
|
||||
if (nodes[i].nodeName == "title") {
|
||||
document.title = nodes[i].childNodes[0].nodeValue;
|
||||
} else if (nodes[i].nodeName == "cookie-user") {
|
||||
setCookie("webbuild-user", nodes[i].childNodes[0].nodeValue, 1);
|
||||
setCookie("webbuild-user", nodes[i].childNodes[0].nodeValue);
|
||||
} else if (nodes[i].nodeName == "cookie-secret") {
|
||||
setCookie("webbuild-secret", nodes[i].childNodes[0].nodeValue, 1);
|
||||
setCookie("webbuild-secret", nodes[i].childNodes[0].nodeValue);
|
||||
} else if (document.getElementById(nodes[i].nodeName) != undefined) {
|
||||
$("#"+nodes[i].nodeName).html(nodes[i].childNodes[0].nodeValue);
|
||||
spectext = document.getElementById("spectext");
|
||||
@ -160,22 +168,19 @@ function ajax_getvalues(request,confirm) {
|
||||
});
|
||||
} else if ((nodes[i].nodeName == "output") && (document.getElementById("outputbottom") != undefined)) {
|
||||
document.getElementById("outputbottom").scrollTop = document.getElementById("outputbottom").scrollHeight;
|
||||
} else if ((nodes[i].nodeName == "processes")) {
|
||||
$(function() { $('.scroll-pane3').jScrollPane({scrollbarWidth:10}); });
|
||||
}
|
||||
}
|
||||
}
|
||||
//alert("nodes done");
|
||||
document.getElementById("webbuildform").disabled = false;
|
||||
document.getElementById("status").innerHTML = "";
|
||||
}
|
||||
xmlhttp.open("POST", url, true);
|
||||
xmlhttp.setRequestHeader("Content-type","application/x-www-form-urlencoded");
|
||||
xmlhttp.send(request);
|
||||
// setTimeout(function() { alert ("Timeout expired"); xmlhttp.abort(); }, 600000);
|
||||
|
||||
var currpos = 0, start = -1;
|
||||
|
||||
xmlhttp.onprogress = function() {
|
||||
var end,to;
|
||||
// save resposneText length when entering the function
|
||||
var end = 0,to;
|
||||
// save responseText length when entering the function
|
||||
to = this.responseText.length - 1;
|
||||
if (start < 0) {
|
||||
start = this.responseText.substring(0,to).indexOf("<!-- SCROLL -->");
|
||||
@ -185,34 +190,87 @@ function ajax_getvalues(request,confirm) {
|
||||
end = this.responseText.substring(start+currpos-15,to).indexOf("<!-- ENDSCROLL -->");
|
||||
if (end >= 0) to = end;
|
||||
if (to > start) {
|
||||
var customscroll = document.getElementById("matrix").scrollTop <
|
||||
(document.getElementById("matrix").scrollHeight - document.getElementById("matrix").clientHeight);
|
||||
document.getElementById("matrix").innerHTML =
|
||||
"<div id=matrixoutput><pre>" + this.responseText.substring(start,to).replace("</pre>","</pre>") + "</pre></div>";
|
||||
currpos = document.getElementById("matrixoutput").innerHTML.length;
|
||||
// document.getElementById("outputbottom").scrollTop = document.getElementById("outputbottom").scrollHeight;
|
||||
document.getElementById("matrix").scrollTop = document.getElementById("matrix").scrollHeight;
|
||||
document.getElementById("matrix").scrollLeft = document.getElementById("matrix").scrollWidth;
|
||||
if (!customscroll)
|
||||
document.getElementById("matrix").scrollTop = document.getElementById("matrix").scrollHeight;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
xmlhttp.open("POST", url, true);
|
||||
xmlhttp.setRequestHeader("Content-type","application/x-www-form-urlencoded");
|
||||
xmlhttp.send(request);
|
||||
// setTimeout(function() { alert ("Timeout expired"); xmlhttp.abort(); }, 600000);
|
||||
|
||||
var currpos = 0, start = -1;
|
||||
|
||||
}
|
||||
|
||||
// ajaxFileUpload
|
||||
function ajaxFileUpload(request)
|
||||
{
|
||||
/* $("#loading")
|
||||
.ajaxStart(function(){
|
||||
$(this).show();
|
||||
})
|
||||
.ajaxComplete(function(){
|
||||
$(this).hide();
|
||||
});*/
|
||||
$.ajaxFileUpload
|
||||
(
|
||||
{
|
||||
url:'/cgi-bin/webbuild',
|
||||
secureuri:false,
|
||||
fileElementId:'fileToUpload',
|
||||
dataType: 'xml',
|
||||
beforeSend:function()
|
||||
{
|
||||
$("#loading").show();
|
||||
},
|
||||
complete:function()
|
||||
{
|
||||
$("#loading").hide();
|
||||
},
|
||||
success: function (data, status)
|
||||
{
|
||||
ajax_getvalues(request);
|
||||
if(typeof(data.error) != 'undefined')
|
||||
{
|
||||
if(data.error != '')
|
||||
{
|
||||
alert(data.error);
|
||||
}else
|
||||
{
|
||||
alert(data.msg);
|
||||
}
|
||||
}
|
||||
},
|
||||
error: function (data, status, e)
|
||||
{
|
||||
alert(e);
|
||||
}
|
||||
}
|
||||
)
|
||||
return false;
|
||||
}
|
||||
//-->
|
||||
</script>
|
||||
</head><body>
|
||||
<table width="100%"><tr><td>
|
||||
<tr><td valign="middle">
|
||||
<table align="left"><tr>
|
||||
<td><img src="/images/webbuild.png" alt="build automatici"></td>
|
||||
<td> <b>- Webbuild - Interfaccia Web per lo sviluppo di openmamba</b></td>
|
||||
</tr></table>
|
||||
</td></tr>
|
||||
<table width="100%">
|
||||
<tr><td>
|
||||
<span class=webbuild>
|
||||
<div id=container style="position:relative;width:894px;height:auto;top:0;left:0;">
|
||||
<form id=webbuildform name=webbuild method=post>
|
||||
<div id=container style="position:relative;width:894px;height:auto;top:0;left:0;margin-left:auto;margin-right:auto;">
|
||||
<form id=webbuildform name=webbuild method=post action="javascript:">
|
||||
<img src="/images/webbuild.png" alt="build automatici">
|
||||
<b>- Webbuild - Interfaccia Web per lo sviluppo di openmamba</b>
|
||||
|
||||
<span id="searchbox"></span>
|
||||
|
||||
|
||||
|
||||
<div style="position:relative;top:-30px;left:0;width:100%;height:100%;">
|
||||
<div id="noajax_msg"><p>Il supporto per AJAX non è abilitato nel tuo browser. L'aggiornamento live non sarà disponibile, premi Ricarica per aggiornare la pagina.</p></div>
|
||||
<span id="status">Caricamento in corso, attendere...</span>
|
||||
@ -223,9 +281,10 @@ function ajax_getvalues(request,confirm) {
|
||||
<br><span id="speccreate"></span>
|
||||
<hr>
|
||||
<div style="position:relative;float:left;width:686px;padding:0;margin:1px;">
|
||||
<span id="processes"></span>
|
||||
<div class="processes"><div class="scroll-pane3"><span id="processes"></span></div></div><br>
|
||||
<div><span id="editor"></span></div>
|
||||
<span id="editcontrols"></span>
|
||||
<span id="showlogcontrols"></span>
|
||||
<span id="output"></span>
|
||||
</div>
|
||||
<div style="position:relative;float:right;width:200px;padding:0;margin:1px;">
|
||||
@ -234,9 +293,10 @@ function ajax_getvalues(request,confirm) {
|
||||
<span id="chatpanel"></span>
|
||||
</div>
|
||||
<div style="clear:both"></div>
|
||||
</span>
|
||||
</div>
|
||||
<span id="window"></span>
|
||||
</form>
|
||||
</div>
|
||||
</span>
|
||||
|
||||
<script>
|
||||
ajax_getvalues("");
|
||||
|
6
webbuild/webbuild-admin
Normal file
6
webbuild/webbuild-admin
Normal file
@ -0,0 +1,6 @@
|
||||
USER_ENABLED=1
|
||||
USER_ADMIN=1
|
||||
USER_CANINSTALL=1
|
||||
USER_CANMAINTAIN=1
|
||||
USER_ALLENVIRONMENTS=1
|
||||
USER_ALLREPOSITORIES=1
|
File diff suppressed because it is too large
Load Diff
@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# webbuild functions
|
||||
# Copyright (c) 2012 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
# Copyright (c) 2012-2014 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
#
|
||||
. /etc/autodist/config
|
||||
|
||||
@ -33,9 +33,17 @@ function social_log() {
|
||||
if [ ! "$STATE_FAKEUSER" ]; then
|
||||
STATE_SOCIALLOG_ID=0
|
||||
. $WEBBUILD_STATEDIR/users/webbuild.state
|
||||
STATE_SOCIALLOG_ID=`expr $STATE_SOCIALLOG_ID + 1`
|
||||
STATE_SOCIALLOG_ID=$(($STATE_SOCIALLOG_ID + 1))
|
||||
set_user_state_var STATE_SOCIALLOG_ID $STATE_SOCIALLOG_ID webbuild
|
||||
echo "SID=$STATE_SOCIALLOG_ID SPRIVACY=$STATE_PRIVACYMODE $line" >> $WEBBUILD_STATEDIR/social_log
|
||||
|
||||
# Note: checking that URL does not point here again to avoid recursive requests
|
||||
if [ "$WEBBUILD_URL" -a "${WEBBUILD_URL/\/localhost\//}" = "$WEBBUILD_URL" ]; then
|
||||
eval $line
|
||||
USER_SECRET_FIXED=`echo $USER_SECRET | sed "s|\$|\\$|"`
|
||||
curl -s "$WEBBUILD_URL?REQUEST=message&USER=$USER&SECRET=`cgi_encodevar \"$USER_SECRET\"`&USER_EMAIL=$USER_EMAIL&\
|
||||
MESSAGE=`cgi_encodevar \"$STEXT\"`" >/dev/null
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
@ -56,17 +64,41 @@ function cgi_encodevar() {
|
||||
# REPLY="${encoded}" #+or echo the result (EASIER)... or both... :p
|
||||
}
|
||||
|
||||
function cgi_get_POST_upload()
|
||||
# NOTE: only single file is supported
|
||||
{
|
||||
local content_disposition content_filename content_type
|
||||
|
||||
saveifs=$IFS
|
||||
IFS=$'\r'
|
||||
read -r
|
||||
read -r content_disposition
|
||||
eval content_filename=${content_disposition/*filename=}
|
||||
# security, remove any trailing path
|
||||
content_filename=${content_filename/*\/}
|
||||
|
||||
read -r content_type
|
||||
read -r
|
||||
IFS=$saveifs
|
||||
head -n -1 | head -c -2 | cat > $WEBBUILD_STATEDIR/uploads/$content_filename
|
||||
}
|
||||
|
||||
#This code for getting code from post data is from http://oinkzwurgl.org/bash_cgi and
|
||||
#was written by Phillippe Kehi <phkehi@gmx.net> and flipflip industries
|
||||
|
||||
|
||||
# (internal) routine to store POST data
|
||||
function cgi_get_POST_vars()
|
||||
{
|
||||
# check content type
|
||||
# FIXME: not sure if we could handle uploads with this..
|
||||
[ "${CONTENT_TYPE}" != "application/x-www-form-urlencoded" ] && \
|
||||
# Handle uploads
|
||||
if [ "${CONTENT_TYPE:0:19}" = "multipart/form-data" ]; then
|
||||
cgi_get_POST_upload "${CONTENT_TYPE/*boundary=}"
|
||||
return
|
||||
fi
|
||||
[ "${CONTENT_TYPE:0:33}" != "application/x-www-form-urlencoded" ] && \
|
||||
echo "Warning: you should probably use MIME type "\
|
||||
"application/x-www-form-urlencoded!" 1>&2
|
||||
"application/x-www-form-urlencoded instead of ${CONTENT_TYPE}!" 1>&2
|
||||
# save POST variables (only first time this is called)
|
||||
[ -z "$QUERY_STRING_POST" \
|
||||
-a "$REQUEST_METHOD" = "POST" -a ! -z "$CONTENT_LENGTH" ] &&
|
||||
@ -136,6 +168,7 @@ function cgi_getvars()
|
||||
p=`echo $q | sed "s|&.*||"`
|
||||
q=`echo $q | sed "s|[^&]*&||"`
|
||||
k="${p%%=*}" # get the key (variable name) from it
|
||||
[ "$k" = "REMOTE_ADDR" -o "$k" = "REMOTE_HOST" -o "$k" = "REMOTE_PORT" -o "$k" = "REMOTE_USER" ] && continue
|
||||
v="${p#*=}" # get the value from it
|
||||
# decode and evaluate var if requested
|
||||
if [ "$k" != "SPECTEXT" ]; then
|
||||
@ -151,7 +184,8 @@ function kill_tree() {
|
||||
|
||||
[ $1 ] || return
|
||||
|
||||
kill `pstree -p $killpid | sed 's/(/\n(/g' | grep '(' | sed 's/(\(.*\)).*/\1/' | tr "\n" " "`
|
||||
# tail here is used to avoid killing first pid, typically sh, which causes apache to stop since some time
|
||||
kill `pstree -pl $killpid | sed 's/(/\n(/g' | grep '(' | sed 's/(\(.*\)).*/\1/' | tail -n+2 | tr "\n" " "`
|
||||
return $?
|
||||
}
|
||||
|
||||
@ -179,7 +213,7 @@ function parse_search_output() {
|
||||
echo -n "<a class=searchlink href=\"/distribution/distromatic.html?tag=$REPOSITORY&pkg=$PKG.$ARCH\" target=_new>$2</a><br>"
|
||||
echo -n "</font>"
|
||||
# if [ "$ARCH" ]
|
||||
# $SUDO_WRAPPER 0 local "$USER" "" "openmamba-repository search -i $REPSEARCHTEXT" | \
|
||||
# $SUDO_WRAPPER 0 local "$USER" "" "autodist-repository search -i $REPSEARCHTEXT" | \
|
||||
# sed "s|\(.*(source).*\)|<font color=white><b>\1</b></font>|;
|
||||
# s|\(.*(${AUTOPORT_ARCH[$ENVIRONMENT]}).*\)|<font color=lightgreen>\1</font>|"
|
||||
done
|
||||
@ -191,20 +225,22 @@ function parse_patch_output() {
|
||||
|
||||
IFS=''
|
||||
echo -n "<font color=gray>"
|
||||
while read line; do
|
||||
[ "${line:0:3}" = "+++" ] && echo -n "</font>"
|
||||
echo "$line" | sed "s|<|\<|g;s|[[:cntrl:]]\[[0-9;]*m||g;
|
||||
sed "s|<|\<|g;s|[[:cntrl:]]\[[0-9;]*m||g;
|
||||
s|^\(+++.*\)|<font color=white style=\"background-color:gray\"><b>\1</b></font>|;
|
||||
s|^\(---.*\)|<font color=white style=\"background-color:gray\"><b>\1</b></font>|;
|
||||
s|^\(-.*\)|<font color=red>\1</font>|;
|
||||
s|^\(+.*\)|<font color=lightgreen>\1</font>|;
|
||||
s|^ |\ |;"
|
||||
s|^ |\ |;" |
|
||||
while read line; do
|
||||
[ "${line:0:3}" = "+++" ] && echo -n "</font>"
|
||||
echo "$line"
|
||||
done
|
||||
IFS=$SAVE_IFS
|
||||
}
|
||||
|
||||
function parse_build_output() {
|
||||
sed "s|<|\<|g;s|[[:cntrl:]]\[[0-9;]*m||g;
|
||||
sed "s|\r.*||;
|
||||
s|\(.\{10000\}\).*|\1 [CUT - LONG LINE]|;s|\\\|\\\\\\\|g;s|<|\<|g;s|[[:cntrl:]]\[[0-9;]*m||g;
|
||||
s|<font|<font|g;
|
||||
s|</font|</font|g;
|
||||
s|^\([\+#] .*\)|<font style=\"color:cyan\">\1</font>|;
|
||||
@ -217,7 +253,8 @@ function parse_build_output() {
|
||||
}
|
||||
|
||||
function parse_generic_output() {
|
||||
sed "s|<|\<|g;s|[[:cntrl:]]\[[0-9;]*m||g;
|
||||
sed "s|\r.*||;
|
||||
s|\(.\{10000\}\).*|\1 [CUT - LONG LINE]|;s|<|\<|g;s|[[:cntrl:]]\[[0-9;]*m||g;
|
||||
s|<font|<font|g;
|
||||
s|</font|</font|g;
|
||||
s|^\([\+#] .*\)|<font style=\"color:cyan\">\1</font>|;
|
||||
@ -263,10 +300,23 @@ function print_environment_descr() {
|
||||
# (${AUTOPORT_BASE_REPOSITORY[$i]} based)"
|
||||
}
|
||||
|
||||
function environment_rootdir() {
|
||||
local env=$1
|
||||
if [ "${AUTOPORT_CHROOT[$env]}" ]; then
|
||||
echo "/var/autoport/${AUTOPORT_CHROOT[$env]}"
|
||||
else
|
||||
echo ""
|
||||
fi
|
||||
}
|
||||
|
||||
function environment_autoport_logdir() {
|
||||
local env=$1
|
||||
if [ "${AUTOPORT_CHROOT[$env]}" ]; then
|
||||
echo "/var/autoport/${AUTOPORT_CHROOT[$env]}/home/${AUTOPORT_CHROOT_USER[$env]}/.autoport/"
|
||||
if [ "${AUTOPORT_CHROOT_USER[$env]}" != "autodist" ]; then
|
||||
echo "/var/autoport/${AUTOPORT_CHROOT[$env]}/home/${AUTOPORT_CHROOT_USER[$env]}/.autoport/"
|
||||
else
|
||||
echo "/var/autoport/${AUTOPORT_CHROOT[$env]}/var/autodist/.autoport/"
|
||||
fi
|
||||
elif [ "${AUTOPORT_NATIVE[$env]}" ]; then
|
||||
local envhome=`eval echo ~${AUTOPORT_CHROOT_USER[$env]}`
|
||||
echo "$envhome/.autoport"
|
||||
@ -275,12 +325,26 @@ function environment_autoport_logdir() {
|
||||
|
||||
function environment_logdir() {
|
||||
local env=$1
|
||||
local chroot=$2
|
||||
|
||||
if [ "${AUTOPORT_CHROOT[$env]}" ]; then
|
||||
echo "/var/autoport/${AUTOPORT_CHROOT[$env]}/home/${AUTOPORT_CHROOT_USER[$env]}/.autodist/log/"
|
||||
if [ "${AUTOPORT_CHROOT_USER[$env]}" != "autodist" ]; then
|
||||
if [ "$chroot" ]; then
|
||||
echo "/home/${AUTOPORT_CHROOT_USER[$env]}/.autodist/log/"
|
||||
else
|
||||
echo "/var/autoport/${AUTOPORT_CHROOT[$env]}/home/${AUTOPORT_CHROOT_USER[$env]}/.autodist/log/"
|
||||
fi
|
||||
else
|
||||
if [ "$chroot" ]; then
|
||||
echo "/var/autodist/log/"
|
||||
else
|
||||
echo "/var/autoport/${AUTOPORT_CHROOT[$env]}/var/autodist/log/"
|
||||
fi
|
||||
fi
|
||||
elif [ "${AUTOPORT_NATIVE[$env]}" ]; then
|
||||
local envhome=`eval echo ~${AUTOPORT_CHROOT_USER[$env]}`
|
||||
if [ "${AUTOPORT_CHROOT_USER[$env]}" = "autodist" ]; then
|
||||
echo "$envhome/log"
|
||||
echo "/var/autodist/log/"
|
||||
else
|
||||
echo "$envhome/.autodist/log/"
|
||||
fi
|
||||
|
@ -1,3 +1,16 @@
|
||||
#
|
||||
# webbuild functions-private include file
|
||||
# Copyright (c) 2012-2014 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
#
|
||||
|
||||
repository_list() {
|
||||
if [ "$WEBBUILD_REPOSITORIES" ]; then
|
||||
echo "${WEBBUILD_REPOSITORIES[*]}"
|
||||
else
|
||||
$SUDO_WRAPPER 0 local "$USER" "" "/usr/sbin/autodist-repository list"
|
||||
fi
|
||||
}
|
||||
|
||||
function showlog() {
|
||||
local LOGDIR LOGFILES LOGFILE1 LOGFILE2 LOGFILE3 LOGFILE4
|
||||
|
||||
@ -23,18 +36,10 @@ function showlog() {
|
||||
LOGFILE3=$LOGFILE/*_${PACKAGE/\//_}__*.${AUTOPORT_ARCH[$ENVIRONMENT]}
|
||||
LOGFILE4=$LOGFILE/*_${PACKAGE/\//_}.${AUTOPORT_ARCH[$ENVIRONMENT]}
|
||||
|
||||
LOGDIR=`environment_logdir $ENVIRONMENT`
|
||||
LOGDIR=`environment_logdir $ENVIRONMENT 1`
|
||||
LOGFILES="$LOGDIR/$LOGFILE1 $LOGDIR/$LOGFILE2 $LOGDIR/$LOGFILE3 $LOGDIR/$LOGFILE4"
|
||||
|
||||
for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do
|
||||
[ "$i" = "$ENVIRONMENT" ] && continue
|
||||
[ "${AUTOPORT_ARCH[$i]}" = "${AUTOPORT_ARCH[$ENVIRONMENT]}" ] || continue
|
||||
if [ "${AUTOPORT_UPDATE[$i]}" ]; then
|
||||
LOGDIR="/var/autodist/log"
|
||||
LOGFILES="$LOGFILES $LOGDIR/$LOGFILE1 $LOGDIR/$LOGFILE2 $LOGDIR/$LOGFILE3 $LOGDIR/$LOGFILE4"
|
||||
fi
|
||||
done
|
||||
LOGFILES=`ls -t $LOGFILES | head -1`
|
||||
# sort by most recent and take first
|
||||
LOGFILES=`$SUDO_WRAPPER 0 $ENVIRONMENT "$USER" "" "ls -t $LOGFILES 2>/dev/null | head -1"`
|
||||
fi
|
||||
echo -n "<output><![CDATA[<hr><b>Console output for $PACKAGE ($LOGTYPE$LOGSTATUSAPPEND):</b>"
|
||||
echo "<div align=left class=output id=$LOGOUTPUTID>"
|
||||
@ -51,7 +56,7 @@ function showlog() {
|
||||
echo -n "<pre>"
|
||||
if [ "$LOGTYPE" = "processtail" ]; then
|
||||
echo -n "<!-- SCROLL -->"
|
||||
tail -n +0 -f $f --pid $PROCESSPID | sed "s|<|\<|g"
|
||||
tail -n +0 -f $f --pid $PROCESSPID | stdbuf -oL sed "s|<|\<|g"
|
||||
echo -n "<!-- ENDSCROLL -->"
|
||||
else
|
||||
if [ $LOGFILESIZE -lt 524288 ]; then
|
||||
@ -102,12 +107,12 @@ function showEnvironmentPanel() {
|
||||
|
||||
# toolchain
|
||||
echo -n "<br>"
|
||||
local toolchain_output=`$SUDO_WRAPPER 0 $ENVIRONMENT "$USER" "" "LANGUAGE=C gcc --version | head -n1; LANGUAGE=C ld -v"`
|
||||
local toolchain_output=`LANGUAGE=C $SUDO_WRAPPER 0 $ENVIRONMENT "$USER" "" "gcc --version | head -n1; LANGUAGE=C ld -v"`
|
||||
local gcc_ver=`echo $toolchain_output | sed "s|.*(GCC) \([0-9.]*\) .*|\1|"`
|
||||
local binutils_ver=`echo $toolchain_output | sed "s|.*GNU \(.*\) (GNU Binutils.*)\(.*\)|\1 \2|"`
|
||||
echo "Toolchain: gcc $gcc_ver, $binutils_ver"
|
||||
|
||||
# smart upgrade
|
||||
# system upgrade
|
||||
echo -n "<br><input type=button id=smartupgrade value=\"system upgrade\" onclick="
|
||||
echo -n "ajax_getvalues(\"ENVIRONMENT=$ENVIRONMENT&REPOSITORY=$REPOSITORY&PACKAGE=$PACKAGEENCODED&"
|
||||
echo -n "REQUEST=smartupgrade\""
|
||||
@ -118,6 +123,11 @@ function showEnvironmentPanel() {
|
||||
#echo -n "ajax_getvalues(\"ENVIRONMENT=$ENVIRONMENT&REPOSITORY=$REPOSITORY&PACKAGE=$PACKAGEENCODED&"
|
||||
#echo -n "REQUEST=runldconfig\");>"
|
||||
|
||||
# rpm manager
|
||||
echo -n "<input type=button id=rpmmanager value=\"RPM manager\" onclick="
|
||||
echo -n "ajax_getvalues(\"ENVIRONMENT=$ENVIRONMENT&REPOSITORY=$REPOSITORY&PACKAGE=$PACKAGEENCODED&"
|
||||
echo -n "REQUEST=rpmmanager\");>"
|
||||
|
||||
# environment search
|
||||
echo -n "<br><div style=\"white-space:nowrap;width:100%;\">Provides:<input type=text style=\"width:75%;align:center;padding:0;margin:2px;\" id=environmentsearch value=\"Search package or provide...\" "
|
||||
echo -n "onfocus=\"if (this.value==this.defaultValue) this.value=''\" "
|
||||
@ -127,6 +137,27 @@ function showEnvironmentPanel() {
|
||||
|
||||
}
|
||||
|
||||
function print_showlogcontrols() {
|
||||
echo -n "<showlogcontrols><![CDATA["
|
||||
# autodist logs
|
||||
echo -n "<hr><b>Show last autodist logs:</b> "
|
||||
echo -n "<input type=button value=\"prepare\" onclick=ajax_getvalues(\"ENVIRONMENT=$ENVIRONMENT&PACKAGE=$PACKAGEENCODED&"
|
||||
echo -n "REQUEST=showlog&LOGTYPE=prepare&LOGSTATUSOK=\"+document.all.logstatusOK.checked);>"
|
||||
echo -n "<input type=button value=\"update\" onclick=ajax_getvalues(\"ENVIRONMENT=$ENVIRONMENT&PACKAGE=$PACKAGEENCODED&"
|
||||
echo -n "REQUEST=showlog&LOGTYPE=update&LOGSTATUSOK=\"+document.all.logstatusOK.checked);>"
|
||||
echo -n "<input type=button class=boldbutton value=\"build\" onclick=ajax_getvalues(\"ENVIRONMENT=$ENVIRONMENT&PACKAGE=$PACKAGEENCODED&"
|
||||
echo -n "REQUEST=showlog&LOGTYPE=build&LOGSTATUSOK=\"+document.all.logstatusOK.checked);>"
|
||||
echo -n "<input type=button value=\"install\" onclick=ajax_getvalues(\"ENVIRONMENT=$ENVIRONMENT&PACKAGE=$PACKAGEENCODED&"
|
||||
echo -n "REQUEST=showlog&LOGTYPE=install&LOGSTATUSOK=\"+document.all.logstatusOK.checked);>"
|
||||
echo -n "<input type=button value=\"send\" onclick=ajax_getvalues(\"ENVIRONMENT=$ENVIRONMENT&PACKAGE=$PACKAGEENCODED&"
|
||||
echo -n "REQUEST=showlog&LOGTYPE=send&LOGSTATUSOK=\"+document.all.logstatusOK.checked);> with status: "
|
||||
echo -n "OK <input id=\"logstatusOK\" type=\"radio\" name=\"logstatus\" value=\"OK\"> "
|
||||
echo -n "FAILED <input type=\"radio\" name=\"logstatus\" value=\"FAILED\" checked=\"checked\">"
|
||||
# close tag
|
||||
echo -n "]]></showlogcontrols>"
|
||||
}
|
||||
|
||||
|
||||
function print_editorcontrols() {
|
||||
|
||||
echo -n "<editcontrols><![CDATA["
|
||||
@ -134,7 +165,7 @@ function print_editorcontrols() {
|
||||
echo -n "<div style=\"width:100%;overflow:hidden;\"><span style=\"float:left\">"
|
||||
echo -n "<input type=button id=savebutton value=\"save\" onclick="
|
||||
echo -n "ajax_getvalues(\"ENVIRONMENT=$ENVIRONMENT&REPOSITORY=$REPOSITORY&PACKAGE=$PACKAGEENCODED&"
|
||||
echo -n "REQUEST=savespec&SPECTEXT=\"+encodeURIComponent(editor.getValue()));"
|
||||
echo -n "REQUEST=savespec&SENDREPOSITORY=$SENDREPOSITORY&SPECTEXT=\"+encodeURIComponent(editor.getValue()));"
|
||||
echo -n "this.disabled=true; disabled=disabled class=redbutton>"
|
||||
# specfile reload
|
||||
echo -n "<input type=button id=updatespecbutton value=\"reload\" onclick="
|
||||
@ -179,3 +210,73 @@ function print_editorcontrols() {
|
||||
echo -n "]]></editcontrols>"
|
||||
|
||||
}
|
||||
|
||||
function show_docs() {
|
||||
local f RET ftype
|
||||
|
||||
for f in $@; do
|
||||
echo -n "<a href=#logfile-$f>$f</a><br>"
|
||||
done
|
||||
echo -n "<br>"
|
||||
for f in $@; do
|
||||
echo -n "<a name=logfile-$f><p style=\"background-color:gray\"><b>File $f:</b></a><pre>"
|
||||
ftype="`$SUDO_WRAPPER 0 $ENVIRONMENT "$USER" $PACKAGE "cd $SPECVAR_RPMBUILDDIR/$SPECVAR_BUILDDIR && file $f"`"
|
||||
if [ "${ftype/text}" = "${ftype}" ]; then
|
||||
echo "<p>Binary file; skipping."
|
||||
continue
|
||||
fi
|
||||
$SUDO_WRAPPER 0 $ENVIRONMENT "$USER" $PACKAGE \
|
||||
"cd $SPECVAR_RPMBUILDDIR/$SPECVAR_BUILDDIR && head -c 10240 $f | sed \"s|<|\<|g;s|[[:cntrl:]]\[[0-9;]*m||g\"" | parse_generic_output
|
||||
RET=$?
|
||||
echo -n "</pre>"
|
||||
done
|
||||
return $RET
|
||||
}
|
||||
|
||||
function download_file() {
|
||||
local RET
|
||||
local download_environment=$1
|
||||
local download_files=$2
|
||||
local f
|
||||
|
||||
for f in $download_files; do
|
||||
echo $f >> /tmp/down
|
||||
echo -e "Content-Type: application/octet-stream"
|
||||
echo -e "Content-Disposition: attachment; filename=\"${f/*\/}\"\n"
|
||||
if [ "$download_environment" ]; then
|
||||
$SUDO_WRAPPER binary $download_environment "$USER" "" "cat $f 2>/dev/null"
|
||||
else
|
||||
cat $f 2>/dev/null
|
||||
fi
|
||||
done
|
||||
|
||||
RET=$?
|
||||
return $RET
|
||||
}
|
||||
|
||||
function resolve_rpmmanagerdir() {
|
||||
local RPMMANAGERDIR=$1
|
||||
local RPMMANAGERARCH=$2
|
||||
local REPOSITORY=$3
|
||||
|
||||
case $RPMMANAGERDIR in
|
||||
REP_SRPMS) rpmmanagerdir=$local_ftp/$REPOSITORY/SRPMS.base
|
||||
rpmmanagermask="*.src.rpm"
|
||||
rpmmanagermode=repository ;;
|
||||
REP_RPMS) rpmmanagerdir=$local_ftp/$REPOSITORY/RPMS.$RPMMANAGERARCH
|
||||
rpmmanagermask="*.$RPMMANAGERARCH.rpm"
|
||||
rpmmanagermode=repository ;;
|
||||
REP_RPMSNOARCH) rpmmanagerdir=$local_ftp/$REPOSITORY/RPMS.$RPMMANAGERARCH
|
||||
rpmmanagermask="*.noarch.rpm"
|
||||
rpmmanagermode=repository ;;
|
||||
SRPMS) rpmmanagerdir=../SRPMS
|
||||
rpmmanagermask="*.src.rpm"
|
||||
rpmmanagermode=environment ;;
|
||||
RPMSNOARCH) rpmmanagerdir=../RPMS/noarch
|
||||
rpmmanagermask="*.noarch.rpm"
|
||||
rpmmanagermode=environment ;;
|
||||
*) rpmmanagerdir=../RPMS/$RPMMANAGERARCH
|
||||
rpmmanagermask="*.$RPMMANAGERARCH.rpm"
|
||||
rpmmanagermode=environment ;;
|
||||
esac
|
||||
}
|
||||
|
@ -9,6 +9,8 @@ PACKAGE=$4
|
||||
COMMAND=$5
|
||||
TMPFILE=$6
|
||||
|
||||
[ -e $WEBBUILD_STATEDIR/cache/config-dynamic ] && . $WEBBUILD_STATEDIR/cache/config-dynamic
|
||||
|
||||
echo "REQUEST: $@" >> $WEBBUILD_STATEDIR/commands_log
|
||||
if [ "$MODE" = "killtree" ]; then
|
||||
KILLPID=$2
|
||||
@ -30,8 +32,10 @@ elif [ "$MODE" = "finishprocess" ]; then
|
||||
exit $RETCODE
|
||||
elif [ "$ENVIRONMENT" = "local" ]; then
|
||||
echo "COMMAND: $COMMAND" >> $WEBBUILD_STATEDIR/commands_log
|
||||
$COMMAND 2>&1 | sed "s|<|\<|g"
|
||||
exit 0
|
||||
$COMMAND 2>&1
|
||||
# | sed "s|<|\<|g"
|
||||
RET=$?
|
||||
exit $RET
|
||||
fi
|
||||
|
||||
if [ "$ENVIRONMENT" = "local" ]; then
|
||||
@ -52,12 +56,13 @@ elif [ "${AUTOPORT_CHROOT[$ENVIRONMENT]}" ]; then
|
||||
SUCMDPREFIX="chroot $ENVPREFIX su -l ${AUTOPORT_CHROOT_USER[$ENVIRONMENT]} -c"
|
||||
[ "$TMPFILE" ] && {
|
||||
cp $TMPFILE /var/autoport/${AUTOPORT_CHROOT[$ENVIRONMENT]}/$TMPFILE
|
||||
chmod 755 /var/autoport/${AUTOPORT_CHROOT[$ENVIRONMENT]}/$TMPFILE
|
||||
chmod +r /var/autoport/${AUTOPORT_CHROOT[$ENVIRONMENT]}/$TMPFILE
|
||||
}
|
||||
elif [ "${AUTOPORT_NATIVE[$ENVIRONMENT]}" ]; then
|
||||
ENVPREFIX=
|
||||
ENVUSER=${AUTOPORT_CHROOT_USER[$ENVIRONMENT]}
|
||||
WORKINGHOME=`getent passwd ${AUTOPORT_CHROOT_USER[$ENVIRONMENT]} | cut -d: -f6`
|
||||
[ -e "$WORKINGHOME/RPM" ] || WORKINGHOME="/usr/src/"
|
||||
SUCMDPREFIX="su -l ${AUTOPORT_CHROOT_USER[$ENVIRONMENT]} -c"
|
||||
else
|
||||
ENVPREFIX=
|
||||
@ -91,10 +96,12 @@ if [ "$MODE" = "specinfo" ]; then
|
||||
[ "$1" = "%package" -o "$1" = "%description" ] && break
|
||||
if [[ "$1" =~ ^[a-zA-Z]*[0-9]*:.* ]]; then
|
||||
line="$(echo ${line/$1})"
|
||||
specvar="SPECVAR_${1/:*}"
|
||||
specvar="${specvar/[0-9]*}"
|
||||
[ "$specvar" = "$lastspecvar" ] && varidx=`expr $varidx + 1` || varidx=0
|
||||
specvarfull="SPECVAR_${1/:*}"
|
||||
specvar="${specvarfull/[0-9]*}"
|
||||
specvaridx="${specvarfull/$specvar}"
|
||||
[ "$specvar" = "$lastspecvar" ] && varidx=$(($varidx + 1)) || varidx=0
|
||||
echo "$specvar[$varidx]=\"${line//\"/}\""
|
||||
[ "$specvaridx" != "" ] && echo "${specvar}_idx[$varidx]=$specvaridx"
|
||||
[ "$specvar" = "SPECVAR_Version" -a ! "$BUILDDIR" ] && BUILDDIR="$PACKAGE-${line}"
|
||||
fi
|
||||
lastspecvar=$specvar
|
||||
@ -119,12 +126,16 @@ cmdtmpfile=`mktemp --tmpdir=$WEBBUILD_STATEDIR/tmp --suffix=.webbuildcmd`
|
||||
[ "$PACKAGE" ] || PACKAGE=nopackage
|
||||
if [ "$MODE" = "background" ]; then
|
||||
if [ "$WORKINGHOME" ]; then
|
||||
[ "$DEBUG" ] && echo "=> . /etc/profile;cd $WORKINGHOME/RPM/SPECS;$SUCMDPREFIX \"$COMMAND\""
|
||||
$SUCMDPREFIX ". /etc/profile;cd $WORKINGHOME/RPM/SPECS;$COMMAND;echo \"# WEBBUILD_EXITCODE=\$?\"" 2>&1 | tr -d '\f' > $cmdtmpfile &
|
||||
[ "$DEBUG" ] && echo "=> . /etc/profile;cd $WORKINGHOME/RPM/SPECS;stdbuf -oL -eL $SUCMDPREFIX \"$COMMAND\""
|
||||
# WARNING: don't add pipes after $COMMAND or command pid will be wrong
|
||||
$SUCMDPREFIX ". /etc/profile;cd $WORKINGHOME/RPM/SPECS;stdbuf -oL -eL $COMMAND 2>&1;echo \"# WEBBUILD_EXITCODE=\$?\"" 2>&1 > $cmdtmpfile &
|
||||
# | tr -d '\f'
|
||||
#sed "s|<|\<|g" |
|
||||
else
|
||||
[ "$DEBUG" ] && echo "=> $SUCMDPREFIX \"$COMMAND\""
|
||||
$SUCMDPREFIX "$COMMAND;echo \"# WEBBUILD_EXITCODE=\$?\"" 2>&1 | sed "s|<|\<|g" | tr -d '\f' > $cmdtmpfile &
|
||||
[ "$DEBUG" ] && echo "=> $SUCMDPREFIX \"stdbuf -oL -eL $COMMAND\""
|
||||
# WARNING: don't add pipes after $COMMAND or command pid will be wrong
|
||||
$SUCMDPREFIX "stdbuf -oL -eL $COMMAND;echo \"# WEBBUILD_EXITCODE=\$?\"" 2>&1 > $cmdtmpfile &
|
||||
# | sed "s|<|\<|g" | tr -d '\f'
|
||||
fi
|
||||
echo "$! $USER $ENVIRONMENT $PACKAGE $cmdtmpfile 256 $COMMAND" >> $WEBBUILD_STATEDIR/processes
|
||||
echo "Started background command: $COMMAND"
|
||||
@ -135,12 +146,20 @@ else
|
||||
echo "$$ $USER $ENVIRONMENT $PACKAGE $cmdtmpfile 256 $COMMAND" >> $WEBBUILD_STATEDIR/processes
|
||||
rettmpfile=`$SUCMDPREFIX "mktemp --suffix=.webbuildret"`
|
||||
if [ "$WORKINGHOME" ]; then
|
||||
[ "$DEBUG" ] && echo "=> . /etc/profile;cd $WORKINGHOME/RPM/SPECS;$SUCMDPREFIX \"$COMMAND\""
|
||||
$SUCMDPREFIX ". /etc/profile;cd $WORKINGHOME/RPM/SPECS;$COMMAND;echo \$? > $rettmpfile" 2>&1 | tr -d '\f' | tee $cmdtmpfile
|
||||
[ "$DEBUG" ] && echo "=> . /etc/profile;cd $WORKINGHOME/RPM/SPECS;\"$COMMAND\""
|
||||
if [ "$MODE" = "binary" ]; then
|
||||
$SUCMDPREFIX ". /etc/profile;cd $WORKINGHOME/RPM/SPECS;$COMMAND;echo \$? > $rettmpfile" 2>&1
|
||||
else
|
||||
$SUCMDPREFIX ". /etc/profile;cd $WORKINGHOME/RPM/SPECS;$COMMAND;echo \$? > $rettmpfile" 2>&1 | tr -d '\f' | tee $cmdtmpfile
|
||||
fi
|
||||
# sed "s|<|\<|g" |
|
||||
else
|
||||
[ "$DEBUG" ] && echo "=> $SUCMDPREFIX \"$COMMAND\""
|
||||
$SUCMDPREFIX "$COMMAND;echo \$? > $rettmpfile" 2>&1 | tr -d '\f' | tee $cmdtmpfile
|
||||
if [ "$MODE" = "binary" ]; then
|
||||
$SUCMDPREFIX "$COMMAND;echo \$? > $rettmpfile" 2>&1
|
||||
else
|
||||
$SUCMDPREFIX "$COMMAND;echo \$? > $rettmpfile" 2>&1 | tr -d '\f' | tee $cmdtmpfile
|
||||
fi
|
||||
# sed "s|<|\<|g" |
|
||||
fi
|
||||
RET=`cat $ENVPREFIX/$rettmpfile`
|
||||
|
Reference in New Issue
Block a user