1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-10 04:43:53 +02:00

Support building with the Perl XS bindings disabled

Since the Perl bindings require shared libraries, this is required on
platforms such as Cygwin where we do a static build.
This commit is contained in:
Eelco Dolstra 2012-05-10 19:03:23 -04:00
parent 6a7b24a3f2
commit 4f7bab7db1
5 changed files with 92 additions and 12 deletions

View file

@ -2,9 +2,12 @@ PERL_MODULES = lib/Nix/Store.pm lib/Nix/Manifest.pm lib/Nix/GeneratePatches.pm l
all: $(PERL_MODULES:.in=)
install-exec-local: $(PERL_MODULES:.in=)
install-exec-local: $(PERL_MODULES:.in=) install-perl-xs
$(INSTALL) -d $(DESTDIR)$(perllibdir)/Nix
$(INSTALL_DATA) $(PERL_MODULES:.in=) $(DESTDIR)$(perllibdir)/Nix
if PERL_BINDINGS
install-perl-xs:
$(INSTALL) -d $(DESTDIR)$(perllibdir)/auto/Nix/Store
ln -sfn $(pkglibdir)/libNixStore$(dynlib_suffix) $(DESTDIR)$(perllibdir)/auto/Nix/Store/Store$(dynlib_suffix)
@ -25,6 +28,10 @@ AM_CXXFLAGS = \
lib/Nix/Store.cc: lib/Nix/Store.xs
xsubpp $^ -output $@
else
install-perl-xs:
endif
EXTRA_DIST = $(PERL_MODULES) lib/Nix/Store.xs
include ../substitute.mk