<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://bugs.gentoo.org/bugzilla.dtd">

<bugzilla version="2.22.7"
          urlbase="http://bugs.gentoo.org/"
          maintainer="bugzilla@gentoo.org"
>

    <bug>
          <bug_id>16827</bug_id>
          
          <creation_ts>2003-03-04 10:10 0000</creation_ts>
          <short_desc>nethack 3.4.1 build fails</short_desc>
          <delta_ts>2003-06-24 04:42:53 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Linux</product>
          <component>Games</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>spider@gentoo.org</reporter>
          <assigned_to>games@gentoo.org</assigned_to>
          <cc>Andreas.Klauer@metamorpher.de</cc>
    
    <cc>chris-gentoo-bugzilla@nightshade.homelinux.net</cc>
    
    <cc>gentoo@plumlocosoft.com</cc>
    
    <cc>mholzer@gentoo.org</cc>
    
    <cc>ryan@jocose.net</cc>

      

      
          <long_desc isprivate="0">
            <who>spider@gentoo.org</who>
            <bug_when>2003-03-04 10:10:04 0000</bug_when>
            <thetext>compare:
http://bugs.gentoo.org/show_bug.cgi?id=16436
http://bugs.gentoo.org/show_bug.cgi?id=16472
http://bugs.gentoo.org/show_bug.cgi?id=16402



gcc -march=athlon-tbird -O2 -pipe -fomit-frame-pointer -I../include -c
../sys/unix/unixres.c
../sys/unix/unixres.c: In function `real_getresuid&apos;:
../sys/unix/unixres.c:35: `RTLD_NEXT&apos; undeclared (first use in this function)
../sys/unix/unixres.c:35: (Each undeclared identifier is reported only once
../sys/unix/unixres.c:35: for each function it appears in.)
../sys/unix/unixres.c: In function `real_getresgid&apos;:
../sys/unix/unixres.c:47: `RTLD_NEXT&apos; undeclared (first use in this function)
make: *** [unixres.o] Error 1



Portage 2.0.47-r8 (default-x86-1.4, gcc-3.2.2, glibc-2.3.1-r3)
=================================================================
System uname: 2.4.20 i686 AMD Athlon(tm) Processor
GENTOO_MIRRORS=&quot;ftp://ftp.sunet.se/pub/Linux/distributions/gentoo/
http://gentoo.oregonstate.edu/&quot;
CONFIG_PROTECT=&quot;/etc /var/qmail/control /usr/kde/2/share/config
/usr/kde/3/share/config /usr/X11R6/lib/X11/xkb /usr/kde/3.1/share/config
/usr/share/config&quot;
CONFIG_PROTECT_MASK=&quot;/etc/gconf /etc/env.d&quot;
PORTDIR=&quot;/usr/portage&quot;
DISTDIR=&quot;/mnt/build/distfiles&quot;
PKGDIR=&quot;/mnt/build/packages&quot;
PORTAGE_TMPDIR=&quot;/mnt/build&quot;
PORTDIR_OVERLAY=&quot;/usr/local/portage&quot;
USE=&quot;x86 apm avi encode libg++ libwww mikmod mpeg ncurses nls pdflib qtmt
quicktime spell xml2 zlib gdbm berkdb slang readline aalib svga tcltk java guile
X sdl gpm tcpd pam perl python esd imlib gtk motif mozilla gphoto2 ldap cdr
crypt alsa oggvorbis -arts -qt -kde -cups gnome gpg gpgme bonobo oss ssl xmms
3dnow mmx -sse -tetex -doc opengl tiff png jpeg smooth truetype gif ggi -gtk2
samba xv gtkhtml&quot;
COMPILER=&quot;gcc3&quot;
CHOST=&quot;i686-pc-linux-gnu&quot;
CFLAGS=&quot;-march=athlon-tbird -O2 -pipe&quot;
CXXFLAGS=&quot;-march=athlon-tbird -O2 -pipe&quot;
ACCEPT_KEYWORDS=&quot;x86 ~x86&quot;
MAKEOPTS=&quot;-j3&quot;
AUTOCLEAN=&quot;yes&quot;
SYNC=&quot;rsync://rsync.gentoo.org/gentoo-portage&quot;
FEATURES=&quot;sandbox ccache&quot;</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>daya-gentoo@crazydays.org</who>
            <bug_when>2003-03-05 08:01:09 0000</bug_when>
            <thetext>Just a note on this, I am also getting this error.

I found in the /usr/include/dlfcn.h __USE_GNU must be defined (line 29) to define RTLD_NEXT.  For kicks when it was compiling I threw a #define __USE_GNU into the sys/unix/unixrexs.c file while it was compiling and it made it much further than that...

Below is where the build falls over after I&apos;ve added the #define __USE_GNU.  I&apos;m not too sure if this might be a side effect of my previous fiddling, but hey, thought I&apos;d add this to the bug report someone else has here incase it helps.

gcc -O3 -march=athlon-xp -fforce-addr -fomit-frame-pointer -funroll-loops -frerun-cse-after-loop -frerun-loop-opt -falign-functions=4 -fomit-frame-pointer -I../include   -c -o version.o version.c
Loading ...
tile.o(.data+0x0): multiple definition of `glyph2tile&apos;
tile.o(.data+0x0): first defined here
tile.o(.data+0x2ba0): multiple definition of `std_tiles0&apos;
tile.o(.data+0x2ba0): first defined here
tile.o(.text+0x0): In function `substitute_tiles&apos;:
: multiple definition of `substitute_tiles&apos;
tile.o(.text+0x0): first defined here
tile.o(.data+0x2bb8): multiple definition of `total_tiles_used&apos;
tile.o(.data+0x2bb8): first defined here
collect2: ld returned 1 exit status
make: *** [Sysunix] Error 1

!!! ERROR: app-games/nethack-3.4.1 failed.
!!! Function src_compile, Line 144, Exitcode 2
!!! (no error message)



</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>gentoo@plumlocosoft.com</who>
            <bug_when>2003-03-06 09:20:20 0000</bug_when>
            <thetext>Created an attachment (id=9021)
nethack-3.4.1-gnome.patch

This patch fixes the various errors about RTLD_NEXT being undefined. It turns
out that the developers check for Linux too late in the include process, and it
ends up screwing them over.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>gentoo@plumlocosoft.com</who>
            <bug_when>2003-03-06 09:23:02 0000</bug_when>
            <thetext>Created an attachment (id=9022)
nethack-3.4.1.ebuild.diff

This is a diff against the nethack-3.4.1.ebuild file. It adds a line to
incorporate the prior gnome patch, and it modifies the sed expression to remove
the extra tile.o link.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2003-03-06 14:39:37 0000</bug_when>
            <thetext>*** Bug 16964 has been marked as a duplicate of this bug. ***</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>mholzer@gentoo.org</who>
            <bug_when>2003-05-11 08:03:42 0000</bug_when>
            <thetext>*** Bug 20215 has been marked as a duplicate of this bug. ***</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2003-06-22 18:17:11 0000</bug_when>
            <thetext>ok, i added your patches, greatly appreciated :) 
 
http://cvs.gentoo.org/cgi-bin/viewcvs.cgi/gentoo-x86/app-games/nethack/nethack-3.4.1.ebuild.diff?r1=1.4&amp;r2=1.5  
http://cvs.gentoo.org/cgi-bin/viewcvs.cgi/gentoo-x86/app-games/nethack/files/3.4.1-GNOME-RTLD_NEXT.patch?rev=1.1&amp;content-type=text/vnd.viewcvs-markup </thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2003-06-24 04:42:53 0000</bug_when>
            <thetext>*** Bug 23366 has been marked as a duplicate of this bug. ***</thetext>
          </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>9021</attachid>
            <date>2003-03-06 09:20 0000</date>
            <desc>nethack-3.4.1-gnome.patch</desc>
            <filename>nethack-3.4.1-gnome.patch</filename>
            <type>text/plain</type>
            <data encoding="base64">ZGlmZiAtdXIgYmFzZS4xL3N5cy91bml4L3VuaXhyZXMuYyB3b3JrL3N5cy91bml4L3VuaXhyZXMu
YwotLS0gYmFzZS4xL3N5cy91bml4L3VuaXhyZXMuYwkyMDAzLTAyLTIzIDA5OjQzOjM5LjAwMDAw
MDAwMCAtMDUwMAorKysgd29yay9zeXMvdW5peC91bml4cmVzLmMJMjAwMy0wMy0wNSAxNjo1Njox
Mi4wMDAwMDAwMDAgLTA1MDAKQEAgLTE0LDE0ICsxNCwxOSBAQAogICogaGlkZSB0aGVtLgogICov
CiAKKy8qIF9HTlVfU09VUkNFIGhhcyB0byBiZSBzZXQgYmVmb3JlIGluY2x1ZGluZyBjb25maWcu
aCwgYXMgb3RoZXJ3aXNlCisgKiBmZWF0dXJlcy5oIHdpbGwgYmUgaW5jbHVkZWQgYW5kIGl0IHdp
bGwgYmUgdG9vIGxhdGUuCisgKi8KKworI2lmIGRlZmluZWQobGludXgpICYmIGRlZmluZWQoX19H
TlVDX18pCisjIGRlZmluZSBfR05VX1NPVVJDRQorI2VuZGlmCisKICNpbmNsdWRlICJjb25maWcu
aCIKIAogI2lmZGVmIEdFVFJFU19TVVBQT1JUCiAKICMgaWYgZGVmaW5lZChMSU5VWCkKLSNpZmRl
ZiBfX0dOVUNfXwotI2RlZmluZSBfR05VX1NPVVJDRQotI2VuZGlmCiAKIC8qIHJlcXVpcmVzIGR5
bmFtaWMgbGlua2luZyB3aXRoIGxpYmMgKi8KICNpbmNsdWRlIDxkbGZjbi5oPgo=
</data>        

          </attachment>
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>9022</attachid>
            <date>2003-03-06 09:23 0000</date>
            <desc>nethack-3.4.1.ebuild.diff</desc>
            <filename>nethack-3.4.1.ebuild.diff</filename>
            <type>text/plain</type>
            <data encoding="base64">LS0tIC91c3IvcG9ydGFnZS9hcHAtZ2FtZXMvbmV0aGFjay9uZXRoYWNrLTMuNC4xLmVidWlsZAky
MDAzLTAzLTA1IDA0OjIwOjUyLjAwMDAwMDAwMCAtMDUwMAorKysgL3Vzci9sb2NhbC9wb3J0YWdl
L2FwcC1nYW1lcy9uZXRoYWNrL25ldGhhY2stMy40LjEuZWJ1aWxkCTIwMDMtMDMtMDYgMDA6MzE6
NDkuMDAwMDAwMDAwIC0wNTAwCkBAIC0zMSw2ICszMSw3IEBACiAKIAljZCAke1N9CiAJZXBhdGNo
ICR7RklMRVNESVJ9LyR7UH0tZXJybm8ucGF0Y2gKKwllcGF0Y2ggJHtGS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