-
Notifications
You must be signed in to change notification settings - Fork 265
/
Makefile.am
90 lines (70 loc) · 2.69 KB
/
Makefile.am
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
BINDIR = $(srcdir)/bin
BINFILES = \
$(BINDIR)/Pinta.exe \
$(BINDIR)/Pinta.Core.dll \
$(BINDIR)/Pinta.Gui.Widgets.dll \
$(BINDIR)/Pinta.Resources.dll \
$(BINDIR)/Extensions/Pinta.Effects.dll \
$(BINDIR)/Extensions/Pinta.Tools.dll
RELEASE_FILE = $(PACKAGE)-$(VERSION)
# target: all - Default target: build
all: build
# target: run - Launch the uninstalled copy
run:
$(MONO) bin/Pinta.exe
# target: help - Display callable targets.
help:
egrep "^# target:" Makefile | sed 's/^# target:/make/'
# target: build - Build Pinta.
build: Pinta.sln
cd $(srcdir) && $(XBUILD) Pinta.sln
cd $(srcdir) && $(XBUILD) Pinta.Install.proj /target:CompileTranslations
# target: list - List source files.
list:
if ! git status > /dev/null 2> /dev/null ;\
then \
find . -type f -name *.cs | sed 's|./||' ;\
else \
git ls-files | grep '\.cs' ;\
fi
#target: updatepot - update the messages.pot file
updatepot: build
find . -type f -name *.cs | sed 's|./||' > files.list
grep -v System.Composition.ComponentModel files.list > files2.list
xgettext --from-code=UTF-8 -f files2.list -o po/messages.pot
cat po/messages.in >> po/messages.pot
rm files.list
rm files2.list
# target: clean - Default clean command: cleanobj and cleanbin
clean: cleanobj cleanbin
# target: distclean - Removes configure files.
distclean: clean
rm -f Makefile pinta config.status config.cache config.log configure.lineno config.status.lineno
# target: cleanall - Removes build files.
cleanall: distclean
rm -rf autom4te.cache
rm -f configure aclocal.m4 missing install-sh Makefile.in
# target: cleanbin - Removes built files.
cleanbin:
rm -rvf $(BINDIR)/*
# target: cleanobj - Removes temporary build files.
cleanobj:
find $(srcdir)/ -type d -name obj | xargs rm -rvf
# target: install - Installs Pinta.
install: pinta $(BINFILES)
cd $(srcdir) && $(XBUILD) /target:Install /property:InstallPrefix=$(DESTDIR)$(prefix) Pinta.Install.proj
$(INSTALL_SCRIPT) pinta $(DESTDIR)$(prefix)/bin/$(PACKAGE)
# target: uninstall - Uninstalls Pinta.
uninstall:
$(XBUILD) /target:Uninstall /property:InstallPrefix=$(DESTDIR)$(prefix) Pinta.Install.proj
# target: release - Default release type: releasetar
release: releasetar
# target: releasetar - Make a release tarball.
releasetar: $(BINFILES)
cd $(BINDIR) && tar -czf ../$(RELEASE_FILE).tgz --exclude=*mdb *
# target: releasezip - Make a release zip file.
releasezip: $(BINFILES)
cd $(BINDIR) && zip -r ../$(RELEASE_FILE).zip * -x "*.mdb"
EXTRA_DIST = Pinta Pinta.Core Pinta.Effects Pinta.Gui.Widgets Pinta.Resources Pinta.Tools po Tarball xdg \
license-mit.txt license-pdn.txt readme.txt todo.txt Pinta.sln Pinta.Install.proj
.PHONY: install uninstall cleanall cleanbin cleanobj release releasetar releasezip