Commit d3dcae41 authored by Vitaly Lipatov's avatar Vitaly Lipatov

Merge branch 'master' of git.alt:packages/etersoft-build-utils

parents 9eb3759c 6b63e916
...@@ -90,7 +90,7 @@ do ...@@ -90,7 +90,7 @@ do
# --nprocs=2 # --nprocs=2
# Note: hasher is already use renice for low priority # Note: hasher is already use renice for low priority
LOGFILE="$LOGDIR/`basename $i .src.rpm`$MENVARG.log" LOGFILE="$LOGDIR/`basename $i .src.rpm`$MENVARG.log"
echo "Build in hasher ($MENV)" >$LOGFILE echo "Build in hasher ($MENV) in $HASHERDIR dir" >$LOGFILE
rm -f $LOGFILE.failed rm -f $LOGFILE.failed
# enable /proc support only if require it # enable /proc support only if require it
#rpm --requires -p $i | grep "/proc" && ARG="$HASHERARG --mountpoints=/proc" || ARG="$HASHERARG" #rpm --requires -p $i | grep "/proc" && ARG="$HASHERARG --mountpoints=/proc" || ARG="$HASHERARG"
......
...@@ -24,7 +24,7 @@ fi ...@@ -24,7 +24,7 @@ fi
############################# #############################
Usage="Usage: $name [-c -p -i -r] spec..." Usage="Usage: $name [-c -p -i -r -R] spec..."
function mygetopts() function mygetopts()
{ {
name=${0##*/} name=${0##*/}
...@@ -39,15 +39,17 @@ phelp() ...@@ -39,15 +39,17 @@ phelp()
echog " -i - install and package" echog " -i - install and package"
echog " -p - packaging installed files into package" echog " -p - packaging installed files into package"
echog " -r - find build requires" echog " -r - find build requires"
echog " -R - find build requires with -bi"
} }
while getopts :hcipr opt; do while getopts :hciprR opt; do
case $opt in case $opt in
h) phelp; exit 0;; h) phelp; exit 0;;
c) BUILDOPT="c" ;; c) BUILDOPT="c" ;;
i) BUILDOPT="i b" ;; i) BUILDOPT="i b" ;;
p) BUILDOPT="b" ;; p) BUILDOPT="b" ;;
r) BUILDREQ=1 ;; r) BUILDREQ="-bc" ;;
R) BUILDREQ="-bi" ;;
+?) echog "$name: options should not be preceded by a '+'." 1>&2; exit 2;; +?) echog "$name: options should not be preceded by a '+'." 1>&2; exit 2;;
# ?) echog "$name: $OPTARG: bad option. Use -h for help." 1>&2 ; exit 2;; # ?) echog "$name: $OPTARG: bad option. Use -h for help." 1>&2 ; exit 2;;
?) OPTIND=$((OPTIND-1)); break; ?) OPTIND=$((OPTIND-1)); break;
...@@ -80,9 +82,9 @@ fi ...@@ -80,9 +82,9 @@ fi
# instead cbuild req # instead cbuild req
if [ -n "$BUILDREQ" ] ; then if [ -n "$BUILDREQ" ] ; then
uni_buildreq $LISTNAMES uni_buildreq $BUILDREQ $LISTNAMES
RET=$? RET=$?
echog "You can run buildreq with -bi param for search a dependences for install section of the package" echog "You can run with -R param for search a dependences for install section of the package (as with buildreq -bi)"
exit $RET exit $RET
fi fi
......
...@@ -18,6 +18,7 @@ DISTRVERSION=`distr_vendor -v` ...@@ -18,6 +18,7 @@ DISTRVERSION=`distr_vendor -v`
alt_tolocal() alt_tolocal()
{ {
local TXTRELEASE
local SPECNAME local SPECNAME
SPECNAME=$1 SPECNAME=$1
...@@ -40,7 +41,9 @@ else ...@@ -40,7 +41,9 @@ else
# Need our compat package and disable strong patch checking # Need our compat package and disable strong patch checking
BUILDREQ="BuildRequires: rpm-build-altlinux-compat >= 0.95 make gcc\n$FIXPATCHFUZZ" BUILDREQ="BuildRequires: rpm-build-altlinux-compat >= 0.95 make gcc\n$FIXPATCHFUZZ"
[ -z "$BUILDCOMMAND" ] && BUILDCOMMAND=$ETERBUILDBIN/rpmbb [ -z "$BUILDCOMMAND" ] && BUILDCOMMAND=$ETERBUILDBIN/rpmbb
set_release $SPECNAME $(get_txtrelease $SPECNAME)$BASERELEASE$VENDOR TXTRELEASE=$(get_txtrelease $SPECNAME)
[ -z "$KORINFTARGETRELEASE" ] || TXTRELEASE=$KORINFTARGETRELEASE
set_release $SPECNAME $TXTRELEASE$BASERELEASE$VENDOR
ADDDEF="%defattr(-, root, root)" ADDDEF="%defattr(-, root, root)"
CLEANTEXT="" CLEANTEXT=""
fi fi
......
...@@ -111,6 +111,9 @@ get_pagepkginfo() ...@@ -111,6 +111,9 @@ get_pagepkginfo()
PKGVERSION=`rpm -q --queryformat "%{VERSION}" ${i}` PKGVERSION=`rpm -q --queryformat "%{VERSION}" ${i}`
PKGNAME=`rpm -q --queryformat "%{sourcerpm}" ${i} | sed -e "s|-$VERSION.*||g"` PKGNAME=`rpm -q --queryformat "%{sourcerpm}" ${i} | sed -e "s|-$VERSION.*||g"`
fi fi
if [ -z "$PKGNAME" ] ; then
PKGNAME="$i"
fi
RPM_URL=$PAGEURL/$PKGNAME RPM_URL=$PAGEURL/$PKGNAME
} }
...@@ -127,7 +130,7 @@ do ...@@ -127,7 +130,7 @@ do
RPM_URL=`dirname $SOURCE` RPM_URL=`dirname $SOURCE`
fi fi
fi fi
test -z "$ABOUTDIR" && test -z ${RPM_URL} && fatal "Cannot get package Url from spec $i" test -z "$ABOUTDIR" && test -z "${RPM_URL}" && fatal "Cannot get package Url from spec $i"
if [ -z "$CHECKONLY" ] ; then if [ -z "$CHECKONLY" ] ; then
if [ -n "$RPM_URL" ] && [ "$RPM_URL" != "(none)" ] ; then if [ -n "$RPM_URL" ] && [ "$RPM_URL" != "(none)" ] ; then
echog "Opening URL '$RPM_URL' with browser '$BROWSER'" echog "Opening URL '$RPM_URL' with browser '$BROWSER'"
......
...@@ -77,15 +77,17 @@ uni_rpmbuild() ...@@ -77,15 +77,17 @@ uni_rpmbuild()
uni_buildreq() uni_buildreq()
{ {
local RET=0 local RET=0
local BUILDREQPARAM="$1"
shift
local SPECNAME=$(realpath "$1") local SPECNAME=$(realpath "$1")
shift shift
local SPECDIR=`dirname $SPECNAME` local SPECDIR=`dirname $SPECNAME`
local GEARBUILDREQ=gear-buildreq local GEARBUILDREQ=gear-buildreq
if is_gear $SPECDIR ; then if is_gear $SPECDIR ; then
$NICE $GEARBUILDREQ --commit -- "$SPECNAME" $@ || RET=$? $NICE $GEARBUILDREQ $BUILDREQPARAM --commit -- "$SPECNAME" $@ || RET=$?
else else
$NICE buildreq "$SPECNAME" $@ || RET=$? $NICE buildreq $BUILDREQPARAM "$SPECNAME" $@ || RET=$?
fi fi
return $RET return $RET
} }
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
# Author: Vitaly Lipatov <lav@etersoft.ru> # Author: Vitaly Lipatov <lav@etersoft.ru>
# Public domain # Public domain
ETERBUILDVERSION=166 ETERBUILDVERSION=167
# SUDO # SUDO
SUDO="sudo" SUDO="sudo"
......
...@@ -4,3 +4,4 @@ jackit-devel| ...@@ -4,3 +4,4 @@ jackit-devel|
# XOrg # XOrg
xorg-x11-devel| xorg-x11-devel|
xorg-sdk|xorg-x11-server-sdk xorg-sdk|xorg-x11-server-sdk
libsmbclient-devel|samba-common
...@@ -92,3 +92,6 @@ librsvg|librsvg2 ...@@ -92,3 +92,6 @@ librsvg|librsvg2
# hack due our wine package with -devel # hack due our wine package with -devel
libwine-devel|libwine-devel libwine-devel|libwine-devel
ImageMagick-tools|imagemagick
wxGTK-devel|wx-common
\ No newline at end of file
libgtkmm2-devel|gtkmm24-devel libgtkmm2-devel|gtkmm24-devel
libice-devel|libICE-devel libice-devel|libICE-devel
\ No newline at end of file
...@@ -77,4 +77,8 @@ xorg-inputproto-devel|x11-proto-devel ...@@ -77,4 +77,8 @@ xorg-inputproto-devel|x11-proto-devel
xorg-xextproto-devel|x11-proto-devel xorg-xextproto-devel|x11-proto-devel
xorg-sdk|x11-server-devel xorg-sdk|x11-server-devel
libICE-devel|libice6-devel libICE-devel|libice6-devel
\ No newline at end of file libarts-devel|libkdemultimedia1-arts-devel
libopensc-devel|libopensc-devel
wxGTK-devel|libwxgtk2.8-devel
netcat|netcat
...@@ -5,4 +5,4 @@ libreadline|libreadline6 ...@@ -5,4 +5,4 @@ libreadline|libreadline6
libgtkmm2-devel|libgtkmm2.4-devel libgtkmm2-devel|libgtkmm2.4-devel
glibc-devel-static|glibc-static-devel glibc-devel-static|glibc-static-devel
libarts-devel|arts3-devel libarts-devel|libarts1-devel
...@@ -101,3 +101,6 @@ GConf|GConf2 ...@@ -101,3 +101,6 @@ GConf|GConf2
libxml++2-devel|libxml++-devel libxml++2-devel|libxml++-devel
glibc-devel-static|glibc-devel glibc-devel-static|glibc-devel
libopensc-devel|opensc-devel
ImageMagick-tools|ImageMagick
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment