3 # Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
5 # Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
8 #--------------------------------------------------------------
9 # You shouldn't need to mess with anything beyond this point...
10 #--------------------------------------------------------------
11 clean_targets := clean realclean distclean \
12 objclean-y headers_clean-y utils_clean
13 noconfig_targets := menuconfig config oldconfig silentoldconfig randconfig \
14 defconfig allyesconfig allnoconfig \
15 release dist tags help
17 include $(top_builddir)Rules.mak
18 sub_headers := headers
20 ifeq ($(HAVE_DOT_CONFIG),y)
25 # In this section, we need .config
28 else # ifeq ($(HAVE_DOT_CONFIG),y)
33 @echo "Need to make a config file first, run: make menuconfig"
36 endif # ifeq ($(HAVE_DOT_CONFIG),y)
38 include $(top_srcdir)ldso/Makefile.in
39 include $(top_srcdir)libcrypt/Makefile.in
40 include $(top_srcdir)libintl/Makefile.in
41 include $(top_srcdir)libm/Makefile.in
42 include $(top_srcdir)libnsl/Makefile.in
43 include $(top_srcdir)libresolv/Makefile.in
44 include $(top_srcdir)libutil/Makefile.in
45 include $(top_srcdir)libpthread/Makefile.in
46 include $(top_srcdir)librt/Makefile.in
47 include $(top_srcdir)extra/locale/Makefile.in
49 # last included to catch all the objects added by others (locales/threads)
50 include $(top_srcdir)libc/Makefile.in
52 ifeq ($(HAVE_DOT_CONFIG),y)
53 # If the .config changes then we have to make sure that our includes are
54 # updated properly. This would normally work by saying that the headers
55 # have uClibc_config.h as prerequisite but since we _symlink_ the headers
56 # and do not (?) want to rely on 'make -L' we better update them right here,
57 # on spot to save us from alot of hazzle.
58 include/bits/uClibc_config.h: extra/config/conf .config $(top_srcdir)extra/scripts/conf-header.sh | include/bits
60 $(Q)@$< -s $(top_srcdir)extra/Configs/Config.in
61 $(Q)$(top_srcdir)extra/scripts/conf-header.sh .config > $@
64 # For the moment, we have to keep re-running this target
65 # because the fix includes scripts rely on pre-processers
66 # in order to generate the headers correctly :(. That
67 # means we can't use the $(HOSTCC) in order to get the
69 ifeq ($(ARCH_USE_MMU),y)
70 export header_extra_args =
72 export header_extra_args = -n
74 HEADERS_BITS_COMMON := $(notdir $(wildcard $(top_srcdir)libc/sysdeps/linux/common/bits/*.h))
75 HEADERS_BITS_ARCH := $(notdir $(wildcard $(top_srcdir)libc/sysdeps/linux/$(TARGET_ARCH)/bits/*.h))
76 HEADERS_BITS_SUBARCH :=
77 ifneq ($(TARGET_SUBARCH),)
78 HEADERS_BITS_SUBARCH := $(notdir $(wildcard $(top_srcdir)libc/sysdeps/linux/$(TARGET_ARCH)/bits/$(TARGET_SUBARCH)/*.h))
80 HEADERS_BITS_COMMON := $(filter-out $(HEADERS_BITS_ARCH) $(HEADERS_BITS_SUBARCH) $(HEADERS_BITS_PTHREAD),$(HEADERS_BITS_COMMON))
82 HEADERS_SYS_COMMON := $(notdir $(wildcard $(top_srcdir)libc/sysdeps/linux/common/sys/*.h))
83 HEADERS_SYS_ARCH := $(notdir $(wildcard $(top_srcdir)libc/sysdeps/linux/$(TARGET_ARCH)/sys/*.h))
84 HEADERS_SYS_COMMON := $(filter-out $(HEADERS_SYS_ARCH),$(HEADERS_SYS_COMMON))
86 ALL_HEADERS_COMMON := include/fpu_control.h include/dl-osinfo.h \
88 ALL_HEADERS_BITS_COMMON := $(addprefix include/bits/,$(HEADERS_BITS_COMMON))
89 ALL_HEADERS_BITS_ARCH := $(addprefix include/bits/,$(HEADERS_BITS_ARCH))
90 ifneq ($(TARGET_SUBARCH),)
91 ALL_HEADERS_BITS_SUBARCH := $(addprefix include/bits/,$(HEADERS_BITS_SUBARCH))
93 ALL_HEADERS_BITS_SUBARCH :=
95 ALL_HEADERS_SYS_COMMON := $(addprefix include/sys/,$(HEADERS_SYS_COMMON))
96 ALL_HEADERS_SYS_ARCH := $(addprefix include/sys/,$(HEADERS_SYS_ARCH))
98 target-headers-sysdep := \
99 $(ALL_HEADERS_COMMON) \
100 $(ALL_HEADERS_BITS_COMMON) \
101 $(ALL_HEADERS_BITS_ARCH) \
102 $(ALL_HEADERS_BITS_SUBARCH) \
103 $(ALL_HEADERS_SYS_COMMON) \
104 $(ALL_HEADERS_SYS_ARCH)
106 include/fpu_control.h:
108 $(Q)[ -r libc/sysdeps/linux/$(TARGET_ARCH)/$(@F) ] && \
109 $(LN) -fs ../libc/sysdeps/linux/$(TARGET_ARCH)/$(@F) $@ || \
110 $(LN) -fs ../libc/sysdeps/linux/common/$(@F) $@
112 include/dl-osinfo.h include/hp-timing.h:
113 $(do_ln) ../libc/sysdeps/linux/common/$(@F) $@
115 $(ALL_HEADERS_BITS_COMMON):
116 $(do_ln) ../../libc/sysdeps/linux/common/bits/$(@F) $@
118 $(ALL_HEADERS_BITS_ARCH):
119 $(do_ln) ../../libc/sysdeps/linux/$(TARGET_ARCH)/bits/$(@F) $@
121 ifneq ($(TARGET_SUBARCH),)
122 $(ALL_HEADERS_BITS_SUBARCH):
123 $(do_ln) ../../../libc/sysdeps/linux/$(TARGET_ARCH)/bits/$(TARGET_SUBARCH)/$(@F) $@
126 ifneq ($(strip $(ALL_HEADERS_SYS_COMMON)),)
127 $(ALL_HEADERS_SYS_COMMON):
128 $(do_ln) ../../libc/sysdeps/linux/common/sys/$(@F) $@
131 ifneq ($(strip $(ALL_HEADERS_SYS_ARCH)),)
132 $(ALL_HEADERS_SYS_ARCH):
133 $(do_ln) ../../libc/sysdeps/linux/$(TARGET_ARCH)/sys/$(@F) $@
136 $(target-headers-sysdep): | include/bits
138 sysdep_common_headers-clean:
139 $(RM) $(ALL_HEADERS_COMMON)
140 headers_clean-y += sysdep_common_headers-clean
142 # The headers. Arch specific headers are specified via ARCH_HEADERS in
143 # libc/sysdeps/linux/$(TARGET_ARCH)/Makefile.arch which appends those via
144 # libc/sysdeps/linux/Makefile.commonarch to headers-y
145 headers-y += $(target-headers-sysdep)
147 headers: include/bits/uClibc_config.h
149 pregen: include/bits/sysnum.h headers
151 include/bits/sysnum.h: $(top_srcdir)extra/scripts/gen_bits_syscall_h.sh
152 $(Q)$(INSTALL) -d $(@D)
155 cd $(top_builddir); \
156 tmp=`mktemp include/bits/sysnum.h.XXXXXX 2>/dev/null`; \
157 [ -z "$$tmp" ] && tmp='include/bits/sysnum.h.new'; \
158 KERNEL_HEADERS="${KERNEL_HEADERS}" top_builddir=. CC="$(CC) $(CPU_CFLAGS)" $(SHELL) extra/scripts/gen_bits_syscall_h.sh > $$tmp; \
159 if cmp include/bits/sysnum.h $$tmp >/dev/null 2>&1; then \
162 mv -f $$tmp include/bits/sysnum.h; \
165 $(LOCAL_INSTALL_PATH):
166 $(Q)$(MAKE) PREFIX=$(shell pwd)/ RUNTIME_PREFIX=./ \
167 DEVEL_PREFIX=$(LOCAL_INSTALL_PATH)/usr/ \
169 install_kernel_headers
170 $(Q)$(MAKE) PREFIX=$(shell pwd)/ RUNTIME_PREFIX=./ \
171 DEVEL_PREFIX=$(LOCAL_INSTALL_PATH)/usr/ \
175 install: install_runtime install_dev
178 RUNTIME_PREFIX_LIB_FROM_DEVEL_PREFIX_LIB=$(shell $(top_srcdir)extra/scripts/relative_path.sh $(DEVEL_PREFIX)lib $(RUNTIME_PREFIX)lib)
180 $(top_builddir)extra/scripts/unifdef: $(top_srcdir)extra/scripts/unifdef.c
183 # Installs kernel header files (linux/*, asm/*, asm-generic/*).
184 install_kernel_headers: headers
185 top_builddir=$(top_builddir) \
186 $(top_srcdir)extra/scripts/install_kernel_headers.sh include $(PREFIX)$(DEVEL_PREFIX)include
188 # Installs header files.
189 install_headers: headers $(top_builddir)extra/scripts/unifdef
190 $(INSTALL) -d $(PREFIX)$(DEVEL_PREFIX)include
191 top_builddir=$(top_builddir) \
192 $(top_srcdir)extra/scripts/install_headers.sh include $(PREFIX)$(DEVEL_PREFIX)include
193 printf '#ifndef _LIBC_INTERNAL_H\n#define _LIBC_INTERNAL_H 1\n#endif\n' > \
194 $(PREFIX)$(DEVEL_PREFIX)include/libc-internal.h
195 echo '/* Dont use _syscall#() macros; use the syscall() function */' > \
196 $(PREFIX)$(DEVEL_PREFIX)include/bits/syscalls.h
197 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/dl-osinfo.h
198 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/_lfs_64.h
199 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/uClibc_uintmaxtostr.h
200 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/kernel_sigaction.h
201 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/kernel_stat.h
202 ifneq ($(UCLIBC_HAS_FLOATS),y)
203 # Remove floating point related headers since float support is disabled.
204 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/complex.h
205 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/fpu_control.h
206 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/ieee754.h
207 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/math.h
208 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/tgmath.h
209 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/uClibc_fpmax.h
211 ifneq ($(UCLIBC_HAS_FENV),y)
212 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/fenv.h \
213 $(PREFIX)$(DEVEL_PREFIX)include/bits/fenv.h \
214 $(PREFIX)$(DEVEL_PREFIX)include/bits/fenvinline.h
216 ifneq ($(UCLIBC_HAS_WCHAR),y)
217 # Remove wide char headers since wide char support is disabled.
218 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/wctype.h
219 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/wchar.h
221 ifneq ($(UCLIBC_HAS_LOCALE),y)
222 # Remove iconv header since locale support is disabled.
223 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/iconv.h
225 ifneq ($(UCLIBC_HAS_GLIBC_CUSTOM_PRINTF),y)
226 # Remove printf header since custom print specifier support is disabled.
227 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/printf.h
229 ifneq ($(UCLIBC_HAS_XLOCALE),y)
230 # Remove xlocale header since extended locale support is disabled.
231 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/xlocale.h
233 ifneq ($(UCLIBC_HAS_GETTEXT_AWARENESS),y)
234 # Remove libintl header since gettext support is disabled.
235 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/libintl.h
237 ifneq ($(UCLIBC_HAS_REGEX),y)
238 # Remove regex headers since regex support is disabled.
239 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/regex.h
240 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/regexp.h
242 ifneq ($(UCLIBC_HAS_WORDEXP),y)
243 # Remove wordexp header since wordexp support is disabled.
244 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/wordexp.h
246 ifneq ($(UCLIBC_HAS_FTW),y)
247 # Remove ftw header since ftw support is disabled.
248 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/ftw.h
250 ifneq ($(UCLIBC_HAS_GLOB),y)
251 # Remove glob header since glob support is disabled.
252 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/glob.h
254 ifneq ($(UCLIBC_HAS_GNU_GETOPT),y)
255 ifneq ($(UCLIBC_HAS_GETOPT_LONG),y)
256 # Remove getopt header since gnu getopt support is disabled.
257 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/getopt.h
260 ifneq ($(UCLIBC_HAS_SHADOW),y)
261 # Remove shadow header since shadow password support is disabled.
262 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/shadow.h
264 ifneq ($(PTHREADS_DEBUG_SUPPORT),y)
265 # Remove thread_db header since thread debug support is disabled.
266 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/thread_db.h
268 ifneq ($(UCLIBC_HAS_THREADS),y)
269 # Remove pthread headers since thread support is disabled.
270 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/*thread*.h
271 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/semaphore.h
272 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/*thread*.h
274 ifneq ($(HAVE_SHARED),y)
275 # Remove dlfcn header if we don't have shared libraries.
276 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/dlfcn.h
277 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/dlfcn.h
279 ifeq ($(UCLIBC_HAS_THREADS_NATIVE),y)
280 # Remove this as it is only used internally.
281 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/tls.h
283 ifneq ($(UCLIBC_HAS_GNU_ERROR),y)
284 # Remove error.h upon request
285 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/error.h
287 ifneq ($(UCLIBC_HAS_BSD_ERR),y)
288 # Remove err.h upon request
289 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/err.h
291 ifneq ($(UCLIBC_SUSV3_LEGACY),y)
292 # Remove timeb.h since the LEGACY ftime() was disabled upon request
293 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/timeb.h
295 ifneq ($(UCLIBC_HAS_EPOLL),y)
296 # Remove epoll.h since epoll_*() were disabled upon request
297 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/epoll.h
299 ifneq ($(UCLIBC_HAS_XATTR),y)
300 # Remove xattr.h since extended attributes were disabled upon request
301 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/xattr.h
303 ifneq ($(UCLIBC_HAS_PTY),y)
304 # Remove pty.h since PTY support was disabled upon request
305 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/pty.h
307 ifneq ($(UCLIBC_LINUX_SPECIFIC),y)
308 # Remove linux-specific headers as requested
309 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/inotify.h
310 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/perm.h
311 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/personality.h
312 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/signalfd.h
314 ifneq ($(UCLIBC_SV4_DEPRECATED),y)
315 # Remove ustat.h since deprecated SV4 support was disabled upon request
316 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/ustat.h
317 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/ustat.h
318 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/ustat.h
320 ifeq ($(UCLIBC_HAS_REALTIME)$(UCLIBC_HAS_ADVANCED_REALTIME),)
321 # Remove SUSv-realtime related message-queue headers upon request
322 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/mqueue.h
323 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/mqueue.h
324 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/mqueue.h
326 ifneq ($(UCLIBC_HAS_REALTIME),y)
327 # Remove SUSv-realtime related headers upon request
328 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sched.h
329 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/sched.h
330 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/sched.h
331 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/semaphore.h
332 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/semaphore.h
333 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/semaphore.h
335 ifneq ($(UCLIBC_HAS_SOCKET),y)
336 # Remove socket related headers upon request
337 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/socket.h
338 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/socket.h
339 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/sys/socketvar.h
341 ifneq ($(UCLIBC_HAS_CRYPT),y)
342 # Remove crypt.h since libcrypt was disabled upon request
343 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/crypt.h
345 ifneq ($(UCLIBC_SUPPORT_AI_ADDRCONFIG),y)
346 # Remove ifaddrs.h since the corresponding functionality is disabled
347 $(RM) $(PREFIX)$(DEVEL_PREFIX)include/ifaddrs.h
350 # Installs development library links.
351 install_dev: install_headers all
352 $(INSTALL) -d $(PREFIX)$(DEVEL_PREFIX)lib
353 -$(INSTALL) -m 644 lib/*.[ao] $(PREFIX)$(DEVEL_PREFIX)lib/
354 ifeq ($(HAVE_SHARED),y)
355 for i in `find lib/ -type l -name 'lib[a-zA-Z]*.so' | \
356 $(SED) -e 's/lib\///'` ; do \
357 $(LN) -sf $(RUNTIME_PREFIX_LIB_FROM_DEVEL_PREFIX_LIB)$$i.$(MAJOR_VERSION) \
358 $(PREFIX)$(DEVEL_PREFIX)lib/$$i; \
360 if [ -f $(top_builddir)lib/libc.so -a -f $(PREFIX)$(RUNTIME_PREFIX)lib/$(SHARED_MAJORNAME) ] ; then \
361 $(RM) $(PREFIX)$(DEVEL_PREFIX)lib/libc.so; \
362 $(SED) -e 's:$(NONSHARED_LIBNAME):$(DEVEL_PREFIX)lib/$(NONSHARED_LIBNAME):' \
363 -e 's:$(SHARED_MAJORNAME):$(RUNTIME_PREFIX)lib/$(SHARED_MAJORNAME):' \
364 -e 's:$(UCLIBC_LDSO):$(RUNTIME_PREFIX)lib/$(UCLIBC_LDSO):' \
365 $(top_builddir)lib/libc.so > $(PREFIX)$(DEVEL_PREFIX)lib/libc.so; \
367 ifeq ($(UCLIBC_HAS_THREADS),y)
368 ifneq ($(LINUXTHREADS_OLD),y)
369 if [ -f $(top_builddir)lib/libpthread.so -a -f $(PREFIX)$(RUNTIME_PREFIX)lib/libpthread.so.$(MAJOR_VERSION) ] ; then \
370 $(RM) $(PREFIX)$(DEVEL_PREFIX)lib/libpthread.so; \
371 cp $(top_srcdir)extra/scripts/format.lds $(PREFIX)$(DEVEL_PREFIX)lib/libpthread.so; \
372 echo "GROUP ( $(RUNTIME_PREFIX)lib/libpthread.so.$(MAJOR_VERSION) $(DEVEL_PREFIX)lib/libpthread_nonshared.a )" \
373 >> $(PREFIX)$(DEVEL_PREFIX)lib/libpthread.so; \
377 ifeq ($(PTHREADS_DEBUG_SUPPORT),y)
378 $(LN) -sf $(RUNTIME_PREFIX_LIB_FROM_DEVEL_PREFIX_LIB)libthread_db.so.1 \
379 $(PREFIX)$(DEVEL_PREFIX)lib/libthread_db.so
382 # # If we build shared libraries then the static libs are PIC...
383 # # Make _pic.a symlinks to make mklibs.py and similar tools happy.
384 if [ -d lib ] ; then \
385 for i in `find lib/ -type f -name 'lib*.a' | $(SED) -e 's/lib\///'` ; do \
386 $(LN) -sf $$i $(PREFIX)$(DEVEL_PREFIX)lib/`echo $$i \
387 | $(SED) -e 's/\.a$$/_pic.a/'`; \
392 ifeq ($(UCLIBC_FORMAT_SHARED_FLAT),y)
393 for file in lib/lib*.gdb; do \
394 if test -f $$file; then \
395 $(INSTALL) -m 755 $$file $(PREFIX)$(DEVEL_PREFIX)lib; \
396 $(INSTALL) -m 755 `echo $$file | $(SED) 's/\.gdb$$//'` \
397 $(PREFIX)$(DEVEL_PREFIX)lib; \
402 # Installs run-time libraries
404 ifeq ($(HAVE_SHARED),y)
405 $(INSTALL) -d $(PREFIX)$(RUNTIME_PREFIX)lib
406 $(INSTALL) -m 644 lib/lib*-$(VERSION).so \
407 $(PREFIX)$(RUNTIME_PREFIX)lib
408 cd lib && $(TAR) -cf - *.so.* | $(TAR) -xf - -C $(PREFIX)$(RUNTIME_PREFIX)lib
409 @if [ -x lib/$(UCLIBC_LDSO_NAME)-$(VERSION).so ] ; then \
412 $(INSTALL) -m 755 lib/$(UCLIBC_LDSO_NAME)-$(VERSION).so \
413 $(PREFIX)$(RUNTIME_PREFIX)lib; \
418 $(Q)$(MAKE) CROSS="$(CROSS)" CC="$(CC)" HOSTCC="$(HOSTCC)" -C utils hostutils
420 $(Q)$(MAKE) CROSS="$(CROSS)" CC="$(CC)" -C utils
422 # Installs helper applications, such as 'ldd' and 'ldconfig'
424 $(MAKE) CROSS="$(CROSS)" CC="$(CC)" -C utils utils_install
426 endif # ifeq ($(HAVE_DOT_CONFIG),y)
428 include/bits include/config:
433 # ---------------------------------------------------------------------------
434 extra/config/conf extra/config/mconf: | include/config
435 $(Q)$(MAKE) -C extra/config $(notdir $@)
437 menuconfig: extra/config/mconf
438 $(Q)./extra/config/mconf extra/Configs/Config.in
440 config: extra/config/conf
441 $(Q)./extra/config/conf extra/Configs/Config.in
443 oldconfig: extra/config/conf
444 $(Q)./extra/config/conf -o extra/Configs/Config.in
446 silentoldconfig: extra/config/conf
447 $(Q)./extra/config/conf -s extra/Configs/Config.in
449 randconfig: extra/config/conf
450 $(Q)./extra/config/conf -r extra/Configs/Config.in
452 allyesconfig: extra/config/conf
453 $(Q)./extra/config/conf -y extra/Configs/Config.in
454 $(SED) -i -e "s/^DODEBUG=.*/# DODEBUG is not set/" .config
455 $(SED) -i -e "s/^DOASSERTS=.*/# DOASSERTS is not set/" .config
456 $(SED) -i -e "s/^SUPPORT_LD_DEBUG_EARLY=.*/# SUPPORT_LD_DEBUG_EARLY is not set/" .config
457 $(SED) -i -e "s/^SUPPORT_LD_DEBUG=.*/# SUPPORT_LD_DEBUG is not set/" .config
458 $(SED) -i -e "s/^UCLIBC_MJN3_ONLY=.*/# UCLIBC_MJN3_ONLY is not set/" .config
459 $(Q)./extra/config/conf -o extra/Configs/Config.in
461 allnoconfig: extra/config/conf
462 $(Q)./extra/config/conf -n extra/Configs/Config.in
464 defconfig: extra/config/conf
465 $(Q)./extra/config/conf -d extra/Configs/Config.in \
466 -D extra/Configs/defconfigs/$(ARCH)
469 $(Q)$(RM) -r lib include/bits
470 $(RM) ldso/*/*.a libpthread/*/*.a libc/*.a libcrypt/*.a libintl/*.a \
471 libm/*.a libnsl/*.a libpthread/*.a libresolv/*.a librt/*.a \
472 libutil/*.a lib/*.a \
473 include/fpu_control.h include/dl-osinfo.h include/hp-timing.h
474 +$(MAKE) -s -C test clean
475 +$(MAKE) -C utils utils_clean
477 for i in `(cd libc/sysdeps/linux/common/sys; ls *.h)` ; do \
478 $(RM) include/sys/$$i; \
480 if [ -d libc/sysdeps/linux/$(TARGET_ARCH)/sys ] ; then \
481 for i in `(cd libc/sysdeps/linux/$(TARGET_ARCH)/sys; ls *.h)` ; do \
482 $(RM) include/sys/$$i; \
485 @$(RM) include/linux include/asm*
486 $(RM) $(top_builddir)extra/scripts/unifdef
487 $(RM) -r $(LOCAL_INSTALL_PATH)
490 -find . \( -name core -o -name \*.orig -o -name \*~ -o -name .\*.dep \) -exec $(RM) {} \;
491 $(RM) .config .config.old .config.cmd
492 $(RM) extra/locale/*.tgz
493 $(MAKE) -C extra/config distclean
496 $(RM) -r ../uClibc-$(VERSION) ../uClibc-$(VERSION).tar.bz2
497 svn -q export . ../uClibc-$(VERSION)
498 $(TAR) cjf ../uClibc-$(VERSION).tar.bz2 -C .. uClibc-$(VERSION)
499 du -b ../uClibc-$(VERSION).tar.bz2
501 test check: test_compile
504 test_compile: $(LOCAL_INSTALL_PATH)
505 $(Q)$(MAKE) -C test compile