Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 455858 - =sys-apps/portage-2.1.11.50 - Emerging portage fails with /bin/sh: -c: line 1: syntax error: unexpected end of file
Summary: =sys-apps/portage-2.1.11.50 - Emerging portage fails with /bin/sh: -c: line 1...
Status: RESOLVED FIXED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Ebuild Support (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks:
 
Reported: 2013-02-06 15:14 UTC by Igor Franchuk
Modified: 2013-02-06 20:44 UTC (History)
1 user (show)

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


Attachments
build.log (build.log,9.82 KB, text/plain)
2013-02-06 15:16 UTC, Igor Franchuk
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Igor Franchuk 2013-02-06 15:14:38 UTC
Emerging portage fails with: 

/bin/sh: -c: line 1: syntax error: unexpected end of file
make: *** [install] Error 1
emake failed
 [31;01m*[0m ERROR: sys-apps/portage-2.1.11.50 failed (install phase):
 [31;01m*[0m   (no error message)
 [31;01m*[0m 
 [31;01m*[0m Call stack:
 [31;01m*[0m     ebuild.sh, line  56:  Called src_install
 [31;01m*[0m   environment, line 4798:  Called die
 [31;01m*[0m The specific snippet of code:
 [31;01m*[0m       emake DESTDIR="${D}" sysconfdir="/etc" prefix="/usr" install || die;
 [31;01m*[0m 
 [31;01m*[0m If you need support, post the output of 'emerge --info =sys-apps/portage-2.1.11.50',
 [31;01m*[0m the complete build log and the output of 'emerge -pqv =sys-apps/portage-2.1.11.50'.
 [31;01m*[0m The complete build log is located at '/var/tmp/portage/sys-apps/portage-2.1.11.50/temp/build.log'.
 [31;01m*[0m The ebuild environment file is located at '/var/tmp/portage/sys-apps/portage-2.1.11.50/temp/environment'.
 [31;01m*[0m S: '/var/tmp/portage/sys-apps/portage-2.1.11.50/work/portage-2.1.11.50'


Reproducible: Always




Portage 2.1.9.43 (default/linux/x86/10.0/server, gcc-4.4.2, glibc-2.10.1-r1, 2.6.33-gentoo i686)
=================================================================
System uname: Linux-2.6.33-gentoo-i686-Intel-R-_Pentium-R-_D_CPU_3.00GHz-with-gentoo-1.12.1
Timestamp of tree: Wed, 06 Feb 2013 15:00:01 +0000
app-shells/bash:     4.2_p42
dev-lang/python:     2.4.3-r1::<unknown repository>, 2.6.8, 3.1.1-r1
dev-util/pkgconfig:  0.27.1
sys-apps/baselayout: 1.12.1::<unknown repository>
sys-apps/sandbox:    2.2
sys-devel/autoconf:  2.13::<unknown repository>, 2.69
sys-devel/automake:  1.4_p6::<unknown repository>, 1.5::<unknown repository>, 1.6.3::<unknown repository>, 1.7.9-r1::<unknown repository>, 1.8.5-r3::<unknown repository>, 1.9.6-r2::<unknown repository>, 1.10::<unknown repository>, 1.11.1, 1.13.1
sys-devel/binutils:  2.21
sys-devel/gcc:       4.1.1::<unknown repository>, 4.2.4-r1, 4.4.2
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   1.5.23b::<unknown repository>, 2.4-r1
sys-devel/make:      3.80-r4::<unknown repository>
sys-kernel/linux-headers: 2.6.21::<unknown repository>
sys-libs/glibc:      2.10.1-r1
virtual/os-headers:  2.6.21::<unknown repository> (sys-kernel/linux-headers)
ACCEPT_KEYWORDS="x86 ~x86"
ACCEPT_LICENSE="* -@EULA"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=pentium4 -O2 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /var/bind"
CONFIG_PROTECT_MASK="/etc/env.d /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=pentium4 -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -march=i686 -pipe"
FEATURES="assume-digests binpkg-logs distlocks fixlafiles fixpackages news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS="-O2 -march=i686 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="acl alsa arts avi berkdb bitmap-fonts bzip2 cairo cdr cli cracklib crypt cups cxx dbus dlloader dri dvd dvdr eds emboss encode esd fam fortran gdbm gif gnutls gpm gstreamer gtk hal iconv isdnlog jpeg kde ldap libg++ mad mikmod modules mp3 mpeg mudflap ncurses nls nptl nptlonly ogg opengl openmp oss pam pcre pdflib perl png ppds pppd python qt3 qt4 quicktime readline reflection sdl session snmp spell spl ssl svg symlink tcpd truetype truetype-fonts type1-fonts udev unicode vorbis win32codecs x86 xml xorg xv zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" 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" 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 ubx" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" PHP_TARGETS="php5-3" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_2" RUBY_TARGETS="ruby18 ruby19" USERLAND="GNU" VIDEO_CARDS="fbdev glint intel mach64 mga nouveau nv r128 radeon savage sis tdfx trident vesa via vmware dummy v4l" 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, LANG, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 1 Igor Franchuk 2013-02-06 15:16:06 UTC
Created attachment 338108 [details]
build.log

Build log
Comment 2 Zac Medico gentoo-dev 2013-02-06 15:39:15 UTC
What shell does /bin/sh refer to?
Comment 3 Igor Franchuk 2013-02-06 15:58:08 UTC
(In reply to comment #2)
> What shell does /bin/sh refer to?

ls -l /bin/sh
lrwxrwxrwx 1 root root 4 Feb  6 17:53 /bin/sh -> bash


*  app-shells/bash
      Latest version available: 4.2_p42
      Latest version installed: 4.2_p42


I'm looking through Makefile install section and so far can't find the cause. It looks OK.
Comment 4 Igor Franchuk 2013-02-06 16:16:55 UTC
(In reply to comment #2)
> What shell does /bin/sh refer to?

I tried to downgrade to: 

# bash --version
GNU bash, version 4.2.37(1)-release (i686-pc-linux-gnu)
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

which is stable. But that didn't seem to help. Same error: 

/bin/sh: -c: line 1: syntax error: unexpected end of file
make: *** [install] Error 1
emake failed
 [31;01m*[0m ERROR: sys-apps/portage-2.1.11.31 failed (install phase):
 [31;01m*[0m   (no error message)
Comment 5 Igor Franchuk 2013-02-06 17:44:41 UTC
This is what extrapolated version of make install looks like:

cd "/tmp/port/portage-2.1.11.50/cnf"; \
install -d -m0755 "/tmp/port/portage-2.1.11.50/image//etc"; \
install -m0644 etc-update.conf dispatch-conf.conf "/tmp/port/portage-2.1.11.50/image//etc"; \
\
install -d -m0755 "/tmp/port/portage-2.1.11.50/image//usr/share/portage/config"; \
cd "/tmp/port/portage-2.1.11.50/cnf"; \
install -m0644 make.globals \
        "/tmp/port/portage-2.1.11.50/image//usr/share/portage/config"; \
install -m0644 "/tmp/port/portage-2.1.11.50/cnf/make.conf" \
        "/tmp/port/portage-2.1.11.50/image//usr/share/portage/config/make.conf.example"; \
\
install -d -m0755 "/tmp/port/portage-2.1.11.50/image//usr/share/portage/config/sets"; \
cd "/tmp/port/portage-2.1.11.50/cnf/sets"; \
install -m0644 *.conf "/tmp/port/portage-2.1.11.50/image//usr/share/portage/config/sets"; \
\
install -d -m0755 "/tmp/port/portage-2.1.11.50/image//etc/logrotate.d"; \
cd "/tmp/port/portage-2.1.11.50/cnf/logrotate.d"; \
install -m0644 elog-save-summary \
        "/tmp/port/portage-2.1.11.50/image//etc/logrotate.d"; \
\
for x in $(cd "/tmp/port/portage-2.1.11.50" && find bin -type d) ; do \
        cd "/tmp/port/portage-2.1.11.50/$x"; \
        install -d -m0755 "/tmp/port/portage-2.1.11.50/image//usr/lib/portage/$x"; \
        files=$(find . -mindepth 1 -maxdepth 1 -type f ! -type l); \
        if [ -n "$files" ] ; then \
                install -m0755 $files \
                        "/tmp/port/portage-2.1.11.50/image//usr/lib/portage/$x"; \
        fi; \
        symlinks=$(find . -mindepth 1 -maxdepth 1 -type l); \
        if [ -n "$symlinks" ] ; then \
                cp -P $symlinks "/tmp/port/portage-2.1.11.50/image//usr/lib/portage/$x"; \
        fi; \
done; \
\
for x in $(cd "/tmp/port/portage-2.1.11.50" && find pym/* -type d ! -path "pym/portage/tests*") ; do \
        cd "/tmp/port/portage-2.1.11.50/$x"; \
        files=$(echo *.py); \
        if [ -z "$files" ] || [ "$files" = "*.py" ]; then \
                # __pycache__ directories contain no py files \
                continue; \
        fi; \
        install -d -m0755 "/tmp/port/portage-2.1.11.50/image//usr/lib/portage/$x"; \
        install -m0644 $files "/tmp/port/portage-2.1.11.50/image//usr/lib/portage/$x"; \
done; \
\
install -d -m0755 "/tmp/port/portage-2.1.11.50/image//usr/bin"; \
relative_path=".."; \
x=/usr/bin ; \
y="/usr/lib/portage"; \
if [ "${x#/usr}" != "$x" ] && \
        [ "${y#/usr}" != "$y" ]; then \
        x=${x#/usr}; \
        y=${y#/usr}; \
fi; \
x=${x%/*}; \
while [ -n "$x" ] ; do \
        relative_path=${relative_path}/..; \
        x=${x%/*}; \
done; \
relative_path=$relative_path$y; \
for x in ebuild egencache emerge emerge-webrsync emirrordist portageq quickpkg repoman ; do \
        ln -sf "$relative_path/bin/$x" \
                "/tmp/port/portage-2.1.11.50/image//usr/bin/$x"; \
done; \
\
install -d -m0755 "/tmp/port/portage-2.1.11.50/image//usr/sbin"; \
relative_path=".."; \
x=/usr/sbin ; \
y="/usr/lib/portage"; \
if [ "${x#/usr}" != "$x" ] && \
        [ "${y#/usr}" != "$y" ]; then \
        x=${x#/usr}; \
        y=${y#/usr}; \
fi; \
x=${x%/*}; \
while [ -n "$x" ] ; do \
        relative_path=${relative_path}/..; \
        x=${x%/*}; \
done; \
relative_path=$relative_path$y; \
for x in archive-conf dispatch-conf emaint env-update etc-update fixpackages regenworld ; do \
        ln -sf "$relative_path/bin/$x" \
                "/tmp/port/portage-2.1.11.50/image//usr/sbin/$x"; \
done; \
\
ln -sf "$relative_path/bin/env-update" \
        "/tmp/port/portage-2.1.11.50/image//usr/sbin/update-env"; \
ln -sf "$relative_path/bin/etc-update" \
        "/tmp/port/portage-2.1.11.50/image//usr/sbin/update-etc"; \
\
# We install some minimal tests for use as a preinst sanity check. \
# These tests must be able to run without a full source tree and \
# without relying on a previous portage instance being installed. \
install -d -m0755 \
        "/tmp/port/portage-2.1.11.50/image//usr/lib/portage/pym/portage/tests"; \
install -m0755 "/tmp/port/portage-2.1.11.50/pym/portage/tests/runTests" \
        "/tmp/port/portage-2.1.11.50/image//usr/lib/portage/pym/portage/tests"; \
cd "/tmp/port/portage-2.1.11.50/pym/portage/tests"; \
install -m0644 *.py \
        "/tmp/port/portage-2.1.11.50/image//usr/lib/portage/pym/portage/tests"; \
install -d -m0755 \
        "/tmp/port/portage-2.1.11.50/image//usr/lib/portage/pym/portage/tests/lint"; \
cd "/tmp/port/portage-2.1.11.50/pym/portage/tests/lint"; \
install -m0644 *.py __test__ \
        "/tmp/port/portage-2.1.11.50/image//usr/lib/portage/pym/portage/tests/lint"; \
\
install -d -m0755 "/tmp/port/portage-2.1.11.50/image//usr/share/doc/portage"; \
cd "/tmp/port/portage-2.1.11.50"; \
install -m 0644 ChangeLog NEWS RELEASE-NOTES "/tmp/port/portage-2.1.11.50/image//usr/share/doc/portage"; \
\
Comment 6 Igor Franchuk 2013-02-06 19:28:12 UTC
The bug is localized. 

The portage-2.1.11.31 is missing dependency on make 3.82-r4.

In particular it doesn't work with make 3.80-r4

Upgrade to make 3.82-r4 or latest to fix this problem.
Comment 7 Zac Medico gentoo-dev 2013-02-06 19:48:52 UTC
Thanks, I've added a dependency to the ebuilds.
Comment 8 Igor Franchuk 2013-02-06 20:44:40 UTC
(In reply to comment #7)
> Thanks, I've added a dependency to the ebuilds.

Glad to help!