Unverified Commit 96dc3ba1 authored by Rick van Schijndel's avatar Rick van Schijndel Committed by GitHub
Browse files

libwebsockets: Fix CMake config for static build (#507822)

parents db5b2066 45b7befa
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -69,6 +69,13 @@ stdenv.mkDerivation (finalAttrs: {
      ]
  );

  # Remove after https://github.com/warmcat/libwebsockets/pull/3567 has been merged or otherwise addressed
  postPatch = lib.optionalString stdenv.hostPlatform.isStatic ''
    substituteInPlace "cmake/libwebsockets-config.cmake.in" --replace-fail \
      "set(LIBWEBSOCKETS_LIBRARIES websockets websockets_shared)" \
      "set(LIBWEBSOCKETS_LIBRARIES websockets)"
  '';

  postInstall = ''
    # Fix path that will be incorrect on move to "dev" output.
    substituteInPlace "$out/lib/cmake/libwebsockets/LibwebsocketsTargets-release.cmake" \