When building /usr/lib64/ocaml/stublibs/dllbrlapi_stubs.so, the Fedora build flags were not applied correctly. At least the linker flags (LDFLAGS) are missing. You need to pass $RPM_LD_FLAGS (or equivalent) down to the linker invocation. See https://src.fedoraproject.org/rpms/redhat-rpm-config/blob/master/f/buildflags.md for information on RPM macros and environment variables provided by the build environment.
I'm not sure how to ensure that if OCaml.
It turns out that /usr/lib64/brltty/libbrlapi_java.so, /usr/lib64/brltty/libbrlttyxsc.so, /usr/lib64/libbrlapi.so.0.6.7, /usr/lib64/tcl8.6/brlapi-0.6.7/libbrlapi_tcl.so and many others are not linked with BIND_NOW, so the LDFLAGS injection issue affects more than just the Ocaml extension.
Please check 5.2-2 in rawhide. I think I fixed it. If not let me know.
This bug appears to have been reported against 'rawhide' during the Fedora 28 development cycle. Changing version to '28'.
Still not fixed: # rpm -qf /usr/lib64/brltty/libbrlttybbg.so brltty-5.6-2.fc28.x86_64 # readelf -d /usr/lib64/brltty/libbrlttybbg.so Dynamic section at offset 0x2df8 contains 24 entries: Tag Type Name/Value 0x0000000000000001 (NEEDED) Shared library: [libc.so.6] 0x000000000000000c (INIT) 0x1078 0x000000000000000d (FINI) 0x1b50 0x0000000000000019 (INIT_ARRAY) 0x202b90 0x000000000000001b (INIT_ARRAYSZ) 8 (bytes) 0x000000000000001a (FINI_ARRAY) 0x202b98 0x000000000000001c (FINI_ARRAYSZ) 8 (bytes) 0x000000006ffffef5 (GNU_HASH) 0x228 0x0000000000000005 (STRTAB) 0x690 0x0000000000000006 (SYMTAB) 0x270 0x000000000000000a (STRSZ) 603 (bytes) 0x000000000000000b (SYMENT) 24 (bytes) 0x0000000000000003 (PLTGOT) 0x203000 0x0000000000000002 (PLTRELSZ) 720 (bytes) 0x0000000000000014 (PLTREL) RELA 0x0000000000000017 (JMPREL) 0xda8 0x0000000000000007 (RELA) 0x988 0x0000000000000008 (RELASZ) 1056 (bytes) 0x0000000000000009 (RELAENT) 24 (bytes) 0x000000006ffffffe (VERNEED) 0x948 0x000000006fffffff (VERNEEDNUM) 1 0x000000006ffffff0 (VERSYM) 0x8ec 0x000000006ffffff9 (RELACOUNT) 38 0x0000000000000000 (NULL) 0x0 NOW/BIND_NOW is still missing (there should be a line with flags).
I tried to address it in brltty-5.6-8, feel free to reopen if the problem persists.
Please also release an update via Fedora 28. Thanks.
(In reply to Florian Weimer from comment #7) > Please also release an update via Fedora 28. Thanks. OK, I will do it.
brltty-5.6-10.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2018-985d578d7b
brltty-5.6-10.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-985d578d7b
brltty-5.6-10.fc28 has been pushed to the Fedora 28 stable repository. If problems still persist, please make note of it in this bug report.
Sorry, it turns out that the build flags coverage is still incomplete: /usr/lib64/libbrlapi.so.0.6.7 has not been linked with full RELRO: gcc -shared -Wl,-soname,libbrlapi.so.0.6 -o libbrlapi.so brlapi_client.o -lpthread So there's no LDFLAGS injection at all. Samething for /usr/lib64/brltty/libbrlapi_java.so: gcc -shared -Wl,-soname,brlapi -o libbrlapi_java.so bindings.o -L./../../Programs -lbrlapi And /usr/lib64/tcl8.6/brlapi-0.6.7/libbrlapi_tcl.so: gcc -shared -Wl,-soname,brlapi -o libbrlapi_tcl.so bindings.o -L/usr/lib64 -ltcl8.6 -L./../../Programs -lbrlapi /usr/lib64/ocaml/stublibs/dllbrlapi_stubs.so is affected as well but may be more difficult to fix because the linker invocation happens within Ocaml.
brltty-5.6-11.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2018-ace78e1472
brltty-5.6-12.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2018-8a0d5b35fe
brltty-5.6-11.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-ace78e1472
brltty-5.6-12.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-8a0d5b35fe
brltty-5.6-12.fc28 has been pushed to the Fedora 28 stable repository. If problems still persist, please make note of it in this bug report.