File: Makefile.in

package info (click to toggle)
fdutils 5.3-3
  • links: PTS
  • area: main
  • in suites: potato
  • size: 1,004 kB
  • ctags: 621
  • sloc: ansic: 6,098; sh: 2,236; makefile: 279; sed: 4
file content (141 lines) | stat: -rw-r--r-- 4,220 bytes parent folder | download | duplicates (2)
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
# Define PIDFILE if you want to have the pid of the diskseekd stored
# somewhere on the filesystem. You'll get a (very) little shell
# script diskseek.sh that uses this to connect with the daemon
# when the disk should be cleaned by hand. In that case it's a replacement
# for diskseek. If you don't want to have this feature, don't define it.
#


top_srcdir=@top_srcdir@
srcdir=@srcdir@
VPATH=@srcdir@

prefix      = @prefix@
exec_prefix = @exec_prefix@
bindir      = @bindir@
infodir     = @infodir@
mandir      = @mandir@
infodir     = @infodir@
sysconfdir  = @sysconfdir@

CC       = @CC@
PID      = -DPIDFILE=\"@localstatedir@/run/diskseekd.pid\"
DEFINES  = $(DEFINES) $(PID) -DSYSCONFDIR=\"@sysconfdir@\"
DEFS     = @DEFS@ -DSYSCONFDIR=\"@sysconfdir@\"
CPPFLAGS = -I. -I@srcdir@ @CPPFLAGS@ $(DEFS)
CFLAGS   = -Wall @CFLAGS@

LDFLAGS     = @LDFLAGS@
LIBS        = -L. -lfdutils @LIBS@
SHLIB       = @SHLIB@
MACHDEPLIBS = @MACHDEPLIBS@	
LN_S        = @LN_S@

INSTALL         = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA    = @INSTALL_DATA@



OBJECTS=enh_options.o floppycontrol.o superformat.o
SOURCES=enh_options.c floppycontrol.o superformat.c
MANPAGES1=diskd.1 diskseekd.1 fdrawcmd.1 floppycontrol.1 getfdprm.1  \
makefloppies.1 superformat.1 xdfcopy.1 fdmount.1
MANPAGES4=fd.4
MANPAGES8=setfdprm.8



PERM=755
SPERM=4750
#we only people in group floppy to run priviledged programs
MANPERM = 644
UID	= root
GID	= floppy



all: floppycontrol getfdprm setfdprm fdrawcmd \
superformat xdfcopy fdmount diskseekd diskd floppymeter convertfdprm


LIBFILES=lex.mediaprm.o lex.driveprm.o mediaprm.o driveprm.o parse.o \
	oldfdprm.o enh_options.o measure.o printfdprm.o calc-format.o \
	misc.o skews.o

lex.%.c: %.lex
	lex -P$* $<

libfdutils.a: libfdutils.a($(LIBFILES))
	ranlib libfdutils.a

floppycontrol.o getfdprm setfdprm: /usr/include/linux/fd.h
diskseekd.o superformat.o fdrawcmd.o: /usr/include/linux/fd.h \
	/usr/include/linux/fdreg.h

convertfdprm: convert.o libfdutils.a
	${CC} $(LDFLAGS) -o $@ $< $(LIBS)

floppycontrol: floppycontrol.o libfdutils.a
	${CC} $(LDFLAGS) -o $@ $< $(LIBS)

diskd: diskd.o  libfdutils.a
	${CC} $(LDFLAGS) -o $@ $< $(LIBS)

diskseekd: diskseekd.o  libfdutils.a
	${CC} $(LDFLAGS) -o $@ $< $(LIBS)

diskseek: diskseekd
	ln -s diskseekd diskseek

superformat: superformat.o libfdutils.a
	${CC} $(LDFLAGS) -o $@ $< $(LIBS)

floppymeter: floppymeter.o libfdutils.a
	${CC} ${LDFLAFS} -o $@ $< $(LIBS)

fdrawcmd: fdrawcmd.o
	${CC} $(LDFLAGS) -o $@ $< $(LIBS)

getfdprm: getfdprm.o libfdutils.a
	${CC} $(LDFLAGS) -o $@ $< $(LIBS)

setfdprm: setfdprm.c libfdutils.a
	${CC} $(LDFLAGS) $(CFLAGS) -o $@ $< $(LIBS)

clean:
	-rm -f *~ *.orig *.o a.out *.a lex.*.c core 2>/dev/null

spotless:	clean
	-rm -f floppycontrol superformat getfdprm fdrawcmd diskseekd diskd \
	diskseek diskd_old setfdprm xdfcopy fdmount convertfdprm floppymeter 2>/dev/null

install: install-bin install-conf
	@grep -q '^floppy:' /etc/group \
	    || echo 'Add a group "floppy" to /etc/group.'


install-conf:
	if [ ! -f $(sysconfdir)/mediaprm ] ; then \
		cp $(srcdir)/mediaprm  $(sysconfdir) ; \
	fi

install-bin: all
	$(INSTALL) -c -m $(PERM) -o $(UID) -g $(GID) $(srcdir)/MAKEFLOPPIES $(bindir)
	$(INSTALL) -c -s -m $(PERM) -o $(UID) -g $(GID) diskd $(bindir)
	$(INSTALL) -c -s -m $(PERM) -o $(UID) -g $(GID) diskseekd $(bindir)
	$(INSTALL) -c -s -m $(PERM) -o $(UID) -g $(GID) floppycontrol $(bindir)
	$(INSTALL) -c -s -m $(PERM) -o $(UID) -g $(GID) floppymeter $(bindir)
	$(INSTALL) -c -s -m $(PERM) -o $(UID) -g $(GID) getfdprm $(bindir)
	$(INSTALL) -c -m $(PERM) -o $(UID) -g $(GID) MAKEFLOPPIES $(bindir)
	$(INSTALL) -c -s -m $(PERM) -o $(UID) -g $(GID) setfdprm $(bindir)
	$(INSTALL) -c -s -m $(PERM) -o $(UID) -g $(GID) fdrawcmd $(bindir)
	$(INSTALL) -c -s -m $(PERM) -o $(UID) -g $(GID) superformat $(bindir)
	$(INSTALL) -c -s -m $(PERM) -o $(UID) -g $(GID) xdfcopy $(bindir)
	$(INSTALL) -c -s -m $(SPERM) -o $(UID) -g $(GID) fdmount $(bindir)
	$(INSTALL) -c -s -m $(SPERM) -o $(UID) -g $(GID) fdmount $(bindir)/fdumount
	( cd $(bindir); \
	ln -sf xdfcopy $(bindir)/xdfformat; \
	ln -sf fdmount $(bindir)/fdumount; \
	ln -sf fdmount $(bindir)/fdlist; \
	ln -sf fdmount $(bindir)/fdmountd )