Mailinglist Archive: zypp-commit (223 mails)

< Previous Next >
[zypp-commit] r10555 - in /trunk/sat-solver/tools: CMakeLists.txt repo2solv.sh
  • From: dmacvicar@xxxxxxxxxxxxxxxx
  • Date: Fri, 11 Jul 2008 23:44:41 -0000
  • Message-id: <20080711234441.C956330108@xxxxxxxxxxxxxxxx>
Author: dmacvicar
Date: Sat Jul 12 01:44:41 2008
New Revision: 10555

URL: http://svn.opensuse.org/viewcvs/zypp?rev=10555&view=rev
Log:
- make repo2solv.sh also take repomd.xml in count
- install repomdxml2solv

Modified:
trunk/sat-solver/tools/CMakeLists.txt
trunk/sat-solver/tools/repo2solv.sh

Modified: trunk/sat-solver/tools/CMakeLists.txt
URL:
http://svn.opensuse.org/viewcvs/zypp/trunk/sat-solver/tools/CMakeLists.txt?rev=10555&r1=10554&r2=10555&view=diff
==============================================================================
--- trunk/sat-solver/tools/CMakeLists.txt (original)
+++ trunk/sat-solver/tools/CMakeLists.txt Sat Jul 12 01:44:41 2008
@@ -69,6 +69,7 @@
rpms2solv
updateinfoxml2solv
deltainfoxml2solv
+ repomdxml2solv
DESTINATION ${BIN_INSTALL_DIR} )

install(PROGRAMS repo2solv.sh DESTINATION ${BIN_INSTALL_DIR} )

Modified: trunk/sat-solver/tools/repo2solv.sh
URL:
http://svn.opensuse.org/viewcvs/zypp/trunk/sat-solver/tools/repo2solv.sh?rev=10555&r1=10554&r2=10555&view=diff
==============================================================================
--- trunk/sat-solver/tools/repo2solv.sh (original)
+++ trunk/sat-solver/tools/repo2solv.sh Sat Jul 12 01:44:41 2008
@@ -47,6 +47,27 @@
$cmd $i | rpmmd2solv $parser_options > $primfile || exit 4
fi

+ # This contains repomd.xml
+ # for now we only read some keys like expiration
+ if test -f repomd.xml || test -f repomd.xml.gz || test -f repomd.xml.bz2 ;
then
+ for i in repomd.xml*; do
+ case $i in
+ *.gz) cmd="gzip -dc" ;;
+ *.bz2) cmd="bzip2 -dc" ;;
+ *) cmd="cat" ;;
+ esac
+ # only check the first updateinfo.xml*, in case there are more
+ break
+ done
+
+ repomdfile="/nonexist"
+ if test -n "$cmd"; then
+ # we have some repomd.xml*
+ repomdfile=`mktemp` || exit 3
+ $cmd $i | repomdxml2solv $parser_options > $repomdfile || exit 4
+ fi
+ fi
+
# This contains a updateinfo.xml* and maybe patches
if test -f updateinfo.xml || test -f updateinfo.xml.gz || test -f
updateinfo.xml.bz2 ; then
for i in updateinfo.xml*; do
@@ -102,6 +123,9 @@
fi

# Now merge primary, patches, updateinfo, and deltainfo
+ if test -s $repomdfile; then
+ m_repomdfile=$repomdfile
+ fi
if test -s $primfile; then
m_primfile=$primfile
fi
@@ -114,8 +138,8 @@
if test -s $deltainfofile; then
m_deltainfofile=$deltainfofile
fi
- mergesolv $m_primfile $m_patchfile $m_updateinfofile $m_deltainfofile
- rm -f $primfile $patchfile $updateinfofile $deltainfofile
+ mergesolv $m_repomdfile $m_primfile $m_patchfile $m_updateinfofile
$m_deltainfofile
+ rm -f $repomdfile $primfile $patchfile $updateinfofile $deltainfofile

elif test_susetags; then
olddir=`pwd`

--
To unsubscribe, e-mail: zypp-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: zypp-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages