source: mainline/uspace/Makefile@ af2d3e3

lfn serial ticket/834-toolchain-update topic/msim-upgrade topic/simplify-dev-export
Last change on this file since af2d3e3 was af2d3e3, checked in by Jiri Svoboda <jiri@…>, 7 years ago

Fix makefile.

  • Property mode set to 100644
File size: 5.9 KB
Line 
1#
2# Copyright (c) 2005 Martin Decky
3# All rights reserved.
4#
5# Redistribution and use in source and binary forms, with or without
6# modification, are permitted provided that the following conditions
7# are met:
8#
9# - Redistributions of source code must retain the above copyright
10# notice, this list of conditions and the following disclaimer.
11# - Redistributions in binary form must reproduce the above copyright
12# notice, this list of conditions and the following disclaimer in the
13# documentation and/or other materials provided with the distribution.
14# - The name of the author may not be used to endorse or promote products
15# derived from this software without specific prior written permission.
16#
17# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
18# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
19# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
20# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
21# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
22# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27#
28
29-include ../Makefile.common
30-include ../Makefile.config
31
32## Common binaries
33#
34
35DIRS = \
36 app/barber \
37 app/bdsh \
38 app/bithenge \
39 app/blkdump \
40 app/bnchmark \
41 app/contacts \
42 app/corecfg \
43 app/cpptest \
44 app/devctl \
45 app/dnscfg \
46 app/dnsres \
47 app/download \
48 app/edit \
49 app/fdisk \
50 app/fontviewer \
51 app/getterm \
52 app/gunzip \
53 app/init \
54 app/inet \
55 app/kill \
56 app/killall \
57 app/kio \
58 app/loc \
59 app/logset \
60 app/mixerctl \
61 app/mkfat \
62 app/mkexfat \
63 app/mkext4 \
64 app/mkmfs \
65 app/modplay \
66 app/netecho \
67 app/nterm \
68 app/perf \
69 app/redir \
70 app/sbi \
71 app/sportdmp \
72 app/stats \
73 app/taskdump \
74 app/tester \
75 app/testread \
76 app/testrunner \
77 app/testwrit \
78 app/tetris \
79 app/tmon \
80 app/trace \
81 app/top \
82 app/untar \
83 app/usbinfo \
84 app/vol \
85 app/vuhid \
86 app/nic \
87 app/ping \
88 app/pkg \
89 app/sysinfo \
90 app/sysinst \
91 app/mkbd \
92 app/date \
93 app/vcalc \
94 app/vdemo \
95 app/viewer \
96 app/vlaunch \
97 app/vterm \
98 app/df \
99 app/wavplay \
100 app/websrv \
101 app/wifi_supplicant \
102 srv/audio/hound \
103 srv/clipboard \
104 srv/locsrv \
105 srv/logger \
106 srv/klog \
107 srv/devman \
108 srv/loader \
109 srv/net/dhcp \
110 srv/net/dnsrsrv \
111 srv/net/ethip \
112 srv/net/inetsrv \
113 srv/net/loopip \
114 srv/net/nconfsrv \
115 srv/net/slip \
116 srv/net/tcp \
117 srv/net/udp \
118 srv/ns \
119 srv/taskmon \
120 srv/vfs \
121 srv/bd/sata_bd \
122 srv/bd/file_bd \
123 srv/bd/rd \
124 srv/bd/vbd \
125 srv/fs/exfat \
126 srv/fs/udf \
127 srv/fs/fat \
128 srv/fs/cdfs \
129 srv/fs/tmpfs \
130 srv/fs/mfs \
131 srv/fs/locfs \
132 srv/fs/ext4fs \
133 srv/volsrv \
134 srv/hid/compositor \
135 srv/hid/console \
136 srv/hid/s3c24xx_ts \
137 srv/hid/isdv4_tablet \
138 srv/hid/input \
139 srv/hid/output \
140 srv/hid/remcons \
141 srv/hw/char/s3c24xx_uart \
142 srv/hid/rfb \
143 srv/test/chardev-test \
144 drv/audio/hdaudio \
145 drv/audio/sb16 \
146 drv/root/root \
147 drv/root/virt \
148 drv/block/ahci \
149 drv/block/ata_bd \
150 drv/block/ddisk \
151 drv/block/usbmast \
152 drv/bus/adb/cuda_adb \
153 drv/bus/isa \
154 drv/bus/pci/pciintel \
155 drv/bus/usb/ehci \
156 drv/bus/usb/ohci \
157 drv/bus/usb/uhci \
158 drv/bus/usb/usbdiag \
159 drv/bus/usb/usbflbk \
160 drv/bus/usb/usbhub \
161 drv/bus/usb/usbmid \
162 drv/bus/usb/vhc \
163 drv/bus/usb/xhci \
164 drv/char/i8042 \
165 drv/char/msim-con \
166 drv/char/ns8250 \
167 drv/char/pl050 \
168 drv/char/ski-con \
169 drv/char/sun4v-con \
170 drv/fb/amdm37x_dispc \
171 drv/fb/kfb \
172 drv/hid/adb-kbd \
173 drv/hid/adb-mouse \
174 drv/hid/atkbd \
175 drv/hid/ps2mouse \
176 drv/hid/usbhid \
177 drv/hid/xtkbd \
178 drv/intctl/apic \
179 drv/intctl/i8259 \
180 drv/intctl/icp-ic \
181 drv/intctl/obio \
182 drv/nic/ne2k \
183 drv/nic/e1k \
184 drv/nic/rtl8139 \
185 drv/nic/rtl8169 \
186 drv/nic/ar9271 \
187 drv/nic/virtio-net \
188 drv/platform/amdm37x \
189 drv/platform/icp \
190 drv/platform/mac \
191 drv/platform/malta \
192 drv/platform/msim \
193 drv/platform/pc \
194 drv/platform/ski \
195 drv/platform/sun4v \
196 drv/test/test1 \
197 drv/test/test2 \
198 drv/test/test3 \
199 drv/time/cmos-rtc
200
201## sun4u driver won't compile on 32-bit targets
202ifeq ($(UARCH),sparc64)
203 DIRS += \
204 drv/platform/sun4u
205endif
206
207## Dynamic linking tests
208#
209ifeq ($(CONFIG_BUILD_SHARED_LIBS),y)
210 DIRS += \
211 app/dltest \
212 app/dltests
213endif
214
215## System libraries
216#
217
218BASE_LIBS = \
219 lib/c \
220 lib/cpp \
221 lib/untar
222
223LIBS = \
224 lib/fs \
225 lib/block \
226 lib/crypto \
227 lib/clui \
228 lib/dltest \
229 lib/fdisk \
230 lib/fmtutil \
231 lib/scsi \
232 lib/sif \
233 lib/compress \
234 lib/drv \
235 lib/graph \
236 lib/gui \
237 lib/hound \
238 lib/http \
239 lib/softrend \
240 lib/draw \
241 lib/label \
242 lib/math \
243 lib/minix \
244 lib/nettl \
245 lib/nic \
246 lib/ext4 \
247 lib/trackmod \
248 lib/uri \
249 lib/usb \
250 lib/usbhost \
251 lib/usbdev \
252 lib/usbhid \
253 lib/usbvirt \
254 lib/pcm \
255 lib/pcut \
256 lib/bithenge \
257 lib/posix \
258 lib/ieee80211 \
259 lib/virtio
260
261BASE_BUILDS := $(addsuffix .build,$(BASE_LIBS))
262BUILDS := $(addsuffix .build,$(DIRS) $(LIBS))
263BUILDS_TESTS := $(addsuffix .build-test,$(DIRS) $(LIBS) $(BASE_LIBS))
264DEPS = $(addsuffix /deps.mk,$(DIRS) $(LIBS))
265CLEANS := $(addsuffix .clean,$(DIRS) $(LIBS) $(BASE_LIBS))
266
267.PHONY: all $(BASE_BUILDS) $(BUILDS) $(BUILDS_TESTS) $(CLEANS) clean export
268
269all: $(BUILDS) $(BUILDS_TESTS)
270
271$(BUILDS_TESTS): $(BASE_BUILDS) $(BUILDS)
272 $(MAKE) -r -C $(basename $@) all-test PRECHECK=$(PRECHECK)
273
274export: lib/posix.build lib/math.build lib/clui.build
275 $(MAKE) -r -C lib/posix export EXPORT_DIR=$(EXPORT_DIR)
276
277clean: $(CLEANS)
278 find lib app drv srv -name '*.o' -follow -exec rm \{\} \;
279 find lib app drv srv -name '*.lo' -follow -exec rm \{\} \;
280 find lib app drv srv -name '*.d' -follow -exec rm \{\} \;
281 rm -fr export
282
283$(CLEANS):
284 -$(MAKE) -r -C $(basename $@) fasterclean
285
286$(BASE_BUILDS) $(BUILDS):
287 $(MAKE) -r -C $(basename $@) all PRECHECK=$(PRECHECK)
288
289$(DEPS): %/deps.mk: %/Makefile
290 $(MAKE) -r -C $(@D) deps.mk SELF_TARGET="$(@D).build"
291
292$(BUILDS): $(BASE_BUILDS)
293
294-include $(DEPS)
Note: See TracBrowser for help on using the repository browser.