Wind River Support Network

HomeDefectsLIN6-4873
Not to be fixed

LIN6-4873 : wrlinux 3.x - [package]-wr-integration.patch hardcodes libwrap path in 3.x

Created: Apr 9, 2013    Updated: Apr 19, 2018
Resolved Date: Apr 17, 2018
Previous ID: LIN3-27968
Found In Version: 6.0
Severity: Severe
Applicable for: Wind River Linux 6
Component/s: Userspace

Description

In wrlinux 3.x, the net-snmp-wr-integration.patch updates the original net-snmp spec file with the following changes:

...
     %if %{tcp_wrappers}
     -    --with-libwrap=%{_libdir}                  \
     +    --with-libwrap=%{_host_cross_lib_dir}      \
     +%else     
     +    --without-libwrap                          \
    %endif
...

Because of this, in the exported sysroot, the libwrap path is hardcoded (for example):
"--with-libwrap=/workspace/3.0.3/host-cross/i586-wrs-linux-gnu/sysroot/usr/lib"

In file: export/sysroot/common_pc-glibc_small/sysroot/usr/include/net-snmp/net-snmp-config-i386.h

Excerpt:

/* configure options specified */
#define NETSNMP_CONFIGURE_OPTIONS "'--host=i686-wrs-linux-gnu' '--build=i686-crosscompile-linux-gnu' '--target=i686-wrs-linux-gnu' '--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--datadir=/usr/share' '--includedir=/usr/include/net-snmp' '--libdir=/usr/lib' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--cache-file=ldat_config_cache' '--enable-static' '--enable-shared' '--with-cc=i586-wrs-linux-gnu-i686-glibc_small-gcc' '--with-cflags=-g -march=pentium4 -mmmx -msse -msse2 -mfpmath=sse -Os -fomit-frame-pointer -pipe' '--with-ar=i586-wrs-linux-gnu-i686-glibc_small-ar' '--with-sys-location=Unknown' '--with-logfile=/var/log/snmpd.log' '--with-persistent-directory=/var/net-snmp' '--with-mib-modules=host agentx smux            ucd-snmp/diskio disman/event disman/schedule tcp-mib udp-mib mibII/mta_sendmail' '--with-libwrap=/workspace/3.0.3/host-cross/i586-wrs-linux-gnu/sysroot/usr/lib' '--sysconfdir=/etc' '--enable-ipv6' '--enable-ucd-snmp-compatibility' '--without-openssl' '--with-ldflags=' '--without-rpm' '--with-pic' '--without-dmalloc' '--without-efence' '--without-rsaref' '--disable-embedded-perl' '--with-perl-modules=no' '--disable-debugging' '--enable-local-smux' '--with-endianness=little' '--with-sys-contact=root@localhost' 'CC=i586-wrs-linux-gnu-i686-glibc_small-gcc' 'CFLAGS=-g -march=pentium4 -mmmx -msse -msse2 -mfpmath=sse -Os -fomit-frame-pointer -pipe' 'CPPFLAGS=-I=/usr/include/rpm' 'CPP=i586-wrs-linux-gnu-i686-glibc_small-gcc -E' 'CXXFLAGS=-g -march=pentium4 -mmmx -msse -msse2 -mfpmath=sse -Os -fno-rtti -fno-implicit-templates -pipe' 'CXX=i586-wrs-linux-gnu-i686-glibc_small-g++' 'FFLAGS=-I/usr/lib/gfortran/modules' 'LDFLAGS=' 'build_alias=i686-crosscompile-linux-gnu' 'host_alias=i686-wrs-linux-gnu' 'target_alias=i686-wrs-linux-gnu'"

This could cause problems when building applications using the exported headers, on other machines, because the original path would not be available.

also affects alsa, ntp, perl.

Steps to Reproduce

build wrlinux 3.x project (any BSP)
export sysroot

check the resulted net-snmp-config-i386.h in the exported sysroot
Live chat
Online