Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 474358 - sys-devel/gcc: update to EAPI 4 (mostly toolchain.eclass)
Summary: sys-devel/gcc: update to EAPI 4 (mostly toolchain.eclass)
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords:
Depends on: 531610
Blocks: prefix-gx86 372663 519080
  Show dependency tree
 
Reported: 2013-06-22 21:15 UTC by Paweł Hajdan, Jr. (RETIRED)
Modified: 2015-05-24 07:02 UTC (History)
3 users (show)

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


Attachments
toolchain.eclass.diff (toolchain.eclass.diff,4.12 KB, patch)
2013-06-22 21:15 UTC, Paweł Hajdan, Jr. (RETIRED)
Details | Diff
gcc-4.7.3.ebuild.diff (gcc-4.7.3.ebuild.diff,1.16 KB, patch)
2013-06-22 21:15 UTC, Paweł Hajdan, Jr. (RETIRED)
Details | Diff
prefix.patch (toolchain.patch,20.28 KB, patch)
2013-07-28 05:40 UTC, Benda Xu
Details | Diff
darwin.patch (darwin.patch,1.17 KB, patch)
2013-07-28 05:43 UTC, Benda Xu
Details | Diff
includes.patch (includes.patch,972 bytes, patch)
2013-07-28 05:44 UTC, Benda Xu
Details | Diff
prefix.patch (toolchain.patch,18.78 KB, patch)
2013-07-28 06:27 UTC, Benda Xu
Details | Diff
prefix.patch (toolchain.patch,19.52 KB, patch)
2013-08-12 08:26 UTC, Benda Xu
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2013-06-22 21:15:03 UTC
There are features in more recent EAPIs that could be used by the core packages.

Care should be taken to provide an upgrade path - just note that there are requirements created by e.g. python and portage anyway.

I'll attach draft patches for toolchain.eclass and gcc ebuild - feedback is welcome and I can later proceed to do a similar thing for example for binutils.
Comment 1 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2013-06-22 21:15:43 UTC
Created attachment 351678 [details, diff]
toolchain.eclass.diff
Comment 2 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2013-06-22 21:15:59 UTC
Created attachment 351680 [details, diff]
gcc-4.7.3.ebuild.diff
Comment 3 Ryan Hill (RETIRED) gentoo-dev 2013-06-24 21:44:59 UTC
I'm surprised there are no prefix changes.
Comment 4 Arfrever Frehtes Taifersar Arahesis 2013-07-26 00:47:28 UTC
New EAPIs could be supported without introduction of new eclass.
E.g.:
if has "${EAPI:-0}" 0 1 2 3; then
    EXPORT_FUNCTIONS pkg_setup src_unpack src_compile src_test src_install pkg_postinst pkg_postrm
else
    EXPORT_FUNCTIONS pkg_pretend pkg_setup src_unpack src_prepare src_configure src_compile src_test src_install pkg_postinst pkg_postrm
fi
...
        if ! has "${EAPI:-0}" 0 1 2 3; then
            REQUIRED_USE+=" gcj? ( cxx )"
        fi
Comment 5 Ryan Hill (RETIRED) gentoo-dev 2013-07-26 01:29:46 UTC
Yes, there won't be a new eclass, i'm working on the existing one.
Comment 6 Benda Xu gentoo-dev 2013-07-28 05:40:58 UTC
Created attachment 354370 [details, diff]
prefix.patch

toolchain eclass Prefix support.

TODO: do we really need to guard against symlink in EPREFIX? Can we make it a function to reduce code duplication?
Comment 7 Benda Xu gentoo-dev 2013-07-28 05:43:58 UTC
Created attachment 354372 [details, diff]
darwin.patch

darwin libtool fix, and rpath?? (TODO: not sure of the source)
Comment 8 Benda Xu gentoo-dev 2013-07-28 05:44:55 UTC
Created attachment 354374 [details, diff]
includes.patch

Seems that in Prefix we retained the fixinclude hack. What's special for ia64?
Comment 9 Benda Xu gentoo-dev 2013-07-28 05:47:33 UTC
(In reply to Benda Xu from comment #6)
> Created attachment 354370 [details, diff] [details, diff]
> prefix.patch
> 
> toolchain eclass Prefix support.
> 
> TODO: do we really need to guard against symlink in EPREFIX? Can we make it
> a function to reduce code duplication?

We also need a way to distinguish between gentoo-fbsd (vanilla) and gentoo-freebsd (Prefix)
Comment 10 Benda Xu gentoo-dev 2013-07-28 06:27:59 UTC
Created attachment 354376 [details, diff]
prefix.patch

I think we'd better drop support for EPREFIX with a symlink, it can be avoided after all.

Comments, haubi?
Comment 11 Benda Xu gentoo-dev 2013-08-12 08:26:50 UTC
Created attachment 355744 [details, diff]
prefix.patch

drop TPREFIX and add a warning for EPREFIX with a symlink as per bug 478434 comment 3.
Comment 12 Benda Xu gentoo-dev 2013-09-21 13:18:11 UTC
Hey, guys. Have you reviewed the patches? Comments welcome so that I could improve it to meet the quality standard.
Comment 13 Ryan Hill (RETIRED) gentoo-dev 2013-12-14 01:53:51 UTC
I'm working on refactoring the eclass now to make separating stuff into the new phase functions a bit cleaner.  Benda, I'd like you to open a new bug for the prefix changes, and I'll need Mike to do the review because I'm really not qualified.  It would be best if you could wait until this bug is closed as any patch you make now won't apply after I'm done here.

I'm strongly considering adding a new toolchain-next eclass for unstable gcc ebuilds.  This would allow us to test big changes without breaking stable versions.  Mike, what do you think?
Comment 14 Benda Xu gentoo-dev 2013-12-14 02:47:11 UTC
(In reply to Ryan Hill from comment #13)
> I'm working on refactoring the eclass now to make separating stuff into the
> new phase functions a bit cleaner.  Benda, I'd like you to open a new bug
> for the prefix changes, and I'll need Mike to do the review because I'm
> really not qualified.  It would be best if you could wait until this bug is
> closed as any patch you make now won't apply after I'm done here.

I am aware that there is a lot of work for a refactorization. I'm okay with plan.
Comment 15 SpanKY gentoo-dev 2014-09-10 22:14:46 UTC
other toolchain packages (binutils/gdb/glibc) are handled in other bugs (and are done now), so this bug is only about gcc
Comment 16 Benda Xu gentoo-dev 2014-12-04 02:04:26 UTC
Now that the toolchain.eclass in tree already supports EAPI 4 and 5, we can close this bug and open a Prefix bug separately, right?
Comment 17 SpanKY gentoo-dev 2015-05-24 07:02:01 UTC
yes, let's handle any more issues in new bugs