build system: makefile for taler-wallet-cli
This commit is contained in:
parent
c32b80c176
commit
89a1b7119e
5
.gitignore
vendored
5
.gitignore
vendored
@ -8,9 +8,8 @@ tsconfig.tsbuildinfo
|
|||||||
build/
|
build/
|
||||||
|
|
||||||
# GNU-style build system
|
# GNU-style build system
|
||||||
/configure
|
configure
|
||||||
/build-system/config.mk
|
.config.mk
|
||||||
/.config.mk
|
|
||||||
|
|
||||||
# Editor files
|
# Editor files
|
||||||
\#*\#
|
\#*\#
|
||||||
|
22
Makefile
22
Makefile
@ -10,7 +10,7 @@ ava = node_modules/.bin/ava
|
|||||||
nyc = node_modules/nyc/bin/nyc.js
|
nyc = node_modules/nyc/bin/nyc.js
|
||||||
git-archive-all = ./build-system/taler-build-scripts/archive-with-submodules/git_archive_all.py
|
git-archive-all = ./build-system/taler-build-scripts/archive-with-submodules/git_archive_all.py
|
||||||
|
|
||||||
include ./build-system/config.mk
|
include .config.mk
|
||||||
|
|
||||||
.PHONY: dist
|
.PHONY: dist
|
||||||
dist:
|
dist:
|
||||||
@ -105,26 +105,6 @@ i18n: compile
|
|||||||
|
|
||||||
# Some commands are only available when ./configure has been run
|
# Some commands are only available when ./configure has been run
|
||||||
|
|
||||||
ifndef prefix
|
|
||||||
.PHONY: warn-noprefix install
|
|
||||||
warn-noprefix:
|
|
||||||
@echo "no prefix configured, did you run ./configure?"
|
|
||||||
install: warn-noprefix
|
|
||||||
else
|
|
||||||
install_target = $(prefix)/lib/taler-wallet-cli
|
|
||||||
.PHONY: install
|
|
||||||
install:
|
|
||||||
pnpm install --frozen-lockfile --filter @gnu-taler/taler-wallet-cli...
|
|
||||||
install -d $(prefix)/bin
|
|
||||||
install -d $(install_target)/bin
|
|
||||||
install -d $(install_target)/node_modules/taler-wallet-cli
|
|
||||||
install -d $(install_target)/node_modules/taler-wallet-cli/bin
|
|
||||||
install -d $(install_target)/node_modules/taler-wallet-cli/dist
|
|
||||||
install ./packages/taler-wallet-cli/dist/taler-wallet-cli.js $(install_target)/node_modules/taler-wallet-cli/dist/
|
|
||||||
install ./packages/taler-wallet-cli/dist/taler-wallet-cli.js.map $(install_target)/node_modules/taler-wallet-cli/dist/
|
|
||||||
install ./packages/taler-wallet-cli/bin/taler-wallet-cli $(install_target)/node_modules/taler-wallet-cli/bin/
|
|
||||||
ln -sf $(install_target)/node_modules/taler-wallet-cli/bin/taler-wallet-cli $(prefix)/bin/taler-wallet-cli
|
|
||||||
endif
|
|
||||||
|
|
||||||
.PHONY: lint
|
.PHONY: lint
|
||||||
lint:
|
lint:
|
||||||
|
18
bootstrap
18
bootstrap
@ -11,8 +11,16 @@ if ! git --version >/dev/null; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
git submodule update --init
|
git submodule update --init
|
||||||
rm -rf configure
|
|
||||||
cp build-system/taler-build-scripts/configure ./configure
|
copy_configure() {
|
||||||
# Try making the configure script read-only to prevent
|
src=$1
|
||||||
# accidental changes in the wrong place.
|
dst=$2
|
||||||
chmod ogu-w ./configure || true
|
rm -f $dst
|
||||||
|
cp $src $dst
|
||||||
|
# Try making the configure script read-only to prevent
|
||||||
|
# accidental changes in the wrong place.
|
||||||
|
chmod ogu-w $dst || true
|
||||||
|
}
|
||||||
|
our_configure=build-system/taler-build-scripts/configure
|
||||||
|
copy_configure "$our_configure" ./configure
|
||||||
|
copy_configure "$our_configure" ./packages/taler-wallet-cli/configure
|
||||||
|
27
packages/taler-wallet-cli/Makefile
Normal file
27
packages/taler-wallet-cli/Makefile
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
# This Makefile has been placed in the public domain.
|
||||||
|
|
||||||
|
include .config.mk
|
||||||
|
|
||||||
|
all:
|
||||||
|
@echo use 'make install' to build and install taler-wallet-cli
|
||||||
|
|
||||||
|
ifndef prefix
|
||||||
|
.PHONY: warn-noprefix install
|
||||||
|
warn-noprefix:
|
||||||
|
@echo "no prefix configured, did you run ./configure?"
|
||||||
|
install: warn-noprefix
|
||||||
|
else
|
||||||
|
install_target = $(prefix)/lib/taler-wallet-cli
|
||||||
|
.PHONY: install
|
||||||
|
install:
|
||||||
|
pnpm install --frozen-lockfile --filter @gnu-taler/taler-wallet-cli...
|
||||||
|
install -d $(prefix)/bin
|
||||||
|
install -d $(install_target)/bin
|
||||||
|
install -d $(install_target)/node_modules/taler-wallet-cli
|
||||||
|
install -d $(install_target)/node_modules/taler-wallet-cli/bin
|
||||||
|
install -d $(install_target)/node_modules/taler-wallet-cli/dist
|
||||||
|
install ./dist/taler-wallet-cli.js $(install_target)/node_modules/taler-wallet-cli/dist/
|
||||||
|
install ./dist/taler-wallet-cli.js.map $(install_target)/node_modules/taler-wallet-cli/dist/
|
||||||
|
install ./bin/taler-wallet-cli $(install_target)/node_modules/taler-wallet-cli/bin/
|
||||||
|
ln -sf $(install_target)/node_modules/taler-wallet-cli/bin/taler-wallet-cli $(prefix)/bin/taler-wallet-cli
|
||||||
|
endif
|
Loading…
Reference in New Issue
Block a user