Bug 246797

Summary: make buildworld fails in rtld-elf code at /usr/src/libexec/rtld-elf/rtld.c:1175:20: error: no member named 'l_refname' in 'struct link_map'; did you mean 'l_name'?
Product: Base System Reporter: Ulas SAYGIN <ulassayginim>
Component: kernAssignee: freebsd-bugs (Nobody) <bugs>
Status: Closed DUPLICATE    
Severity: Affects Many People CC: emaste, markj
Priority: ---    
Version: 12.1-STABLE   
Hardware: amd64   
OS: Any   

Description Ulas SAYGIN 2020-05-28 03:51:45 UTC
https://github.com/freebsd/freebsd/archive/stable/12.zip

MFC r361303, r361349, r361394, r361398, r361537 commit.

has problem with build world.


/usr/src/libexec/rtld-elf/rtld.c:1175:20: error: no member named 'l_refname' in 'struct link_map'; did you mean 'l_name'?
                if (obj->linkmap.l_refname == NULL)
                                 ^~~~~~~~~
                                 l_name
/usr/include/sys/link_elf.h:64:14: note: 'l_name' declared here
        const char      *l_name;                /* Absolute Path to Library */
                         ^
/usr/src/libexec/rtld-elf/rtld.c:1176:20: error: no member named 'l_refname' in 'struct link_map'; did you mean 'l_name'?
                    obj->linkmap.l_refname = (char *)dynp->d_un.d_val;
                                 ^~~~~~~~~
                                 l_name
/usr/include/sys/link_elf.h:64:14: note: 'l_name' declared here
        const char      *l_name;                /* Absolute Path to Library */
                         ^
/usr/src/libexec/rtld-elf/rtld.c:1360:22: error: no member named 'l_refname' in 'struct link_map'; did you mean 'l_name'?
    if (obj->linkmap.l_refname != NULL)
                     ^~~~~~~~~
                     l_name
/usr/include/sys/link_elf.h:64:14: note: 'l_name' declared here
        const char      *l_name;                /* Absolute Path to Library */
                         ^
/usr/src/libexec/rtld-elf/rtld.c:1362:12: error: no member named 'l_refname' in 'struct link_map'; did you mean 'l_name'?
          linkmap.l_refname;
                  ^~~~~~~~~
                  l_name
/usr/include/sys/link_elf.h:64:14: note: 'l_name' declared here
        const char      *l_name;                /* Absolute Path to Library */
                         ^
/usr/src/libexec/rtld-elf/rtld.c:1361:15: error: no member named 'l_refname' in 'struct link_map'; did you mean 'l_name'?
        obj->linkmap.l_refname = obj->strtab + (unsigned long)obj->
                     ^~~~~~~~~
                     l_name
/usr/include/sys/link_elf.h:64:14: note: 'l_name' declared here
        const char      *l_name;                /* Absolute Path to Library */
                         ^
/usr/src/libexec/rtld-elf/rtld.c:3329:16: error: use of undeclared identifier 'RTLD_DEEPBIND'
    if (mode & RTLD_DEEPBIND)
               ^
/usr/src/libexec/rtld-elf/rtld.c:3995:5: error: no member named 'l_base' in 'struct link_map'; did you mean 'l_name'?
        l->l_base = obj->mapbase;
           ^~~~~~
           l_name
/usr/include/sys/link_elf.h:64:14: note: 'l_name' declared here
        const char      *l_name;                /* Absolute Path to Library */
                         ^
7 errors generated.
*** Error code 1

Stop.
make[4]: stopped in /usr/src/libexec/rtld-elf
.ERROR_TARGET='rtld.o'
.ERROR_META_FILE='/usr/obj/usr/src/amd64.amd64/libexec/rtld-elf/rtld.o.meta'
.MAKE.LEVEL='4'
MAKEFILE=''
.MAKE.MODE='meta missing-filemon=yes missing-meta=yes silent=yes verbose'
_ERROR_CMD='/usr/local/libexec/ccache/world/cc  -O2 -pipe -fno-strict-aliasing -fno-common -march=native  -Wall -DFREEBSD_ELF -DIN_RTLD -ffreestanding -I/usr/src/lib/csu/common -I/usr/src/libexec/rtld-elf/amd64 -I/usr/src/libexec/rtld-elf -fpic -DPIC  -fvisibility=hidden -mno-mmx -mno-sse -mno-avx -mno-avx2 -msoft-float -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual -Wwrite-strings -Wswitch -Wshadow -Wunused-parameter -Wchar-subscripts -Winline -Wnested-externs -Wredundant-decls -Wold-style-definition -Wno-pointer-sign -Wformat=2 -Wno-format-extra-args -Werror -Wmissing-variable-declarations -Wthread-safety -Wno-empty-body -Wno-string-plus-int -Wno-unused-const-variable  -Qunused-arguments  -c /usr/src/libexec/rtld-elf/rtld.c -o rtld.o; ;'
.CURDIR='/usr/src/libexec/rtld-elf'
.MAKE='make'
.OBJDIR='/usr/obj/usr/src/amd64.amd64/libexec/rtld-elf'
.TARGETS='all'
DESTDIR='/usr/obj/usr/src/amd64.amd64/tmp'
LD_LIBRARY_PATH=''
MACHINE='amd64'
MACHINE_ARCH='amd64'
MAKEOBJDIRPREFIX=''
MAKESYSPATH='/usr/src/share/mk'
MAKE_VERSION='20180512'
PATH='/usr/obj/usr/src/amd64.amd64/tmp/legacy/usr/sbin:/usr/obj/usr/src/amd64.amd64/tmp/legacy/usr/bin:/usr/obj/usr/src/amd64.amd64/tmp/legacy/bin:/usr/obj/usr/src/amd64.amd64/tmp/usr/sbin:/usr/obj/usr/src/amd64.amd64/tmp/usr/bin:/sbin:/bin:/usr/sbin:/usr/bin'
SRCTOP='/usr/src'
OBJTOP='/usr/obj/usr/src/amd64.amd64'
.MAKE.MAKEFILES='/usr/src/share/mk/sys.mk /usr/src/share/mk/local.sys.env.mk /usr/src/share/mk/src.sys.env.mk /etc/src-env.conf /usr/src/share/mk/bsd.mkopt.mk /usr/src/share/mk/src.sys.obj.mk /usr/src/share/mk/auto.obj.mk /usr/src/share/mk/bsd.suffixes.mk /etc/make.conf /usr/src/share/mk/local.sys.mk /usr/src/share/mk/src.sys.mk /etc/src.conf /usr/src/libexec/rtld-elf/Makefile /usr/src/share/mk/src.opts.mk /usr/src/share/mk/bsd.own.mk /usr/src/share/mk/bsd.opts.mk /usr/src/share/mk/bsd.cpu.mk /usr/src/share/mk/bsd.compiler.mk /usr/src/share/mk/bsd.linker.mk /usr/src/libexec/rtld-elf/amd64/Makefile.inc /usr/src/share/mk/bsd.prog.mk /usr/src/share/mk/bsd.init.mk /usr/src/share/mk/local.init.mk /usr/src/share/mk/src.init.mk /usr/src/libexec/rtld-elf/../Makefile.inc /usr/src/share/mk/bsd.libnames.mk /usr/src/share/mk/src.libnames.mk /usr/src/share/mk/bsd.nls.mk /usr/src/share/mk/bsd.confs.mk /usr/src/share/mk/bsd.files.mk /usr/src/share/mk/bsd.dirs.mk /usr/src/share/mk/bsd.incs.mk /usr/src/share/mk/bsd.links.mk /usr/src/share/mk/bsd.dep.mk /usr/src/share/mk/bsd.clang-analyze.mk /usr/src/share/mk/bsd.obj.mk /usr/src/share/mk/bsd.subdir.mk /usr/src/share/mk/bsd.sys.mk /usr/src/share/mk/bsd.symver.mk'
.PATH='. /usr/src/libexec/rtld-elf /usr/src/libexec/rtld-elf/amd64'
*** Error code 1

Stop.
make[3]: stopped in /usr/src/libexec
.ERROR_TARGET='all_subdir_libexec/rtld-elf'
.ERROR_META_FILE=''
.MAKE.LEVEL='3'
MAKEFILE=''
.MAKE.MODE='meta missing-filemon=yes missing-meta=yes silent=yes verbose'
_ERROR_CMD='.PHONY'
.CURDIR='/usr/src/libexec'
.MAKE='make'
.OBJDIR='/usr/obj/usr/src/amd64.amd64/libexec'
.TARGETS='all'
DESTDIR='/usr/obj/usr/src/amd64.amd64/tmp'
LD_LIBRARY_PATH=''
MACHINE='amd64'
MACHINE_ARCH='amd64'
MAKEOBJDIRPREFIX=''
MAKESYSPATH='/usr/src/share/mk'
MAKE_VERSION='20180512'
PATH='/usr/obj/usr/src/amd64.amd64/tmp/legacy/usr/sbin:/usr/obj/usr/src/amd64.amd64/tmp/legacy/usr/bin:/usr/obj/usr/src/amd64.amd64/tmp/legacy/bin:/usr/obj/usr/src/amd64.amd64/tmp/usr/sbin:/usr/obj/usr/src/amd64.amd64/tmp/usr/bin:/sbin:/bin:/usr/sbin:/usr/bin'
SRCTOP='/usr/src'
OBJTOP='/usr/obj/usr/src/amd64.amd64'
.MAKE.MAKEFILES='/usr/src/share/mk/sys.mk /usr/src/share/mk/local.sys.env.mk /usr/src/share/mk/src.sys.env.mk /etc/src-env.conf /usr/src/share/mk/bsd.mkopt.mk /usr/src/share/mk/src.sys.obj.mk /usr/src/share/mk/auto.obj.mk /usr/src/share/mk/bsd.suffixes.mk /etc/make.conf /usr/src/share/mk/local.sys.mk /usr/src/share/mk/src.sys.mk /etc/src.conf /usr/src/libexec/Makefile /usr/src/share/mk/src.opts.mk /usr/src/share/mk/bsd.own.mk /usr/src/share/mk/bsd.opts.mk /usr/src/share/mk/bsd.cpu.mk /usr/src/share/mk/bsd.compiler.mk /usr/src/share/mk/bsd.linker.mk /usr/src/share/mk/bsd.arch.inc.mk /usr/src/libexec/Makefile.amd64 /usr/src/share/mk/bsd.subdir.mk /usr/src/share/mk/bsd.init.mk /usr/src/share/mk/local.init.mk /usr/src/share/mk/src.init.mk'
.PATH='. /usr/src/libexec'
*** Error code 1

Stop.
make[2]: stopped in /usr/src
.ERROR_TARGET='all_subdir_libexec'
.ERROR_META_FILE=''
.MAKE.LEVEL='2'
MAKEFILE=''
.MAKE.MODE='meta missing-filemon=yes missing-meta=yes silent=yes verbose'
_ERROR_CMD='.PHONY'
.CURDIR='/usr/src'
.MAKE='make'
.OBJDIR='/usr/obj/usr/src/amd64.amd64'
.TARGETS='all'
DESTDIR='/usr/obj/usr/src/amd64.amd64/tmp'
LD_LIBRARY_PATH=''
MACHINE='amd64'
MACHINE_ARCH='amd64'
MAKEOBJDIRPREFIX=''
MAKESYSPATH='/usr/src/share/mk'
MAKE_VERSION='20180512'
PATH='/usr/obj/usr/src/amd64.amd64/tmp/legacy/usr/sbin:/usr/obj/usr/src/amd64.amd64/tmp/legacy/usr/bin:/usr/obj/usr/src/amd64.amd64/tmp/legacy/bin:/usr/obj/usr/src/amd64.amd64/tmp/usr/sbin:/usr/obj/usr/src/amd64.amd64/tmp/usr/bin:/sbin:/bin:/usr/sbin:/usr/bin'
SRCTOP='/usr/src'
OBJTOP='/usr/obj/usr/src/amd64.amd64'
.MAKE.MAKEFILES='/usr/src/share/mk/sys.mk /usr/src/share/mk/local.sys.env.mk /usr/src/share/mk/src.sys.env.mk /etc/src-env.conf /usr/src/share/mk/bsd.mkopt.mk /usr/src/share/mk/src.sys.obj.mk /usr/src/share/mk/auto.obj.mk /usr/src/share/mk/bsd.suffixes.mk /etc/make.conf /usr/src/share/mk/local.sys.mk /usr/src/share/mk/src.sys.mk /etc/src.conf /usr/src/Makefile.inc1 /usr/src/share/mk/bsd.compiler.mk /usr/src/share/mk/bsd.opts.mk /usr/src/share/mk/bsd.cpu.mk /usr/src/share/mk/src.opts.mk /usr/src/share/mk/bsd.own.mk /usr/src/share/mk/bsd.linker.mk /usr/src/share/mk/bsd.subdir.mk /usr/src/share/mk/bsd.init.mk /usr/src/share/mk/local.init.mk /usr/src/share/mk/src.init.mk'
.PATH='. /usr/src'
*** Error code 1

Stop.
make[1]: stopped in /usr/src
.ERROR_TARGET='everything'
.ERROR_META_FILE=''
.MAKE.LEVEL='1'
MAKEFILE=''
.MAKE.MODE='meta missing-filemon=yes missing-meta=yes silent=yes verbose'
_ERROR_CMD='.PHONY'
.CURDIR='/usr/src'
.MAKE='make'
.OBJDIR='/usr/obj/usr/src/amd64.amd64'
.TARGETS='buildworld'
DESTDIR=''
LD_LIBRARY_PATH=''
MACHINE='amd64'
MACHINE_ARCH='amd64'
MAKEOBJDIRPREFIX=''
MAKESYSPATH='/usr/src/share/mk'
MAKE_VERSION='20180512'
PATH='/sbin:/bin:/usr/sbin:/usr/bin'
SRCTOP='/usr/src'
OBJTOP='/usr/obj/usr/src/amd64.amd64'
.MAKE.MAKEFILES='/usr/src/share/mk/sys.mk /usr/src/share/mk/local.sys.env.mk /usr/src/share/mk/src.sys.env.mk /etc/src-env.conf /usr/src/share/mk/bsd.mkopt.mk /usr/src/share/mk/src.sys.obj.mk /usr/src/share/mk/auto.obj.mk /usr/src/share/mk/bsd.suffixes.mk /etc/make.conf /usr/src/share/mk/local.sys.mk /usr/src/share/mk/src.sys.mk /etc/src.conf /usr/src/Makefile.inc1 /usr/src/share/mk/bsd.compiler.mk /usr/src/share/mk/bsd.opts.mk /usr/src/share/mk/bsd.cpu.mk /usr/src/share/mk/src.opts.mk /usr/src/share/mk/bsd.own.mk /usr/src/share/mk/bsd.linker.mk /usr/src/share/mk/bsd.subdir.mk /usr/src/share/mk/bsd.init.mk /usr/src/share/mk/local.init.mk /usr/src/share/mk/src.init.mk'
.PATH='. /usr/src'
*** Error code 1

Stop.
make: stopped in /usr/src
.ERROR_TARGET='buildworld'
.ERROR_META_FILE=''
.MAKE.LEVEL='0'
MAKEFILE=''
.MAKE.MODE='normal'
_ERROR_CMD='.PHONY'
.CURDIR='/usr/src'
.MAKE='make'
.OBJDIR='/usr/obj/usr/src/amd64.amd64'
.TARGETS='buildworld'
DESTDIR=''
LD_LIBRARY_PATH=''
MACHINE='amd64'
MACHINE_ARCH='amd64'
MAKEOBJDIRPREFIX='/usr/obj'
MAKESYSPATH='/usr/src/share/mk'
MAKE_VERSION='20180512'
PATH='/sbin:/bin:/usr/sbin:/usr/bin'
SRCTOP='/usr/src'
OBJTOP='/usr/obj/usr/src/amd64.amd64'
Comment 1 Ed Maste freebsd_committer 2020-05-28 20:36:03 UTC
https://ci.freebsd.org/job/FreeBSD-stable-12-amd64-build/
CI is green so this appears to be something unique in your environment.

What FreeBSD version is installed on your build host, do you have any /etc/src.conf settings, etc.?
Comment 2 Mark Johnston freebsd_committer 2020-06-04 15:57:54 UTC

*** This bug has been marked as a duplicate of bug 246788 ***