From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTP id CCFE7383B830 for ; Wed, 23 Jun 2021 20:35:53 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org CCFE7383B830 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-300-dY3Wwfo3PW-rb-0Yd4Tljg-1; Wed, 23 Jun 2021 16:35:52 -0400 X-MC-Unique: dY3Wwfo3PW-rb-0Yd4Tljg-1 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 406FF100C660; Wed, 23 Jun 2021 20:35:51 +0000 (UTC) Received: from oldenburg.str.redhat.com (ovpn-112-211.ams2.redhat.com [10.36.112.211]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 66980604CD; Wed, 23 Jun 2021 20:35:50 +0000 (UTC) From: Florian Weimer To: George Hodgkins via Libc-help Cc: George Hodgkins Subject: Re: Diagnosing symbol conflicts in modified glibc build References: Date: Wed, 23 Jun 2021 22:35:48 +0200 In-Reply-To: (George Hodgkins via Libc-help's message of "Wed, 23 Jun 2021 14:03:05 -0600") Message-ID: <87pmwcxqsb.fsf@oldenburg.str.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain X-Spam-Status: No, score=-6.7 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-help@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-help mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jun 2021 20:35:55 -0000 * George Hodgkins via Libc-help: > With that extensive preamble, the actual problem we are facing is the > failure of this command: > ################# > cc -nostdlib -nostartfiles -r -o /glibc-wsp/build/elf/librtld.map.o > -Wl,--defsym=calloc=0 -Wl,--defsym=free=0 -Wl,--defsym=malloc=0 > -Wl,--defsym=realloc=0 -Wl,--defsym=__stack_chk_fail=0 > -Wl,--defsym=__stack_chk_fail_local=0 \ > '-Wl,-(' /glibc-wsp/build/elf/dl-allobjs.os > /glibc-wsp/build/libc_pic.a -lgcc '-Wl,-)' > -Wl,-Map,/glibc-wsp/build/elf/librtld.mapT > /glibc-wsp/build/libc_pic.a(getcwd.os): In function `__GI___getcwd': > /glibc-wsp/src/io/../sysdeps/unix/sysv/linux/getcwd.c:47: multiple > definition of `__getcwd' > /glibc-wsp/build/elf/dl-allobjs.os:/glibc-wsp/src/elf/../sysdeps/unix/sysv/linux/getcwd.c:47: > first defined here This probably means that you are linking more into the dynamic loader than you intend. You may have to cover your own additions with #if IS_IN (libc) or #if !IS_IN (rtld). Thanks, Florian