-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
31 lines (23 loc) · 892 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# ===== Build settings =====
MLMORPH_VERSION=1.0
MLMORPH_PACKAGENAME:=libreoffice-mlmorph
SRCDIST=README.md LICENSE.txt AUTHORS.md requirements.txt Makefile
EXTENSIONFILES=META-INF pythonpath description.xml lomlmorph.py icon.png mlmorph.components
.PHONY: all build clean bdist sdist
all: clean bdist sdist
bdist: build
@mkdir -p dist
cd build/oxt && zip -rq ../../dist/$(MLMORPH_PACKAGENAME)-$(MLMORPH_VERSION).oxt $(EXTENSIONFILES)
sdist:
@mkdir -p dist
tar -czf dist/$(MLMORPH_PACKAGENAME)-$(MLMORPH_VERSION).tar.gz oxt $(SRCDIST)
build: clean
@mkdir -p build
@cp -rf oxt build/
@cp -r README.md LICENSE.txt build/
@pip install --upgrade --target build/oxt/pythonpath -r requirements.txt
@sed -i -e s/MLMORPH_VERSION/$(MLMORPH_VERSION)/g build/oxt/description.xml
install: bdist
unopkg add -f dist/$(MLMORPH_PACKAGENAME)-$(MLMORPH_VERSION).oxt
clean:
@rm -rf build dist