diff --git a/projects/libwebsockets.org/package.yml b/projects/libwebsockets.org/package.yml index 5e023a89..eaf055aa 100644 --- a/projects/libwebsockets.org/package.yml +++ b/projects/libwebsockets.org/package.yml @@ -13,9 +13,24 @@ build: dependencies: cmake.org: 3 working-directory: build - script: | - cmake .. -DCMAKE_INSTALL_PREFIX="{{prefix}}" $ARGS - make --jobs {{ hw.concurrency }} install + script: + - cmake .. -DCMAKE_INSTALL_PREFIX="{{prefix}}" $ARGS + - make --jobs {{ hw.concurrency }} install + + - run: | + sed -E -i.bak \ + -e "s:{{pkgx.prefix}}:\$\{_IMPORT_PREFIX\}/../..:g" \ + -e '/^ INTERFACE_INCLUDE_DIRECTORIES/ s|/v([0-9]+)(\.[0-9]+)*[a-z]?/include|/v\1/include|g' \ + -e '/^ INTERFACE_LINK_LIBRARIES/ s|/v([0-9]+)(\.[0-9]+)*[a-z]?/lib|/v\1/lib|g' \ + LibwebsocketsTargets.cmake + + sed -E -i.bak \ + -e "s:{{pkgx.prefix}}:\$\{_IMPORT_PREFIX\}/../..:g" \ + -e '/^set\(LIBWEBSOCKETS_INCLUDE_DIRS/ s|/v([0-9]+)(\.[0-9]+)*[a-z]?/include|/v\1/include|g' \ + libwebsockets-config.cmake + + rm LibwebsocketsTargets.cmake.bak libwebsockets-config.cmake.bak + working-directory: ${{prefix}}/lib/cmake/libwebsockets env: ARGS: - -DLWS_IPV6=ON