Thank you, all variants work fine.

Now I have another issue with "nfdump" package, probably for the same reason: a build flag interference.

I use '-fPIC' in LDFLAGS to make "configure" happy: https://src.fedoraproject.org/rpms/nfdump/blob/rawhide/f/nfdump.spec#_49

I suspect that this flag presence affects the package build, or maybe it's related to other changes.
It worked for F35 and earlier, and still works with simple "./configure && make" (without RPM build flags).

...
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I.. -ggdb -g -O3 -std=gnu11 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wmissing-noreturn -fno-strict-aliasing -DNSEL -c ipconv.c  -fPIC -DPIC -o .libs/ipconv.o
/bin/sh ../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I. -I..    -ggdb  -g -O3 -std=gnu11 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wmissing-noreturn -fno-strict-aliasing -DNSEL -c -o exporter.lo exporter.c
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I.. -ggdb -g -O3 -std=gnu11 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wmissing-noreturn -fno-strict-aliasing -DNSEL -c exporter.c  -fPIC -DPIC -o .libs/exporter.o
/bin/sh ../libtool  --tag=CC   --mode=link gcc -ggdb  -g -O3 -std=gnu11 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wmissing-noreturn -fno-strict-aliasing -DNSEL -release 1.6.23 -Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -Wl,--build-id=sha1 -Wl,-dT,/home/mock/rpmbuild/BUILD/nfdump-1.6.23/.package_note-nfdump-1.6.23-3.fc36.x86_64.ld -fPIC -o libnfdump.la -rpath /usr/lib64 output_util.lo output_raw.lo output_json.lo output_csv.lo output_pipe.lo output_fmt.lo util.lo minilzo.lo lz4.lo nffile.lo nfx.lo flist.lo fts_compat.lo grammar.lo scanner.lo nftree.lo ipconv.lo exporter.lo  -lresolv -lbz2
libtool: link: gcc -shared  -fPIC -DPIC  .libs/output_util.o .libs/output_raw.o .libs/output_json.o .libs/output_csv.o .libs/output_pipe.o .libs/output_fmt.o .libs/util.o .libs/minilzo.o .libs/lz4.o .libs/nffile.o .libs/nfx.o .libs/flist.o .libs/fts_compat.o .libs/grammar.o .libs/scanner.o .libs/nftree.o .libs/ipconv.o .libs/exporter.o   -lresolv -lbz2 -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -ggdb -g -O3 -Wl,-z -Wl,relro -Wl,--as-needed -Wl,-z -Wl,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 -Wl,-dT -Wl,/home/mock/rpmbuild/BUILD/nfdump-1.6.23/.package_note-nfdump-1.6.23-3.fc36.x86_64.ld   -Wl,-soname -Wl,libnfdump-1.6.23.so -o .libs/libnfdump-1.6.23.so
libtool: link: (cd ".libs" && rm -f "libnfdump.so" && ln -s "libnfdump-1.6.23.so" "libnfdump.so")
libtool: link: ( cd ".libs" && rm -f "libnfdump.la" && ln -s "../libnfdump.la" "libnfdump.la" )
/bin/sh ../libtool  --tag=CC   --mode=link gcc -DPCAP -g -O3 -std=gnu11 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wmissing-noreturn -fno-strict-aliasing -DNSEL  -Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -Wl,--build-id=sha1 -Wl,-dT,/home/mock/rpmbuild/BUILD/nfdump-1.6.23/.package_note-nfdump-1.6.23-3.fc36.x86_64.ld -fPIC -o nfcapd nfcapd-nfcapd.o nfcapd-nfstatfile.o nfcapd-launch.o nfcapd-nfnet.o nfcapd-collector.o nfcapd-netflow_v1.o nfcapd-netflow_v5_v7.o nfcapd-netflow_v9.o nfcapd-ipfix.o nfcapd-bookkeeper.o nfcapd-expire.o nfcapd-pcap_reader.o libnfdump.la -lpcap  -lresolv -lbz2
libtool: link: gcc -DPCAP -g -O3 -std=gnu11 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wmissing-noreturn -fno-strict-aliasing -DNSEL -Wl,-z -Wl,relro -Wl,--as-needed -Wl,-z -Wl,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 -Wl,-dT -Wl,/home/mock/rpmbuild/BUILD/nfdump-1.6.23/.package_note-nfdump-1.6.23-3.fc36.x86_64.ld -fPIC -o .libs/nfcapd nfcapd-nfcapd.o nfcapd-nfstatfile.o nfcapd-launch.o nfcapd-nfnet.o nfcapd-collector.o nfcapd-netflow_v1.o nfcapd-netflow_v5_v7.o nfcapd-netflow_v9.o nfcapd-ipfix.o nfcapd-bookkeeper.o nfcapd-expire.o nfcapd-pcap_reader.o  ./.libs/libnfdump.so -lpcap -lresolv -lbz2
/usr/bin/ld: nfcapd-nfcapd.o: relocation R_X86_64_32 against `.rodata.str1.8' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld: nfcapd-nfstatfile.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld: nfcapd-launch.o: relocation R_X86_64_32S against `.rodata' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld: nfcapd-nfnet.o: relocation R_X86_64_32 against `.rodata.str1.8' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld: nfcapd-collector.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld: nfcapd-netflow_v1.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld: nfcapd-netflow_v5_v7.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld: nfcapd-netflow_v9.o: relocation R_X86_64_32 against `.rodata.str1.8' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld: nfcapd-ipfix.o: relocation R_X86_64_32 against `.rodata.str1.8' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld: nfcapd-bookkeeper.o: relocation R_X86_64_32 against `.rodata.str1.8' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld: nfcapd-expire.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld: nfcapd-pcap_reader.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a PIE object; recompile with -fPIE
collect2: error: ld returned 1 exit status
make[3]: *** [Makefile:988: nfcapd] Error 1
make[3]: Leaving directory '/home/mock/rpmbuild/BUILD/nfdump-1.6.23/bin'
make[2]: *** [Makefile:845: all] Error 2
make[2]: Leaving directory '/home/mock/rpmbuild/BUILD/nfdump-1.6.23/bin'
make[1]: *** [Makefile:414: all-recursive] Error 1
make[1]: Leaving directory '/home/mock/rpmbuild/BUILD/nfdump-1.6.23'
make: *** [Makefile:346: all] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.0FLKs6 (%build)


On Wed, Feb 9, 2022 at 6:55 PM Vitaly Zaitsev via devel <devel@lists.fedoraproject.org> wrote:
On 08/02/2022 21:41, Florian Weimer wrote:
> CFLAGS?=-O2 -Wall -g -D_FORTIFY_SOURCE=2 -fstack-protector -fPIC
> LDFLAGS?=-Wl,-z,now -Wl,-z,relro -Wl,-soname,libscrypt.so.0 -Wl,--version-script=libscrypt.version

Can be easily fixed by changing ?= with +=.

--
Sincerely,
   Vitaly Zaitsev (vitaly@easycoding.org)
_______________________________________________
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-leave@lists.fedoraproject.org
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure


--
wbr, Denis.