config.h, socket.c: move NI_MAXHOST to socket.c
[s-mailx.git] / makefile
blob1532fb11b70d4db37d21cea30374bd1fa2ccbf79
1 #@ Makefile for S-nail.
2 #@ Adjustments have to be made in make.rc -- or on the command line.
3 #@ See the file INSTALL if you need help.
5 .PHONY: ohno tangerine citron \
6 all config build install uninstall clean distclean test \
7 devel odevel
9 CWDDIR=./
10 SRCDIR=./
12 ohno: build
13 tangerine: config build test install
14 citron: config build install
15 all: config build
17 config:
18 @$(_prego)
19 build:
20 @$(_prestop); LC_ALL=C $${MAKE} -f mk-config.mk $(MAKEJOBS) all
21 install packager-install: build
22 @$(_prestop);\
23 LC_ALL=C $${MAKE} -f mk-config.mk DESTDIR="$(DESTDIR)" install
24 uninstall:
25 @$(_prestop); LC_ALL=C $${MAKE} -f mk-config.mk uninstall
27 clean:
28 @$(_prestop); LC_ALL=C $${MAKE} -f mk-config.mk clean
29 distclean:
30 @$(_prestop); LC_ALL=C $${MAKE} -f mk-config.mk distclean
32 test:
33 @$(_prestop); LC_ALL=C $${MAKE} -f mk-config.mk $(MAKEJOBS) test
35 devel:
36 @CONFIG=DEVEL; export CONFIG; $(_prego); $(_prestop);\
37 LC_ALL=C $${MAKE} -f mk-config.mk _update-version &&\
38 LC_ALL=C $${MAKE} -f mk-config.mk $(MAKEJOBS) all
39 odevel:
40 @CONFIG=ODEVEL; export CONFIG; $(_prego); $(_prestop);\
41 LC_ALL=C $${MAKE} -f mk-config.mk _update-version &&\
42 LC_ALL=C $${MAKE} -f mk-config.mk $(MAKEJOBS) all
43 d-b:
44 @$(_prestop);\
45 LC_ALL=C $${MAKE} -f mk-config.mk _update-version &&\
46 LC_ALL=C $${MAKE} -f mk-config.mk $(MAKEJOBS) all
48 d-gettext:
49 cd "$(SRCDIR)" &&\
50 LC_ALL=C xgettext --sort-by-file --strict --add-location \
51 --from-code=UTF-8 --keyword --keyword=_ --keyword=N_ \
52 --add-comments=I18N --foreign-user \
53 -o messages.pot *.c *.h
55 _prego = if CWDDIR="$(CWDDIR)" SRCDIR="$(SRCDIR)" \
56 SHELL="$(SHELL)" MAKE="$(MAKE)" CC="$(CC)" \
57 CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" \
58 $(SHELL) "$(SRCDIR)"make-config.sh; then :; else exit 1; fi
59 _prestop = if [ -f ./mk-config.mk ]; then :; else \
60 echo 'Program not configured, nothing to do';\
61 echo 'Use one of the targets: config, all, tangerine';\
62 exit 1;\
63 fi;\
64 < ./mk-config.ev read __ev__; eval $${__ev__}; unset __ev__
66 # s-mk-mode