Print this page
10051 cw(1) shouldn't have to translate -g
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/cmd/backup/dump/Makefile
+++ new/usr/src/cmd/backup/dump/Makefile
1 1 #
2 2 # Copyright 2009 Sun Microsystems, Inc. All rights reserved.
3 3 # Use is subject to license terms.
4 4 #
5 5 # cmd/backup/dump/Makefile
6 6 #
7 7 # Copyright (c) 1980 Regents of the University of California.
8 8 # All rights reserved. The Berkeley software License Agreement
9 9 # specifies the terms and conditions for redistribution.
10 10 #
11 11 # dump.h header file
12 12 # dumpfstab.c reads fstab/vfstab, mtab/mnttab
13 13 # dumpitime.c reads /etc/dumpdates
14 14 # dumpmain.c driver
15 15 # dumponline.c online dump support
16 16 # dumpoptr.c operator interface
17 17 # dumptape.c handles the mag tape and opening/closing
18 18 # dumptraverse.c traverses the file system
19 19 # lftw.c fixed version of ftw(3)
20 20 # partial.c partial filesystem dump support
21 21 # unctime.c undo ctime
22 22 #
23 23 # CPPFLAGS:
24 24 # DEBUG use local directory to find ddate and dumpdates
25 25 # PARTIAL enable partial filesystem dump support
26 26 # TDEBUG trace out the process forking
27 27 #
28 28 # CAUTION: FSTYPE must be defined before including ../Makefile.backup,
29 29 # otherwise UFSROOTPKGUSRLIBFSTYPE doesn't get expanded
30 30 # properly and the magic doesn't happen.
31 31
32 32 FSTYPE= ufs
33 33
34 34 include ../Makefile.backup
35 35
36 36 #CFLAGS += -DTDEBUG
37 37 UFSDUMP= ufsdump
38 38
39 39 PROG= $(UFSDUMP)
40 40 PRODUCT= $(PROG)
41 41 ROLLDIR= ../../fs.d/ufs/roll_log
42 42 ROLLOBJS= $(ROLLDIR)/$(MACH)/roll_log.o
43 43 ROLLSRCS= $(ROLLDIR)/roll_log.c
44 44
45 45 LOBJECTS= dumponline.o dumpfstab.o dumpitime.o dumpmain.o \
46 46 dumpoptr.o dumptape.o dumptraverse.o unctime.o \
47 47 partial.o lftw.o
48 48 OBJECTS= $(LOBJECTS) roll_log.o
49 49 SRCS= $(LOBJECTS:.o=.c)
50 50
51 51 POFILES= $(OBJECTS:.o=.po) ../lib/libdump.po
52 52 POFILE= ufsdump.po
53 53 ROLLPOFILES= roll_log.po
54 54
55 55 # XXX This is only needed for the check: target. It would be nice to
56 56 # XXX automatically generate the list when needed.
57 57 HEADERS= ../../../head/protocols/dumprestore.h \
58 58 ../../fs.d/ufs/roll_log/roll_log.h ../include/byteorder.h \
59 59 ../include/memutils.h \
60 60 ../include/rmt.h dump.h dumpusg.h
61 61
62 62 CLOBBERFILES += $(PRODUCT) $(DEBUGPRODUCTS) dumpdates
63 63
64 64 LOCAL= .
65 65 GENERAL= ../include
66 66 GLOBAL= ../../../head
67 67 CPPFLAGS= -I$(LOCAL) -I$(GENERAL) -I$(GLOBAL) -DPARTIAL \
68 68 -I$(ROLLDIR) $(CPPFLAGS.master) \
69 69 -D_LARGEFILE64_SOURCE=1
70 70 CERRWARN += -_gcc=-Wno-implicit-function-declaration
71 71 CERRWARN += -_gcc=-Wno-parentheses
72 72 CERRWARN += -_gcc=-Wno-uninitialized
73 73 CERRWARN += -_gcc=-Wno-clobbered
74 74 CERRWARN += -_gcc=-Wno-extra
75 75 LIBDUMP= ../lib/libdump.a
76 76 LINTLIBDUMP= ../lib/llib-ldump.ln -lkstat
77 77 LDLIBS += $(BSTATIC) -L../lib -ldump $(BDYNAMIC) \
78 78 -lsocket -lnsl -ladm -lm -lkstat
79 79
80 80 UFSROOTDUMPDATES= $(UFSROOTETC)/dumpdates
↓ open down ↓ |
80 lines elided |
↑ open up ↑ |
81 81 UFSROOTLINK= $(UFSROOTUSRSBIN)/$(PROG)
82 82 LINKVALUE= ../lib/fs/$(FSTYPE)/$(PROG)
83 83 LIBDIR= $(UFSROOTUSRLIBFS)/$(FSTYPE)
84 84 $(UFSROOTDUMPDATES):= FILEMODE= 0664
85 85 $(LIBDIR):= DIRMODE= 0755
86 86
87 87 FILEMODE= 04555
88 88
89 89 .KEEP_STATE:
90 90
91 -all: $(PRODUCT)
91 +all: $(PRODUCT)
92 92
93 93 $(PROG): $(OBJECTS) $$(LIBDUMP)
94 94 $(LINK.c) -o $@ $(OBJECTS) $(LDLIBS)
95 95 $(POST_PROCESS)
96 96
97 97 $(LIBDUMP): FRC
98 98 $(DO_LIBDIR)
99 99
100 100 $(POFILE): $(POFILES)
101 101 $(RM) $@; cat $(POFILES) > $@
102 102
103 103 FRC:
104 104
105 105 install: all $(LIBDIR) $(UFSROOTPKGUSRLIBFSTYPE) dumpdates \
106 106 $(UFSROOTDUMPDATES) $(UFSROOTLINK)
107 107
108 108 dumpdates:
109 109 cp /dev/null dumpdates
110 110
111 111 #XXX Should actually note return value from close(2), particularly regarding
112 112 #XXX tape descriptors. Some drives don't actually force anything to media
113 113 #XXX except when they are writing a file mark....
114 114
115 115 # grep is looking for non-space/tab
116 116 lint: $(SRCS) $(ROLLSRCS) $$(LINTLIBDUMP)
117 117 $(LINT.c) $(SRCS) $(ROLLSRCS) $(LINTLIBDUMP) 2>&1 \
118 118 | sed -f lint.sed | grep '^[^ ]'
119 119
120 120 $(LINTLIBDUMP): FRC
121 121 cd ../lib; pwd; $(MAKE) lint
122 122 pwd
123 123
124 124 check: FRC
125 125 $(CSTYLE) $(CSTYLEFLAGS) $(SRCS) $(ROLLSRCS) $(HEADERS)
126 126 $(HDRCHK) $(HDRCHKFLAGS) $(HEADERS)
127 127
128 128 clean:
129 129 $(RM) $(OBJECTS) $(ROLLOBJS) $(DEBUGOBJS) *.ln
↓ open down ↓ |
28 lines elided |
↑ open up ↑ |
130 130
131 131 $(LIBDIR):
132 132 $(INS.dir)
133 133
134 134 $(UFSROOTLINK):
135 135 -$(RM) $@; $(SYMLINK) $(LINKVALUE) $(UFSROOTLINK)
136 136
137 137 roll_log.o:
138 138 cd $(ROLLDIR) ; pwd ; $(MAKE)
139 139 cp $(ROLLOBJS) .
140 - pwd
141 -
142 -.debug/roll_log.o:
143 - cd $(ROLLDIR) ; pwd ; $(MAKE) CFLAGS=-g
144 - cp $(ROLLOBJS) .debug
145 140 pwd
146 141
147 142 $(ROLLPOFILES): $(ROLLSRCS)
148 143 cd $(ROLLDIR) ; pwd ; $(MAKE) `echo $(ROLLPOFILES) | sed -e 's@$(ROLLDIR)/@@g'`
149 144 cp $(ROLLDIR)/*.po .
150 145 pwd
151 146
152 147 ../lib/libdump.po:
153 148 cd ../lib ; pwd ; $(MAKE) libdump.po
154 149
155 150 include ../Makefile.targ
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX