File: Makefile

package info (click to toggle)
xvt 2.1-8
  • links: PTS
  • area: main
  • in suites: slink
  • size: 268 kB
  • ctags: 429
  • sloc: ansic: 5,116; makefile: 119; sh: 43
file content (142 lines) | stat: -rw-r--r-- 3,593 bytes parent folder | download | duplicates (5)
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
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
# @(#)Makefile	1.8 9/12/93 (UKC)
#
#  To build xvt for one of the supported architectures:
#
#  1.  Uncomment the appropriate ARCH= line below
#
#  2.  Comment out the SITE=UKC line unless this is UKC
#
#  3.  write out the edited Makefile and type 'make config'
#
#  4.  look at the Makefile and check that the uncommented options
#      seem sensible.  If you want to use a different C compiler
#      or different libraries or include files then edit the Makefile
#      by hand.
#
#  5.  Type make depend (if your system has makedepend(1) installed).
#
#  6.  Type make
#
######################################################################
#
# Supported architectures.  Only one of these lines should be uncommented.
#
#ARCH=SUNOS4
#ARCH=SUNOS5
#ARCH=OSF1
#ARCH=AIX3
#ARCH=ULTRIX
#ARCH=HPUX
ARCH=LINUX
#
#
# If this line is uncommented then `Make config' will unclude several options
# that are probably only wanted at UKC.
#
#SITE=UKC
#
#
# Directories to install the binary and the manual page
#
BIN=/usr/local/X11
MANDIR=/usr/local/man/man1
#
######################################################################
#
# Lines in this section are automatically commented or uncommented
# by running `make config'.  Edit them by hand if the configured
# options are not appropriate.
#
#
# Enable the code that allows xvt to provide a Hex encoded Magic Cookie
# for inclusion in a .Xauthority file.  
#
#MAGIC_COOKIE=-DMAGIC_COOKIE				#SITE UKC
#
#
# Needed for the Magic Cookie code but not otherwise.
#
#AUTHLIB=-lXau						#SITE UKC
#
#
# Enable code that can make use of the UKC locations database.  This
# is almost obsolete, even at UKC, and totally useless anywhere else.
#
#UKC_LOCATIONS=-DUKC_LOCATIONS				#SITE UKC
#
#
# Enable some extra debugging code
#
#DEBUG=-DDEBUG						#SITE UKC
#
OPTIONS=$(MAGIC_COOKIE) $(DEBUG)			#ARCH SUNOS5 OSF1 AIX3 ULTRIX LINUX
#OPTIONS=$(MAGIC_COOKIE) $(UKC_LOCATIONS) $(DEBUG)	#ARCH SUNOS4
#
# Additional architecture dependent defines
#
# add lines and columns to environment - delays startup
#
#DEFS=-DLC_ENV						#ARCH HPUX
#
# Additional directories to search for include files.  These may need
# modifying if you have local include directories.
#
#ANSI_INCLUDE=-I/usr/local/lib/ansi-include		#SITE UKC
#INCLUDE=$(ANSI_INCLUDE)					#ARCH SUNOS4
#INCLUDE=-I/usr/openwin/include				#ARCH SUNOS5
#INCLUDE=-I/usr/include/X11R5				#ARCH HPUX
#
#
# Any architecture dependent libraries or library search paths.
#
#LIB=-lnsl $(AUTHLIB)					#ARCH SUNOS5
LIB=$(AUTHLIB)						#ARCH SUNOS4 OSF1 AIX3 ULTRIX LINUX
#LDFLAGS=-i -R /usr/openwin/lib -L /usr/openwin/lib	#ARCH SUNOS5
#LDFLAGS=-L/usr/lib/X11R5				#ARCH HPUX
#
#
# The C compiler 
#
#CC=gcc -g -ansi -Wall -Wmissing-prototypes		#SITE UKC
#CC=cc							#ARCH OSF1 AIX3 HPUX ULTRIX
#
# End of automatically configured options.
#
######################################################################
#
OBJ=xvt.o xsetup.o command.o screen.o sbar.o ttyinit.o
SRC=xvt.c xsetup.c command.c screen.c sbar.c ttyinit.c
#
CFLAGS=-O $(INCLUDE) $(OPTIONS) $(DEFS) -D$(ARCH)
#
xvt: $(OBJ)
	$(CC) $(LDFLAGS) -o xvt $(OBJ) $(LIB) -lX11

install: $(BIN)/xvt $(MANDIR)/xvt.1

$(MANDIR)/xvt.1: xvt.1
	cp xvt.1 $@
	chmod 0644 $@

$(BIN)/xvt: xvt
	cp xvt $@.new
	strip $@.new
	chown root $@.new
	chmod 04755 $@.new
	mv $@.new $@

clean:
	rm -f $(OBJ) xvt

tags:	$(SRC)
	ctags $(SRC)

config:
	./cmake ARCH $(ARCH) < Makefile | ./cmake SITE $(SITE) >Makefile.new
	mv Makefile Makefile.old
	mv Makefile.new Makefile

depend:
	makedepend -- $(CFLAGS) -- $(SRC)

# DO NOT DELETE THIS LINE -- make depend depends on it.