make install for taler-util into taler-js

This commit is contained in:
Sebastian 2023-10-10 10:34:01 -03:00
parent 5d1e0ae008
commit 0631187f42
No known key found for this signature in database
GPG Key ID: 173909D1A5F66069
2 changed files with 44 additions and 1 deletions

View File

@ -29,5 +29,6 @@ copy_configure "$our_configure" ./configure
copy_configure "$our_configure" ./packages/taler-wallet-cli/configure copy_configure "$our_configure" ./packages/taler-wallet-cli/configure
copy_configure "$our_configure" ./packages/anastasis-cli/configure copy_configure "$our_configure" ./packages/anastasis-cli/configure
copy_configure "$our_configure" ./packages/demobank-ui/configure copy_configure "$our_configure" ./packages/demobank-ui/configure
copy_configure "$our_configure" ./packages/merchant-backoffice-ui/configure
copy_configure "$our_configure" ./packages/taler-harness/configure copy_configure "$our_configure" ./packages/taler-harness/configure
copy_configure "$our_configure" ./packages/taler-util/configure
copy_configure "$our_configure" ./packages/merchant-backoffice-ui/configure

View File

@ -0,0 +1,42 @@
# This Makefile has been placed in the public domain.
ifeq ($(TOPLEVEL), yes)
$(info top-level build)
-include ../../.config.mk
override DESTDIR := $(TOP_DESTDIR)
else
$(info package-level build)
-include ../../.config.mk
-include .config.mk
endif
$(info prefix is $(prefix))
all:
@echo use 'make install' to build and install taler-util
ifndef prefix
.PHONY: warn-noprefix install
warn-noprefix:
@echo "no prefix configured, did you run ./configure?"
install: warn-noprefix
else
LIBDIR = $(prefix)/share/taler-js/taler-util
NODE_DEPS = $(shell jq "(.dependencies|keys|map(\"node_modules/\" + .)|join(\" \"))" package.json -r)
.PHONY: install install-nodeps deps
install-nodeps:
pnpm compile
@echo installing taler-util to $(DESTDIR)$(prefix)
install -d $(DESTDIR)$(LIBDIR)/lib/globbing
install lib/*.* $(DESTDIR)$(LIBDIR)/lib
install lib/globbing/*.* $(DESTDIR)$(LIBDIR)/lib/globbing
install package.json $(DESTDIR)$(LIBDIR)
tar hcf - $(NODE_DEPS) | (cd $(DESTDIR)$(LIBDIR); tar xf -)
deps:
pnpm install --frozen-lockfile --filter @gnu-taler/taler-util...
pnpm run --filter @gnu-taler/taler-util... compile
install:
$(MAKE) deps
$(MAKE) install-nodeps
endif