gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-bank] 02/04: build system


From: gnunet
Subject: [taler-bank] 02/04: build system
Date: Mon, 09 Nov 2020 16:43:36 +0100

This is an automated email from the git hooks/post-receive script.

dold pushed a commit to branch master
in repository bank.

commit 421b008359dcee492c5ed0ecaea58e8b404e900b
Author: Florian Dold <florian@dold.me>
AuthorDate: Mon Nov 9 16:26:59 2020 +0100

    build system
---
 .gitignore                | 12 +++---------
 build-system/Makefile     | 41 +++++++++++++++++++++++++++++++++++++++++
 build-system/configure.py | 24 ++++++++++++++++++++++++
 3 files changed, 68 insertions(+), 9 deletions(-)

diff --git a/.gitignore b/.gitignore
index c71b3b6..0232395 100644
--- a/.gitignore
+++ b/.gitignore
@@ -13,17 +13,11 @@ doc/taler-bank.info
 doc/version.texi
 doc/texinfo.tex
 *.mo
-**/Makefile
-**/Makefile.in
 aclocal.m4
 autom4te.cache/
 bank.wsgi
 compile
-config.log
-config.status
-dev.py
-install-dev.py
-install-sh
-missing
 taler-bank-manage
-
+taler-bank-*.tar.gz
+/Makefile
+/configure
diff --git a/build-system/Makefile b/build-system/Makefile
new file mode 100644
index 0000000..d07c66d
--- /dev/null
+++ b/build-system/Makefile
@@ -0,0 +1,41 @@
+# This Makefile is in the public domain
+
+version := $(shell poetry version | awk '{ print $$2 }')
+
+.PHONY: all
+all: wheel
+
+.PHONY: wheel
+wheel:
+       poetry run python3 manage.py compilemessages
+       poetry build -f wheel
+
+.PHONY: install
+install: wheel
+       pip3 install --user "dist/talerbank-$(version)-py3-none-any.whl"
+
+.PHONY: i18n-strings
+i18n-strings: install-dependencies
+       poetry run python3 manage.py makemessages -l it
+       poetry run python3 manage.py makemessages -l de
+       # Also update template for new languages
+       poetry run python3 manage.py makemessages -l en
+       mv talerbank/app/locale/en/LC_MESSAGES/django.po 
talerbank/app/locale/django.pot
+       rm -r talerbank/app/locale/en/
+
+# See bug #5850 for some test cases that are currently disabled.
+.PHONY: check
+check:
+       ./run-tests.sh
+
+.PHONY: clean
+clean:
+       rm -rf dist
+
+.PHONY: dist
+dist:
+       
./build-system/taler-build-scripts/archive-with-submodules/git_archive_all.py 
taler-bank-$(version).tar.gz
+
+.PHONY: pretty
+pretty:
+       black talerbank/
diff --git a/build-system/configure.py b/build-system/configure.py
new file mode 100644
index 0000000..2276a87
--- /dev/null
+++ b/build-system/configure.py
@@ -0,0 +1,24 @@
+# This configure.py file is places in the public domain.
+
+# Configure the build directory.
+# This file is invoked by './configure' and should usually not be invoked
+# manually.
+
+import talerbuildconfig as tbc
+import sys
+import shutil
+
+if getattr(tbc, "serialversion", 0) < 2:
+    print("talerbuildconfig outdated, please update the build-common submodule 
and/or bootstrap")
+    sys.exit(1)
+
+b = tbc.BuildConfig()
+
+# Declare dependencies
+b.add_tool(tbc.PosixTool("find"))
+b.add_tool(tbc.GenericTool("poetry", version_arg="-V"))
+
+b.run()
+
+print("copying Makefile")
+shutil.copyfile("build-system/Makefile", "Makefile")

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]