diff options
author | Charles Duffy <charles@dyfis.net> | 2023-03-13 15:20:35 -0500 |
---|---|---|
committer | Charles Duffy <charles@dyfis.net> | 2023-03-13 15:20:35 -0500 |
commit | d742e50b2f36832c88699bb71bb6362f8baf5582 (patch) | |
tree | a97ac82f25c0f11b2872c6be1d89ae85f495894a | |
parent | 77f3fa8c58fda2038c94322f28629c4f22c0b827 (diff) |
osslsigncode: per review feedback, pull patches from github rather than vendoring into the tree
-rw-r--r-- | pkgs/development/tools/osslsigncode/darwin-cmake.patch | 20 | ||||
-rw-r--r-- | pkgs/development/tools/osslsigncode/default.nix | 14 |
2 files changed, 13 insertions, 21 deletions
diff --git a/pkgs/development/tools/osslsigncode/darwin-cmake.patch b/pkgs/development/tools/osslsigncode/darwin-cmake.patch deleted file mode 100644 index 477a81c9c3999..0000000000000 --- a/pkgs/development/tools/osslsigncode/darwin-cmake.patch +++ /dev/null @@ -1,20 +0,0 @@ -diff --git a/cmake/SetCompilerFlags.cmake b/cmake/SetCompilerFlags.cmake -index 8e83390..bd734f0 100644 ---- a/cmake/SetCompilerFlags.cmake -+++ b/cmake/SetCompilerFlags.cmake -@@ -98,13 +98,13 @@ function(add_compile_flags target) - endif() - endif() - # Support address space layout randomization (ASLR) -- if(NOT (MINGW OR CMAKE_C_COMPILER_ID STREQUAL "AppleClang")) -+ if(NOT (MINGW OR CMAKE_C_COMPILER_ID STREQUAL "AppleClang" OR ((CMAKE_SYSTEM_NAME MATCHES Darwin) AND (CMAKE_C_COMPILER_ID MATCHES Clang)))) - target_compile_options(${target} PRIVATE -fPIE) - target_link_options(${target} PRIVATE -fPIE -pie) - target_link_options(${target} PRIVATE -Wl,-z,relro) - target_link_options(${target} PRIVATE -Wl,-z,now) - target_link_options(${target} PRIVATE -Wl,-z,noexecstack) -- endif(NOT (MINGW OR CMAKE_C_COMPILER_ID STREQUAL "AppleClang")) -+ endif(NOT (MINGW OR CMAKE_C_COMPILER_ID STREQUAL "AppleClang" OR ((CMAKE_SYSTEM_NAME MATCHES Darwin) AND (CMAKE_C_COMPILER_ID MATCHES Clang)))) - target_link_options(${target} PRIVATE -fstack-check) - add_compile_flag_to_targets(${target}) - endif(MSVC) diff --git a/pkgs/development/tools/osslsigncode/default.nix b/pkgs/development/tools/osslsigncode/default.nix index b0407c96eec1b..4738ccd74a9c0 100644 --- a/pkgs/development/tools/osslsigncode/default.nix +++ b/pkgs/development/tools/osslsigncode/default.nix @@ -2,6 +2,7 @@ , stdenv , fetchFromGitHub , cmake +, fetchpatch , pkg-config , curl , openssl @@ -18,7 +19,18 @@ stdenv.mkDerivation rec { sha256 = "sha256-33uT9PFD1YEIMzifZkpbl2EAoC98IsM72K4rRjDfh8g="; }; - patches = [ ./darwin-cmake.patch ]; + patches = [ + # Cygwin patch is prereq for Darwin fix applying -- committed to master after 2.5 release + (fetchpatch { + url = "https://github.com/mtrojnar/osslsigncode/commit/1c678bf926b78c947b14c46c3ce88e06268c738e.patch"; + sha256 = "sha256-vOBMGIJ3PHJTvmsXRRfAUJRi7P929PcfmrUiRuM0pf4="; + }) + # Fix build on Darwin when clang not identified as Apple (https://github.com/mtrojnar/osslsigncode/pull/247) + (fetchpatch { + url = "https://github.com/charles-dyfis-net/osslsigncode/commit/b2ed89b35c8a26faa7eb6515fecaff3c4c5f7fed.patch"; + sha256 = "sha256-FGKZK/IzHbbkTzSoAtpC75z79d5+qQvvJrjEDY31WJ0="; + }) + ]; nativeBuildInputs = [ cmake pkg-config ]; |