Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 529694 - dev-lang/ghc-7.6.3-r1 - make: invalid option -- '>'
Summary: dev-lang/ghc-7.6.3-r1 - make: invalid option -- '>'
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Gentoo's Haskell Language team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-18 15:13 UTC by Heinrich Götzger
Modified: 2014-11-23 18:46 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 Heinrich Götzger 2014-11-18 15:13:55 UTC
Emerge of failed with following message:

[...]
>>> Source configured.
>>> Compiling source in /var/tmp/portage/dev-lang/ghc-7.6.3-r1/work/ghc-7.6.3 ...
make -j9 * Limiting MAKEOPTS -j9 -> -j4 (bug #456386) -j4 ghc/stage2/build/tmp/ghc-stage2 V=1 
make: invalid option -- '>'
Usage: make [options] [target] ...
Options:
[...]


Reproducible: Always




# emerge --info
Portage 2.2.8-r2 (default/linux/amd64/13.0, gcc-4.8.3, glibc-2.19-r1, 3.10.32-gentoo x86_64)
=================================================================
System uname: Linux-3.10.32-gentoo-x86_64-Intel-R-_Core-TM-_i7-2860QM_CPU_@_2.50GHz-with-gentoo-2.2
KiB Mem:     8140408 total,   3020504 free
KiB Swap:    8388604 total,   8388604 free
Timestamp of tree: Tue, 18 Nov 2014 12:45:01 +0000
ld GNU ld (Gentoo 2.24 p1.4) 2.24
app-shells/bash:          4.2_p53
dev-java/java-config:     2.2.0
dev-lang/perl:            5.18.2-r2
dev-lang/python:          2.7.7, 3.2.5-r6, 3.3.5-r1, 3.4.1
dev-util/cmake:           2.8.12.2-r1
dev-util/pkgconfig:       0.28-r1
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.12.4
sys-apps/sandbox:         2.6-r1
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.11.6, 1.12.6, 1.13.4
sys-devel/binutils:       2.24-r3
sys-devel/gcc:            4.8.3
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4.2-r1
sys-devel/make:           4.0-r1
sys-kernel/linux-headers: 3.13 (virtual/os-headers)
sys-libs/glibc:           2.19-r1
Repositories: gentoo x-local
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=core2 -mtune=generic -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/maven-bin-3.0/conf /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=core2 -mtune=generic -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://io http://boo http://mirror.netcologne.de/gentoo/ ftp://ftp-stud.hs-esslingen.de/pub/Mirrors/gentoo/ http://ftp.uni-erlangen.de/pub/mirrors/gentoo ftp://gentoo.imj.fr/pub/gentoo/ ftp://91.121.125.139/gentoo-distfiles/ http://gentoo.supp.name/ ftp://mirror.netcologne.de/gentoo/ http://gentoo.mirror.dkm.cz/pub/gentoo/ rsync://gentoo.mirror.dkm.cz/gentoo/ http://gd.tuwien.ac.at/opsys/linux/gentoo/ ftp://ftp.snt.utwente.nl/pub/os/linux/gentoo"
LANG="C"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j9"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local"
SYNC="rsync://io/gentoo-portage"
USE="X a52 acl acpi alsa amd64 apache2 apm arts avi bash-completion berkdb bitmap-fonts bzip2 cdr cli corefonts cracklib crypt cups cxx dbus divx4linux dri dv dvd dvdr dvdread encode exif fame foomaticdb fortran gdbm gif gtk gtk2 iconv imagemagick ipv6 java jikes jpeg jpg kde kipi mjpeg mmx modules mp3 mpeg multilib ncurses nls nptl nptlonly ogg opengl openmp pam pcmcia pcre pdf png ppds python qt3 qt3support qt4 quicktime rdesktop readline samba semantic-desktop session sse sse2 ssl subtitles svg tcpd truetype truetype-fonts type1-fonts unicode usb vorbis xine xinerama xml xulrunner xv xvid zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="evdev synaptics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_3" RUBY_TARGETS="ruby19 ruby20" USERLAND="GNU" VIDEO_CARDS="nvidia nv vesa fbdev" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON

# cat /proc/cpuinfo 
processor       : 0
vendor_id       : GenuineIntel
cpu family      : 6
model           : 42
model name      : Intel(R) Core(TM) i7-2860QM CPU @ 2.50GHz
stepping        : 7
microcode       : 0x17
cpu MHz         : 2501.000
cache size      : 8192 KB
physical id     : 0
siblings        : 8
core id         : 0
cpu cores       : 4
apicid          : 0
initial apicid  : 0
fpu             : yes
fpu_exception   : yes
cpuid level     : 13
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts nopl xtopology nonstop_tsc aperfmperf eagerfpu pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 cx16 xtpr pdcm pcid sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes xsave avx lahf_lm ida arat epb xsaveopt pln pts dtherm tpr_shadow vnmi flexpriority ept vpid
bogomips        : 4988.82
clflush size    : 64
cache_alignment : 64
address sizes   : 36 bits physical, 48 bits virtual
power management:

but eight of them ....
Comment 1 Sergei Trofimovich (RETIRED) gentoo-dev 2014-11-20 22:32:42 UTC
Integesting, somehow ewarn managed to pipe stderr to stdout.
It certainly does not happen here, which is odd.

MAKEOPTS=-j4 ahould be a stop-gap workaround for you, but

do you happen to do something with manually
overriding portage's ewarn via /etc/portage/bashrc or something like that?

I'll remove ewarn from limit_jobs if we won't find real cause.
Comment 2 Heinrich Götzger 2014-11-21 09:10:55 UTC
(In reply to Sergei Trofimovich from comment #1)
> Interesting, somehow ewarn managed to pipe stderr to stdout.
Interesting, that's what I thought as well ...

> It certainly does not happen here, which is odd.

> MAKEOPTS=-j4 ahould be a stop-gap workaround for you, but
> do you happen to do something with manually
> overriding portage's ewarn via /etc/portage/bashrc or something like that?
Yes, with MAKEOPTS=-j4 it is working as expected.

After successful emerge with j4, I tried again with j9 and it failed again as described earlier.

I have no /etc/portage/bashrc and I'm not aware that I do something like ewarn manipulation.
The only occurrence besides lots of usage in /etc/.... is in /etc/portage/profile/profile.bashrc

ewarn() {
        enotice warn "${*}"
}

> I'll remove ewarn from limit_jobs if we won't find real cause.
Is there a way how I can debug this?
Comment 3 Sergei Trofimovich (RETIRED) gentoo-dev 2014-11-22 12:01:49 UTC
(In reply to Heinrich Götzger from comment #2)
> (In reply to Sergei Trofimovich from comment #1)
> > Interesting, somehow ewarn managed to pipe stderr to stdout.
> Interesting, that's what I thought as well ...
> 
> > It certainly does not happen here, which is odd.
> 
> > MAKEOPTS=-j4 ahould be a stop-gap workaround for you, but
> > do you happen to do something with manually
> > overriding portage's ewarn via /etc/portage/bashrc or something like that?
> Yes, with MAKEOPTS=-j4 it is working as expected.
> 
> After successful emerge with j4, I tried again with j9 and it failed again
> as described earlier.
> 
> I have no /etc/portage/bashrc and I'm not aware that I do something like
> ewarn manipulation.
> The only occurrence besides lots of usage in /etc/.... is in
> /etc/portage/profile/profile.bashrc
> 
> ewarn() {
>         enotice warn "${*}"
> }
> 
> > I'll remove ewarn from limit_jobs if we won't find real cause.
> Is there a way how I can debug this?

Interesting! Where did you get that file from? Must be a remnant of
ancient portage install (or a manual tweak?).

Right now 'ewarn()' lives in
    /usr/lib/portage/python*/isolated-functions.sh
which carefully pipes text into stderr:
    ewarn() {
        __elog_base WARN "$*"
        [[ ${RC_ENDCOL} != "yes" && ${LAST_E_CMD} == "ebegin" ]] && echo
        echo -e "$@" | while read -r ; do
                echo " $WARN*$NORMAL $RC_INDENTATION$REPLY" >&2
        done
        LAST_E_CMD="ewarn"
        return 0
    }

Can you post your complete /etc/portage/profile/profile.bashrc ?
Would ease tracking of it's origin.
Comment 4 Heinrich Götzger 2014-11-23 12:04:45 UTC
(In reply to Sergei Trofimovich from comment #3)
> (In reply to Heinrich Götzger from comment #2)
> > (In reply to Sergei Trofimovich from comment #1)
> > > Interesting, somehow ewarn managed to pipe stderr to stdout.
> > Interesting, that's what I thought as well ...

[...[

> > I have no /etc/portage/bashrc and I'm not aware that I do something like
> > ewarn manipulation.
> > The only occurrence besides lots of usage in /etc/.... is in
> > /etc/portage/profile/profile.bashrc
> > 
> > ewarn() {
> >         enotice warn "${*}"
> > }
> > 

> Interesting! Where did you get that file from? Must be a remnant of
> ancient portage install (or a manual tweak?).
Ancient hits it pretty good, I think. Manual? I can't remember.

> Right now 'ewarn()' lives in
>     /usr/lib/portage/python*/isolated-functions.sh
> which carefully pipes text into stderr:
>     ewarn() {
>         __elog_base WARN "$*"
>         [[ ${RC_ENDCOL} != "yes" && ${LAST_E_CMD} == "ebegin" ]] && echo
>         echo -e "$@" | while read -r ; do
>                 echo " $WARN*$NORMAL $RC_INDENTATION$REPLY" >&2
>         done
>         LAST_E_CMD="ewarn"
>         return 0
>     }
> 
> Can you post your complete /etc/portage/profile/profile.bashrc ?
> Would ease tracking of it's origin.
Sure, here it is:

root@io:~ # cat /etc/portage/profile/profile.bashrc
if [ "$EBUILD_PHASE" != "depend" ]; then
        if [ ! -z "${PORT_ENOTICE_DIR}" ]; then
                export SANDBOX_WRITE="$SANDBOX_WRITE:${PORT_ENOTICE_DIR}"
                install -d "${PORT_ENOTICE_DIR}" &>/dev/null
                chown root:portage "${PORT_ENOTICE_DIR}" &>/dev/null
                chmod g+rwxs "${PORT_ENOTICE_DIR}" &>/dev/null
                if  [ "$EBUILD_PHASE" == "unpack" ]; then
                        rm -f ${PORT_ENOTICE_DIR}/${PF}
                fi
        fi
fi

einfo() {
        enotice info "${*}"
}

ewarn() {
        enotice warn "${*}"
}

eerror()
{
        enotice error "${*}"
}

enotice()
{
        local color
        local type

        type="${1}"

        case "${type}" in
                "info")
                        color="${GOOD}"
                        ;;
                "warn")
                        color="${WARN}"
                        ;;
                "error")
                        color="${BAD}"
                        ;;
        esac

        shift

        if [ ! -z "${PORT_ENOTICE_DIR}" ]; then
                echo "${type}:${*}" >> ${PORT_ENOTICE_DIR}/${PF}
        fi
        echo " ${color}*${NORMAL} ${*}"
}

root@io:~ # equery b /etc/portage/profile/profile.bashrc
 * Searching for /etc/portage/profile/profile.bashrc ...

No result at all, I checked this on four other gentoo-boxes amd64 and x86, young and old ones, it's all the same, the age as well.

root@io:~ # ll /etc/portage/profile/profile.bashrc
-rw-r--r-- 1 root root 811 Nov 10  2004 /etc/portage/profile/profile.bashrc

This looks then not as a dev-lang/ghc Problem any more.

Thanks for your efforts.
Comment 5 Sergei Trofimovich (RETIRED) gentoo-dev 2014-11-23 15:28:53 UTC
Yeah, I'd suggest inspecting contents of
    /etc/portage/profile/
and remove crufty bits completely.
Comment 6 Sergei Trofimovich (RETIRED) gentoo-dev 2014-11-23 18:42:53 UTC
> > Interesting! Where did you get that file from? Must be a remnant of
> > ancient portage install (or a manual tweak?).
> Ancient hits it pretty good, I think. Manual? I can't remember.

robbat2 helped me to track down origin [1] of enotice script.
It had had a install-enotice.sh that installed needed files.

At that time I didn't even know that gentoo exists :)

I've put a backup copy of scripts here:
https://dev.gentoo.org/~slyfox/historical/eldad-enotice.tar.gz (~7KB)

[1]: line 483+ http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo/xml/htdocs/news/en/gwn/20050801-newsletter.xml?view=markup
Comment 7 Sergei Trofimovich (RETIRED) gentoo-dev 2014-11-23 18:46:56 UTC
(In reply to Sergei Trofimovich from comment #5)
> Yeah, I'd suggest inspecting contents of
>     /etc/portage/profile/
> and remove crufty bits completely.

Or altrnatively you can port enotice bit to redirect text to stderr
to match portage's behaviour (changed in 2008):

https://github.com/gentoo/portage/commit/b36c8955cedf9e01869efe8400c1ed98ab21ec98