[41578] trunk/dports/sysutils

afb at macports.org afb at macports.org
Thu Nov 6 03:25:42 PST 2008


Revision: 41578
          http://trac.macports.org/changeset/41578
Author:   afb at macports.org
Date:     2008-11-06 03:25:42 -0800 (Thu, 06 Nov 2008)
Log Message:
-----------
new port: yum-based createrepo variant

Modified Paths:
--------------
    trunk/dports/sysutils/yum-createrepo/Portfile

Added Paths:
-----------
    trunk/dports/sysutils/yum-createrepo/
    trunk/dports/sysutils/yum-createrepo/files/patch-prefix.diff
    trunk/dports/sysutils/yum-createrepo/files/patch-sqlite.diff

Removed Paths:
-------------
    trunk/dports/sysutils/yum-createrepo/files/patch-Makefile
    trunk/dports/sysutils/yum-createrepo/files/patch-createrepo
    trunk/dports/sysutils/yum-createrepo/files/patch-dumpMetadata.py
    trunk/dports/sysutils/yum-createrepo/files/patch-genpkgmetadata.py
    trunk/dports/sysutils/yum-createrepo/files/patch-modifyrepo
    trunk/dports/sysutils/yum-createrepo/files/patch-modifyrepo.py
    trunk/dports/sysutils/yum-createrepo/files/patch-readMetadata.py


Property changes on: trunk/dports/sysutils/yum-createrepo
___________________________________________________________________
Added: svn:mergeinfo
   + 

Modified: trunk/dports/sysutils/yum-createrepo/Portfile
===================================================================
--- trunk/dports/sysutils/createrepo/Portfile	2008-10-17 06:59:34 UTC (rev 40888)
+++ trunk/dports/sysutils/yum-createrepo/Portfile	2008-11-06 11:25:42 UTC (rev 41578)
@@ -2,8 +2,8 @@
 
 PortSystem 1.0
 
-name			createrepo
-version			0.4.11
+name			yum-createrepo
+version			0.9.6
 categories		sysutils
 platforms		darwin
 maintainers		afb at macports.org
@@ -13,24 +13,22 @@
 			apt, red-carpet(zen), smart, up2date, Yast and yum.
 
 homepage		http://createrepo.baseurl.org/
+distname		createrepo-${version}
 master_sites		${homepage}download/
-checksums		md5 3e9ccf4abcffe3f49af078c83611eda2 \
-				sha1 10316e9ee98e92f961c727cf991589611a2de7cb \
-				rmd160 74b89d3f097914bd5fc67282d083c063ad7fc18e
-patchfiles		patch-Makefile patch-createrepo patch-modifyrepo \
-			patch-dumpMetadata.py patch-genpkgmetadata.py \
-			patch-readMetadata.py patch-modifyrepo.py
+checksums		md5 d8b11b3b38205fe351497c7e10ae5500 \
+			sha1 8b5642fd4f699b77caf11baebd97e9ac0abf83b3 \
+			rmd160 dacd3d124688f2ff29d947f1f28de1d396808a4d
+patchfiles		patch-prefix.diff patch-sqlite.diff
 
-depends_run		port:python24 port:rpm port:py-yum-metadata-parser
+depends_run		port:python24 port:yum
 # this should be depends_test:
 depends_build	port:py-checker
 
-post-patch {
-	reinplace "s|__PREFIX__|${prefix}|g" \
-		${worksrcpath}/bin/createrepo ${worksrcpath}/bin/modifyrepo
-	reinplace "s|__PYTHON__|${prefix}/bin/python2.4|g" \
-		${worksrcpath}/dumpMetadata.py ${worksrcpath}/genpkgmetadata.py \
-		${worksrcpath}/readMetadata.py ${worksrcpath}/modifyrepo.py
+patch {
+		foreach patch $patchfiles {
+			system "cd '${workpath}/${distname}' && \
+			sed -e 's#@@PREFIX@@#${prefix}#g' -e 's#@@PYTHON@@#${prefix}/bin/python2.4#g' '${portpath}/${filesdir}/${patch}' | patch -p0"
+		}
 }
 
 use_configure	no
@@ -45,4 +43,4 @@
 livecheck.check	regex
 # get the last modified tarball
 livecheck.url	${master_sites}?C=M\;O=D
-livecheck.regex	${name}-(0\.4\.\[0-9.\]+)${extract.suffix}
+livecheck.regex	createrepo-(\[0-9.\]+)${extract.suffix}

Deleted: trunk/dports/sysutils/yum-createrepo/files/patch-Makefile
===================================================================
--- trunk/dports/sysutils/createrepo/files/patch-Makefile	2008-10-17 06:59:34 UTC (rev 40888)
+++ trunk/dports/sysutils/yum-createrepo/files/patch-Makefile	2008-11-06 11:25:42 UTC (rev 41578)
@@ -1,20 +0,0 @@
---- Makefile.orig	2007-11-26 21:23:16.000000000 +0100
-+++ Makefile	2007-12-14 09:25:01.000000000 +0100
-@@ -6,6 +6,8 @@
- prefix = /usr
- exec_prefix = ${prefix}
- 
-+PYTHON = python
-+
- bindir = ${exec_prefix}/bin
- sbindir = ${exec_prefix}/sbin
- libexecdir = ${exec_prefix}/libexec
-@@ -46,7 +48,7 @@
- 
- .SUFFIXES: .py .pyc
- .py.pyc: 
--	python -c "import py_compile; py_compile.compile($*.py)"
-+	$(PYTHON) -c "import py_compile; py_compile.compile($*.py)"
- 
- 
- all: $(MODULES)

Deleted: trunk/dports/sysutils/yum-createrepo/files/patch-createrepo
===================================================================
--- trunk/dports/sysutils/createrepo/files/patch-createrepo	2008-10-17 06:59:34 UTC (rev 40888)
+++ trunk/dports/sysutils/yum-createrepo/files/patch-createrepo	2008-11-06 11:25:42 UTC (rev 41578)
@@ -1,6 +0,0 @@
---- bin/createrepo	2006-03-04 07:30:50.000000000 +0100
-+++ bin/createrepo	2006-04-22 20:04:22.000000000 +0200
-@@ -1,2 +1,2 @@
- #!/bin/sh
--exec /usr/share/createrepo/genpkgmetadata.py "$@"
-+exec __PREFIX__/share/createrepo/genpkgmetadata.py "$@"

Deleted: trunk/dports/sysutils/yum-createrepo/files/patch-dumpMetadata.py
===================================================================
--- trunk/dports/sysutils/createrepo/files/patch-dumpMetadata.py	2008-10-17 06:59:34 UTC (rev 40888)
+++ trunk/dports/sysutils/yum-createrepo/files/patch-dumpMetadata.py	2008-11-06 11:25:42 UTC (rev 41578)
@@ -1,8 +0,0 @@
---- dumpMetadata.py	2006-06-10 18:28:03.000000000 +0200
-+++ dumpMetadata.py	2006-06-10 19:13:42.000000000 +0200
-@@ -1,4 +1,4 @@
--#!/usr/bin/python -t
-+#!__PYTHON__ -t
- # base classes and functions for dumping out package Metadata
- #
- # This program is free software; you can redistribute it and/or modify

Deleted: trunk/dports/sysutils/yum-createrepo/files/patch-genpkgmetadata.py
===================================================================
--- trunk/dports/sysutils/createrepo/files/patch-genpkgmetadata.py	2008-10-17 06:59:34 UTC (rev 40888)
+++ trunk/dports/sysutils/yum-createrepo/files/patch-genpkgmetadata.py	2008-11-06 11:25:42 UTC (rev 41578)
@@ -1,8 +0,0 @@
---- genpkgmetadata.py	2006-06-10 18:28:03.000000000 +0200
-+++ genpkgmetadata.py	2006-06-10 19:13:53.000000000 +0200
-@@ -1,4 +1,4 @@
--#!/usr/bin/python -t
-+#!__PYTHON__ -t
- # primary functions and glue for generating the repository metadata
- #
- 

Deleted: trunk/dports/sysutils/yum-createrepo/files/patch-modifyrepo
===================================================================
--- trunk/dports/sysutils/createrepo/files/patch-modifyrepo	2008-10-17 06:59:34 UTC (rev 40888)
+++ trunk/dports/sysutils/yum-createrepo/files/patch-modifyrepo	2008-11-06 11:25:42 UTC (rev 41578)
@@ -1,6 +0,0 @@
---- bin/modifyrepo.orig	2007-06-23 09:33:56.000000000 +0200
-+++ bin/modifyrepo	2007-06-23 09:36:03.000000000 +0200
-@@ -1,2 +1,2 @@
- #!/bin/sh
--exec /usr/share/createrepo/modifyrepo.py "$@"
-+exec __PREFIX__/share/createrepo/modifyrepo.py "$@"

Deleted: trunk/dports/sysutils/yum-createrepo/files/patch-modifyrepo.py
===================================================================
--- trunk/dports/sysutils/createrepo/files/patch-modifyrepo.py	2008-10-17 06:59:34 UTC (rev 40888)
+++ trunk/dports/sysutils/yum-createrepo/files/patch-modifyrepo.py	2008-11-06 11:25:42 UTC (rev 41578)
@@ -1,8 +0,0 @@
---- modifyrepo.py.orig	2007-11-26 21:23:16.000000000 +0100
-+++ modifyrepo.py	2007-12-14 09:17:43.000000000 +0100
-@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!__PYTHON__
- # $Id$
- #
- # This tools is used to insert arbitrary metadata into an RPM repository.

Added: trunk/dports/sysutils/yum-createrepo/files/patch-prefix.diff
===================================================================
--- trunk/dports/sysutils/yum-createrepo/files/patch-prefix.diff	                        (rev 0)
+++ trunk/dports/sysutils/yum-createrepo/files/patch-prefix.diff	2008-11-06 11:25:42 UTC (rev 41578)
@@ -0,0 +1,132 @@
+--- ./Makefile.orig	2008-10-28 20:58:14.000000000 +0100
++++ ./Makefile	2008-11-06 11:36:24.000000000 +0100
+@@ -2,7 +2,7 @@ PKGNAME = createrepo
+ VERSION=$(shell awk '/Version:/ { print $$2 }' ${PKGNAME}.spec)
+ RELEASE=$(shell awk '/Release:/ { print $$2 }' ${PKGNAME}.spec)
+ CVSTAG=createrepo-$(subst .,_,$(VERSION)-$(RELEASE))
+-PYTHON=python
++PYTHON=@@PYTHON@@
+ SUBDIRS = $(PKGNAME) bin docs
+ PYFILES = $(wildcard *.py)
+ 
+@@ -10,7 +10,7 @@ PYFILES = $(wildcard *.py)
+ SHELL = /bin/sh
+ top_srcdir = .
+ srcdir = .
+-prefix = /usr
++prefix = @@PREFIX@@
+ exec_prefix = ${prefix}
+ 
+ bindir = ${exec_prefix}/bin
+@@ -50,7 +50,7 @@ MODULES = $(srcdir)/genpkgmetadata.py \
+ 
+ .SUFFIXES: .py .pyc
+ .py.pyc: 
+-	python -c "import py_compile; py_compile.compile($*.py)"
++	$(PYTHON) -c "import py_compile; py_compile.compile($*.py)"
+ 
+ 
+ all: $(MODULES)
+--- ./bin/Makefile.orig	2008-10-28 20:58:14.000000000 +0100
++++ ./bin/Makefile	2008-11-06 11:32:42.000000000 +0100
+@@ -1,7 +1,7 @@
+ SHELL = /bin/sh
+ top_srcdir = ..
+ srcdir = ../bin
+-prefix = /usr
++prefix = @@PREFIX@@
+ exec_prefix = ${prefix}
+ 
+ bindir = ${exec_prefix}/bin
+--- ./bin/createrepo.orig	2008-10-28 20:58:14.000000000 +0100
++++ ./bin/createrepo	2008-11-06 11:33:18.000000000 +0100
+@@ -1,2 +1,2 @@
+ #!/bin/sh
+-exec /usr/share/createrepo/genpkgmetadata.py "$@"
++exec @@PREFIX@@/share/createrepo/genpkgmetadata.py "$@"
+--- ./bin/mergerepo.orig	2008-10-28 20:58:14.000000000 +0100
++++ ./bin/mergerepo	2008-11-06 11:33:48.000000000 +0100
+@@ -1,2 +1,3 @@
+ #!/bin/sh
+-exec /usr/share/createrepo/mergerepo.py "$@"
++exec @@PREFIX@@/share/createrepo/mergerepo.py "$@"
++
+--- ./bin/modifyrepo.orig	2008-10-28 20:58:14.000000000 +0100
++++ ./bin/modifyrepo	2008-11-06 11:33:27.000000000 +0100
+@@ -1,2 +1,2 @@
+ #!/bin/sh
+-exec /usr/share/createrepo/modifyrepo.py "$@"
++exec @@PREFIX@@/share/createrepo/modifyrepo.py "$@"
+--- ./genpkgmetadata.py.orig	2008-10-28 20:58:14.000000000 +0100
++++ ./genpkgmetadata.py	2008-11-06 11:34:22.000000000 +0100
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python -t
++#!@@PYTHON@@ -t
+ # primary functions and glue for generating the repository metadata
+ #
+ 
+--- ./mergerepo.py.orig	2008-10-28 20:58:14.000000000 +0100
++++ ./mergerepo.py	2008-11-06 11:34:52.000000000 +0100
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python -tt
++#!@@PYTHON@@ -tt
+ # This program is free software; you can redistribute it and/or modify
+ # it under the terms of the GNU General Public License as published by
+ # the Free Software Foundation; either version 2 of the License, or
+--- ./modifyrepo.py.orig	2008-10-28 20:58:14.000000000 +0100
++++ ./modifyrepo.py	2008-11-06 11:34:39.000000000 +0100
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python
++#!@@PYTHON@@
+ # This tools is used to insert arbitrary metadata into an RPM repository.
+ # Example:
+ #           ./modifyrepo.py updateinfo.xml myrepo/repodata
+--- createrepo/Makefile.orig	2008-10-28 20:58:14.000000000 +0100
++++ createrepo/Makefile	2008-11-06 11:42:50.000000000 +0100
+@@ -1,4 +1,4 @@
+-PYTHON=python
++PYTHON=@@PYTHON@@
+ PACKAGE = $(shell basename `pwd`)
+ PYFILES = $(wildcard *.py)
+ PYVER := $(shell $(PYTHON) -c 'import sys; print "%.3s" %(sys.version)')
+@@ -9,7 +9,7 @@ PKGDIR = $(PYLIBDIR)/site-packages/$(PKG
+ SHELL = /bin/sh
+ top_srcdir = ..
+ srcdir = ../$(PKGNAME)
+-prefix = /usr
++prefix = @@PREFIX@@
+ exec_prefix = ${prefix}
+ 
+ bindir = ${exec_prefix}/bin
+--- createrepo/merge.py.orig	2008-10-28 20:58:14.000000000 +0100
++++ createrepo/merge.py	2008-11-06 11:43:43.000000000 +0100
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python -tt
++#!@@PYTHON@@ -tt
+ # This program is free software; you can redistribute it and/or modify
+ # it under the terms of the GNU General Public License as published by
+ # the Free Software Foundation; either version 2 of the License, or
+--- createrepo/readMetadata.py.orig	2008-10-28 20:58:14.000000000 +0100
++++ createrepo/readMetadata.py	2008-11-06 11:43:39.000000000 +0100
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python -t
++#!@@PYTHON@@ -t
+ 
+ # This program is free software; you can redistribute it and/or modify
+ # it under the terms of the GNU General Public License as published by
+--- createrepo/utils.py.orig	2008-10-28 20:58:14.000000000 +0100
++++ createrepo/utils.py	2008-11-06 11:43:37.000000000 +0100
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python
++#!@@PYTHON@@
+ # util functions for createrepo
+ # This program is free software; you can redistribute it and/or modify
+ # it under the terms of the GNU General Public License as published by
+--- createrepo/yumbased.py.orig	2008-10-28 20:58:14.000000000 +0100
++++ createrepo/yumbased.py	2008-11-06 11:43:34.000000000 +0100
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python -tt
++#!@@PYTHON@@ -tt
+ # This program is free software; you can redistribute it and/or modify
+ # it under the terms of the GNU General Public License as published by
+ # the Free Software Foundation; either version 2 of the License, or

Deleted: trunk/dports/sysutils/yum-createrepo/files/patch-readMetadata.py
===================================================================
--- trunk/dports/sysutils/createrepo/files/patch-readMetadata.py	2008-10-17 06:59:34 UTC (rev 40888)
+++ trunk/dports/sysutils/yum-createrepo/files/patch-readMetadata.py	2008-11-06 11:25:42 UTC (rev 41578)
@@ -1,8 +0,0 @@
---- readMetadata.py.orig	2007-06-07 12:33:34.000000000 +0200
-+++ readMetadata.py	2007-06-29 13:33:08.000000000 +0200
-@@ -1,4 +1,4 @@
--#!/usr/bin/python -t
-+#!__PYTHON__ -t
- 
- # This program is free software; you can redistribute it and/or modify
- # it under the terms of the GNU General Public License as published by

Added: trunk/dports/sysutils/yum-createrepo/files/patch-sqlite.diff
===================================================================
--- trunk/dports/sysutils/yum-createrepo/files/patch-sqlite.diff	                        (rev 0)
+++ trunk/dports/sysutils/yum-createrepo/files/patch-sqlite.diff	2008-11-06 11:25:42 UTC (rev 41578)
@@ -0,0 +1,11 @@
+--- createrepo/__init__.py.orig	2008-10-28 20:58:14.000000000 +0100
++++ createrepo/__init__.py	2008-11-06 11:52:03.000000000 +0100
+@@ -36,7 +36,7 @@ import readMetadata
+ try:
+     import sqlite3 as sqlite
+ except ImportError:
+-    import sqlite
++    from pysqlite2 import dbapi2 as sqlite
+ 
+ try:
+     import sqlitecachec
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20081106/727ba48e/attachment.html>


More information about the macports-changes mailing list