File: Makefile.in

package info (click to toggle)
xshisen 1:1.51-4.1+deb8u1
  • links: PTS
  • area: main
  • in suites: jessie
  • size: 1,156 kB
  • ctags: 553
  • sloc: cpp: 4,008; sh: 152; perl: 146; makefile: 114
file content (119 lines) | stat: -rw-r--r-- 3,243 bytes parent folder | download | duplicates (4)
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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
# Makefile for Autoconf.
# -*-Makefile-*-
# @configure_input@

# by Debian maintainer
DESTDIR =

srcdir      = @srcdir@
VPATH       = @srcdir@

prefix      = @prefix@
exec_prefix = @exec_prefix@
bindir      = @bindir@
datadir     = @datadir@
exec_name   = xshisen
class_name  = XShisen

XSHISENLIB = @datadir@/xshisen
XSHISENDAT = @sharedstatedir@
CXXFLAGS = @CXXFLAGS@ -DNO_GLOBAL_HIGHSCORE
CPPFLAGS = $(CPPOPTS) @CPPFLAGS@
CPPOPTS  =
LDFLAGS  = @LDFLAGS@
DEFS     = @DEFS@
CXX      = @CXX@
INSTALL  = @INSTALL@
INSTALLP = @INSTALL_PROGRAM@
INSTALLD = @INSTALL_DATA@
MKDIR    = @MKDIR@
XAD_DIR  = @XAD_DIR@
MANDIR   = @mandir@
LANGS    = @LANGS@

SRCS = main.C menubar.C body.C mahjong.C timer.C score.C \
       history.C image.C actions.C callbacks.C readxpm.C \
       common.C gamesize.C kconv.C nonstandard.C
OBJS = main.o menubar.o body.o mahjong.o timer.o score.o \
       history.o image.o actions.o callbacks.o readxpm.o \
       common.o gamesize.o kconv.o nonstandard.o
PROGS = $(exec_name)
AD    = work/XShisen.ad
SCF   = xshisen.scores

LIBS      = @LIBS@ 
CODECONV  = ./$(exec_name) -KCONV none

all: $(PROGS)

$(exec_name): $(OBJS)
	$(CXX) $(LDFLAGS) $(OBJS) $(LIBS) -o $(exec_name)

install: install-resource install-prog

install-prog: $(PROGS)
	@echo "XShisen executable directory is " $(bindir)
	@$(MKDIR) $(bindir)
	@chmod 755 $(bindir)
	$(INSTALLP) $(PROGS) $(bindir)/$(PROGS)
	@echo "XShisen data directory is " $(XSHISENLIB)
	@echo "XShisen higscore/shared data directory is " $(XSHISENDAT)
	#@$(MKDIR) $(XSHISENDAT)
	#@chmod 755 $(XSHISENDAT)
	@if [ -f $(XSHISENDAT)/$(SCF) ]; then \
	echo "Old high-score file exists."; \
	else \
	$(INSTALL) -m 0666 $(SCF) $(XSHISENDAT)/$(SCF); \
	fi
	## @$(MKDIR) $(XSHISENLIB)
	@set -x; \
	for dir in pixmaps/s?; do \
		dn=`basename $$dir`; \
		$(MKDIR) $(XSHISENLIB)/$$dn; \
		for file in $$dir/*.xpm; do \
			fn=$(XSHISENLIB)/$$dn/`basename $$file`; \
			$(INSTALLD) $$file $$fn; \
		done; \
	done

install-resource: $(AD)
	echo destdir $(DESTDIR)
	$(MKDIR) $(DESTDIR)$(XAD_DIR)/app-defaults
	$(INSTALLD) $(AD) $(DESTDIR)$(XAD_DIR)/app-defaults/$(class_name)
	-[ -n $(LANG) ] && $(MKDIR) $(DESTDIR)$(XAD_DIR)/$(LANG)/app-defaults
	-@set -x; \
	for lang in $(LANGS); do \
	[ -d $(DESTDIR)$(XAD_DIR)/$$lang/app-defaults ] || \
	$(MKDIR) $(DESTDIR)$(XAD_DIR)/$$lang/app-defaults; \
	$(INSTALLD) $(AD).$$lang $(DESTDIR)$(XAD_DIR)/$$lang/app-defaults/$(class_name); \
	done

install.man: man/$(exec_name).6
	-$(MKDIR) $(MANDIR)/man6
	$(INSTALLD) man/$(exec_name).6 $(MANDIR)/man6/$(exec_name).6
	-[ -n "$(LANG)" ] && $(MKDIR) $(MANDIR)/$(LANG)
	-@set -x; \
	for lang in $(LANGS); do \
	[ -d $(MANDIR)/$$lang/man6 ] || $(MKDIR) $(MANDIR)/$$lang/man6; \
	[ -f man/$(exec_name).6.$$lang ] && $(INSTALLD) man/$(exec_name).6.$$lang $(MANDIR)/$$lang/man6/$(exec_name).6; \
	done

clean:
	rm -rf work
	rm -f *.o $(PROGS)

distclean: clean
	rm -f config.log config.cache config.status config.h Makefile

$(AD): $(exec_name) lang/XShisen.ad
	-$(MKDIR) work
	cp lang/* work
	#$(CODECONV) < lang/XShisen.ad > $(AD)
	#-@set -x; \
	#for lang in $(LANGS); do \
	#$(CODECONV) < lang/XShisen.ad.$$lang > $(AD).$$lang; \
	#done

.SUFFIXES: .C
.C.o:
	$(CXX) -c $(CXXFLAGS) $(CPPFLAGS) $(DEFS) $< -o $@