Closed cdepillabout closed 1 year ago
Without this PR, I was seeing errors like the following:
...
[ 55%] Linking CXX executable bin/inproc_lat
/nix/store/fhzz4yrdy17czwc9i4swhlpcp445inzb-binutils-2.40/bin/ld: lib/libzmq.so.5.2.4: undefined reference to `pgm_error_free'
/nix/store/fhzz4yrdy17czwc9i4swhlpcp445inzb-binutils-2.40/bin/ld: lib/libzmq.so.5.2.4: undefined reference to `pgm_send'
/nix/store/fhzz4yrdy17czwc9i4swhlpcp445inzb-binutils-2.40/bin/ld: lib/libzmq.so.5.2.4: undefined reference to `pgm_shutdown'
/nix/store/fhzz4yrdy17czwc9i4swhlpcp445inzb-binutils-2.40/bin/ld: lib/libzmq.so.5.2.4: undefined reference to `pgm_bind3'
/nix/store/fhzz4yrdy17czwc9i4swhlpcp445inzb-binutils-2.40/bin/ld: lib/libzmq.so.5.2.4: undefined reference to
collect2: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/local_lat.dir/build.make:99: bin/local_lat] Error 1
make[1]: *** [CMakeFiles/Makefile2:445: CMakeFiles/local_lat.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
...
From the error messages, you can tell I'm building with Nix on Linux, but I expect that this error affects other distros as well.
It looks like the CI job "OBS: libzmq - openSUSE_Leap_15/x86_64" is failing, but the failure doesn't look related to this PR?
I was noticing a problem where libzmq fails to link to openpgm when building with CMake.
This PR fixes the problem by making sure to link to openpgm when passing the
-DWITH_OPENPGM=1
to cmake.