Summary: | dev-vcs/colorsvn-0.3.2-r2 : add prefix support | ||
---|---|---|---|
Product: | Gentoo/Alt | Reporter: | Myk Taylor <myk002> |
Component: | Prefix Support | Assignee: | Gentoo Prefix <prefix> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | idl0r |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | OS X | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 315803 | ||
Attachments: |
patched ebuild
patch for Makefile.in |
Created attachment 324222 [details, diff]
patch for Makefile.in
stabilize? Changed Summary. I feel like your patch to Makefile.in is faulty, since ebuilds must install to DESTDIR and not the live fs directly. This isn't a "hack" in the ebuild, as you say. Ah, sorry if I misread this. I'm quite new to prefix. This is what I'm seeing: In the Makefile (generated from Makefile.in), DESTDIR is respected. Config files are installed to DESTDIR/confdir. It's just that confdir ignores the values passed in to ./configure and is hard-coded to /etc. sysconfdir, defined in the line previous to confdir, correctly derives its value from the parameters to ./configure. Removing the DESTDIR definition from the ebuild prevents $EPREFIX from being prepended twice to all other paths (i.e. when DESTDIR is defined in the ebuild, lcov gets installed into $EPREFIX/$EPREFIX/usr/bin/lcov). Of course, when DESTDIR is defined in the original ebuild, config files go the right place, but for the wrong reason. looking in other ebuilds, perhaps this would be more appropriate: - emake PREFIX="${D}" install || die "emake install failed" + emake PREFIX="${ED}" install || die "emake install failed" i.e. using PREFIX instead of DESTDIR? The problem is that the Makefile hardcodes confdir. It is a broken build system, this fixes it and obsoletes your patch: + sed -i -e '/^confdir/d' Makefile.in || die + sed -i -e 's/$(confdir)/$(sysconfdir)/g' Makefile.in || die Please test. confirmed: your code (added to prepare()) works without any additional patches. Thanks! (In reply to comment #5) > The problem is that the Makefile hardcodes confdir. It is a broken build > system, this fixes it and obsoletes your patch: > > + sed -i -e '/^confdir/d' Makefile.in || die > + sed -i -e 's/$(confdir)/$(sysconfdir)/g' Makefile.in || die @idl0r: are you ok with adding this to src_prepare? (In reply to comment #7) > (In reply to comment #5) > > The problem is that the Makefile hardcodes confdir. It is a broken build > > system, this fixes it and obsoletes your patch: > > > > + sed -i -e '/^confdir/d' Makefile.in || die > > + sed -i -e 's/$(confdir)/$(sysconfdir)/g' Makefile.in || die > > @idl0r: are you ok with adding this to src_prepare? +1 Just add a comment / bug id there as well please. (In reply to comment #8) > (In reply to comment #7) > > (In reply to comment #5) > > > The problem is that the Makefile hardcodes confdir. It is a broken build > > > system, this fixes it and obsoletes your patch: > > > > > > + sed -i -e '/^confdir/d' Makefile.in || die > > > + sed -i -e 's/$(confdir)/$(sysconfdir)/g' Makefile.in || die > > > > @idl0r: are you ok with adding this to src_prepare? > > +1 > Just add a comment / bug id there as well please. thanks, committed and done. |
Created attachment 324220 [details] patched ebuild I got colorsvn working on my OSX 10.8 (Mountain Lion) system. The ebuild needed some manual updating. The package's Makefile.in had hard-coded /etc instead of using %sysconfdir%, and the ebuild had been working around that. I patched Makefile.in and removed the hack in the ebuild. --- usr/portage/dev-vcs/colorsvn/colorsvn-0.3.2-r2.ebuild 2010-12-29 08:20:06.000000000 -0800 +++ usr/local/portage/dev-vcs/colorsvn/colorsvn-0.3.2-r2.ebuild 2012-09-18 09:54:31.000000000 -0700 @@ -24,6 +24,7 @@ sed -i -e 's:rxvt:rxvt rxvt-unicode:' colorsvnrc-original || die epatch "${FILESDIR}/0001-Don-t-colorize-svn-mkdir-bug-321451.-Use-IPC-open2-i.patch" + epatch "${FILESDIR}/0002-Makefile_in_respect_sysconfdir.patch" } src_compile() { @@ -32,7 +33,7 @@ } src_install() { - emake DESTDIR="${D}" install || die "emake install failed" + emake install || die "emake install failed" dodoc CREDITS || die "dodoc failed" } patched ebuild and patch for Makefile.in attached