Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 501332 - dev-db/couchdb-1.5.0 add Gentoo Prefix support
Summary: dev-db/couchdb-1.5.0 add Gentoo Prefix support
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-14 22:30 UTC by Matt
Modified: 2014-12-29 10:52 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,10.96 KB, text/plain)
2014-02-14 22:31 UTC, Matt
Details
couchdb prefix patch (couchdb-1.5.0-prefix.patch,1.45 KB, patch)
2014-02-15 18:01 UTC, Jeremy Olexa (darkside) (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Matt 2014-02-14 22:30:45 UTC
couchdb fails building on a Gentoo "prefix" installation (see <http://www.gentoo.org/proj/en/gentoo-alt/prefix/>) because the .ebuild paths are hard coded to use /usr, etc. The build fails for both 1.4.0 and 1.5.0.

Reproducible: Always

Steps to Reproduce:
1. Create a "prefix" installation (e.g., in "${HOME}/gentoo").
2. Install couchdb (e.g., "emerge ... couchdb").
Actual Results:  
See attached build.log for details. Relevant parts (actual prefix path has been replaced with "[__PREFIX__]"):

...
./configure --prefix=[__PREFIX__]/usr --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu --mandir=[__PREFIX__]/usr/share/man --infodir=[__P\
REFIX__]/usr/share/info --datadir=[__PREFIX__]/usr/share --sysconfdir=[__PREFIX__]/etc --localstatedir=[__PREFIX__]/var/lib --libdir=[__PREFIX_\
_]/usr/lib --disable-dependency-tracking --with-erlang=/usr/lib/erlang/usr/include --localstatedir=/var --with-js-lib=/usr/lib
...
checking erl_driver.h usability... no
checking erl_driver.h presence... no
checking for erl_driver.h... no
configure: error: Could not find the `erl_driver.h' header.
...

Expected Results:  
I expected it to build and install without error.

Note that configure has been called with:

--with-erlang=/usr/lib/erlang/usr/include

This is hard-coded in [__PREFIX__]/usr/portage/dev-db/couchdb/couchdb-1.[45].0.ebuild.
Comment 1 Matt 2014-02-14 22:31:27 UTC
Created attachment 370438 [details]
build.log

Note, the actual prefix has been replaced with the text "[__PREFIX__]".
Comment 2 Dirkjan Ochtman (RETIRED) gentoo-dev 2014-02-15 14:15:14 UTC
Prefix guys, feel free to fix this, I'll post-review.
Comment 3 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2014-02-15 18:01:58 UTC
Created attachment 370506 [details, diff]
couchdb prefix patch

Something like this will have to be tested
Comment 4 Matt 2014-02-15 18:51:57 UTC
I'm happy to test if someone can tell me how to get around this:

> * Digest verification failed:
> * [__PREFIX__]/usr/portage/dev-db/couchdb/couchdb-1.5.0.ebuild
> * Reason: Filesize does not match recorded size
> * Got: 1827
> * Expected: 1775

The man page seems to indicate that emerge ... manifest ... is the way to go:

>       manifest
>              Updates the manifest file for the package.  This creates checksums for all of the files found in the same directory
>              as the current ebuild as well as the recursive contents of the files subdirectory. It also  creates  checksums  for
>              all of the files listed in SRC_URI for each ebuild. For further information regarding the behavior of this command,
>              see the documentation for the assume-digests value of the FEATURES variable in make.conf(5). See the --force option
>              if you would like to prevent digests from being assumed.

But I'm afraid to do emerge couchdb manifest --force based on this comment:

http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=2&chap=1#digesterror

If someone can confirm what the appropriate steps are to test, I can at least look to see that it's resolved in my environment. Someone else will have to test to make sure it doesn't brake non-prefix builds....
Comment 5 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2014-02-15 19:04:45 UTC
(In reply to Matt from comment #4)
 
> But I'm afraid to do emerge couchdb manifest --force based on this comment:
> 
> http://www.gentoo.org/doc/en/handbook/handbook-x86.
> xml?part=2&chap=1#digesterror

Obviously, since you are modifying your local tree, it is "safe" to modify your own manifest(s). :)

apply fix locally
cd usr/portage/dev-db/couchdb
ebuild couchdb-1.5.0.ebuild manifest
Comment 6 Matt 2014-02-16 22:54:37 UTC
Thanks for the pointer. (As you might have guessed, I'm a noob when it comes to the nuances of the Gentoo build system, so I'm basically one step up from a turnip.)

I can verify this now builds on my prefix installation.
Comment 7 Dirkjan Ochtman (RETIRED) gentoo-dev 2014-12-29 10:52:57 UTC
Fixed in couchdb-1.6.1.