    )
  
    install(TARGETS czmq-static
-@@ -407,7 +407,7 @@
+@@ -407,7 +409,7 @@
  target_link_libraries(
      zmakecert
      czmq

-    list(APPEND MORE_LIBRARIES ${LIBZMQ_LIBRARIES})
+find_package(ZeroMQ REQUIRED)
+IF (ZeroMQ_FOUND)
+    include_directories(${ZeroMQ_INCLUDE_DIR})
+    list(APPEND MORE_LIBRARIES ${ZeroMQ_LIBRARY})
     set(pkg_config_libs_private "${pkg_config_libs_private} -lzmq")

     ${OPTIONAL_LIBRARIES}
 )
 endif()
@@ -458,7 +460,7 @@
 target_link_libraries(
     test_randof
     czmq-static
