Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 35723 - filte-flags in dietlibc ebuild is ignored
Summary: filte-flags in dietlibc ebuild is ignored
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Alexander Gabert (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-12-13 06:24 UTC by Jens Gutzeit
Modified: 2003-12-13 20:10 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jens Gutzeit 2003-12-13 06:24:21 UTC
Seems the filter-flags in dietlibc 0.24 ebuild is somewhat broken. It doesn't filter out the "-fstack-protector" which results in compilation errors.

CFLAGS="-O3 -march=i686 -funroll-loops -pipe -fstack-protector"

A line from the build process:
gcc -I. -Iinclude -O3 -march=i686 -funroll-loops -pipe -fstack-protector -c syscalls.s/sched_get_priority_max.S -o bin-i386/sched_get_priority_max.o

My portage version: 2.0.49-r18

BTW: in the grub ebuild the filter-flags works, seems its really dietlibc-ebuild specific.


Reproducible: Always
Steps to Reproduce:
1.
2.
3.
Comment 1 Jens Gutzeit 2003-12-13 08:34:12 UTC
Ok I had a deeper look into the ebuild now. filter-flags should go into src_unpack
Comment 2 Alexander Gabert (RETIRED) gentoo-dev 2003-12-13 20:10:16 UTC
src_unpack() {
    unpack ${A} ; cd ${S}

    epatch ${FILESDIR}/${PV}-dirent-prototype.patch

    # depending on glibc to provide guard symbols, does not work with -nostdlib building
    filter-flags "-fstack-protector"
    filter-flags "fstack-protector-all"

    sed -i \
        -e "s:^CFLAGS.*:CFLAGS = ${CFLAGS}:" \
        -e "s:^prefix.*:prefix=/usr/diet:" \
        -e "s:^#DESTDIR=.*:DESTDIR=${D}:" Makefile || \
            die "sed Makefile failed"

    ht_fix_all
}

src_compile() {
    filter-flags "-fstack-protector"

the second filter-flags in src_compile is useless because the sed logic to insert the CFLAGS comes before in src_unpack

>>> dev-libs/dietlibc-0.24 merged.


hooray,

Alex