Debian Codegraph @

utils/Makefile

raw ◀ ▶
1 Debian patch touch this file
1 # Copyright (C) 1994,95,96,97,98,99,2000,01,02,12,14 Free Software Foundation,
2 # Inc.
3 #
4 # This program is free software; you can redistribute it and/or
5 # modify it under the terms of the GNU General Public License as
6 # published by the Free Software Foundation; either version 2, or (at
7 # your option) any later version.
8 #
9 # This program is distributed in the hope that it will be useful, but
10 # WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 # General Public License for more details.
13 #
14 # You should have received a copy of the GNU General Public License
15 # along with this program; if not, write to the Free Software
16 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17
18 dir := utils
19 makemode := utilities
20
21 targets = shd ps settrans showtrans syncfs fsysopts \
22 storeinfo login w uptime ids loginpr sush vmstat portinfo \
23 devprobe vminfo addauth rmauth unsu setauth ftpcp ftpdir storecat \
24 storeread msgport rpctrace mount gcore fakeauth fakeroot remap \
25 umount nullauth rpcscan vmallocate exists
26
27 special-targets = loginpr sush uptime fakeroot remap
28 SRCS = shd.c ps.c settrans.c syncfs.c showtrans.c addauth.c rmauth.c \
29 fsysopts.c storeinfo.c login.c loginpr.sh sush.sh w.c \
30 uptime.sh psout.c ids.c vmstat.c portinfo.c devprobe.c vminfo.c \
31 parse.c frobauth.c frobauth-mod.c setauth.c pids.c nonsugid.c \
32 unsu.c ftpcp.c ftpdir.c storeread.c storecat.c msgport.c \
33 rpctrace.c mount.c gcore.c fakeauth.c fakeroot.sh remap.sh \
34 nullauth.c match-options.c msgids.c rpcscan.c exists.c
35
36 OBJS = $(filter-out %.sh,$(SRCS:.c=.o))
37 HURDLIBS = ps ihash store fshelp ports ftpconn shouldbeinlibc
38 LDLIBS += -lpthread
39 login-LDLIBS = -lutil $(and $(HAVE_LIBCRYPT),-lcrypt)
40 addauth-LDLIBS = $(and $(HAVE_LIBCRYPT),-lcrypt)
41 setauth-LDLIBS = $(and $(HAVE_LIBCRYPT),-lcrypt)
42 mount-LDLIBS = $(libblkid_LIBS)
43 mount-CPPFLAGS = $(libblkid_CFLAGS)
44
45 include ../Makeconf
46
47 ps addauth rmauth setauth unsu msgport: parse.o pids.o
48 login addauth setauth: nonsugid.o
49 addauth rmauth setauth unsu: frobauth.o
50 rmauth setauth unsu: frobauth-mod.o
51 ps w: psout.o ../libps/libps.a ../libihash/libihash.a
52 portinfo: ../libihash/libihash.a ../libps/libps.a
53
54 storeinfo storecat storeread: ../libstore/libstore.a
55 ftpcp ftpdir: ../libftpconn/libftpconn.a
56 mount umount: ../libihash/libihash.a
57 settrans: ../libfshelp/libfshelp.a ../libihash/libihash.a \
58 ../libports/libports.a
59 ps w ids settrans syncfs showtrans fsysopts storeinfo login vmstat portinfo \
60 devprobe vminfo addauth rmauth setauth unsu ftpcp ftpdir storeread \
61 storecat msgport mount umount nullauth rpctrace: \
62 ../libshouldbeinlibc/libshouldbeinlibc.a
63
64 $(filter-out $(special-targets), $(targets)): %: %.o
65
66 rpctrace: ../libports/libports.a
67 rpctrace rpcscan msgport: msgids.o \
68 ../libihash/libihash.a \
69 ../libshouldbeinlibc/libshouldbeinlibc.a
70 msgids-CPPFLAGS = -DDATADIR=\"${datadir}\"
71
72 fakeauth: authServer.o auth_requestUser.o interruptServer.o \
73 ../libports/libports.a ../libihash/libihash.a \
74 ../libshouldbeinlibc/libshouldbeinlibc.a
75 auth-MIGSFLAGS = -imacros $(srcdir)/../auth/mig-mutate.h
76 fakeauth-CPPFLAGS = -I$(srcdir)/../auth
77 authServer-CPPFLAGS = -I$(srcdir)/../auth
78 auth_requestUser-CPPFLAGS = -I$(srcdir)/../auth
79
80 mount umount: ../sutils/fstab.o ../sutils/clookup.o match-options.o \
81 $(foreach L,fshelp ports,../lib$L/lib$L.a)
82 ../sutils/fstab.o ../sutils/clookup.o: FORCE
83 $(MAKE) -C $(@D) $(@F)
84 FORCE:
85
86 shd vmallocate: ../libshouldbeinlibc/libshouldbeinlibc.a