Commit 45b7befa authored by Henri Menke's avatar Henri Menke
Browse files

libwebsockets: Fix CMake config for static build

parent f23b37e0
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" \