forked from icann/lgr-django
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
71 lines (55 loc) · 2.58 KB
/
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
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
#MKMSG_OPTIONS=--no-wrap
MKMSG_OPTIONS=
MAKEMESSAGES=PYTHONPATH=../.. ../../manage.py makemessages
COMPILEMESSAGES=PYTHONPATH=../.. ../../manage.py compilemessages
LANGUAGES= \
-l ar \
-l en \
-l fr \
MO_FILES= \
src/lgr_web/locale/ar/LC_MESSAGES/django.mo \
src/lgr_web/locale/en/LC_MESSAGES/django.mo \
src/lgr_web/locale/fr/LC_MESSAGES/django.mo \
src/lgr_editor/locale/ar/LC_MESSAGES/django.mo \
src/lgr_editor/locale/en/LC_MESSAGES/django.mo \
src/lgr_editor/locale/fr/LC_MESSAGES/django.mo \
src/lgr_validator/locale/ar/LC_MESSAGES/django.mo \
src/lgr_validator/locale/en/LC_MESSAGES/django.mo \
src/lgr_validator/locale/fr/LC_MESSAGES/django.mo \
src/lgr_tools/locale/ar/LC_MESSAGES/django.mo \
src/lgr_tools/locale/en/LC_MESSAGES/django.mo \
src/lgr_tools/locale/fr/LC_MESSAGES/django.mo \
PO_FILES= \
src/lgr_web/locale/ar/LC_MESSAGES/django.po \
src/lgr_web/locale/en/LC_MESSAGES/django.po \
src/lgr_web/locale/fr/LC_MESSAGES/django.po \
src/lgr_editor/locale/ar/LC_MESSAGES/django.po \
src/lgr_editor/locale/en/LC_MESSAGES/django.po \
src/lgr_editor/locale/fr/LC_MESSAGES/django.po \
src/lgr_validator/locale/ar/LC_MESSAGES/django.po \
src/lgr_validator/locale/en/LC_MESSAGES/django.po \
src/lgr_validator/locale/fr/LC_MESSAGES/django.po \
src/lgr_tools/locale/ar/LC_MESSAGES/django.po \
src/lgr_tools/locale/en/LC_MESSAGES/django.po \
src/lgr_tools/locale/fr/LC_MESSAGES/django.po \
all: messages
messages: $(MO_FILES)
update: update-lgrweb update-lgreditor update-lgrvalidator update-lgrtools
update-lgrweb:
cd src/lgr_web && $(MAKEMESSAGES) $(LANGUAGES) $(MKMSG_OPTIONS)
update-lgreditor:
cd src/lgr_editor && $(MAKEMESSAGES) $(LANGUAGES) $(MKMSG_OPTIONS)
update-lgrvalidator:
cd src/lgr_validator && $(MAKEMESSAGES) $(LANGUAGES) $(MKMSG_OPTIONS)
update-lgrtools:
cd src/lgr_tools && $(MAKEMESSAGES) $(LANGUAGES) $(MKMSG_OPTIONS)
src/lgr_web/locale/%/LC_MESSAGES/django.po:
cd `echo "$@" | sed -e 's#\/locale/.*##'` && django-admin.py makemessages $(LANGUAGES) $(MKMSG_OPTIONS)
src/lgr_editor/locale/%/LC_MESSAGES/django.po:
cd `echo "$@" | sed -e 's#\/locale/.*##'` && django-admin.py makemessages $(LANGUAGES) $(MKMSG_OPTIONS)
src/lgr_validator/locale/%/LC_MESSAGES/django.po:
cd `echo "$@" | sed -e 's#\/locale/.*##'` && django-admin.py makemessages $(LANGUAGES) $(MKMSG_OPTIONS)
src/lgr_tools/locale/%/LC_MESSAGES/django.po:
cd `echo "$@" | sed -e 's#\/locale/.*##'` && django-admin.py makemessages $(LANGUAGES) $(MKMSG_OPTIONS)
$(MO_FILES): $(PO_FILES)
cd `echo "$@" | sed -e 's#\/locale/.*##'` && $(COMPILEMESSAGES)