diff -r c9323ebe0764 -r 71503088f51b openpkg/rpm.patch.feature --- a/openpkg/rpm.patch.feature Tue Jul 31 10:03:54 2012 +0200 +++ b/openpkg/rpm.patch.feature Tue Jul 31 12:12:54 2012 +0200 @@ -58,7 +58,7 @@ install-data-local: - @$(mkinstalldirs) $(DESTDIR)$(varprefix)/lib/rpm -+ @$(mkinstalldirs) $(DESTDIR)$(varprefix)/lib/openpkg ++ @$(mkinstalldirs) $(DESTDIR)$(libdir)/openpkg @rm -f $(DESTDIR)$(libdir)/rpmrc @@LN_S@ rpm/rpmrc $(DESTDIR)$(libdir)/rpmrc @rm -f $(DESTDIR)$(libdir)/rpmpopt @@ -184,7 +184,7 @@ install-data-local: - @$(mkinstalldirs) $(DESTDIR)$(varprefix)/lib/rpm -+ @$(mkinstalldirs) $(DESTDIR)$(varprefix)/lib/openpkg ++ @$(mkinstalldirs) $(DESTDIR)$(libdir)/openpkg @rm -f $(DESTDIR)$(libdir)/rpmrc @@LN_S@ rpm/rpmrc $(DESTDIR)$(libdir)/rpmrc @rm -f $(DESTDIR)$(libdir)/rpmpopt @@ -1934,6 +1934,8 @@ | (package build-time feature for performing vendor source tracking) | and %test (package install-time feature for performing package | run-time tests). +| +| MSvB: Additionally provide a default %clean section, removing buildroot. +--------------------------------------------------------------------------- Index: build/parseSpec.c --- build/parseSpec.c 15 May 2003 13:38:57 -0000 1.1.1.15 @@ -1965,6 +1967,20 @@ case PART_NONE: /* XXX avoid gcc whining */ case PART_LAST: case PART_BUILDARCHITECTURES: +@@ -576,6 +589,13 @@ + } + /*@=infloops@*/ /* LCL: parsePart is modified @*/ + ++ if (spec->clean == NULL) { ++ char *body = rpmExpand("%{?buildroot: %{__rm} -rf %{buildroot}}", NULL); ++ spec->clean = newStringBuf(); ++ appendLineStringBuf(spec->clean, body); ++ free(body); ++ } ++ + /* Check for description in each package and add arch and os */ + { + #ifdef DYING +--------------------------------------------------------------------------- | Add support for the OpenPKG custom .spec file sections %track