Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 489542 - netsurf.eclass should not include EROOT in PREFIX
Summary: netsurf.eclass should not include EROOT in PREFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Eclasses (show other bugs)
Hardware: All Linux
: Normal normal with 1 vote (vote)
Assignee: No maintainer - Look at if you want to take care of it
Depends on:
Reported: 2013-10-27 08:45 UTC by Another Mortal
Modified: 2020-06-21 12:18 UTC (History)
2 users (show)

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


Note You need to log in before you can comment on or make changes to this bug.
Description Another Mortal 2013-10-27 08:45:32 UTC
Running 'emerge --root=/test-root netsurf-3.0-r1' breaks on
        mv -v "${ED}"/usr/bin/netsurf{,-gtk} || die
because the install procedure directs output to ${ED}${EROOT}usr ...

Also, files in the "live" system will end up in /test-root/test-root/usr
instead of /test-root/usr..

Reproducible: Always

--- /usr/portage/eclass/netsurf.eclass.orig     2013-10-27 09:36:51.876661016 +0100
+++ /usr/portage/eclass/netsurf.eclass  2013-10-27 09:37:00.112558053 +0100
@@ -83,7 +83,7 @@
                BUILD=$(usex debug debug release)
-               PREFIX="${EROOT}"usr
+               PREFIX=/usr
Comment 1 Another Mortal 2016-12-29 19:46:22 UTC
After 3 years this bug is still unresolved,
despite the fact that the change is trivial.
Anything wrong?
Comment 2 Another Mortal 2016-12-30 11:56:01 UTC
BTW, the problem is not only that everything ends up in the wrong place,
setting the prefix also hardcodes those faulty paths in the executable,
which means that after moving everything to the "right" place 'netsurf'
doesn't find its dependencies, resulting in errors like this:

> netsurf
Message translations failed to load
Unable to initialise the font system

Is there some other scenario I'm not aware of (like setting EPREFIX
manually, or some such), where this behaviour can be seen as useful?
Comment 3 Another Mortal 2018-01-14 22:29:10 UTC
Another year, still no progress?  )-;

Or, perhaps there is, I haven't bothered checking.
Comment 4 Michael Orlitzky gentoo-dev 2020-06-10 21:16:01 UTC
Let's fix this after seven years. Can you send a patch to the gentoo-dev mailing list. All eclass changes generally go there. The netsurf eclass is limited in scope so it might have normally earned an exception, but since no one is maintaining it, that will collect a few more eyeballs. If no one sees a problem with it I'll merge your fix.
Comment 5 Larry the Git Cow gentoo-dev 2020-06-16 17:49:30 UTC
The bug has been referenced in the following commit(s):

commit a73024729860f9224b8d1660d24c450080b67d9f
Author:     Michael Orlitzky <>
AuthorDate: 2020-06-16 17:36:35 +0000
Commit:     Zac Medico <>
CommitDate: 2020-06-16 17:49:02 +0000

    repoman: deprecate netsurf.eclass.
    While investigating bug 489542, it became clear that the netsurf
    eclass is deprecated in spirit if not in fact. All of the newer
    netsurf ebuilds use a custom function loaded from a script that is
    shipped in netsurf-buildsystem's $FILESDIR to do (some of) what the
    eclass used to do. That function probably does belong in an eclass,
    but at this point, we should throw this thing out and start from
    By deprecating the eclass, we make sure that no one else inherits it
    during the time it takes to purge the two remaining consumers. Then,
    once those are gone, the build system script magic can be put back
    into an eclass, and its consumers updated one-at-a-time.
    Signed-off-by: Michael Orlitzky <>
    Signed-off-by: Zac Medico <>

 repoman/lib/repoman/modules/linechecks/deprecated/ | 1 +
 1 file changed, 1 insertion(+)
Comment 6 Larry the Git Cow gentoo-dev 2020-06-17 13:38:41 UTC
The bug has been referenced in the following commit(s):

commit eee8e638bf1559af6f93fe2995d69e2b0b9f176c
Author:     Michael Orlitzky <>
AuthorDate: 2020-06-17 11:37:50 +0000
Commit:     Michael Orlitzky <>
CommitDate: 2020-06-17 13:38:16 +0000

    dev-util/netsurf-buildsystem: new version 1.9.
    This version comes with a that contains the
    correct Gentoo-prefix paths for PREFIX and NSSHARED. The problem was
    originally reported against netsurf.eclass, but it has migrated to
    this script in the meantime.
    Package-Manager: Portage-2.3.99, Repoman-2.3.22
    Signed-off-by: Michael Orlitzky <>

 dev-util/netsurf-buildsystem/Manifest              |  1 +
 .../netsurf-buildsystem/files/ | 22 ++++++++++++++++++
 .../netsurf-buildsystem-1.9.ebuild                 | 26 ++++++++++++++++++++++
 3 files changed, 49 insertions(+)
Comment 7 Michael Orlitzky gentoo-dev 2020-06-17 13:42:40 UTC
This is now fixed in netsurf-buildsystem-1.9, and all of its consumers *except* www-client/netsurf itself. When the proxy maintainer gets around to doing the v3.10 version bump, that will be fixed as well.

This eclass is now deprecated, and will be marked dead as soon as the one remaining consumer (dev-libs/libparserutils) can be stabilized and cleaned up. So, there's no point in fixing the eclass itself.

It's been a wild ride, thanks for pointing out the breakage!
Comment 8 Larry the Git Cow gentoo-dev 2020-06-21 12:18:07 UTC
The bug has been referenced in the following commit(s):

commit ca7819ae8a75cab9e401e3106415a6528cdd1f52
Author:     Michael Orlitzky <>
AuthorDate: 2020-06-21 01:43:05 +0000
Commit:     Michael Orlitzky <>
CommitDate: 2020-06-21 12:17:03 +0000

    www-client/netsurf: new version 3.10.
    This new version (bug 727882) combined with the removal of the old
    versions fixes some outstanding issues:
      * Fixes the mixup between ED/D (and EROOT, variously) throughout
        the build system (bug 489542).
      * Adds a dependency on dev-lang/duktape, but as a result, has to
        drop keywords for arm, ppc, and ppc64 (bugs 698650, 728592).
      * Adds a patch to fix the location of utf8proc.h (bug 721318)
      * Adds a patch to disable failing tests (bug 687378).
      * Drops the broken USE=pdf-writer flag (bug 625770).
      * Apparently fixes the test failure with USE="-gtk2", since the
        test suite now passes (bug 672812).
      * Eliminates another test failure in v3.8 (bug 701322).
    Package-Manager: Portage-2.3.99, Repoman-2.3.22
    Signed-off-by: Michael Orlitzky <>

 www-client/netsurf/Manifest                        |   1 +
 .../files/netsurf-3.10-disable-failing-tests.patch |  42 +++++++
 ...rf-3.10-julia-libutf8proc-header-location.patch |  34 ++++++
 www-client/netsurf/netsurf-3.10.ebuild             | 131 +++++++++++++++++++++
 4 files changed, 208 insertions(+)