libelf.h looks broken. checking libelf.h usability... no checking libelf.h presence... yes configure: WARNING: libelf.h: present but cannot be compiled configure: WARNING: libelf.h: check for missing prerequisite headers? configure: WARNING: libelf.h: proceeding with the preprocessor's result configure: WARNING: ## ------------------------------------ ## configure: WARNING: ## Report this to bug-autoconf@gnu.org. ## configure: WARNING: ## ------------------------------------ ## checking for libelf.h... yes checking gelf.h usability... no checking gelf.h presence... yes configure: WARNING: gelf.h: present but cannot be compiled configure: WARNING: gelf.h: check for missing prerequisite headers? configure: WARNING: gelf.h: proceeding with the preprocessor's result configure: WARNING: ## ------------------------------------ ## configure: WARNING: ## Report this to bug-autoconf@gnu.org. ## configure: WARNING: ## ------------------------------------ ## checking for gelf.h... yes checking for elf_begin in -lelf... yes checking for gelf_getvernaux... yes checking whether FTW_ACTIONRETVAL is supported... yes checking for is_selinux_enabled in -lselinux... no checking selinux/selinux.h usability... no checking selinux/selinux.h presence... no checking for selinux/selinux.h... no checking for special C compiler options needed for large files... no checking for _FILE_OFFSET_BITS value needed for large files... 64 checking for _LARGE_FILES value needed for large files... no configure: error: libelf does not properly convert Elf64_Sxword quantities. If you are using libelf-0.7.0, please use patches/libelf-0.7.0.patch. !!! Please attach the following file when seeking support: !!! /var/tmp/portage/sys-devel/prelink-20071009/work/prelink/config.log * * ERROR: sys-devel/prelink-20071009 failed. Portage 2.1.4_rc14 (default-linux/x86/2007.0, gcc-4.2.2, glibc-2.7-r1, 2.6.23.12 i686) ================================================================= System uname: 2.6.23.12 i686 Genuine Intel(R) CPU T2300 @ 1.66GHz Timestamp of tree: Unknown ccache version 2.4 [enabled] app-shells/bash: 3.2_p33 dev-java/java-config: 1.3.7, 2.1.3 dev-lang/python: 2.5.1-r4 dev-python/pycrypto: 2.0.1-r6 dev-util/ccache: 2.4-r7 sys-apps/baselayout: 2.0.0_rc6-r1 sys-apps/sandbox: 1.2.18.1-r2 sys-devel/autoconf: 2.13, 2.61-r1 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10 sys-devel/binutils: 2.18-r1, 2.18.50.0.2, 2.18.50.0.3 sys-devel/gcc-config: 1.4.0-r4 sys-devel/libtool: 1.5.24 virtual/os-headers: 2.6.23-r3 ACCEPT_KEYWORDS="x86 ~x86" CBUILD="i686-pc-linux-gnu" CFLAGS="-O2 -g -march=prescott -fomit-frame-pointer -pipe" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config" CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d" CXXFLAGS="-O2 -g -march=prescott -fomit-frame-pointer -pipe" DISTDIR="/usr/portage/distfiles" EMERGE_DEFAULT_OPTS="--with-bdeps=y --nospinner" FEATURES="assume-digests ccache collision-protect cvs digest distlocks fixpackages parallel-fetch sandbox sfperms sign splitdebug strict unmerge-orphans userfetch" GENTOO_MIRRORS=" http://gentoo.osuosl.org http://distfiles.gentoo.org" LANG="en_US.utf8" LDFLAGS="-Wl,-O1,--hash-style=gnu" LINGUAS="en en_GB en_US" MAKEOPTS="-j3" PKGDIR="/usr/portage/packages" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/home/dirtyepic/overlay /home/dirtyepic/svn/dirtyepic" SYNC="rsync://rsync.gentoo.org/gentoo-portage"
Created attachment 140243 [details] config.log
why is your libelf.h including linux/sys.h ? mine isnt: $ grep '#include' /usr/include/libelf.h #include <sys/types.h> #include <elf.h>
Created attachment 140245 [details] config.log crap, wrong log. sorry.
off64_t only shows up when building with -D_LARGEFILE64_SOURCE ... wtf thought that was a good idea
add this to the top of your libelf.h: #if !defined(_LARGEFILE64_SOURCE) && !defined(__off64_t_defined) # define _LARGEFILE64_SOURCE #endif and make sure things work
nope, sorry. still getting the same error.
do `sed -i 's:off64_t:__off64_t:'` on libelf.h ... that lets me build prelink
I wonder how this was ever supposed to work on redhat.. I'd vote for doing the sed in a -r1 ebuild.
*** Bug 204208 has been marked as a duplicate of this bug. ***
yep, this works. there's another, separate, problem with inlining and -std=gnu99 but it can be fixed anytime.
they may not have rebuilt prelink against newer libelf yet and thus didnt notice 0.131-r1 in the tree using __off64_t