diff options
author | Jörg Thalheim <Mic92@users.noreply.github.com> | 2021-09-11 15:32:36 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-09-11 15:32:36 +0100 |
commit | 57c3e7db502b0b5854df911d58cd34c5f5515233 (patch) | |
tree | 108654e8c5a91b6b6ebe431b5b884a8fd71b5d60 | |
parent | 88177c44f8fd9fa77ac0f1e24a5cec84dd01dcff (diff) | |
parent | d2f4d2e3b50c6669b14c8797aca675a825b77a74 (diff) | |
download | patchelf-57c3e7db502b0b5854df911d58cd34c5f5515233.tar.gz |
Merge pull request #317 from Mic92/clang
also build with clang
-rw-r--r-- | flake.nix | 15 | ||||
-rw-r--r-- | patchelf.nix | 8 |
2 files changed, 17 insertions, 6 deletions
@@ -23,18 +23,13 @@ { overlay = final: prev: { - patchelf-new = final.stdenv.mkDerivation { - pname = "patchelf"; + patchelf-new = final.callPackage ./patchelf.nix { inherit version; src = self; - nativeBuildInputs = [ final.autoreconfHook ]; - doCheck = true; }; - }; hydraJobs = { - tarball = pkgs.releaseTools.sourceTarball rec { name = "patchelf-tarball"; @@ -58,7 +53,13 @@ build = forAllSystems (system: nixpkgsFor.${system}.patchelf-new); build-sanitized = forAllSystems (system: nixpkgsFor.${system}.patchelf-new.overrideAttrs (old: { configureFlags = [ "--with-asan " "--with-ubsan" ]; + # -Wno-unused-command-line-argument is for clang, which does not like + # our cc wrapper arguments + CFLAGS = "-Werror -Wno-unused-command-line-argument"; })); + build-sanitized-clang = forAllSystems (system: self.hydraJobs.build-sanitized.${system}.override { + stdenv = pkgs.libcxxStdenv; + }); release = pkgs.releaseTools.aggregate { name = "patchelf-${self.hydraJobs.tarball.version}"; @@ -68,6 +69,8 @@ self.hydraJobs.build.i686-linux self.hydraJobs.build-sanitized.x86_64-linux self.hydraJobs.build-sanitized.i686-linux + self.hydraJobs.build-sanitized-clang.x86_64-linux + self.hydraJobs.build-sanitized-clang.i686-linux ]; meta.description = "Release-critical builds"; }; diff --git a/patchelf.nix b/patchelf.nix new file mode 100644 index 0000000..fdeba6b --- /dev/null +++ b/patchelf.nix @@ -0,0 +1,8 @@ +{ stdenv, autoreconfHook, version, src }: + +stdenv.mkDerivation { + pname = "patchelf"; + inherit version src; + nativeBuildInputs = [ autoreconfHook ]; + doCheck = true; +} |