Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 474750 - sys-devel/clang-3.3: failed in QA check, invalid install_name
Summary: sys-devel/clang-3.3: failed in QA check, invalid install_name
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 474748
  Show dependency tree
 
Reported: 2013-06-25 16:39 UTC by yegle
Modified: 2016-08-16 16:34 UTC (History)
1 user (show)

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 yegle 2013-06-25 16:39:37 UTC
* QA Notice: invalid self-reference install_name /Users/yegle/.gentoo/var/tmp/portage/sys-devel/clang-3.3/work/llvm-3.3.src/Release/lib/clang/3.3/lib/darwin/libclang_rt.asan_osx_dynamic.dylib in /Users/yegle/.gentoo/usr/lib/clang/3.3/lib/darwin/libclang_rt.asan_osx_dynamic.dylib
 * QA Notice: invalid self-reference install_name /Users/yegle/.gentoo/var/tmp/portage/sys-devel/clang-3.3/work/llvm-3.3.src/Release/lib/clang/3.3/lib/darwin/libclang_rt.asan_osx_dynamic.dylib in /Users/yegle/.gentoo/usr/lib/clang/3.3/lib/darwin/libclang_rt.asan_osx_dynamic.dylib
 * ERROR: sys-devel/clang-3.3 failed:
 *   invalid install_name found, your application or library will crash at runtime
 * 
 * Call stack:
 *   misc-functions.sh, line 1886:  Called install_qa_check
 *   misc-functions.sh, line  290:  Called install_qa_check_macho
 *   misc-functions.sh, line 1097:  Called die
 * The specific snippet of code:
 *   		has allow_broken_install_names ${FEATURES} || \
 *   			die "invalid install_name found, your application or library will crash at runtime"
 * 
 * If you need support, post the output of `emerge --info '=sys-devel/clang-3.3'`,
 * the complete build log and the output of `emerge -pqv '=sys-devel/clang-3.3'`.
 * The complete build log is located at '/Users/yegle/.gentoo/var/tmp/portage/sys-devel/clang-3.3/temp/build.log'.
 * The ebuild environment file is located at '/Users/yegle/.gentoo/var/tmp/portage/sys-devel/clang-3.3/temp/environment'.
 * Working directory: '/Users/yegle/.gentoo/var/tmp/portage/sys-devel/clang-3.3/image'
 * S: '/Users/yegle/.gentoo/var/tmp/portage/sys-devel/clang-3.3/work/llvm-3.3.src'
!!! post install failed; exiting.

Reproducible: Always




Portage 2.2.01.22013-prefix (prefix/darwin/macos/10.8/x64, gcc-4.2.1, unavailable, 13.0.0 x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Darwin-13.0.0-x86_64-i386-64bit
Timestamp of tree: Tue, 25 Jun 2013 16:06:25 +0000
app-shells/bash:      4.2_p39-r1
dev-lang/python:      2.7.5, 3.3.2
dev-util/pkgconfig:   0.28
sys-devel/autoconf:   2.69
sys-devel/automake:   1.12.4
sys-devel/gcc-config: 1.8-r00.1
sys-devel/libtool:    2.4.2
sys-devel/make:       3.82-r4
Repositories: gentoo_prefix yegle-s-overlay
ACCEPT_KEYWORDS="~x64-macos"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-apple-darwin12"
CFLAGS="-march=native -O2 -pipe"
CHOST="x86_64-apple-darwin12"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-march=native -O2 -pipe"
DISTDIR="/Users/yegle/.gentoo/usr/portage/distfiles"
FCFLAGS=""
FEATURES="assume-digests binpkg-logs collision-protect config-protect-if-modified distlocks ebuild-locks fixlafiles force-prefix merge-sync news nostrip parallel-fetch preserve-libs protect-owned sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS=""
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_US.UTF-8"
LDFLAGS="-L/Users/yegle/.gentoo/usr/lib"
MAKEOPTS="-j3"
PKGDIR="/Users/yegle/.gentoo/usr/portage/packages"
PORTAGE_CONFIGROOT="/Users/yegle/.gentoo/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/Users/yegle/.gentoo/var/tmp"
PORTDIR="/Users/yegle/.gentoo/usr/portage"
PORTDIR_OVERLAY="/Users/yegle/portage"
SYNC="rsync://rsync.prefix.freens.org/gentoo-portage-prefix"
USE="aqua coreaudio cracklib cxx ipv6 mmx mmxext modules ncurses objc objc++ prefix readline sse sse2 ssl unicode x64-macos zlib" 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="Darwin" 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" KERNEL="Darwin" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-3" PYTHON_SINGLE_TARGET="python3_3 python2_7" PYTHON_TARGETS="python3_3 python2_7" RUBY_TARGETS="ruby19 ruby18" USERLAND="GNU" 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"
USE_PYTHON="2.7 3.3"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

=================================================================
                        Package Settings
=================================================================
USE="(prefix) static-analyzer -debug -multitarget -python -test" PYTHON_TARGETS="python2_7 -pypy1_9 -pypy2_0 -python2_6"

sys-devel/clang-3.3 was built with the following:
CFLAGS="-march=nocona -O2 -pipe"
CXXFLAGS="-march=nocona -O2 -pipe"
Comment 1 Fabian Groffen gentoo-dev 2013-06-26 09:34:13 UTC
please try to fix the ebuild, it would be great to have a running build again
Comment 2 yegle 2013-06-27 17:28:02 UTC
I tried to fix this by adding extra calls to install_name_tool to the corresponding dylib file, and QA check doesn't complain anymore. But now clang crashes right after invoking it.

--- /Users/yegle/.gentoo/usr/portage/sys-devel/clang/clang-3.3.ebuild	2013-06-18 15:20:08.000000000 -0700
+++ clang-3.3-r1.ebuild	2013-06-27 10:27:24.000000000 -0700
@@ -190,6 +190,10 @@
 				"${ED}"/usr/lib/llvm/${lib}
 			eend $?
 		done
+		ebegin "fixing install_name of $lib"
+		install_name_tool -id "${EPREFIX}"/usr/lib/clang/3.3/lib/darwin/libclang_rt.asan_osx_dynamic.dylib \
+			"${ED}"/usr/lib/clang/3.3/lib/darwin/libclang_rt.asan_osx_dynamic.dylib
+		eend $?
 		for f in usr/bin/{c-index-test,clang} usr/lib/llvm/libclang.dylib ; do
 			ebegin "fixing references in ${f##*/}"
 			install_name_tool \

$ clang
clang(1965,0x7fff7cd6a310) malloc: *** error for object 0x10f967600: pointer being freed was not allocated
*** set a breakpoint in malloc_error_break to debug
0  libLLVM-3.3.dylib        0x000000010f00b9f8 llvm::sys::PrintStackTrace(__sFILE*) + 40
1  libLLVM-3.3.dylib        0x000000010f00bee4 SignalHandler(int) + 436
2  libsystem_platform.dylib 0x00007fff8f3b680a _sigtramp + 26
3  libsystem_platform.dylib 0x00007fff6ece6248 _sigtramp + 3750951512
4  libsystem_c.dylib        0x00007fff96564c22 abort + 125
5  libsystem_malloc.dylib   0x00007fff96bb17cb malloc_get_zone_name + 0
6  libstdc++.6.dylib        0x00007fff8ec25b18 std::string::reserve(unsigned long) + 112
7  libstdc++.6.dylib        0x00007fff8ec25e3b std::string::append(char const*, unsigned long) + 101
8  libLLVM-3.3.dylib        0x000000010f02b0bd llvm::raw_string_ostream::~raw_string_ostream() + 45
9  clang                    0x000000010d605746 clang::driver::toolchains::Darwin::Darwin(clang::driver::Driver const&, llvm::Triple const&, clang::driver::ArgList const&) + 380
10 clang                    0x000000010d60598b clang::driver::toolchains::DarwinClang::DarwinClang(clang::driver::Driver const&, llvm::Triple const&, clang::driver::ArgList const&) + 23
11 clang                    0x000000010d5e53f6 clang::driver::Driver::getToolChain(clang::driver::ArgList const&, llvm::StringRef) const + 2248
12 clang                    0x000000010d5eea39 clang::driver::Driver::BuildCompilation(llvm::ArrayRef<char const*>) + 1549
13 clang                    0x000000010d536dba main + 2557
14 clang                    0x000000010d530690 start + 52
Stack dump:
0.	Program arguments: clang 
1.	Compilation construction
Abort trap: 6
Comment 3 yegle 2013-07-10 04:58:42 UTC
Seems like a false alarm.

I tried with FEATURES="allow_broken_install_names" and installed =clang-3.3. It actually works well.
Comment 4 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2016-08-16 16:34:30 UTC
Mass-closing of bugs pinned to old clang versions. Please reopen and update summary appropriately if the bug still applies to a newer version (and hasn't been reported separately for it).