Commit 881ee58e authored by Ethan Carter Edwards's avatar Ethan Carter Edwards Committed by Weijia Wang
Browse files
parent 9020f041
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
diff --git a/makefile b/makefile
index 444feae..0b2d482 100644
index ce33665..d85152e 100644
--- a/makefile
+++ b/makefile
@@ -134,8 +134,12 @@ clean:
@@ -148,9 +148,12 @@ clean:
 
 install: install-oprf install-noiseXK
 
-install-oprf: $(DESTDIR)$(PREFIX)/lib/liboprf.$(SOEXT) \
-	$(DESTDIR)$(PREFIX)/$(DEBUGDIR)/liboprf.$(SOEXT).debug \
-	$(DESTDIR)$(PREFIX)/lib/liboprf.$(STATICEXT) \
+INSTALL_EXT=$(STATICEXT)
+ifeq ($(findstring -shared,$(LDFLAGS)),)
+8 −2
Original line number Diff line number Diff line
@@ -9,13 +9,13 @@

stdenv.mkDerivation (finalAttrs: {
  pname = "liboprf";
  version = "0.9.2";
  version = "0.9.3";

  src = fetchFromGitHub {
    owner = "stef";
    repo = "liboprf";
    tag = "v${finalAttrs.version}";
    hash = "sha256-Toja0rR0321i7L1dsB9YxrwNJwKUzuSfK5LLR3tex7U=";
    hash = "sha256-BH7sLkj7vGtz2kSSuV2+BrwlQJ26s4UTlNL/owJhzCk=";
  };

  sourceRoot = "${finalAttrs.src.name}/src";
@@ -24,6 +24,12 @@ stdenv.mkDerivation (finalAttrs: {
    ./no-static.patch
  ];

  # strip: error: option is not supported for MachO
  postPatch = lib.optionalString stdenv.hostPlatform.isMacho ''
    substituteInPlace makefile \
      --replace-fail "--strip-unneeded" ""
  '';

  strictDeps = true;

  nativeBuildInputs = [ pkgconf ];