diff options
author | Peter S. Mazinger <ps.m@gmx.net> | 2005-10-25 22:17:39 +0000 |
---|---|---|
committer | Peter S. Mazinger <ps.m@gmx.net> | 2005-10-25 22:17:39 +0000 |
commit | a80fc77b658a7883df95ac41ad83ac9ff7c8ff07 (patch) | |
tree | 3edbcb812b876e0ba1424b229d50e9c04a2b0d4a | |
parent | 7ce8f67d27885ea6b1cba2c43e5edc9f1dc17f0f (diff) | |
download | uClibc-alpine-a80fc77b658a7883df95ac41ad83ac9ff7c8ff07.tar.bz2 uClibc-alpine-a80fc77b658a7883df95ac41ad83ac9ff7c8ff07.tar.xz |
All Makefile.in's. Only arm/i386/mips/powerpc/x86_64 are done, the other archs lack proper crt1. The Makefiles in extra/scripts are intended to be linked into each dir, where it is necessary to build locally.
80 files changed, 3476 insertions, 292 deletions
diff --git a/Makefile.in b/Makefile.in new file mode 100644 index 000000000..95479231d --- /dev/null +++ b/Makefile.in @@ -0,0 +1,392 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +#-------------------------------------------------------------- +# You shouldn't need to mess with anything beyond this point... +#-------------------------------------------------------------- +noconfig_targets := menuconfig config oldconfig randconfig \ + defconfig allyesconfig allnoconfig clean distclean \ + release tags + +TOPDIR=./ + +top_srcdir=$(TOPDIR) +top_builddir=./ +include $(top_builddir)Rules.mak + +# need to have libc.so built, before we can build the others +ifeq ($(HAVE_SHARED),y) +PRE_DIRS = ldso libc +DIRS = ldso libcrypt libresolv libnsl libutil librt +else +PRE_DIRS = libc +DIRS = libcrypt libresolv libnsl libutil librt +endif +ifeq ($(UCLIBC_HAS_FLOATS),y) + DIRS += libm +endif +ifeq ($(UCLIBC_HAS_THREADS),y) + DIRS += libpthread +endif +ifeq ($(UCLIBC_HAS_GETTEXT_AWARENESS),y) + DIRS += libintl +endif + +ifeq ($(HAVE_DOT_CONFIG),y) + +all: finished + +# In this section, we need .config +-include .config.cmd + +finished: subdirs + $(SECHO) + $(SECHO) Finally finished compiling ... + $(SECHO) + +include/bits/uClibc_config.h: .config + @if [ ! -x $(top_builddir)extra/config/conf ] ; then \ + $(MAKE) -C $(top_builddir)extra/config conf; \ + fi + $(RM) -r $(top_builddir)include/bits + $(INSTALL) -d $(top_builddir)include/bits + @$(top_builddir)extra/config/conf -o $(top_srcdir)extra/Configs/Config.in + +# For the moment, we have to keep re-running this target +# because the fix includes scripts rely on pre-processers +# in order to generate the headers correctly :(. That +# means we can't use the $(HOSTCC) in order to get the +# correct output. +ifeq ($(ARCH_HAS_MMU),y) +export header_extra_args = +else +export header_extra_args = -n +endif +headers: $(top_srcdir)include/bits/uClibc_config.h + @$(SHELL_SET_X); \ + $(top_srcdir)extra/scripts/fix_includes.sh \ + -k $(KERNEL_SOURCE) -t $(TARGET_ARCH) \ + $(header_extra_args) + @cd $(top_builddir)include/bits; \ + set -e; \ + for i in `ls ../../libc/sysdeps/linux/common/bits/*.h` ; do \ + $(LN) -fs $$i .; \ + done; \ + if [ -d ../../libc/sysdeps/linux/$(TARGET_ARCH)/bits ] ; then \ + for i in `ls ../../libc/sysdeps/linux/$(TARGET_ARCH)/bits/*.h` ; do \ + $(LN) -fs $$i .; \ + done; \ + fi + @cd $(top_builddir)include/sys; \ + set -e; \ + for i in `ls ../../libc/sysdeps/linux/common/sys/*.h` ; do \ + $(LN) -fs $$i .; \ + done; \ + if [ -d ../../libc/sysdeps/linux/$(TARGET_ARCH)/sys ] ; then \ + for i in `ls ../../libc/sysdeps/linux/$(TARGET_ARCH)/sys/*.h` ; do \ + $(LN) -fs $$i .; \ + done; \ + fi + @cd $(top_builddir); \ + set -e; \ + $(SHELL_SET_X); \ + TOPDIR=. CC="$(CC)" /bin/sh extra/scripts/gen_bits_syscall_h.sh > include/bits/sysnum.h.new; \ + if cmp include/bits/sysnum.h include/bits/sysnum.h.new >/dev/null 2>&1; then \ + $(RM) include/bits/sysnum.h.new; \ + else \ + $(RM) include/bits/sysnum.h; \ + mv -f include/bits/sysnum.h.new include/bits/sysnum.h; \ + fi +ifeq ($(UCLIBC_HAS_THREADS),y) + $(MAKE) -C libpthread threads_headers +endif + $(MAKE) -C libc/sysdeps/linux/common common_headers + $(MAKE) -C libc/sysdeps/linux/$(TARGET_ARCH) arch_headers + +# Command used to download source code +WGET:=wget --passive-ftp + +LOCALE_DATA_FILENAME:=uClibc-locale-030818.tgz + +pregen: headers +ifeq ($(UCLIBC_DOWNLOAD_PREGENERATED_LOCALE_DATA),y) + (cd $(top_builddir)extra/locale; \ + if [ ! -f $(LOCALE_DATA_FILENAME) ] ; then \ + $(WGET) http://www.uclibc.org/downloads/$(LOCALE_DATA_FILENAME) ; \ + fi ) +endif +ifeq ($(UCLIBC_PREGENERATED_LOCALE_DATA),y) + (cd $(top_builddir)extra/locale; zcat $(LOCALE_DATA_FILENAME) | tar -xvf -) + $(MAKE) -C $(top_srcdir)extra/locale pregen +endif + +pre_subdirs: $(patsubst %, _pre_dir_%, $(PRE_DIRS)) +$(patsubst %, _pre_dir_%, $(PRE_DIRS)): pregen + $(MAKE) -C $(patsubst _pre_dir_%, %, $@) + +subdirs: $(patsubst %, _dir_%, $(DIRS)) +$(patsubst %, _dir_%, $(DIRS)): pre_subdirs + $(MAKE) -C $(patsubst _dir_%, %, $@) + +install: install_runtime install_dev finished2 + + +RUNTIME_PREFIX_LIB_FROM_DEVEL_PREFIX_LIB=$(shell $(top_srcdir)extra/scripts/relative_path.sh $(DEVEL_PREFIX)lib $(RUNTIME_PREFIX)lib) + +# Installs header files. +install_headers: + $(INSTALL) -d $(PREFIX)$(DEVEL_PREFIX)include + if [ "$(KERNEL_SOURCE)" == "$(DEVEL_PREFIX)" ] ; then \ + extra_exclude="--exclude include/linux --exclude include/asm'*'" ; \ + else \ + extra_exclude="" ; \ + fi ; \ + tar -chf - include --exclude .svn --exclude CVS $$extra_exclude \ + | tar -xf - -C $(PREFIX)$(DEVEL_PREFIX) + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/ssp-internal.h +ifneq ($(UCLIBC_HAS_FLOATS),y) + # Remove floating point related headers since float support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/complex.h + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/fpu_control.h + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/ieee754.h + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/math.h + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/tgmath.h + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/uClibc_fpmax.h +endif +ifneq ($(UCLIBC_HAS_WCHAR),y) + # Remove wide char headers since wide char support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/wctype.h + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/wchar.h +endif +ifneq ($(UCLIBC_HAS_LOCALE),y) + # Remove iconv header since locale support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/iconv.h +endif +ifneq ($(UCLIBC_HAS_GLIBC_CUSTOM_PRINTF),y) + # Remove printf header since custom print specifier support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/printf.h +endif +ifneq ($(UCLIBC_HAS_XLOCALE),y) + # Remove xlocale header since extended locale support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/xlocale.h +endif +ifneq ($(UCLIBC_HAS_GETTEXT_AWARENESS),y) + # Remove libintl header since gettext support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/libintl.h +endif +ifneq ($(UCLIBC_HAS_REGEX),y) + # Remove regex headers since regex support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/regex.h + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/regexp.h +endif +ifneq ($(UCLIBC_HAS_WORDEXP),y) + # Remove wordexp header since wordexp support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/wordexp.h +endif +ifneq ($(UCLIBC_HAS_FTW),y) + # Remove ftw header since ftw support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/ftw.h +endif +ifneq ($(UCLIBC_HAS_GLOB),y) + # Remove glob header since glob support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/glob.h +endif +ifneq ($(UCLIBC_HAS_GNU_GETOPT),y) + # Remove getopt header since gnu getopt support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/getopt.h +endif +ifneq ($(HAS_SHADOW),y) + # Remove shadow header since shadow password support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/shadow.h +endif +ifneq ($(PTHREADS_DEBUG_SUPPORT),y) + # Remove thread_db header since thread debug support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/thread_db.h +endif +ifneq ($(UCLIBC_HAS_THREADS),y) + # Remove pthread headers since thread support is disabled. + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/*thread*.h + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/semaphore.h + $(RM) $(PREFIX)$(DEVEL_PREFIX)include/bits/*thread*.h +endif + -@for i in `find $(PREFIX)$(DEVEL_PREFIX) -type d` ; do \ + chmod 755 $$i; chmod 644 $$i/*.h > /dev/null 2>&1; \ + done + -find $(PREFIX)$(DEVEL_PREFIX) -name .svn | xargs $(RM) -r + -chown -R `id | sed 's/^uid=\([0-9]*\).*gid=\([0-9]*\).*$$/\1:\2/'` $(PREFIX)$(DEVEL_PREFIX) + +# Installs development library links. +install_dev: install_headers + $(INSTALL) -d $(PREFIX)$(DEVEL_PREFIX)lib + -$(INSTALL) -m 644 lib/*.[ao] $(PREFIX)$(DEVEL_PREFIX)lib/ +ifeq ($(HAVE_SHARED),y) + for i in `find lib/ -type l -name 'lib[a-zA-Z]*.so' | \ + sed -e 's/lib\///'` ; do \ + $(LN) -sf $(RUNTIME_PREFIX_LIB_FROM_DEVEL_PREFIX_LIB)$$i.$(MAJOR_VERSION) \ + $(PREFIX)$(DEVEL_PREFIX)lib/$$i; \ + done + if [ -f $(top_builddir)lib/libc.so -a -f $(PREFIX)$(RUNTIME_PREFIX)lib/$(SHARED_MAJORNAME) ] ; then \ + $(RM) $(PREFIX)$(DEVEL_PREFIX)lib/libc.so; \ + sed -e '/^GROUP/d' $(top_builddir)lib/libc.so > $(PREFIX)$(DEVEL_PREFIX)lib/libc.so; \ + fi +ifeq ($(COMPAT_ATEXIT),y) + if [ -f $(top_builddir)lib/libc.so -a -f $(PREFIX)$(RUNTIME_PREFIX)lib/$(SHARED_MAJORNAME) ] ; then \ + echo "GROUP ( $(DEVEL_PREFIX)lib/$(NONSHARED_LIBNAME) $(RUNTIME_PREFIX)lib/$(SHARED_MAJORNAME) )" \ + >> $(PREFIX)$(DEVEL_PREFIX)lib/libc.so; \ + fi +else + if [ -f $(top_builddir)lib/libc.so -a -f $(PREFIX)$(RUNTIME_PREFIX)lib/$(SHARED_MAJORNAME) ] ; then \ + echo "GROUP ( $(RUNTIME_PREFIX)lib/$(SHARED_MAJORNAME) $(DEVEL_PREFIX)lib/$(NONSHARED_LIBNAME) )" \ + >> $(PREFIX)$(DEVEL_PREFIX)lib/libc.so; \ + fi +endif +ifeq ($(PTHREADS_DEBUG_SUPPORT),y) + $(LN) -sf $(RUNTIME_PREFIX_LIB_FROM_DEVEL_PREFIX_LIB)libthread_db.so.1 \ + $(PREFIX)$(DEVEL_PREFIX)lib/libthread_db.so +endif +# # If we build shared libraries then the static libs are PIC... +# # Make _pic.a symlinks to make mklibs.py and similar tools happy. + if [ -d lib ] ; then \ + for i in `find lib/ -type f -name 'lib*.a' | sed -e 's/lib\///'` ; do \ + $(LN) -sf $$i $(PREFIX)$(DEVEL_PREFIX)lib/`echo $$i \ + | sed -e 's/\.a$$/_pic.a/'`; \ + done ; \ + fi +endif + +# Installs run-time libraries +install_runtime: +ifeq ($(HAVE_SHARED),y) + $(INSTALL) -d $(PREFIX)$(RUNTIME_PREFIX)lib + $(INSTALL) -m 644 lib/lib*-$(MAJOR_VERSION).$(MINOR_VERSION).$(SUBLEVEL).so \ + $(PREFIX)$(RUNTIME_PREFIX)lib + cp -dRf lib/*.so.* $(PREFIX)$(RUNTIME_PREFIX)lib + @if [ -x lib/ld-uClibc-$(MAJOR_VERSION).$(MINOR_VERSION).$(SUBLEVEL).so ] ; then \ + set -e; \ + $(SHELL_SET_X); \ + $(INSTALL) -m 755 lib/ld-uClibc-$(MAJOR_VERSION).$(MINOR_VERSION).$(SUBLEVEL).so \ + $(PREFIX)$(RUNTIME_PREFIX)lib; \ + fi +endif + +utils: + $(MAKE) CROSS="$(CROSS)" CC="$(CC)" -C utils + +# Installs helper applications, such as 'ldd' and 'ldconfig' +install_utils: utils + $(MAKE) CROSS="$(CROSS)" CC="$(CC)" -C utils install + +finished2: + $(SECHO) + $(SECHO) Finished installing ... + $(SECHO) + +else # ifeq ($(HAVE_DOT_CONFIG),y) + +all: menuconfig + +# configuration +# --------------------------------------------------------------------------- +extra/config/conf: + $(MAKE) -C extra/config conf + +extra/config/mconf: + $(MAKE) -C extra/config ncurses mconf + +menuconfig: extra/config/mconf + $(RM) -r include/bits + $(INSTALL) -d include/bits + @./extra/config/mconf extra/Configs/Config.in + $(MAKE) headers + +config: extra/config/conf + $(RM) -r include/bits + $(INSTALL) -d include/bits + @./extra/config/conf extra/Configs/Config.in + +oldconfig: extra/config/conf + $(RM) -r include/bits + $(INSTALL) -d include/bits + @./extra/config/conf -o extra/Configs/Config.in + +randconfig: extra/config/conf + $(RM) -r include/bits + $(INSTALL) -d include/bits + @./extra/config/conf -r extra/Configs/Config.in + +allyesconfig: extra/config/conf + $(RM) -r include/bits + $(INSTALL) -d include/bits + @./extra/config/conf -y extra/Configs/Config.in + sed -i -e "s/^DODEBUG=.*/# DODEBUG is not set/" .config + sed -i -e "s/^DOASSERTS=.*/# DOASSERTS is not set/" .config + sed -i -e "s/^SUPPORT_LD_DEBUG_EARLY=.*/# SUPPORT_LD_DEBUG_EARLY is not set/" .config + sed -i -e "s/^SUPPORT_LD_DEBUG=.*/# SUPPORT_LD_DEBUG is not set/" .config + sed -i -e "s/^UCLIBC_MJN3_ONLY=.*/# UCLIBC_MJN3_ONLY is not set/" .config + @./extra/config/conf -o extra/Configs/Config.in + +allnoconfig: extra/config/conf + $(RM) -r include/bits + $(INSTALL) -d include/bits + @./extra/config/conf -n extra/Configs/Config.in + +defconfig: extra/config/conf + $(RM) -r include/bits + $(INSTALL) -d include/bits + @./extra/config/conf -d extra/Configs/Config.in + +clean: + @$(RM) -r lib include/bits + $(RM) lib*/*.a ldso/*/*.a + $(RM) libc/misc/locale/locale_data.c + $(RM) libc/misc/internals/interp.c + $(RM) include/fpu_control.h + $(MAKE) -C extra/locale clean + $(MAKE) -C ldso ldso_headers_clean + $(MAKE) -C libpthread threads_headers_clean + $(MAKE) -C test clean + $(MAKE) -C utils clean + @set -e; \ + for i in `(cd $(top_builddir)libc/sysdeps/linux/common/sys; ls *.h)` ; do \ + $(RM) include/sys/$$i; \ + done; \ + if [ -d libc/sysdeps/linux/$(TARGET_ARCH)/sys ] ; then \ + for i in `(cd libc/sysdeps/linux/$(TARGET_ARCH)/sys; ls *.h)` ; do \ + $(RM) include/sys/$$i; \ + done; \ + fi + @$(RM) include/linux include/asm* + @if [ -d libc/sysdeps/linux/$(TARGET_ARCH) ]; then \ + $(MAKE) -C libc/sysdeps/linux/$(TARGET_ARCH) clean; \ + fi + -find . \( -name \*.o -o -name \*.os -o -name \*.oS \) -exec $(RM) {} \; + +distclean: clean + -find . \( -name core -o -name \*.orig -o -name \*~ -o -name .\#\* \) -exec $(RM) {} \; + $(RM) .config .config.old .config.cmd + $(RM) extra/locale/*.txt + $(MAKE) -C extra clean + +release: distclean + cd ..; \ + $(RM) -r uClibc-$(VERSION); \ + cp -dRf uClibc uClibc-$(VERSION); \ + find uClibc-$(VERSION)/ -type f \ + -name .\#* -exec $(RM) -r {} \; ; \ + find uClibc-$(VERSION)/ -type d \ + -name .svn -exec $(RM) -r {} \; ; \ + \ + tar -cvzf uClibc-$(VERSION).tar.gz uClibc-$(VERSION)/ + +endif # ifeq ($(HAVE_DOT_CONFIG),y) + +include $(top_srcdir)Makerules + +check: + $(MAKE) -C test + +.PHONY: dummy subdirs release distclean clean config oldconfig menuconfig utils diff --git a/Makefile.libs b/Makefile.libs deleted file mode 100644 index 970127076..000000000 --- a/Makefile.libs +++ /dev/null @@ -1,109 +0,0 @@ -# Makefile for uClibc -# -# Copyright (C) 2002-2003 Erik Andersen <andersen@uclibc.org> -# -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. -# - -#LIB_NAME:=libsome - -ifneq ($(strip $(LIB_NAME)),) - -ifeq ($(strip $(srcdir)),) -srcdir=$(top_srcdir)$(LIB_NAME) -endif -ifeq ($(strip $($(LIB_NAME)_DIR)),) -$(LIB_NAME)_DIR:=$(top_builddir)$(LIB_NAME) -endif -ifeq ($(strip $($(LIB_NAME)_FULL_NAME)),) -$(LIB_NAME)_FULL_NAME:=$(LIB_NAME)-$(MAJOR_VERSION).$(MINOR_VERSION).$(SUBLEVEL).so -endif - -ifeq ($(strip $($(LIB_NAME)_SRC)),) -ifeq ($(strip $($(LIB_NAME)_MSRC)),) -$(LIB_NAME)_SRC:=$(wildcard $(srcdir)/*.c) -endif -endif -ifeq ($(strip $($(LIB_NAME)_OBJ)),) -$(LIB_NAME)_OBJ:=$(patsubst $(srcdir)/%.c,$($(LIB_NAME)_DIR)/%.o,$($(LIB_NAME)_SRC)) -endif -$(LIB_NAME)_OBJ_PIC:=$(patsubst %.o,%.os,$($(LIB_NAME)_OBJ)) - -$(LIB_NAME)_MOBJ_PIC:=$(patsubst %.o,%.os,$($(LIB_NAME)_MOBJ)) - -$(LIB_NAME)_SOBJ_PIC:=$(patsubst %.o,%.os,$($(LIB_NAME)_SOBJ)) - -#libso-y+=$(top_builddir)lib/$(LIB_NAME).so -#liba-y+=$(top_builddir)lib/$(LIB_NAME).a -#libclean-y+=$(LIB_NAME)_clean - -$($(LIB_NAME)_OBJ): %.o : %.c - $(compile.c) - -$($(LIB_NAME)_OBJ_PIC): %.os : %.c - $(compile.c) $(PICFLAG) - -$($(LIB_NAME)_MOBJ): $($(LIB_NAME)_MSRC) - $(compile.m) - -$($(LIB_NAME)_MOBJ_PIC): $($(LIB_NAME)_MSRC) - $(compile.m) $(PICFLAG) - -$($(LIB_NAME)_SOBJ): %.o : %.S - $(compile.S) - -$($(LIB_NAME)_SOBJ_PIC): %.os : %.S - $(compile.S) $(PICFLAG) - -# this should be changed to .os after libc/misc/internals/ is done -libc:=$(top_builddir)lib/libc.so -interp:=$(top_builddir)libc/misc/internals/interp.o -ifeq ($(strip $(EXTRA_LINK_LIBS)),) -#EXTRA_LINK_LIBS:=$(interp) -L$(top_builddir)lib -lc $(LDADD_LIBFLOAT) $(LIBGCC) -EXTRA_LINK_LIBS:=$(interp) $(libc) $(LDADD_LIBFLOAT) $(LIBGCC) -endif - -$(top_builddir)lib/$(LIB_NAME).so: $($(LIB_NAME)_DIR)/$(LIB_NAME)_pic.a $(interp) $(libc) - $(INSTALL) -d $(top_builddir)lib - $(RM) $@ $@.$(MAJOR_VERSION) $(top_builddir)lib/$($(LIB_NAME)_FULL_NAME) - $(LD) $(LDFLAGS) $(EXTRA_LINK_OPTS) -soname=$(notdir $@).$(MAJOR_VERSION) \ - -o $(top_builddir)lib/$($(LIB_NAME)_FULL_NAME) $(SHARED_START_FILES) \ - --whole-archive $(firstword $^) --no-whole-archive \ - $(EXTRA_LINK_LIBS) $(SHARED_END_FILES) - $(LN) -sf $($(LIB_NAME)_FULL_NAME) $@.$(MAJOR_VERSION) - $(LN) -sf $($(LIB_NAME)_FULL_NAME) $@ - -$(top_builddir)lib/$(LIB_NAME).so1: $($(LIB_NAME)_OBJ_PIC) $($(LIB_NAME)_MOBJ_PIC) $($(LIB_NAME)_SOBJ_PIC) $($(LIB_NAME)_SO_ADD) - $(INSTALL) -d $(top_builddir)lib - $(RM) $@ $@.$(MAJOR_VERSION) $(top_builddir)lib/$($(LIB_NAME)_FULL_NAME) - $(LD) $(LDFLAGS) $(EXTRA_LINK_OPTS) -soname=$(notdir $@).$(MAJOR_VERSION) \ - -o $(top_builddir)lib/$($(LIB_NAME)_FULL_NAME) $(SHARED_START_FILES) $^ \ - $(EXTRA_LINK_LIBS) $(SHARED_END_FILES) - $(LN) -sf $($(LIB_NAME)_FULL_NAME) $@.$(MAJOR_VERSION) - $(LN) -sf $($(LIB_NAME)_FULL_NAME) $@ - -$($(LIB_NAME)_DIR)/$(LIB_NAME)_pic.a: $($(LIB_NAME)_OBJ_PIC) $($(LIB_NAME)_MOBJ_PIC) $($(LIB_NAME)_SOBJ_PIC) $($(LIB_NAME)_SO_ADD) -ifneq ($(strip $(STRIP_FLAGS)),) - $(STRIPTOOL) $(STRIP_FLAGS) $^ -else - $(STRIPTOOL) -x -R .note -R .comment $^ -endif - $(AR) $(ARFLAGS) $@ $^ - -ifeq ($(DOPIC),y) -$(top_builddir)lib/$(LIB_NAME).a: $($(LIB_NAME)_DIR)/$(LIB_NAME)_pic.a - $(RM) $@ - cp $< $@ -else -$(top_builddir)lib/$(LIB_NAME).a: $($(LIB_NAME)_OBJ) $($(LIB_NAME)_MOBJ) $($(LIB_NAME)_SOBJ) $($(LIB_NAME)_A_ADD) - $(RM) $@ - $(STRIPTOOL) -x -R .note -R .comment $^ - $(AR) $(ARFLAGS) $@ $^ -endif - -$(LIB_NAME)_clean: - rm -f $($(LIB_NAME)_DIR)/*.{o,os,a} - -endif - -include $(top_srcdir)Makerules @@ -1,34 +1,263 @@ # # Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. # -.SUFFIXES: .c .S .o .os .so .a .s .i -ifndef top_srcdir -top_srcdir=$(CURDIR) -endif +.SUFFIXES: .c .S .o .os .oS .so .a .s .i -ifndef top_builddir -top_builddir=$(CURDIR) +ifeq ($(DOPIC),y) +lib-a-y: $(lib-a-pic-y) +else +lib-a-y: $(lib-a-y) endif +lib-so-y: $(lib-so-y) -top_srcdir:=$(shell echo "$(top_srcdir)/" | sed -e 's://:/:') -top_builddir:=$(shell echo "$(top_builddir)/" | sed -e 's://:/:') - +# order is important, the stripping uses STRIP_FLAGS for lib-so, but not for lib-a ifeq ($(HAVE_SHARED),y) .LIBPATTERNS: "lib%.so" -libs: libso-y liba-y +libs: lib-so-y lib-a-y else .LIBPATTERNS: "lib%.a" -libs: liba-y +libs: lib-a-y endif -libso-y: $(libso-y) -liba-y: $(liba-y) -libclean-y: $(libclean-y) +crt-y: $(crt-y) +other-y: $(other-y) +objclean-y: $(objclean-y) + +lib-multi-y: $(lib-multi-y) +ifeq ($(DOPIC),y) +lib-nomulti-y: $(lib-nomulti-y:.o=.os) +else +lib-nomulti-y: $(lib-nomulti-y) $(lib-nomulti-y:.o=.os) +endif -compile.c=$(CC) -c $< -o $@ $(CPPFLAGS) $(CFLAGS) $(ARCH_CFLAGS) $(CFLAGS-$(suffix $@)) $(CFLAGS-$@) $(CFLAGS-$<) -compile.S=$(compile.c) $(S_CPPFLAGS) $(ASFLAGS) $(ARCH_ASFLAGS) $(ASFLAGS-$(suffix $@)) $(ASFLAGS-$@) $(ASFLAGS-$<) +libc-nonshared-y: $(libc-nonshared-y) + +$(top_builddir)lib/$(NONSHARED_LIBNAME): $(libc-nonshared-y) + $(INSTALL) -d $(top_builddir)lib + $(AR) $(ARFLAGS) $@ $^ + +compile.c=$(CC) -c $< -o $@ $(CPPFLAGS) $(CFLAGS) $(ARCH_CFLAGS) $(CFLAGS-$(suffix $@)) $(CFLAGS-$(notdir $@)) $(CFLAGS-$(notdir $<)) +compile.S=$(compile.c) $(S_CPPFLAGS) $(ASFLAGS) $(ARCH_ASFLAGS) $(ASFLAGS-$(suffix $@)) $(ASFLAGS-$(notdir $@)) $(ASFLAGS-$(notdir $<)) compile.m=$(compile.c) -DL_$(patsubst %$(suffix $(notdir $@)),%,$(notdir $@)) -.PHONY: clean -clean: libclean-y +#compile.i=$(compile.m) -E + +compile-m=$(CC) $^ -c -o $@ $(CPPFLAGS) $(CFLAGS) $(ARCH_CFLAGS) $(CFLAGS-$(suffix $@)) $(CFLAGS-$(notdir $@)) $(CFLAGS-$(notdir $<)) $(S_CPPFLAGS) $(ASFLAGS) $(ARCH_ASFLAGS) $(ASFLAGS-$(suffix $@)) $(ASFLAGS-$(notdir $@)) $(ASFLAGS-$(notdir $<)) $(CFLAGS-multi-y) + +CFLAGS-.os+=$(PICFLAG) + +%.o: %.c + $(compile.c) + +%.os: %.c + $(compile.c) + +%.oS: %.c + $(compile.c) -DSHARED + +%.o: %.S + $(compile.S) + +%.os: %.S + $(compile.S) + +#ifeq ($(HAVE_ELF),y) +CRT=crt1 +#else +#CRT=crt0.o +#endif + +CRTS=$(top_builddir)lib/$(CRT).o $(top_builddir)lib/S$(CRT).o + +$(top_builddir)lib/$(CRT).o: $(top_srcdir)libc/sysdeps/linux/$(TARGET_ARCH)/$(CRT).S + $(INSTALL) -d $(dir $@) + $(compile.S) -DL_$(patsubst %$(suffix $(notdir $@)),%,$(notdir $@)) + $(STRIPTOOL) -x -R .note -R .comment $@ + +$(top_builddir)lib/S$(CRT).o: $(top_srcdir)libc/sysdeps/linux/$(TARGET_ARCH)/$(CRT).S + $(INSTALL) -d $(dir $@) + $(compile.S) $(PIEFLAG) -DL_$(patsubst %$(suffix $(notdir $@)),%,$(notdir $@)) + $(STRIPTOOL) -x -R .note -R .comment $@ + +CTOR_TARGETS=$(top_builddir)lib/crti.o $(top_builddir)lib/crtn.o + +ifeq ($(UCLIBC_CTOR_DTOR),y) +$(top_builddir)lib/crti.o: $(top_srcdir)libc/sysdeps/linux/$(TARGET_ARCH)/crti.S + $(INSTALL) -d $(dir $@) + $(compile.S) $(PICFLAG) $(SSP_DISABLE_FLAGS) + +$(top_builddir)lib/crtn.o: $(top_srcdir)libc/sysdeps/linux/$(TARGET_ARCH)/crtn.S + $(INSTALL) -d $(dir $@) + $(compile.S) $(PICFLAG) $(SSP_DISABLE_FLAGS) +else +$(CTOR_TARGETS): + $(INSTALL) -d $(top_builddir)lib + $(AR) $(ARFLAGS) $@ +endif + +$(crt-y): $(CRTS) $(CTOR_TARGETS) + +.PHONY: clean headers dummy create +clean: objclean-y headers_clean-y +headers: $(headers-y) + +headers_clean-y: $(headers_clean-y) + +ifneq ($(strip $(LIB_NAME)),) + +ifeq ($(strip $($(LIB_NAME)_FULL_NAME)),) +$(LIB_NAME)_FULL_NAME:=$(LIB_NAME)-$(MAJOR_VERSION).$(MINOR_VERSION).$(SUBLEVEL).so +endif + +ifeq ($(DOPIC),y) +$(LIB_NAME)-a-y: $($(LIB_NAME)-a-pic-y) +else +$(LIB_NAME)-a-y: $($(LIB_NAME)-a-y) +endif +$(LIB_NAME)-so-y: $($(LIB_NAME)-so-y) + +ifeq ($(HAVE_SHARED),y) +objs: $(LIB_NAME)-a-y $(LIB_NAME)-so-y +else +objs: $(LIB_NAME)-a-y +endif + +$($(LIB_NAME)_OUT)/$(LIB_NAME).o $($(LIB_NAME)_OUT)/$(LIB_NAME).os: $($(LIB_NAME)-multi-y) + $(compile-m) + +libc=$(top_builddir)lib/libc.so +interp=$(top_builddir)libc/misc/internals/interp.os +ifeq ($(strip $(EXTRA_LINK_LIBS)),) +#EXTRA_LINK_LIBS:=$(interp) -L$(top_builddir)lib -lc $(LDADD_LIBFLOAT) $(LIBGCC) +EXTRA_LINK_LIBS:=$(interp) $(libc) $(LDADD_LIBFLOAT) $(LIBGCC) +endif + +ifneq ($(strip $(LIB_NAME)),libc) +ifneq ($(strip $(LIB_NAME)),ld-uClibc) +$(top_builddir)lib/$(LIB_NAME).so: $($(LIB_NAME)_OUT)/$(LIB_NAME)_so.a $(interp) $(libc) +else +$(top_builddir)lib/$(LIB_NAME).so: $($(LIB_NAME)_OUT)/$(LIB_NAME)_so.a +endif +else +$(top_builddir)lib/$(LIB_NAME).so: $($(LIB_NAME)_OUT)/$(LIB_NAME)_so.a $(interp) +endif + $(INSTALL) -d $(dir $@) + $(RM) $@ $@.$(MAJOR_VERSION) $(top_builddir)lib/$($(LIB_NAME)_FULL_NAME) + $(LD) $(LDFLAGS) $(EXTRA_LINK_OPTS) -soname=$(notdir $@).$(MAJOR_VERSION) \ + -o $(top_builddir)lib/$($(LIB_NAME)_FULL_NAME) $(SHARED_START_FILES) \ + --whole-archive $(firstword $^) --no-whole-archive \ + $(EXTRA_LINK_LIBS) $(SHARED_END_FILES) + $(LN) -sf $($(LIB_NAME)_FULL_NAME) $@.$(MAJOR_VERSION) +ifneq ($(strip $(LIB_NAME)),libc) +ifneq ($(strip $(LIB_NAME)),ld-uClibc) + $(LN) -sf $($(LIB_NAME)_FULL_NAME) $@ +endif +else + echo "/* GNU ld script" > $@ + echo " * Use the shared library, but some functions are only in" >> $@ + echo " * the static library, so try that secondarily. */" >> $@ +ifeq ($(COMPAT_ATEXIT),y) + echo "GROUP ( $(top_builddir)lib/$(NONSHARED_LIBNAME) $(top_builddir)lib/$(SHARED_MAJORNAME) )" >> $@ +else + echo "GROUP ( $(top_builddir)lib/$(SHARED_MAJORNAME) $(top_builddir)lib/$(NONSHARED_LIBNAME) )" >> $@ +endif +endif + +$(top_builddir)lib/$(LIB_NAME).so.notused: $($(LIB_NAME)-so-y) +ifneq ($(strip $(STRIP_FLAGS)),) + $(STRIPTOOL) $(STRIP_FLAGS) $^ +else + $(STRIPTOOL) -x -R .note -R .comment $^ +endif + $(INSTALL) -d $(dir $@) + $(RM) $@ $@.$(MAJOR_VERSION) $(top_builddir)lib/$($(LIB_NAME)_FULL_NAME) + $(LD) $(LDFLAGS) $(EXTRA_LINK_OPTS) -soname=$(notdir $@).$(MAJOR_VERSION) \ + -o $(top_builddir)lib/$($(LIB_NAME)_FULL_NAME) $(SHARED_START_FILES) $^ \ + $(EXTRA_LINK_LIBS) $(SHARED_END_FILES) + $(LN) -sf $($(LIB_NAME)_FULL_NAME) $@.$(MAJOR_VERSION) +ifneq ($(strip $(LIB_NAME)),libc) + $(LN) -sf $($(LIB_NAME)_FULL_NAME) $@ +else + echo "/* GNU ld script" > $@ + echo " * Use the shared library, but some functions are only in" >> $@ + echo " * the static library, so try that secondarily. */" >> $@ +ifeq ($(COMPAT_ATEXIT),y) + echo "GROUP ( $(top_builddir)lib/$(NONSHARED_LIBNAME) $(top_builddir)lib/$(SHARED_MAJORNAME) )" >> $@ +else + echo "GROUP ( $(top_builddir)lib/$(SHARED_MAJORNAME) $(top_builddir)lib/$(NONSHARED_LIBNAME) )" >> $@ +endif +endif + +ifeq ($(DOMULTI),y) + +$($(LIB_NAME)_OUT)/$(LIB_NAME)_so.a: $($(LIB_NAME)_OUT)/$(LIB_NAME).os $($(LIB_NAME)-nomulti-y:.o=.os) + $(RM) $@ +ifneq ($(strip $(STRIP_FLAGS)),) + $(STRIPTOOL) $(STRIP_FLAGS) $^ +else + $(STRIPTOOL) -x -R .note -R .comment $^ +endif + $(AR) $(ARFLAGS) $@ $^ + +ifeq ($(DOPIC),y) +$(top_builddir)lib/$(LIB_NAME).a: $($(LIB_NAME)_OUT)/$(LIB_NAME).os $($(LIB_NAME)-nomulti-y:.o=.os) +else +$(top_builddir)lib/$(LIB_NAME).a: $($(LIB_NAME)_OUT)/$(LIB_NAME).o $($(LIB_NAME)-nomulti-y) +endif + $(INSTALL) -d $(dir $@) + $(RM) $@ + $(STRIPTOOL) -x -R .note -R .comment $^ + $(AR) $(ARFLAGS) $@ $^ + +else # DOMULTI + +$($(LIB_NAME)_OUT)/$(LIB_NAME)_so.a: $($(LIB_NAME)-so-y) + $(RM) $@ +ifneq ($(strip $(STRIP_FLAGS)),) + $(STRIPTOOL) $(STRIP_FLAGS) $^ +else + $(STRIPTOOL) -x -R .note -R .comment $^ +endif + $(AR) $(ARFLAGS) $@ $^ + +ifeq ($(DOPIC),y) +$(top_builddir)lib/$(LIB_NAME).a: $($(LIB_NAME)-a-pic-y) +else +$(top_builddir)lib/$(LIB_NAME).a: $($(LIB_NAME)-a-y) +endif + $(INSTALL) -d $(dir $@) + $(RM) $@ + $(STRIPTOOL) -x -R .note -R .comment $^ + $(AR) $(ARFLAGS) $@ $^ + +endif # DOMULTI + +$(LIB_NAME)_clean: + rm -f $($(LIB_NAME)_OUT)/*.{o,os,a} + +else # LIB_NAME + +ifeq ($(DOPIC),y) +libc-a-y: $(libc-a-pic-y) +libc-nomulti-y: $(libc-nomulti-y:.o=.os) +else +libc-a-y: $(libc-a-y) +libc-nomulti-y: $(libc-nomulti-y) $(libc-nomulti-y:.o=.os) +endif +libc-so-y: $(libc-so-y) + +libc-multi-y: $(libc-multi-y) + $(compile-m) + +ifeq ($(HAVE_SHARED),y) +objs: libc-a-y libc-so-y crt-y other-y +else +objs: libc-a-y crt-y other-y +endif + +# only for local multi testing +libc.o libc.os: $(libc-multi-y) + $(compile-m) + +endif # LIB_NAME @@ -340,9 +340,10 @@ endif else # psm: the next 2 are probably incorrect, the generic header will # win over the arch specific one -PTINC := -I$(PTDIR)/sysdeps/pthread \ - -I$(PTDIR)/sysdeps/$(TARGET_ARCH) +PTINC := -I$(PTDIR)/sysdeps/$(TARGET_ARCH) \ + -I$(PTDIR)/sysdeps/pthread endif +CFLAGS+=$(PTINC) endif ifeq ($(UCLIBC_BUILD_RELRO),y) diff --git a/extra/scripts/Makefile.libs.lvl1 b/extra/scripts/Makefile.libs.lvl1 new file mode 100644 index 000000000..e1fda52df --- /dev/null +++ b/extra/scripts/Makefile.libs.lvl1 @@ -0,0 +1,13 @@ +# Makefile for uClibc +# +# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# + +TOPDIR=../ + +top_srcdir=$(TOPDIR) +top_builddir=../ +include $(top_builddir)Rules.mak +all: libs +include Makefile.in +include $(top_srcdir)Makerules diff --git a/extra/scripts/Makefile.libs.lvl2 b/extra/scripts/Makefile.libs.lvl2 new file mode 100644 index 000000000..fc3b4f1d0 --- /dev/null +++ b/extra/scripts/Makefile.libs.lvl2 @@ -0,0 +1,13 @@ +# Makefile for uClibc +# +# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# + +TOPDIR=../../ + +top_srcdir=$(TOPDIR) +top_builddir=../../ +include $(top_builddir)Rules.mak +all: libs +include Makefile.in +include $(top_srcdir)Makerules diff --git a/extra/scripts/Makefile.objs.lvl2 b/extra/scripts/Makefile.objs.lvl2 new file mode 100644 index 000000000..8a961e4dc --- /dev/null +++ b/extra/scripts/Makefile.objs.lvl2 @@ -0,0 +1,13 @@ +# Makefile for uClibc +# +# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# + +TOPDIR=../../ + +top_srcdir=$(TOPDIR) +top_builddir=../../ +all: objs +include $(top_builddir)Rules.mak +include Makefile.in +include $(top_srcdir)Makerules diff --git a/extra/scripts/Makefile.objs.lvl3 b/extra/scripts/Makefile.objs.lvl3 new file mode 100644 index 000000000..b78cba738 --- /dev/null +++ b/extra/scripts/Makefile.objs.lvl3 @@ -0,0 +1,13 @@ +# Makefile for uClibc +# +# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# + +TOPDIR=../../../ + +top_srcdir=$(TOPDIR) +top_builddir=../../../ +all: objs +include $(top_builddir)Rules.mak +include Makefile.in +include $(top_srcdir)Makerules diff --git a/extra/scripts/Makefile.objs.lvl4 b/extra/scripts/Makefile.objs.lvl4 new file mode 100644 index 000000000..65a8bf6bf --- /dev/null +++ b/extra/scripts/Makefile.objs.lvl4 @@ -0,0 +1,13 @@ +# Makefile for uClibc +# +# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# + +TOPDIR=../../../../ + +top_srcdir=$(TOPDIR) +top_builddir=../../../../ +all: objs +include $(top_builddir)Rules.mak +include Makefile.in +include $(top_srcdir)Makerules diff --git a/ldso/Makefile.in b/ldso/Makefile.in new file mode 100644 index 000000000..8d3c5fcda --- /dev/null +++ b/ldso/Makefile.in @@ -0,0 +1,45 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +DIRS=$(shell if test -f $(top_builddir)lib/libc.so ; then echo "ldso libdl" ; else echo "ldso" ; fi) + +libs: subdirs + +LN_HEADERS := $(patsubst %, include/%, elf.h) +LN_ARCH_HEADERS := $(patsubst %, include/%, dl-startup.h dl-syscalls.h dl-sysdep.h dl-debug.h) +HEADERS := $(LN_HEADERS) $(LN_ARCH_HEADERS) include/dl-progname.h + +headers-y+=ldso_headers + +ldso_headers: $(HEADERS) + +$(LN_HEADERS): + $(LN) -sf $(top_builddir)../$@ $@ + +$(LN_ARCH_HEADERS): + $(LN) -sf ../ldso/$(TARGET_ARCH)/$(patsubst include/%,%,$@) $@ + +include/dl-progname.h: + echo '#include "$(TARGET_ARCH)/elfinterp.c"' > $@ + +headers_clean-y+=ldso_headers_clean + +ldso_headers_clean: + $(RM) $(HEADERS) + +clean: subdirs_clean ldso_headers_clean + +subdirs: $(patsubst %, _dir_%, $(DIRS)) +subdirs_clean: $(patsubst %, _dirclean_%, $(DIRS)) + +$(patsubst %, _dir_%, $(DIRS)): ldso_headers + $(MAKE) -C $(patsubst _dir_%, %, $@) + +$(patsubst %, _dirclean_%, $(DIRS)): dummy + $(MAKE) -C $(patsubst _dirclean_%, %, $@) clean + +.PHONY: dummy diff --git a/ldso/ldso/Makefile.in b/ldso/ldso/Makefile.in index a272e771b..2ba7e2f71 100644 --- a/ldso/ldso/Makefile.in +++ b/ldso/ldso/Makefile.in @@ -1,13 +1,13 @@ # Makefile for uClibc # -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # - -LIB_NAME:=ld-uClibc # psm: I do not know if the order of includes is relevant # to be sure I have put them first -CFLAGS:=-I$(top_srcdir)ldso/include -I. $(CFLAGS) $(PICFLAG) $(SSP_DISABLE_FLAGS) +CFLAGS:=-I$(top_builddir)ldso/include -I. $(CFLAGS) $(PICFLAG) $(SSP_DISABLE_FLAGS) CFLAGS+=-DUCLIBC_RUNTIME_PREFIX=\"$(RUNTIME_PREFIX)\" -DUCLIBC_LDSO=\"$(UCLIBC_LDSO)\" @@ -39,21 +39,32 @@ ifeq ($(SUPPORT_LD_DEBUG),y) LDFLAGS:=$(LDFLAGS_NOSTRIP) endif -srcdir=$(top_srcdir)ldso/ldso -$(LIB_NAME)_DIR:=$(top_builddir)ldso/ldso +# useless, only 1 source file +DOMULTI=n + +LIB_NAME:=ld-uClibc -$(LIB_NAME)_SRC:=$(srcdir)/ldso.c +ld-uClibc_DIR:=$(top_srcdir)ldso/ldso +ld-uClibc_OUT:=$(top_builddir)ldso/ldso -$(LIB_NAME)_SSRC:=$(wildcard $(srcdir)/$(TARGET_ARCH)/*.S) -$(LIB_NAME)_SOBJ:=$(patsubst $(srcdir)/$(TARGET_ARCH)/%.S,$($(LIB_NAME)_DIR)/$(TARGET_ARCH)/%.o,$($(LIB_NAME)_SSRC)) +ld-uClibc_SRC:=$(ld-uClibc_DIR)/ldso.c +ld-uClibc_OBJ:=$(patsubst $(ld-uClibc_DIR)/%.c,$(ld-uClibc_OUT)/%.o,$(ld-uClibc_SRC)) + +ld-uClibc_SSRC:=$(wildcard $(ld-uClibc_DIR)/$(TARGET_ARCH)/*.S) +ld-uClibc_SOBJ:=$(patsubst $(ld-uClibc_DIR)/$(TARGET_ARCH)/%.S,$(ld-uClibc_OUT)/$(TARGET_ARCH)/%.o,$(ld-uClibc_SSRC)) + +ld-uClibc_OBJS:=$(ld-uClibc_OBJ) $(ld-uClibc_SOBJ) EXTRA_LINK_OPTS:=-e _start -z now -Bsymbolic --export-dynamic --sort-common --discard-locals --discard-all --no-undefined EXTRA_LINK_LIBS:=$(LIBGCC) # $(LDADD_LIBFLOAT) -libso-$(HAVE_SHARED)+=$(top_builddir)lib/$(LIB_NAME).so -libclean-y+=$(LIB_NAME)_clean $(LIB_NAME)_arch_clean +ld-uClibc-so-$(HAVE_SHARED):=$(ld-uClibc_OBJS:.o=.os) + +#ld-uClibc-multi-$(HAVE_SHARED):=$(ld-uClibc_SRC) + +objclean-y+=ld-uClibc_clean ld-uClibc_arch_clean -$(LIB_NAME)_arch_clean: - $(RM) $($(LIB_NAME)_DIR)/*/*.{o,os} +ld-uClibc_arch_clean: + $(RM) $(ld-uClibc_OUT)/*/*.{o,os} -include $(top_srcdir)Makefile.libs +lib-so-$(HAVE_SHARED)+=$(top_builddir)lib/ld-uClibc.so diff --git a/ldso/libdl/Makefile.in b/ldso/libdl/Makefile.in index 389484e9b..24a53422e 100644 --- a/ldso/libdl/Makefile.in +++ b/ldso/libdl/Makefile.in @@ -1,12 +1,13 @@ # Makefile.in for uClibc # -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # - -LIB_NAME:=libdl # psm: I do not know if the order of includes is relevant -# to be sure I added them first +# to be sure I added them first, Jocke please cleanup if needed CFLAGS:=-I$(top_builddir)ldso/include -I$(top_builddir)ldso/ldso $(CFLAGS) $(SSP_ALL_CFLAGS) CFLAGS+=-DUCLIBC_RUNTIME_PREFIX=\"$(RUNTIME_PREFIX)\" @@ -20,33 +21,39 @@ ifeq ($(TARGET_ARCH),mips) CFLAGS:=$(CFLAGS:-O0=-O1) endif -CFLAGS-.os=-DSHARED -# we adapt CFLAGS, because libdl.a has an additional object -ifeq ($(DOPIC),y) -CFLAGS-.o=$(PICFLAG) -resolv:=$(top_builddir)ldso/ldso/$(TARGET_ARCH)/resolve.os -else -resolv:=$(top_builddir)ldso/ldso/$(TARGET_ARCH)/resolve.o -endif +# useless, only 1 source file +DOMULTI=n + +LIB_NAME:=libdl EXTRA_LINK_OPTS:=-fini dl_cleanup +# keep in sync w/ Makerules +EXTRA_LINK_LIBS:=$(top_builddir)libc/misc/internals/interp.os $(top_builddir)lib/libc.so $(LIBGCC) $(top_builddir)lib/$(UCLIBC_LDSO) + +libdl_DIR:=$(top_srcdir)ldso/libdl +libdl_OUT:=$(top_builddir)ldso/libdl + +libdl_SRC:=$(libdl_DIR)/libdl.c +libdl_OBJ:=$(patsubst $(libdl_DIR)/%.c,$(libdl_OUT)/%.o,$(libdl_SRC)) -# we need for all cases a "full" libdl.a the pic version used to build libdl.so misses $(resolv) -# because it is linked against ld.so -DOPIC=n +# use other suffixes, so that it does not pick up the multi rule from Makerules +$(libdl_OUT)/libdl.oS: $(libdl_DIR)/libdl.c + $(compile.c) -DSHARED -srcdir=$(top_srcdir)ldso/$(LIB_NAME) -$(LIB_NAME)_DIR:=$(top_builddir)ldso/$(LIB_NAME) +resolve:=$(top_builddir)ldso/ldso/$(TARGET_ARCH)/resolve.o -$(LIB_NAME)_SRC:=$(srcdir)/libdl.c +libdl-a-$(HAVE_SHARED):=$(libdl_OBJ) $(resolve) +libdl-a-pic-$(HAVE_SHARED):=$(libdl_OBJ:.o=.os) $(resolve:.o=.os) +libdl-so-$(HAVE_SHARED):=$(libdl_OBJ:.o=.oS) -$(LIB_NAME)_A_ADD:=$(resolv) +# we enable this although no use of multi, else libdl.o gets empty sources +libdl-multi-$(HAVE_SHARED):=$(libdl_SRC) -libso-$(HAVE_SHARED)+=$(top_builddir)lib/$(LIB_NAME).so -liba-$(HAVE_SHARED)+=$(top_builddir)lib/$(LIB_NAME).a -libclean-y+=$(LIB_NAME)_clean +objclean-y+=libdl_clean libdl_extra_clean -include $(top_srcdir)Makefile.libs +libdl_extra_clean: + $(RM) $(libdl_OUT)/*.oS -# !!! these lines have to come after including Makefile.libs !!! -EXTRA_LINK_LIBS+=$(top_builddir)lib/$(UCLIBC_LDSO) +lib-a-$(HAVE_SHARED)+=$(top_builddir)lib/libdl.a +lib-a-pic-$(HAVE_SHARED)+=$(top_builddir)lib/libdl.a +lib-so-$(HAVE_SHARED)+=$(top_builddir)lib/libdl.so diff --git a/libc/Makefile.in b/libc/Makefile.in new file mode 100644 index 000000000..33a1070d9 --- /dev/null +++ b/libc/Makefile.in @@ -0,0 +1,57 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +DOMULTI=n + +# we have SHARED_MAJORNAME=libc.so.$(MAJOR_VERSION) defined in Rules.mak +LIB_NAME:=libc + +libc_DIR:=$(top_srcdir)libc +libc_OUT:=$(top_builddir)libc + +libc_FULL_NAME:=libuClibc-$(MAJOR_VERSION).$(MINOR_VERSION).$(SUBLEVEL).so + +#DIRS:=misc pwd_grp stdio string termios inet signal stdlib sysdeps unistd + +# this comes first, so duplicate removal works correctly +include $(libc_DIR)/sysdeps/Makefile.in + +include $(libc_DIR)/misc/Makefile.in +include $(libc_DIR)/pwd_grp/Makefile.in +include $(libc_DIR)/stdio/Makefile.in +include $(libc_DIR)/string/Makefile.in +include $(libc_DIR)/termios/Makefile.in +include $(libc_DIR)/inet/Makefile.in +include $(libc_DIR)/signal/Makefile.in +include $(libc_DIR)/stdlib/Makefile.in +include $(libc_DIR)/unistd/Makefile.in + +# Check if the target architecture has a version script for +# libc, and if so, include it when linking. +VERSION_SCRIPT:=${shell if [ -f $(libc_DIR)/sysdeps/linux/$(TARGET_ARCH)/libc.map ] ; then \ + echo "--version-script $(libc_DIR)/sysdeps/linux/$(TARGET_ARCH)/libc.map"; fi} + +EXTRA_LINK_OPTS:=$(VERSION_SCRIPT) -init __uClibc_init +EXTRA_LINK_LIBS:=$(libc_OUT)/misc/internals/interp.os $(top_builddir)lib/$(UCLIBC_LDSO) $(LIBGCC) # $(LDADD_LIBFLOAT) + +ifeq ($(DOPIC),y) +libc-a-y: $(libc-a-pic-y) +else +libc-a-y: $(libc-a-y) +endif + +libc-so-y: $(libc-so-y) + +crt-y: $(crt-y) +other-y: $(other-y) + +objclean-y+=libc_clean + +lib-a-y+=$(top_builddir)lib/libc.a +lib-a-pic-y+=$(top_builddir)lib/libc.a +lib-so-y+=$(top_builddir)lib/libc.so $(top_builddir)lib/$(NONSHARED_LIBNAME) crt-y diff --git a/libc/inet/Makefile.in b/libc/inet/Makefile.in new file mode 100644 index 000000000..0b5ea7cc3 --- /dev/null +++ b/libc/inet/Makefile.in @@ -0,0 +1,72 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +include $(top_srcdir)libc/inet/rpc/Makefile.in + +CSRC:= getservice.c getproto.c hostid.c getnetent.c getnetbynm.c getnetbyad.c \ + inet_net.c ntop.c herror.c if_nametoindex.c gai_strerror.c getaddrinfo.c \ + in6_addr.c ether_addr.c ntohl.c + +MSRC1:= addr.c +MOBJ1:= inet_aton.o inet_addr.o inet_ntoa.o inet_makeaddr.o inet_lnaof.o \ + inet_netof.o + +MSRC2:= resolv.c +MOBJ2:= encodeh.o decodeh.o encoded.o decoded.o lengthd.o encodeq.o \ + decodeq.o lengthq.o encodea.o decodea.o encodep.o decodep.o \ + formquery.o dnslookup.o resolveaddress.o opennameservers.o \ + closenameservers.o resolvename.o gethostbyname.o res_init.o \ + res_query.o gethostbyaddr.o read_etc_hosts_r.o get_hosts_byname_r.o \ + get_hosts_byaddr_r.o gethostbyname2.o getnameinfo.o gethostent.o \ + gethostbyname_r.o gethostbyname2_r.o gethostbyaddr_r.o \ + res_comp.o ns_name.o + +MSRC3:= socketcalls.c +MOBJ3:= accept.o bind.o connect.o getpeername.o getsockname.o getsockopt.o \ + listen.o recv.o recvfrom.o recvmsg.o send.o sendmsg.o sendto.o \ + setsockopt.o shutdown.o socket.o socketpair.o + +INET_DIR:=$(top_srcdir)libc/inet +INET_OUT:=$(top_builddir)libc/inet + +INET_SRC:=$(patsubst %.c,$(INET_DIR)/%.c,$(CSRC)) +INET_OBJ:=$(patsubst %.c,$(INET_OUT)/%.o,$(CSRC)) + +INET_MSRC1:=$(INET_DIR)/$(MSRC1) +INET_MSRC2:=$(INET_DIR)/$(MSRC2) +INET_MSRC3:=$(INET_DIR)/$(MSRC3) +INET_MOBJ1:=$(patsubst %.o,$(INET_OUT)/%.o,$(MOBJ1)) +INET_MOBJ2:=$(patsubst %.o,$(INET_OUT)/%.o,$(MOBJ2)) +INET_MOBJ3:=$(patsubst %.o,$(INET_OUT)/%.o,$(MOBJ3)) + +INET_MSRC:=$(INET_MSRC1) $(INET_MSRC2) $(INET_MSRC3) +INET_MOBJ:=$(INET_MOBJ1) $(INET_MOBJ2) $(INET_MOBJ3) +INET_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(INET_MOBJ)))) + +INET_OBJS:=$(INET_OBJ) $(INET_MOBJ) + +$(INET_MOBJ1) $(INET_MOBJ1:.o=.os): $(INET_MSRC1) + $(compile.m) + +$(INET_MOBJ2) $(INET_MOBJ2:.o=.os): $(INET_MSRC2) + $(compile.m) + +$(INET_MOBJ3) $(INET_MOBJ3:.o=.os): $(INET_MSRC3) + $(compile.m) + +libc-a-y+=$(INET_OBJS) +libc-a-pic-y+=$(INET_OBJS:.o=.os) +libc-so-y+=$(INET_OBJS:.o=.os) + +CFLAGS-multi-y+=$(INET_DEF) +libc-multi-y+=$(INET_SRC) $(INET_MSRC) + +objclean-y+=inet_objclean + +inet_objclean: + $(RM) $(INET_OUT)/*.{o,os} diff --git a/libc/inet/rpc/Makefile.in b/libc/inet/rpc/Makefile.in new file mode 100644 index 000000000..08f4eeca2 --- /dev/null +++ b/libc/inet/rpc/Makefile.in @@ -0,0 +1,50 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +ifeq ($(UCLIBC_HAS_FULL_RPC),y) +CSRC:= auth_none.c auth_unix.c authunix_prot.c bindresvport.c \ + clnt_generic.c clnt_perror.c clnt_raw.c clnt_simple.c clnt_tcp.c \ + clnt_udp.c rpc_dtablesize.c get_myaddress.c getrpcent.c getrpcport.c \ + pmap_clnt.c pmap_getmaps.c pmap_getport.c pmap_prot.c \ + pmap_prot2.c pmap_rmt.c rpc_prot.c rpc_commondata.c rpc_callmsg.c \ + svc.c svc_auth.c svc_auth_unix.c svc_raw.c svc_run.c svc_simple.c \ + svc_tcp.c svc_udp.c xdr.c xdr_array.c xdr_float.c xdr_mem.c \ + xdr_rec.c xdr_reference.c xdr_stdio.c \ + rtime.c clnt_unix.c svc_unix.c create_xid.c xdr_intXX_t.c rcmd.c \ + rexec.c sa_len.c ruserpass.c rpc_thread.c +else +# For now, only compile the stuff needed to do an NFS mount.... +CSRC:= create_xid.c pmap_clnt.c pmap_getmaps.c pmap_getport.c \ + pmap_prot.c pmap_prot2.c clnt_simple.c clnt_perror.c \ + clnt_tcp.c clnt_udp.c bindresvport.c authunix_prot.c \ + auth_none.c auth_unix.c xdr.c xdr_array.c xdr_rec.c \ + xdr_reference.c xdr_mem.c svc.c svc_auth.c svc_auth_unix.c \ + rpc_callmsg.c rpc_prot.c rpc_dtablesize.c rpc_commondata.c \ + rpc_thread.c rcmd.c rexec.c sa_len.c ruserpass.c rtime.c \ + getrpcent.c +endif + +INET_RPC_DIR:=$(top_srcdir)libc/inet/rpc +INET_RPC_OUT:=$(top_builddir)libc/inet/rpc + +INET_RPC_NO_MULTI:=rpc_commondata.c rpc_thread.c svc.c + +INET_RPC_SRC:=$(patsubst %.c,$(INET_RPC_DIR)/%.c,$(CSRC)) +INET_RPC_OBJ:=$(patsubst %.c,$(INET_RPC_OUT)/%.o,$(CSRC)) + +libc-a-$(UCLIBC_HAS_RPC)+=$(INET_RPC_OBJ) +libc-a-pic-$(UCLIBC_HAS_RPC)+=$(INET_RPC_OBJ:.o=.os) +libc-so-$(UCLIBC_HAS_RPC)+=$(INET_RPC_OBJ:.o=.os) + +libc-multi-$(UCLIBC_HAS_RPC)+=$(filter-out $(patsubst %.c,$(INET_RPC_DIR)/%.c,$(INET_RPC_NO_MULTI)),$(INET_RPC_SRC)) +libc-nomulti-$(UCLIBC_HAS_RPC)+=$(patsubst %.c,$(INET_RPC_OUT)/%.o,$(INET_RPC_NO_MULTI)) + +objclean-y+=inet_rpc_objclean + +inet_rpc_objclean: + $(RM) $(INET_RPC_OUT)/*.{o,os} diff --git a/libc/misc/Makefile.in b/libc/misc/Makefile.in new file mode 100644 index 000000000..f9331c9dd --- /dev/null +++ b/libc/misc/Makefile.in @@ -0,0 +1,36 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +#DIRS:=assert ctype dirent error file fnmatch ftw glob gnu internals intl locale mntent \ +# pthread regex search statfs syslog sysvipc time ttyent utmp wchar wctype wordexp + +include $(top_srcdir)libc/misc/assert/Makefile.in +include $(top_srcdir)libc/misc/ctype/Makefile.in +include $(top_srcdir)libc/misc/dirent/Makefile.in +include $(top_srcdir)libc/misc/error/Makefile.in +include $(top_srcdir)libc/misc/file/Makefile.in +include $(top_srcdir)libc/misc/fnmatch/Makefile.in +include $(top_srcdir)libc/misc/ftw/Makefile.in +include $(top_srcdir)libc/misc/glob/Makefile.in +include $(top_srcdir)libc/misc/gnu/Makefile.in +include $(top_srcdir)libc/misc/internals/Makefile.in +include $(top_srcdir)libc/misc/intl/Makefile.in +include $(top_srcdir)libc/misc/locale/Makefile.in +include $(top_srcdir)libc/misc/mntent/Makefile.in +include $(top_srcdir)libc/misc/pthread/Makefile.in +include $(top_srcdir)libc/misc/regex/Makefile.in +include $(top_srcdir)libc/misc/search/Makefile.in +include $(top_srcdir)libc/misc/statfs/Makefile.in +include $(top_srcdir)libc/misc/syslog/Makefile.in +include $(top_srcdir)libc/misc/sysvipc/Makefile.in +include $(top_srcdir)libc/misc/time/Makefile.in +include $(top_srcdir)libc/misc/ttyent/Makefile.in +include $(top_srcdir)libc/misc/utmp/Makefile.in +include $(top_srcdir)libc/misc/wchar/Makefile.in +include $(top_srcdir)libc/misc/wctype/Makefile.in +include $(top_srcdir)libc/misc/wordexp/Makefile.in diff --git a/libc/misc/assert/Makefile.in b/libc/misc/assert/Makefile.in new file mode 100644 index 000000000..6fbdcb72a --- /dev/null +++ b/libc/misc/assert/Makefile.in @@ -0,0 +1,26 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=__assert.c + +MISC_ASSERT_DIR:=$(top_srcdir)libc/misc/assert +MISC_ASSERT_OUT:=$(top_builddir)libc/misc/assert + +MISC_ASSERT_SRC:=$(MISC_ASSERT_DIR)/__assert.c +MISC_ASSERT_OBJ:=$(MISC_ASSERT_OUT)/__assert.o + +libc-a-y+=$(MISC_ASSERT_OBJ) +libc-a-pic-y+=$(MISC_ASSERT_OBJ:.o=.os) +libc-so-y+=$(MISC_ASSERT_OBJ:.o=.os) + +libc-multi-y+=$(MISC_ASSERT_SRC) + +objclean-y+=misc_assert_objclean + +misc_assert_objclean: + $(RM) $(MISC_ASSERT_OUT)/*.{o,os} diff --git a/libc/misc/ctype/Makefile.in b/libc/misc/ctype/Makefile.in new file mode 100644 index 000000000..f9f1bfbed --- /dev/null +++ b/libc/misc/ctype/Makefile.in @@ -0,0 +1,56 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC:=ctype.c +MOBJ:= isalnum.o isalpha.o isascii.o iscntrl.o isdigit.o \ + isgraph.o islower.o isprint.o ispunct.o isspace.o \ + isupper.o isxdigit.o toascii.o tolower.o toupper.o \ + isblank.o isxlower.o isxupper.o + +ifeq ($(UCLIBC_HAS_CTYPE_TABLES),y) +MOBJ+= __C_ctype_b.o __C_ctype_tolower.o __C_ctype_toupper.o \ + __ctype_b_loc.o __ctype_tolower_loc.o __ctype_toupper_loc.o \ + __ctype_assert.o isctype.o +endif + +MOBJx= isalnum_l.o isalpha_l.o isascii_l.o iscntrl_l.o isdigit_l.o \ + isgraph_l.o islower_l.o isprint_l.o ispunct_l.o isspace_l.o \ + isupper_l.o isxdigit_l.o toascii_l.o tolower_l.o toupper_l.o \ + isblank_l.o # isxlower_l.o isxupper_l.o + +MISC_CTYPE_DIR:=$(top_srcdir)libc/misc/ctype +MISC_CTYPE_OUT:=$(top_builddir)libc/misc/ctype + +MISC_CTYPE_MSRC:=$(MISC_CTYPE_DIR)/$(MSRC) +MISC_CTYPE_MOBJ:=$(patsubst %.o,$(MISC_CTYPE_OUT)/%.o,$(MOBJ)) +MISC_CTYPE_MOBJx=$(patsubst %.o,$(MISC_CTYPE_OUT)/%.o,$(MOBJx)) + +# adapt this if MOBJx is done for multi +MISC_CTYPE_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(MISC_CTYPE_MOBJ)))) + +$(MISC_CTYPE_MOBJ) $(MISC_CTYPE_MOBJ:.o=.os): $(MISC_CTYPE_MSRC) + $(compile.m) + +$(MISC_CTYPE_MOBJx) $(MISC_CTYPE_MOBJx:.o=.os): $(MISC_CTYPE_MSRC) + $(compile.m) -D__UCLIBC_DO_XLOCALE + +libc-a-y+=$(MISC_CTYPE_MOBJ) +libc-a-$(UCLIBC_HAS_XLOCALE)+=$(MISC_CTYPE_MOBJx) +libc-a-pic-y+=$(MISC_CTYPE_MOBJ:.o=.os) +libc-a-pic-$(UCLIBC_HAS_XLOCALE)+=$(MISC_CTYPE_MOBJx:.o=.os) +libc-so-y+=$(MISC_CTYPE_MOBJ:.o=.os) +libc-so-$(UCLIBC_HAS_XLOCALE)+=$(MISC_CTYPE_MOBJx:.o=.os) + +CFLAGS-multi-y+=$(MISC_CTYPE_DEF) +libc-multi-y+=$(MISC_CTYPE_MSRC) +libc-nomulti-$(UCLIBC_HAS_XLOCALE)+=$(MISC_CTYPE_MOBJx) + +objclean-y+=misc_ctype_objclean + +misc_ctype_objclean: + $(RM) $(MISC_CTYPE_OUT)/*.{o,os} diff --git a/libc/misc/dirent/Makefile.in b/libc/misc/dirent/Makefile.in new file mode 100644 index 000000000..8ba28cdeb --- /dev/null +++ b/libc/misc/dirent/Makefile.in @@ -0,0 +1,28 @@ +# Makefile for uClibc +# +# Copyright (C) 2001 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:= alphasort.c closedir.c dirfd.c opendir.c readdir.c rewinddir.c scandir.c \ + seekdir.c telldir.c readdir64.c alphasort64.c scandir64.c readdir_r.c \ + readdir64_r.c + +MISC_DIRENT_DIR:=$(top_srcdir)libc/misc/dirent +MISC_DIRENT_OUT:=$(top_builddir)libc/misc/dirent + +MISC_DIRENT_SRC:=$(patsubst %.c,$(MISC_DIRENT_DIR)/%.c,$(CSRC)) +MISC_DIRENT_OBJ:=$(patsubst %.c,$(MISC_DIRENT_OUT)/%.o,$(CSRC)) + +libc-a-y+=$(MISC_DIRENT_OBJ) +libc-a-pic-y+=$(MISC_DIRENT_OBJ:.o=.os) +libc-so-y+=$(MISC_DIRENT_OBJ:.o=.os) + +libc-multi-y+=$(MISC_DIRENT_SRC) + +objclean-y+=misc_dirent_objclean + +misc_dirent_objclean: + $(RM) $(MISC_DIRENT_OUT)/*.{o,os} diff --git a/libc/misc/error/Makefile.in b/libc/misc/error/Makefile.in new file mode 100644 index 000000000..86bf881fa --- /dev/null +++ b/libc/misc/error/Makefile.in @@ -0,0 +1,25 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=error.c err.c + +MISC_ERROR_DIR:=$(top_srcdir)libc/misc/error +MISC_ERROR_OUT:=$(top_builddir)libc/misc/error + +MISC_ERROR_SRC:=$(patsubst %.c,$(MISC_ERROR_DIR)/%.c,$(CSRC)) +MISC_ERROR_OBJ:=$(patsubst %.c,$(MISC_ERROR_OUT)/%.o,$(CSRC)) + +libc-a-y+=$(MISC_ERROR_OBJ) +libc-a-pic-y+=$(MISC_ERROR_OBJ:.o=.os) +libc-so-y+=$(MISC_ERROR_OBJ:.o=.os) + +libc-multi-y+=$(MISC_ERROR_SRC) + +objclean-y+=misc_error_objclean + +misc_error_objclean: + $(RM) $(MISC_ERROR_OUT)/*.{o,os} diff --git a/libc/misc/file/Makefile.in b/libc/misc/file/Makefile.in new file mode 100644 index 000000000..76eff7868 --- /dev/null +++ b/libc/misc/file/Makefile.in @@ -0,0 +1,27 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MISC_FILE_DIR:=$(top_srcdir)libc/misc/file +MISC_FILE_OUT:=$(top_builddir)libc/misc/file + +MISC_FILE_SRC:=$(wildcard $(MISC_FILE_DIR)/*.c) +ifneq ($(UCLIBC_HAS_LFS),y) +MISC_FILE_SRC:=$(filter-out $(MISC_FILE_DIR)/lockf64.c,$(MISC_FILE_SRC)) +endif +MISC_FILE_OBJ:=$(patsubst $(MISC_FILE_DIR)/%.c,$(MISC_FILE_OUT)/%.o,$(MISC_FILE_SRC)) + +libc-a-y+=$(MISC_FILE_OBJ) +libc-a-pic-y+=$(MISC_FILE_OBJ:.o=.os) +libc-so-y+=$(MISC_FILE_OBJ:.o=.os) + +libc-multi-y+=$(MISC_FILE_SRC) + +objclean-y+=misc_file_objclean + +misc_file_objclean: + $(RM) $(MISC_FILE_OUT)/*.{o,os} diff --git a/libc/misc/fnmatch/Makefile.in b/libc/misc/fnmatch/Makefile.in new file mode 100644 index 000000000..24019dede --- /dev/null +++ b/libc/misc/fnmatch/Makefile.in @@ -0,0 +1,24 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MISC_FNMATCH_DIR:=$(top_srcdir)libc/misc/fnmatch +MISC_FNMATCH_OUT:=$(top_builddir)libc/misc/fnmatch + +MISC_FNMATCH_SRC:=$(MISC_FNMATCH_DIR)/fnmatch.c +MISC_FNMATCH_OBJ:=$(MISC_FNMATCH_OUT)/fnmatch.o + +libc-a-y+=$(MISC_FNMATCH_OBJ) +libc-a-pic-y+=$(MISC_FNMATCH_OBJ:.o=.os) +libc-so-y+=$(MISC_FNMATCH_OBJ:.o=.os) + +libc-multi-y+=$(MISC_FNMATCH_SRC) + +objclean-y+=misc_fnmatch_objclean + +misc_fnmatch_objclean: + $(RM) $(MISC_FNMATCH_OUT)/*.{o,os} diff --git a/libc/misc/ftw/Makefile.in b/libc/misc/ftw/Makefile.in new file mode 100644 index 000000000..2f92ef0ec --- /dev/null +++ b/libc/misc/ftw/Makefile.in @@ -0,0 +1,38 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC:=ftw.c +MOBJ:=ftw.o ftw64.o + +MISC_FTW_DIR:=$(top_srcdir)libc/misc/ftw +MISC_FTW_OUT:=$(top_builddir)libc/misc/ftw + +# ftw.c has to be rewritten to allow multi +MISC_FTW_NO_MULTI:=ftw64.o +MOBJ:=$(filter-out $(MISC_FTW_NO_MULTI),$(MOBJ)) + +MISC_FTW_MSRC:=$(MISC_FTW_DIR)/$(MSRC) +MISC_FTW_MOBJ:=$(patsubst %.o,$(MISC_FTW_OUT)/%.o,$(MOBJ)) +MISC_FTW_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(MISC_FTW_MOBJ)))) + +MISC_FTW_OBJS:=$(MISC_FTW_MOBJ) $(MISC_FTW_OUT)/$(MISC_FTW_NO_MULTI) + +$(MISC_FTW_OBJS) $(MISC_FTW_OBJS:.o=.os): $(MISC_FTW_MSRC) + $(compile.m) + +libc-a-$(UCLIBC_HAS_FTW)+=$(MISC_FTW_OBJS) +libc-a-pic-$(UCLIBC_HAS_FTW)+=$(MISC_FTW_OBJS:.o=.os) +libc-so-$(UCLIBC_HAS_FTW)+=$(MISC_FTW_OBJS:.o=.os) + +CFLAGS-multi-$(UCLIBC_HAS_FTW)+=$(MISC_FTW_DEF) +libc-multi-$(UCLIBC_HAS_FTW)+=$(MISC_FTW_MSRC) +libc-nomulti-$(UCLIBC_HAS_FTW)+=$(MISC_FTW_OUT)/$(MISC_FTW_NO_MULTI) + +objclean-y+=misc_ftw_objclean + +misc_ftw_objclean: + $(RM) $(MISC_FTW_OUT)/*.{o,os} diff --git a/libc/misc/glob/Makefile.in b/libc/misc/glob/Makefile.in new file mode 100644 index 000000000..c17086fde --- /dev/null +++ b/libc/misc/glob/Makefile.in @@ -0,0 +1,30 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=glob.c glob64.c glob-hooks.c + +MISC_GLOB_DIR:=$(top_srcdir)libc/misc/glob +MISC_GLOB_OUT:=$(top_builddir)libc/misc/glob + +MISC_GLOB_SRC:=$(patsubst %.c,$(MISC_GLOB_DIR)/%.c,$(CSRC)) +MISC_GLOB_OBJ:=$(patsubst %.c,$(MISC_GLOB_OUT)/%.o,$(CSRC)) + +$(MISC_GLOB_OUT)/glob64.o $(MISC_GLOB_OUT)/glob64.os: $(MISC_GLOB_DIR)/glob64.c $(MISC_GLOB_DIR)/glob.c + +libc-a-$(UCLIBC_HAS_GLOB)+=$(MISC_GLOB_OBJ) +libc-a-pic-$(UCLIBC_HAS_GLOB)+=$(MISC_GLOB_OBJ:.o=.os) +libc-so-$(UCLIBC_HAS_GLOB)+=$(MISC_GLOB_OBJ:.o=.os) + +# glob has to be rewritten to allow multi +#libc-multi-$(UCLIBC_HAS_GLOB)+=$(MISC_GLOB_SRC) +libc-nomulti-$(UCLIBC_HAS_GLOB)+=$(MISC_GLOB_OBJ) + +objclean-y+=misc_glob_objclean + +misc_glob_objclean: + $(RM) $(MISC_GLOB_OUT)/*.{o,os} diff --git a/libc/misc/gnu/Makefile.in b/libc/misc/gnu/Makefile.in new file mode 100644 index 000000000..263b45713 --- /dev/null +++ b/libc/misc/gnu/Makefile.in @@ -0,0 +1,26 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=obstack.c + +MISC_GNU_DIR:=$(top_srcdir)libc/misc/gnu +MISC_GNU_OUT:=$(top_builddir)libc/misc/gnu + +MISC_GNU_SRC:=$(MISC_GNU_DIR)/obstack.c +MISC_GNU_OBJ:=$(MISC_GNU_OUT)/obstack.o + +libc-a-y+=$(MISC_GNU_OBJ) +libc-a-pic-y+=$(MISC_GNU_OBJ:.o=.os) +libc-so-y+=$(MISC_GNU_OBJ:.o=.os) + +libc-multi-y+=$(MISC_GNU_SRC) + +objclean-y+=misc_gnu_objclean + +misc_gnu_objclean: + $(RM) $(MISC_GNU_OUT)/*.{o,os} diff --git a/libc/misc/internals/Makefile.in b/libc/misc/internals/Makefile.in new file mode 100644 index 000000000..de611323e --- /dev/null +++ b/libc/misc/internals/Makefile.in @@ -0,0 +1,41 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CFLAGS-__uClibc_main.c=$(SSP_DISABLE_FLAGS) + +CSRC:=__uClibc_main.c tempname.c errno.c __errno_location.c __h_errno_location.c + +MISC_INTERNALS_DIR:=$(top_srcdir)libc/misc/internals +MISC_INTERNALS_OUT:=$(top_builddir)libc/misc/internals + +MISC_INTERNALS_SRC:=$(patsubst %.c,$(MISC_INTERNALS_DIR)/%.c,$(CSRC)) +MISC_INTERNALS_OBJ:=$(patsubst %.c,$(MISC_INTERNALS_OUT)/%.o,$(CSRC)) + +MISC_INTERNALS_OBJS:=$(MISC_INTERNALS_OBJ) $(MISC_INTERNALS_OUT)/static.o + +$(MISC_INTERNALS_OUT)/interp.c: $(MISC_INTERNALS_DIR)/Makefile.in + echo "/* Force shared libraries to know about the correct library loader */" > $@ + echo "#include <features.h>" >> $@ + echo "#ifdef __HAVE_ELF__" >> $@ + echo "const char __dl_ldso__[] __attribute__ ((section " \ + "(\".interp\"))) =\""$(SHARED_LIB_LOADER_PREFIX)/$(UCLIBC_LDSO)"\";" >> $@ + echo "#endif" >> $@ + +libc-a-y+=$(MISC_INTERNALS_OBJS) +libc-a-pic-y+=$(MISC_INTERNALS_OBJS:.o=.os) +# this is OBJ, not OBJS !!!, static does not go into .so +libc-so-y+=$(MISC_INTERNALS_OBJ:.o=.os) +other-y+=$(MISC_INTERNALS_OUT)/interp.os + +libc-multi-y+=$(filter-out $(MISC_INTERNALS_DIR)/__uClibc_main.c,$(MISC_INTERNALS_SRC)) +libc-nomulti-y+=$(MISC_INTERNALS_OUT)/__uClibc_main.o + +objclean-y+=misc_internals_objclean + +misc_internals_objclean: + $(RM) $(MISC_INTERNALS_OUT)/{*.{o,os},interp.c} diff --git a/libc/misc/intl/Makefile.in b/libc/misc/intl/Makefile.in new file mode 100644 index 000000000..40eadfa1b --- /dev/null +++ b/libc/misc/intl/Makefile.in @@ -0,0 +1,33 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC:=intl.c +MOBJ:= __uClibc_dgettext.o __uClibc_dcgettext.o \ + __uClibc_textdomain.o __uClibc_bindtextdomain.o # for libstd++ + +MISC_INTL_DIR:=$(top_srcdir)libc/misc/intl +MISC_INTL_OUT:=$(top_builddir)libc/misc/intl + +MISC_INTL_MSRC:=$(MISC_INTL_DIR)/$(MSRC) +MISC_INTL_MOBJ:=$(patsubst %.o,$(MISC_INTL_OUT)/%.o,$(MOBJ)) +MISC_INTL_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(MISC_INTL_MOBJ)))) + +$(MISC_INTL_MOBJ) $(MISC_INTL_MOBJ:.o=.os): $(MISC_INTL_MSRC) + $(compile.m) + +libc-a-$(UCLIBC_HAS_GETTEXT_AWARENESS)+=$(MISC_INTL_MOBJ) +libc-a-pic-$(UCLIBC_HAS_GETTEXT_AWARENESS)+=$(MISC_INTL_MOBJ:.o=.os) +libc-so-$(UCLIBC_HAS_GETTEXT_AWARENESS)+=$(MISC_INTL_MOBJ:.o=.os) + +CFLAGS-multi-$(UCLIBC_HAS_GETTEXT_AWARENESS)+=$(MISC_INTL_DEF) +libc-multi-$(UCLIBC_HAS_GETTEXT_AWARENESS)+=$(MISC_INTL_MSRC) + +objclean-y+=misc_intl_objclean + +misc_intl_objclean: + $(RM) $(MISC_INTL_OUT)/*.{o,os} diff --git a/libc/misc/locale/Makefile.in b/libc/misc/locale/Makefile.in new file mode 100644 index 000000000..f93abef33 --- /dev/null +++ b/libc/misc/locale/Makefile.in @@ -0,0 +1,61 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC:=locale.c +MOBJ:=setlocale.o localeconv.o _locale_init.o nl_langinfo.o +MOBJx= + +ifeq ($(UCLIBC_HAS_LOCALE),y) +MOBJ+=newlocale.o __locale_mbrtowc_l.o +endif + +ifeq ($(UCLIBC_HAS_XLOCALE),y) +MOBJx+=nl_langinfo_l.o duplocale.o freelocale.o uselocale.o __curlocale.o +endif + +DATA= +ifeq ($(UCLIBC_HAS_LOCALE),y) +DATA:=locale_data.o +endif + +MISC_LOCALE_DIR:=$(top_srcdir)libc/misc/locale +MISC_LOCALE_OUT:=$(top_builddir)libc/misc/locale + +MISC_LOCALE_MSRC:=$(MISC_LOCALE_DIR)/$(MSRC) +MISC_LOCALE_MOBJ:=$(patsubst %.o,$(MISC_LOCALE_OUT)/%.o,$(MOBJ)) +MISC_LOCALE_MOBJx=$(patsubst %.o,$(MISC_LOCALE_OUT)/%.o,$(MOBJx)) +MISC_LOCALE_DATA=$(patsubst %.o,$(MISC_LOCALE_OUT)/%.o,$(DATA)) + +MISC_LOCALE_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(MISC_LOCALE_MOBJ)))) + +$(MISC_LOCALE_MOBJ) $(MISC_LOCALE_MOBJ:.o=.os): $(MISC_LOCALE_MSRC) + $(compile.m) + +$(MISC_LOCALE_MOBJx) $(MISC_LOCALE_MOBJx:.o=.os): $(MISC_LOCALE_MSRC) + $(compile.m) -D__UCLIBC_DO_XLOCALE + +$(MISC_LOCALE_DATA) $(MISC_LOCALE_DATA:.o=.os): $(top_builddir)extra/locale/$(notdir $(MISC_LOCALE_DATA:.o=.c)) + $(compile.c) -D__WCHAR_ENABLED -I$< + +libc-a-y+=$(MISC_LOCALE_MOBJ) +libc-a-$(UCLIBC_HAS_XLOCALE)+=$(MISC_LOCALE_MOBJx) +libc-a-pic-y+=$(MISC_LOCALE_MOBJ:.o=.os) +libc-a-pic-$(UCLIBC_HAS_XLOCALE)+=$(MISC_LOCALE_MOBJx:.o=.os) +libc-so-y+=$(MISC_LOCALE_MOBJ:.o=.os) +libc-so-$(UCLIBC_HAS_XLOCALE)+=$(MISC_LOCALE_MOBJx:.o=.os) + +#CFLAGS-multi-y+=$(MISC_LOCALE_DEF) +#libc-multi-y+=$(MISC_LOCALE_MSRC) +libc-nomulti-y+=$(MISC_LOCALE_MOBJ) +libc-nomulti-$(UCLIBC_HAS_LOCALE)+=$(MISC_LOCALE_DATA) +libc-nomulti-$(UCLIBC_HAS_XLOCALE)+=$(MISC_LOCALE_MOBJx) + +objclean-y+=misc_locale_objclean + +misc_locale_objclean: + $(RM) $(MISC_LOCALE_OUT)/{*.{o,os},locale_data.c} diff --git a/libc/misc/mntent/Makefile.in b/libc/misc/mntent/Makefile.in new file mode 100644 index 000000000..cdb8acd5e --- /dev/null +++ b/libc/misc/mntent/Makefile.in @@ -0,0 +1,26 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=mntent.c + +MISC_MNTENT_DIR:=$(top_srcdir)libc/misc/mntent +MISC_MNTENT_OUT:=$(top_builddir)libc/misc/mntent + +MISC_MNTENT_SRC:=$(MISC_MNTENT_DIR)/mntent.c +MISC_MNTENT_OBJ:=$(MISC_MNTENT_OUT)/mntent.o + +libc-a-y+=$(MISC_MNTENT_OBJ) +libc-a-pic-y+=$(MISC_MNTENT_OBJ:.o=.os) +libc-so-y+=$(MISC_MNTENT_OBJ:.o=.os) + +libc-multi-y+=$(MISC_MNTENT_SRC) + +objclean-y+=misc_mntent_objclean + +misc_mntent_objclean: + $(RM) $(MISC_MNTENT_OUT)/*.{o,os} diff --git a/libc/misc/pthread/Makefile.in b/libc/misc/pthread/Makefile.in new file mode 100644 index 000000000..0bcb1496b --- /dev/null +++ b/libc/misc/pthread/Makefile.in @@ -0,0 +1,26 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=no-tsd.c weaks.c + +MISC_PTHREAD_DIR:=$(top_srcdir)libc/misc/pthread +MISC_PTHREAD_OUT:=$(top_builddir)libc/misc/pthread + +MISC_PTHREAD_SRC:=$(patsubst %.c,$(MISC_PTHREAD_DIR)/%.c,$(CSRC)) +MISC_PTHREAD_OBJ:=$(patsubst %.c,$(MISC_PTHREAD_OUT)/%.o,$(CSRC)) + +libc-a-$(UCLIBC_HAS_THREADS)+=$(MISC_PTHREAD_OBJ) +libc-a-pic-$(UCLIBC_HAS_THREADS)+=$(MISC_PTHREAD_OBJ:.o=.os) +libc-so-$(UCLIBC_HAS_THREADS)+=$(MISC_PTHREAD_OBJ:.o=.os) + +#libc-multi-$(UCLIBC_HAS_THREADS)+=$(MISC_PTHREAD_SRC) +libc-nomulti-$(UCLIBC_HAS_THREADS)+=$(MISC_PTHREAD_OBJ) + +objclean-y+=misc_pthread_objclean + +misc_pthread_objclean: + $(RM) $(MISC_PTHREAD_OUT)/*.{o,os} diff --git a/libc/misc/regex/Makefile.in b/libc/misc/regex/Makefile.in new file mode 100644 index 000000000..6909e6246 --- /dev/null +++ b/libc/misc/regex/Makefile.in @@ -0,0 +1,26 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=regex.c + +MISC_REGEX_DIR:=$(top_srcdir)libc/misc/regex +MISC_REGEX_OUT:=$(top_builddir)libc/misc/regex + +MISC_REGEX_SRC:=$(patsubst %.c,$(MISC_REGEX_DIR)/%.c,$(CSRC)) +MISC_REGEX_OBJ:=$(patsubst %.c,$(MISC_REGEX_OUT)/%.o,$(CSRC)) + +libc-a-$(UCLIBC_HAS_REGEX)+=$(MISC_REGEX_OBJ) +libc-a-pic-$(UCLIBC_HAS_REGEX)+=$(MISC_REGEX_OBJ:.o=.os) +libc-so-$(UCLIBC_HAS_REGEX)+=$(MISC_REGEX_OBJ:.o=.os) + +libc-multi-$(UCLIBC_HAS_REGEX)+=$(MISC_REGEX_SRC) + +objclean-y+=misc_regex_objclean + +misc_regex_objclean: + $(RM) $(MISC_REGEX_OUT)/*.{o,os} diff --git a/libc/misc/search/Makefile.in b/libc/misc/search/Makefile.in new file mode 100644 index 000000000..b762db6e0 --- /dev/null +++ b/libc/misc/search/Makefile.in @@ -0,0 +1,66 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC1:=tsearch.c +MOBJ1:=tsearch.o tfind.o tdelete.o twalk.o tdestroy.o + +MSRC2:=lsearch.c +MOBJ2:=lfind.o lsearch.o + +MSRC3:=insremque.c +MOBJ3:=insque.o remque.o + +MSRC4:=hsearch_r.c +MOBJ4:=hcreate_r.o hdestroy_r.o hsearch_r.o + +CSRC:=hsearch.c + +MISC_SEARCH_DIR:=$(top_srcdir)libc/misc/search +MISC_SEARCH_OUT:=$(top_builddir)libc/misc/search + +MISC_SEARCH_SRC:=$(patsubst %.c,$(MISC_SEARCH_DIR)/%.c,$(CSRC)) +MISC_SEARCH_OBJ:=$(patsubst %.c,$(MISC_SEARCH_OUT)/%.o,$(CSRC)) + +MISC_SEARCH_MSRC1:=$(MISC_SEARCH_DIR)/$(MSRC1) +MISC_SEARCH_MSRC2:=$(MISC_SEARCH_DIR)/$(MSRC2) +MISC_SEARCH_MSRC3:=$(MISC_SEARCH_DIR)/$(MSRC3) +MISC_SEARCH_MSRC4:=$(MISC_SEARCH_DIR)/$(MSRC4) +MISC_SEARCH_MOBJ1:=$(patsubst %.o,$(MISC_SEARCH_OUT)/%.o,$(MOBJ1)) +MISC_SEARCH_MOBJ2:=$(patsubst %.o,$(MISC_SEARCH_OUT)/%.o,$(MOBJ2)) +MISC_SEARCH_MOBJ3:=$(patsubst %.o,$(MISC_SEARCH_OUT)/%.o,$(MOBJ3)) +MISC_SEARCH_MOBJ4:=$(patsubst %.o,$(MISC_SEARCH_OUT)/%.o,$(MOBJ4)) + +MISC_SEARCH_MSRC:=$(MISC_SEARCH_MSRC1) $(MISC_SEARCH_MSRC2) $(MISC_SEARCH_MSRC3) $(MISC_SEARCH_MSRC4) +MISC_SEARCH_MOBJ:=$(MISC_SEARCH_MOBJ1) $(MISC_SEARCH_MOBJ2) $(MISC_SEARCH_MOBJ3) $(MISC_SEARCH_MOBJ4) +MISC_SEARCH_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(MISC_SEARCH_MOBJ)))) + +MISC_SEARCH_OBJS:=$(MISC_SEARCH_OBJ) $(MISC_SEARCH_MOBJ) + +$(MISC_SEARCH_MOBJ1) $(MISC_SEARCH_MOBJ1:.o=.os): $(MISC_SEARCH_MSRC1) + $(compile.m) + +$(MISC_SEARCH_MOBJ2) $(MISC_SEARCH_MOBJ2:.o=.os): $(MISC_SEARCH_MSRC2) + $(compile.m) + +$(MISC_SEARCH_MOBJ3) $(MISC_SEARCH_MOBJ3:.o=.os): $(MISC_SEARCH_MSRC3) + $(compile.m) + +$(MISC_SEARCH_MOBJ4) $(MISC_SEARCH_MOBJ4:.o=.os): $(MISC_SEARCH_MSRC4) + $(compile.m) + +libc-a-y+=$(MISC_SEARCH_OBJS) +libc-a-pic-y+=$(MISC_SEARCH_OBJS:.o=.os) +libc-so-y+=$(MISC_SEARCH_OBJS:.o=.os) + +CFLAGS-multi-y+=$(MISC_SEARCH_DEF) +libc-multi-y+=$(MISC_SEARCH_SRC) $(MISC_SEARCH_MSRC) + +objclean-y+=misc_search_objclean + +misc_search_objclean: + $(RM) $(MISC_SEARCH_OUT)/*.{o,os} diff --git a/libc/misc/statfs/Makefile.in b/libc/misc/statfs/Makefile.in new file mode 100644 index 000000000..2adb20f1d --- /dev/null +++ b/libc/misc/statfs/Makefile.in @@ -0,0 +1,28 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=statvfs.c fstatvfs.c +ifeq ($(UCLIBC_HAS_LFS),y) +CSRC+=fstatfs64.c statfs64.c statvfs64.c fstatvfs64.c +endif + +MISC_STATFS_DIR:=$(top_srcdir)libc/misc/statfs +MISC_STATFS_OUT:=$(top_builddir)libc/misc/statfs + +MISC_STATFS_SRC:=$(patsubst %.c,$(MISC_STATFS_DIR)/%.c,$(CSRC)) +MISC_STATFS_OBJ:=$(patsubst %.c,$(MISC_STATFS_OUT)/%.o,$(CSRC)) + +libc-a-y+=$(MISC_STATFS_OBJ) +libc-a-pic-y+=$(MISC_STATFS_OBJ:.o=.os) +libc-so-y+=$(MISC_STATFS_OBJ:.o=.os) + +libc-multi-y+=$(MISC_STATFS_SRC) + +objclean-y+=misc_statfs_objclean + +misc_statfs_objclean: + $(RM) $(MISC_STATFS_OUT)/*.{o,os} diff --git a/libc/misc/syslog/Makefile.in b/libc/misc/syslog/Makefile.in new file mode 100644 index 000000000..bc6cb0710 --- /dev/null +++ b/libc/misc/syslog/Makefile.in @@ -0,0 +1,26 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=syslog.c + +MISC_SYSLOG_DIR:=$(top_srcdir)libc/misc/syslog +MISC_SYSLOG_OUT:=$(top_builddir)libc/misc/syslog + +MISC_SYSLOG_SRC:=$(patsubst %.c,$(MISC_SYSLOG_DIR)/%.c,$(CSRC)) +MISC_SYSLOG_OBJ:=$(patsubst %.c,$(MISC_SYSLOG_OUT)/%.o,$(CSRC)) + +libc-a-y+=$(MISC_SYSLOG_OBJ) +libc-a-pic-y+=$(MISC_SYSLOG_OBJ:.o=.os) +libc-so-y+=$(MISC_SYSLOG_OBJ:.o=.os) + +libc-multi-y+=$(MISC_SYSLOG_SRC) + +objclean-y+=misc_syslog_objclean + +misc_syslog_objclean: + $(RM) $(MISC_SYSLOG_OUT)/*.{o,os} diff --git a/libc/misc/sysvipc/Makefile.in b/libc/misc/sysvipc/Makefile.in new file mode 100644 index 000000000..73cc932aa --- /dev/null +++ b/libc/misc/sysvipc/Makefile.in @@ -0,0 +1,62 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC1:=sem.c +MOBJ1:=semget.o semctl.o semop.o + +MSRC2:=shm.c +MOBJ2:=shmat.o shmctl.o shmdt.o shmget.o + +MSRC3:=msgq.c +MOBJ3:=msgctl.o msgget.o msgrcv.o msgsnd.o + +CSRC:=ftok.c + +MISC_SYSVIPC_DIR:=$(top_srcdir)libc/misc/sysvipc +MISC_SYSVIPC_OUT:=$(top_builddir)libc/misc/sysvipc + +MISC_SYSVIPC_SRC:=$(patsubst %.c,$(MISC_SYSVIPC_DIR)/%.c,$(CSRC)) +MISC_SYSVIPC_OBJ:=$(patsubst %.c,$(MISC_SYSVIPC_OUT)/%.o,$(CSRC)) + +MISC_SYSVIPC_NO_MULTI:=$(MOBJ1) $(MOBJ3) + +MISC_SYSVIPC_MSRC1:=$(patsubst %.c,$(MISC_SYSVIPC_DIR)/%.c,$(MSRC1)) +MISC_SYSVIPC_MSRC2:=$(patsubst %.c,$(MISC_SYSVIPC_DIR)/%.c,$(MSRC2)) +MISC_SYSVIPC_MSRC3:=$(patsubst %.c,$(MISC_SYSVIPC_DIR)/%.c,$(MSRC3)) +MISC_SYSVIPC_MOBJ1:=$(patsubst %.o,$(MISC_SYSVIPC_OUT)/%.o,$(MOBJ1)) +MISC_SYSVIPC_MOBJ2:=$(patsubst %.o,$(MISC_SYSVIPC_OUT)/%.o,$(MOBJ2)) +MISC_SYSVIPC_MOBJ3:=$(patsubst %.o,$(MISC_SYSVIPC_OUT)/%.o,$(MOBJ3)) + +MISC_SYSVIPC_MSRC:=$(MISC_SYSVIPC_MSRC1) $(MISC_SYSVIPC_MSRC2) $(MISC_SYSVIPC_MSRC3) +MISC_SYSVIPC_MOBJ:=$(MISC_SYSVIPC_MOBJ1) $(MISC_SYSVIPC_MOBJ2) $(MISC_SYSVIPC_MOBJ3) +# only MSRC2 +MISC_SYSVIPC_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(MISC_SYSVIPC_MOBJ2)))) + +MISC_SYSVIPC_OBJS:=$(MISC_SYSVIPC_OBJ) $(MISC_SYSVIPC_MOBJ) + +$(MISC_SYSVIPC_MOBJ1) $(MISC_SYSVIPC_MOBJ1:.o=.os): $(MISC_SYSVIPC_MSRC1) + $(compile.m) + +$(MISC_SYSVIPC_MOBJ2) $(MISC_SYSVIPC_MOBJ2:.o=.os): $(MISC_SYSVIPC_MSRC2) + $(compile.m) + +$(MISC_SYSVIPC_MOBJ3) $(MISC_SYSVIPC_MOBJ3:.o=.os): $(MISC_SYSVIPC_MSRC3) + $(compile.m) + +libc-a-y+=$(MISC_SYSVIPC_OBJS) +libc-a-pic-y+=$(MISC_SYSVIPC_OBJS:.o=.os) +libc-so-y+=$(MISC_SYSVIPC_OBJS:.o=.os) + +CFLAGS-multi-y+=$(MISC_SYSVIPC_DEF) +libc-multi-y+=$(MISC_SYSVIPC_SRC) $(MISC_SYSVIPC_MSRC2) +libc-nomulti-y+=$(MISC_SYSVIPC_MOBJ1) $(MISC_SYSVIPC_MOBJ3) + +objclean-y+=misc_sysvipc_objclean + +misc_sysvipc_objclean: + $(RM) $(MISC_SYSVIPC_OUT)/*.{o,os} diff --git a/libc/misc/time/Makefile.in b/libc/misc/time/Makefile.in new file mode 100644 index 000000000..986e5ed29 --- /dev/null +++ b/libc/misc/time/Makefile.in @@ -0,0 +1,69 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC:=time.c +MOBJ:= asctime.o asctime_r.o clock.o ctime.o ctime_r.o gmtime.o gmtime_r.o \ + localtime.o localtime_r.o mktime.o strftime.o strptime.o tzset.o \ + _time_t2tm.o __time_tm.o _time_mktime.o dysize.o timegm.o \ + _time_mktime_tzi.o _time_localtime_tzi.o +MOBJx= + +ifeq ($(UCLIBC_HAS_FLOATS),y) +MOBJ+=difftime.o +endif +ifeq ($(UCLIBC_HAS_XLOCALE),y) +MOBJx+=strftime_l.o strptime_l.o +endif + +ifeq ($(UCLIBC_HAS_WCHAR),y) +MOBJ+=wcsftime.o +ifeq ($(UCLIBC_HAS_XLOCALE),y) +MOBJx+=wcsftime_l.o +endif +endif + +CSRC:=adjtime.c ftime.c + +MISC_TIME_DIR:=$(top_srcdir)libc/misc/time +MISC_TIME_OUT:=$(top_builddir)libc/misc/time + +MISC_TIME_NO_MULTI:=strftime.o + +MISC_TIME_SRC:=$(patsubst %.c,$(MISC_TIME_DIR)/%.c,$(CSRC)) +MISC_TIME_OBJ:=$(patsubst %.c,$(MISC_TIME_OUT)/%.o,$(CSRC)) + +MISC_TIME_MSRC:=$(patsubst %.c,$(MISC_TIME_DIR)/%.c,$(MSRC)) +MISC_TIME_MOBJ:=$(patsubst %.o,$(MISC_TIME_OUT)/%.o,$(MOBJ)) +MISC_TIME_MOBJx=$(patsubst %.o,$(MISC_TIME_OUT)/%.o,$(MOBJx)) + +MISC_TIME_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(filter-out $(MISC_TIME_OUT)/$(MISC_TIME_NO_MULTI),$(MISC_TIME_MOBJ))))) + +MISC_TIME_OBJS:=$(MISC_TIME_OBJ) $(MISC_TIME_MOBJ) + +$(MISC_TIME_MOBJ) $(MISC_TIME_MOBJ:.o=.os): $(MISC_TIME_MSRC) + $(compile.m) + +$(MISC_TIME_MOBJx) $(MISC_TIME_MOBJx:.o=.os): $(MISC_TIME_MSRC) + $(compile.m) -D__UCLIBC_DO_XLOCALE + +libc-a-y+=$(MISC_TIME_OBJS) +libc-a-$(UCLIBC_HAS_XLOCALE)+=$(MISC_TIME_MOBJx) +libc-a-pic-y+=$(MISC_TIME_OBJS:.o=.os) +libc-a-pic-$(UCLIBC_HAS_XLOCALE)+=$(MISC_TIME_MOBJx:.o=.os) +libc-so-y+=$(MISC_TIME_OBJS:.o=.os) +libc-so-$(UCLIBC_HAS_XLOCALE)+=$(MISC_TIME_MOBJx:.o=.os) + +CFLAGS-multi-y+=$(MISC_TIME_DEF) +libc-multi-y+=$(MISC_TIME_MSRC) +libc-nomulti-y+=$(MISC_TIME_OUT)/$(MISC_TIME_NO_MULTI) +libc-nomulti-$(UCLIBC_HAS_XLOCALE)+=$(MISC_TIME_MOBJx) + +objclean-y+=misc_time_objclean + +misc_time_objclean: + $(RM) $(MISC_TIME_OUT)/*.{o,os} diff --git a/libc/misc/ttyent/Makefile.in b/libc/misc/ttyent/Makefile.in new file mode 100644 index 000000000..e653ef2c1 --- /dev/null +++ b/libc/misc/ttyent/Makefile.in @@ -0,0 +1,25 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=getttyent.c + +MISC_TTYENT_DIR:=$(top_srcdir)libc/misc/ttyent +MISC_TTYENT_OUT:=$(top_builddir)libc/misc/ttyent + +MISC_TTYENT_SRC:=$(patsubst %.c,$(MISC_TTYENT_DIR)/%.c,$(CSRC)) +MISC_TTYENT_OBJ:=$(patsubst %.c,$(MISC_TTYENT_OUT)/%.o,$(CSRC)) + +libc-a-y+=$(MISC_TTYENT_OBJ) +libc-a-pic-y+=$(MISC_TTYENT_OBJ:.o=.os) +libc-so-y+=$(MISC_TTYENT_OBJ:.o=.os) + +libc-multi-y+=$(MISC_TTYENT_SRC) + +objclean-y+=misc_ttyent_objclean + +misc_ttyent_objclean: + $(RM) $(MISC_TTYENT_OUT)/*.{o,os} diff --git a/libc/misc/utmp/Makefile.in b/libc/misc/utmp/Makefile.in new file mode 100644 index 000000000..6240a160d --- /dev/null +++ b/libc/misc/utmp/Makefile.in @@ -0,0 +1,26 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=utent.c wtent.c + +MISC_UTMP_DIR:=$(top_srcdir)libc/misc/utmp +MISC_UTMP_OUT:=$(top_builddir)libc/misc/utmp + +MISC_UTMP_SRC:=$(patsubst %.c,$(MISC_UTMP_DIR)/%.c,$(CSRC)) +MISC_UTMP_OBJ:=$(patsubst %.c,$(MISC_UTMP_OUT)/%.o,$(CSRC)) + +libc-a-y+=$(MISC_UTMP_OBJ) +libc-a-pic-y+=$(MISC_UTMP_OBJ:.o=.os) +libc-so-y+=$(MISC_UTMP_OBJ:.o=.os) + +libc-multi-y+=$(MISC_UTMP_SRC) + +objclean-y+=misc_utmp_objclean + +misc_utmp_objclean: + $(RM) $(MISC_UTMP_OUT)/*.{o,os} diff --git a/libc/misc/wchar/Makefile.in b/libc/misc/wchar/Makefile.in new file mode 100644 index 000000000..885f2476b --- /dev/null +++ b/libc/misc/wchar/Makefile.in @@ -0,0 +1,49 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +# The stdio and time related wide functions are now built in the normal +# directories. +# +# stdio: +# fwide fgetwc getwchar fgetws fputwc putwchar fputws ungetwc +# getwc (fgetwc alias) getwc_unlocked (fgetwc_unlocked alias) +# putwc (fputwc alias) putwc_unlocked (fputwc_unlocked alias) +# time: +# wcsftime +# + +MSRC:=wchar.c +MOBJ:= btowc.o wctob.o mbsinit.o mbrlen.o mbrtowc.o wcrtomb.o mbsrtowcs.o \ + wcsrtombs.o _wchar_utf8sntowcs.o _wchar_wcsntoutf8s.o \ + __mbsnrtowcs.o __wcsnrtombs.o wcwidth.o wcswidth.o + +ifeq ($(UCLIBC_HAS_LOCALE),y) +MOBJ+=iconv.o +endif + +MISC_WCHAR_DIR:=$(top_srcdir)libc/misc/wchar +MISC_WCHAR_OUT:=$(top_builddir)libc/misc/wchar + +MISC_WCHAR_MSRC:=$(MISC_WCHAR_DIR)/$(MSRC) +MISC_WCHAR_MOBJ:=$(patsubst %.o,$(MISC_WCHAR_OUT)/%.o,$(MOBJ)) +MISC_WCHAR_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(MISC_WCHAR_MOBJ)))) + +$(MISC_WCHAR_MOBJ) $(MISC_WCHAR_MOBJ:.o=.os): $(MISC_WCHAR_MSRC) + $(compile.m) + +libc-a-$(UCLIBC_HAS_WCHAR)+=$(MISC_WCHAR_MOBJ) +libc-a-pic-$(UCLIBC_HAS_WCHAR)+=$(MISC_WCHAR_MOBJ:.o=.os) +libc-so-$(UCLIBC_HAS_WCHAR)+=$(MISC_WCHAR_MOBJ:.o=.os) + +CFLAGS-multi-$(UCLIBC_HAS_WCHAR)+=$(MISC_WCHAR_DEF) +libc-multi-$(UCLIBC_HAS_WCHAR)+=$(MISC_WCHAR_MSRC) + +objclean-y+=misc_wchar_objclean + +misc_wchar_objclean: + $(RM) $(MISC_WCHAR_OUT)/*.{o,os} diff --git a/libc/misc/wctype/Makefile.in b/libc/misc/wctype/Makefile.in new file mode 100644 index 000000000..1db745223 --- /dev/null +++ b/libc/misc/wctype/Makefile.in @@ -0,0 +1,50 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC:=wctype.c +MOBJ:= iswalnum.o iswalpha.o iswcntrl.o iswdigit.o iswgraph.o \ + iswlower.o iswprint.o iswpunct.o iswspace.o iswupper.o \ + iswxdigit.o iswblank.o wctrans.o towctrans.o \ + wctype.o iswctype.o towlower.o towupper.o + +MOBJx= iswalnum_l.o iswalpha_l.o iswcntrl_l.o iswdigit_l.o iswgraph_l.o \ + iswlower_l.o iswprint_l.o iswpunct_l.o iswspace_l.o iswupper_l.o \ + iswxdigit_l.o iswblank_l.o \ + wctype_l.o iswctype_l.o wctrans_l.o towctrans_l.o towlower_l.o towupper_l.o + +MISC_WCTYPE_DIR:=$(top_srcdir)libc/misc/wctype +MISC_WCTYPE_OUT:=$(top_builddir)libc/misc/wctype + +MISC_WCTYPE_MSRC:=$(MISC_WCTYPE_DIR)/$(MSRC) +MISC_WCTYPE_MOBJ:=$(patsubst %.o,$(MISC_WCTYPE_OUT)/%.o,$(MOBJ)) +MISC_WCTYPE_MOBJx=$(patsubst %.o,$(MISC_WCTYPE_OUT)/%.o,$(MOBJx)) + +# adapt this if MOBJx is done for multi +MISC_WCTYPE_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(MISC_WCTYPE_MOBJ)))) + +$(MISC_WCTYPE_MOBJ) $(MISC_WCTYPE_MOBJ:.o=.os): $(MISC_WCTYPE_MSRC) + $(compile.m) + +$(MISC_WCTYPE_MOBJx) $(MISC_WCTYPE_MOBJx:.o=.os): $(MISC_WCTYPE_MSRC) + $(compile.m) -D__UCLIBC_DO_XLOCALE + +libc-a-$(UCLIBC_HAS_WCHAR)+=$(MISC_WCTYPE_MOBJ) +libc-a-$(UCLIBC_HAS_XLOCALE)+=$(MISC_WCTYPE_MOBJx) +libc-a-pic-$(UCLIBC_HAS_WCHAR)+=$(MISC_WCTYPE_MOBJ:.o=.os) +libc-a-pic-$(UCLIBC_HAS_XLOCALE)+=$(MISC_WCTYPE_MOBJx:.o=.os) +libc-so-$(UCLIBC_HAS_WCHAR)+=$(MISC_WCTYPE_MOBJ:.o=.os) +libc-so-$(UCLIBC_HAS_XLOCALE)+=$(MISC_WCTYPE_MOBJx:.o=.os) + +CFLAGS-multi-$(UCLIBC_HAS_WCHAR)+=$(MISC_WCTYPE_DEF) +libc-multi-$(UCLIBC_HAS_WCHAR)+=$(MISC_WCTYPE_MSRC) +libc-nomulti-$(UCLIBC_HAS_XLOCALE)+=$(MISC_WCTYPE_MOBJx) + +objclean-y+=misc_wctype_objclean + +misc_wctype_objclean: + $(RM) $(MISC_WCTYPE_OUT)/*.{o,os} diff --git a/libc/misc/wordexp/Makefile.in b/libc/misc/wordexp/Makefile.in new file mode 100644 index 000000000..c5199fe07 --- /dev/null +++ b/libc/misc/wordexp/Makefile.in @@ -0,0 +1,25 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=wordexp.c + +MISC_WORDEXP_DIR:=$(top_srcdir)libc/misc/wordexp +MISC_WORDEXP_OUT:=$(top_builddir)libc/misc/wordexp + +MISC_WORDEXP_SRC:=$(patsubst %.c,$(MISC_WORDEXP_DIR)/%.c,$(CSRC)) +MISC_WORDEXP_OBJ:=$(patsubst %.c,$(MISC_WORDEXP_OUT)/%.o,$(CSRC)) + +libc-a-$(UCLIBC_HAS_WORDEXP)+=$(MISC_WORDEXP_OBJ) +libc-a-pic-$(UCLIBC_HAS_WORDEXP)+=$(MISC_WORDEXP_OBJ:.o=.os) +libc-so-$(UCLIBC_HAS_WORDEXP)+=$(MISC_WORDEXP_OBJ:.o=.os) + +libc-multi-$(UCLIBC_HAS_WORDEXP)+=$(MISC_WORDEXP_SRC) + +objclean-y+=misc_wordexp_objclean + +misc_wordexp_objclean: + $(RM) $(MISC_WORDEXP_OUT)/*.{o,os} diff --git a/libc/pwd_grp/Makefile.in b/libc/pwd_grp/Makefile.in new file mode 100644 index 000000000..991f38872 --- /dev/null +++ b/libc/pwd_grp/Makefile.in @@ -0,0 +1,48 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC:=pwd_grp.c +MOBJ:= fgetpwent_r.o fgetgrent_r.o fgetpwent.o fgetgrent.o \ + getpwnam_r.o getgrnam_r.o getpwuid_r.o getgrgid_r.o \ + getpwuid.o getgrgid.o getpwnam.o getgrnam.o getpw.o \ + getpwent_r.o getgrent_r.o getpwent.o getgrent.o \ + initgroups.o putpwent.o putgrent.o \ + __parsepwent.o __parsegrent.o __pgsreader.o + +ifeq ($(HAS_SHADOW),y) +MOBJ+= fgetspent_r.o fgetspent.o sgetspent_r.o getspnam_r.o \ + getspnam.o getspent_r.o getspent.o sgetspent.o \ + putspent.o __parsespent.o # getspuid_r.o getspuid.o +endif + +PWDGRP_DIR:=$(top_srcdir)libc/pwd_grp +PWDGRP_OUT:=$(top_builddir)libc/pwd_grp + +PWDGRP_MSRC:=$(PWDGRP_DIR)/$(MSRC) +PWDGRP_MOBJ:=$(patsubst %.o,$(PWDGRP_OUT)/%.o,$(MOBJ)) + +PWDGRP_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(PWDGRP_MOBJ)))) + +$(PWDGRP_MOBJ) $(PWDGRP_MOBJ:.o=.os): $(PWDGRP_MSRC) + $(compile.m) + +libc-a-y+=$(PWDGRP_MOBJ) +libc-a-$(HAS_SHADOW)+=$(PWDGRP_OUT)/lckpwdf.o +libc-a-pic-y+=$(PWDGRP_MOBJ:.o=.os) +libc-a-pic-$(HAS_SHADOW)+=$(PWDGRP_OUT)/lckpwdf.os +libc-so-y+=$(PWDGRP_MOBJ:.o=.os) +libc-so-$(HAS_SHADOW)+=$(PWDGRP_OUT)/lckpwdf.os + +CFLAGS-multi-y+=$(PWDGRP_DEF) +libc-multi-y+=$(PWDGRP_MSRC) +libc-multi-$(HAS_SHADOW)+=$(PWDGRP_DIR)/lckpwdf.c + +objclean-y+=pwdgrp_objclean + +pwdgrp_objclean: + $(RM) $(PWDGRP_OUT)/*.{o,os} diff --git a/libc/signal/Makefile.in b/libc/signal/Makefile.in new file mode 100644 index 000000000..22c9f35ea --- /dev/null +++ b/libc/signal/Makefile.in @@ -0,0 +1,36 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:= allocrtsig.c killpg.c raise.c sigaction.c sigaddset.c sigandset.c \ + sigblock.c sigdelset.c sigempty.c sigfillset.c siggetmask.c sighold.c \ + sigignore.c sigintr.c sigisempty.c sigismem.c sigjmp.c signal.c \ + sigorset.c sigpause.c sigrelse.c sigset.c sigsetmask.c sigsetops.c \ + sysv_signal.c sigwait.c + +ifneq ($(strip $(ARCH_OBJS)),) +CSRC:=$(filter-out $(notdir $(ARCH_OBJS:.o=.c)),$(CSRC)) +endif + +SIGNAL_DIR:=$(top_srcdir)libc/signal +SIGNAL_OUT:=$(top_builddir)libc/signal + +SIGNAL_SRC:=$(patsubst %.c,$(SIGNAL_DIR)/%.c,$(CSRC)) + +SIGNAL_OBJ:=$(patsubst $(SIGNAL_DIR)/%.c,$(SIGNAL_OUT)/%.o,$(SIGNAL_SRC)) + +libc-a-y+=$(SIGNAL_OBJ) +libc-a-pic-y+=$(SIGNAL_OBJ:.o=.os) +libc-so-y+=$(SIGNAL_OBJ:.o=.os) + +# either sigaction or allocrtsig have to be removed +#libc-multi-y+=$(SIGNAL_SRC) +libc-nomulti-y+=$(SIGNAL_OBJ) + +objclean-y+=signal_objclean + +signal_objclean: + $(RM) $(SIGNAL_OUT)/*.{o,os} diff --git a/libc/stdio/Makefile.in b/libc/stdio/Makefile.in new file mode 100644 index 000000000..9a98afe8a --- /dev/null +++ b/libc/stdio/Makefile.in @@ -0,0 +1,143 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2004 Manuel Novoa III <mjn3@codepoet.org> +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# + +# Note: The *64.o objects are empty when compiled without large file support. + +# SUSv3 functions +CSRC:= fclose.c fcloseall.c fdopen.c fgetpos.c fopen.c freopen.c \ + fseeko.c fsetpos.c ftello.c getdelim.c getline.c gets.c getw.c \ + perror.c puts.c putw.c remove.c rewind.c setbuf.c setbuffer.c \ + setlinebuf.c setvbuf.c ungetc.c \ + printf.c vprintf.c vsprintf.c fprintf.c snprintf.c dprintf.c \ + asprintf.c sprintf.c vasprintf.c vdprintf.c vsnprintf.c \ + tmpfile.c tmpnam.c tmpnam_r.c popen.c tempnam.c ctermid.c + +# getc -> alias for fgetc +# putc -> alias for fputc +# rename is a syscall + +# Implementation support functions +CSRC+= _READ.c _WRITE.c _adjust_pos.c _fopen.c _fwrite.c \ + _rfill.c _stdio.c _trans2r.c _trans2w.c _wcommit.c \ + _cs_funcs.c _load_inttype.c _store_inttype.c _uintmaxtostr.c +ifeq ($(UCLIBC_HAS_FLOATS),y) +CSRC+=_fpmaxtostr.c +endif + +# stdio_ext.h functions +CSRC+= __fbufsize.c __flbf.c __fpending.c __fpurge.c __freadable.c \ + __freading.c __fsetlocking.c __fwritable.c __fwriting.c _flushlbf.c + +# Other glibc extensions +ifeq ($(UCLIBC_HAS_GLIBC_CUSTOM_STREAMS),y) +CSRC+=fopencookie.c fmemopen.c open_memstream.c +endif + +# pthread functions +CSRC+=flockfile.c ftrylockfile.c funlockfile.c + +# Functions with unlocked versions +CUSRC:= clearerr.c feof.c ferror.c fflush.c fgetc.c fgets.c fileno.c \ + fputc.c fputs.c fread.c fwrite.c getchar.c putchar.c +# getc_unlocked -> alias for fgetc_unlocked +# putc_unlocked -> alias for fputc_unlocked + +# Largefile functions (%64.o) +CLSRC:= +ifeq ($(UCLIBC_HAS_LFS),y) +CLSRC:=fgetpos.c fopen.c freopen.c fseeko.c fsetpos.c ftello.c # tmpfile +endif + +# vfprintf and support functions +MSRC1:=vfprintf.c +ifneq ($(USE_OLD_VFPRINTF),y) +MOBJ1:= vfprintf.o \ + _ppfs_init.o _ppfs_prepargs.o _ppfs_setargs.o _ppfs_parsespec.o \ + register_printf_function.o parse_printf_format.o +else +MOBJ1:= +CSRC+=old_vfprintf.c +endif + +# vfscanf and support functions plus other *scanf funcs +MSRC2:=scanf.c +MOBJ2:= vfscanf.o __scan_cookie.o __psfs_parse_spec.o __psfs_do_numeric.o \ + scanf.o sscanf.o fscanf.o vscanf.o vsscanf.o + +CWSRC:= +ifeq ($(UCLIBC_HAS_WCHAR),y) +CWSRC+=_wfwrite.c fwprintf.c swprintf.c vswprintf.c vwprintf.c wprintf.c \ + fwide.c ungetwc.c +CUSRC+=fgetwc.c getwchar.c fgetws.c fputwc.c putwchar.c fputws.c +# getwc (fgetwc alias) getwc_unlocked (fgetwc_unlocked alias) +# putwc (fputwc alias) putwc_unlocked (fputwc_unlocked alias) +MOBJ1+=vfwprintf.o +MOBJ2+=wscanf.o swscanf.o fwscanf.o vwscanf.o vswscanf.o vfwscanf.o +endif + +CSRC+=$(CUSRC) $(CWSRC) + +STDIO_DIR:=$(top_srcdir)libc/stdio +STDIO_OUT:=$(top_builddir)libc/stdio + +STDIO_SRC:=$(patsubst %.c,$(STDIO_DIR)/%.c,$(CSRC)) +STDIO_OBJ:=$(patsubst %.c,$(STDIO_OUT)/%.o,$(CSRC)) +STDIO_CUSRC:=$(patsubst %.c,$(STDIO_DIR)/%.c,$(CUSRC)) +STDIO_CUOBJ:=$(patsubst %.c,$(STDIO_OUT)/%_unlocked.o,$(CUSRC)) +STDIO_CLSRC:=$(patsubst %.c,$(STDIO_OUT)/%64.c,$(CLSRC)) +STDIO_CLOBJ:=$(patsubst %.c,$(STDIO_OUT)/%64.o,$(CLSRC)) + +STDIO_MSRC1:=$(patsubst %.c,$(STDIO_DIR)/%.c,$(MSRC1)) +STDIO_MSRC2:=$(patsubst %.c,$(STDIO_DIR)/%.c,$(MSRC2)) +STDIO_MOBJ1:=$(patsubst %.o,$(STDIO_OUT)/%.o,$(MOBJ1)) +STDIO_MOBJ2:=$(patsubst %.o,$(STDIO_OUT)/%.o,$(MOBJ2)) + +STDIO_MSRC:=$(STDIO_MSRC1) $(STDIO_MSRC2) +STDIO_MOBJ:=$(STDIO_MOBJ1) $(STDIO_MOBJ2) + +#STDIO_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(STDIO_MOBJ)))) + +STDIO_OBJS:=$(STDIO_OBJ) $(STDIO_MOBJ) $(STDIO_CUOBJ) $(STDIO_CLOBJ) + +#STDIO_NO_MULTI:=$(STDIO_CUOBJ) $(STDIO_CLOBJ) + +# these need special handling or rewrite to support multi-build +# CUOBJ +%_unlocked.o %_unlocked.os: %.c + $(compile.c) -D__DO_UNLOCKED + +# need this, else the other %64 files will get false rules +$(STDIO_CLSRC): $(STDIO_OUT)/%64.c : $(STDIO_DIR)/%.c + cp $< $@ + +$(STDIO_CLOBJ): %.o : %.c + $(compile.c) -D__DO_LARGEFILE + +$(STDIO_CLOBJ:.o=.os): %.os : %.c + $(compile.c) -D__DO_LARGEFILE + +$(STDIO_MOBJ1) $(STDIO_MOBJ1:.o=.os): $(STDIO_MSRC1) + $(compile.m) + +$(STDIO_MOBJ2) $(STDIO_MOBJ2:.o=.os): $(STDIO_MSRC2) + $(compile.m) + +libc-a-y+=$(STDIO_OBJS) +libc-a-pic-y+=$(STDIO_OBJS:.o=.os) +libc-so-y+=$(STDIO_OBJS:.o=.os) + +#CFLAGS-multi-y+=$(STDIO_DEF) +#libc-multi-y+=$(STDIO_SRC) $(STDIO_MSRC) +#libc-nomulti-y+=$(STDIO_NO_MULTI) +libc-nomulti-y+=$(STDIO_OBJS) + +objclean-y+=stdio_objclean + +stdio_objclean: + $(RM) $(STDIO_OUT)/*.{o,os} diff --git a/libc/stdlib/Makefile.in b/libc/stdlib/Makefile.in new file mode 100644 index 000000000..3b00c8115 --- /dev/null +++ b/libc/stdlib/Makefile.in @@ -0,0 +1,122 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +include $(top_srcdir)libc/stdlib/malloc/Makefile.in +include $(top_srcdir)libc/stdlib/malloc-simple/Makefile.in +include $(top_srcdir)libc/stdlib/malloc-standard/Makefile.in + +MSRC1:=stdlib.c +MOBJ1:= abs.o labs.o atoi.o atol.o strtol.o strtoul.o _stdlib_strto_l.o \ + qsort.o bsearch.o \ + llabs.o atoll.o strtoll.o strtoull.o _stdlib_strto_ll.o +# (aliases) strtoq.o strtouq.o +ifeq ($(UCLIBC_HAS_XLOCALE),y) +MOBJ1x:=strtol_l.o strtoul_l.o _stdlib_strto_l_l.o \ + strtoll_l.o strtoull_l.o _stdlib_strto_ll_l.o +endif + +MSRC2:=strtod.c +MOBJ2:= +MOBJ2x:= + +ifeq ($(UCLIBC_HAS_FLOATS),y) +MOBJ1+=atof.o +MOBJ2+=strtod.o strtof.o strtold.o __strtofpmax.o __fp_range_check.o +ifeq ($(UCLIBC_HAS_XLOCALE),y) +MOBJ2x+=strtod_l.o strtof_l.o strtold_l.o __strtofpmax_l.o +endif +ifeq ($(UCLIBC_HAS_WCHAR),y) +MOBJ2+=wcstod.o wcstof.o wcstold.o __wcstofpmax.o +ifeq ($(UCLIBC_HAS_XLOCALE),y) +MOBJ2x+=wcstod_l.o wcstof_l.o wcstold_l.o __wcstofpmax_l.o +endif +endif +endif + +ifeq ($(UCLIBC_HAS_WCHAR),y) +MOBJ1+= mblen.o mbtowc.o wctomb.o mbstowcs.o wcstombs.o \ + _stdlib_mb_cur_max.o _stdlib_wcsto_l.o _stdlib_wcsto_ll.o \ + wcstol.o wcstoul.o wcstoll.o wcstoull.o +ifeq ($(UCLIBC_HAS_XLOCALE),y) +MOBJ1x+=_stdlib_wcsto_l_l.o _stdlib_wcsto_ll_l.o \ + wcstol_l.o wcstoul_l.o wcstoll_l.o wcstoull_l.o +endif +endif +# (aliases) wcstoq.o wcstouq.o +# wcstod wcstof wcstold + +MSRC3:=atexit.c +MOBJ3:=on_exit.o __cxa_atexit.o __cxa_finalize.o __exit_handler.o exit.o +ifeq ($(COMPAT_ATEXIT),y) +MOBJ3+=old_atexit.o +endif + +CSRC:= \ + abort.c getenv.c mkdtemp.c mktemp.c realpath.c mkstemp.c mkstemp64.c \ + rand.c random.c random_r.c setenv.c system.c div.c ldiv.c lldiv.c \ + getpt.c ptsname.c grantpt.c unlockpt.c gcvt.c drand48-iter.c jrand48.c \ + jrand48_r.c lrand48.c lrand48_r.c mrand48.c mrand48_r.c nrand48.c \ + nrand48_r.c rand_r.c srand48.c srand48_r.c seed48.c seed48_r.c \ + valloc.c posix_memalign.c a64l.c l64a.c +ifeq ($(UCLIBC_HAS_FLOATS),y) +CSRC+=drand48.c drand48_r.c erand48.c erand48_r.c +endif + +STDLIB_DIR:=$(top_srcdir)libc/stdlib +STDLIB_OUT:=$(top_builddir)libc/stdlib + +STDLIB_SRC:=$(patsubst %.c,$(STDLIB_DIR)/%.c,$(CSRC)) +STDLIB_OBJ:=$(patsubst %.c,$(STDLIB_OUT)/%.o,$(CSRC)) + +STDLIB_MSRC1:=$(patsubst %.c,$(STDLIB_DIR)/%.c,$(MSRC1)) +STDLIB_MSRC2:=$(patsubst %.c,$(STDLIB_DIR)/%.c,$(MSRC2)) +STDLIB_MSRC3:=$(patsubst %.c,$(STDLIB_DIR)/%.c,$(MSRC3)) +STDLIB_MOBJ1:=$(patsubst %.o,$(STDLIB_OUT)/%.o,$(MOBJ1)) +STDLIB_MOBJ2:=$(patsubst %.o,$(STDLIB_OUT)/%.o,$(MOBJ2)) +STDLIB_MOBJ3:=$(patsubst %.o,$(STDLIB_OUT)/%.o,$(MOBJ3)) +STDLIB_MOBJ1x:=$(patsubst %.o,$(STDLIB_OUT)/%.o,$(MOBJ1x)) +STDLIB_MOBJ2x:=$(patsubst %.o,$(STDLIB_OUT)/%.o,$(MOBJ2x)) + +STDLIB_MSRC:=$(STDLIB_MSRC1) $(STDLIB_MSRC2) $(STDLIB_MSRC3) +STDLIB_MOBJ:=$(STDLIB_MOBJ1) $(STDLIB_MOBJ2) $(STDLIB_MOBJ3) + +STDLIB_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(STDLIB_MOBJ)))) + +STDLIB_MOBJx:=$(STDLIB_MOBJ1x) $(STDLIB_MOBJ2x) + +STDLIB_OBJS:=$(STDLIB_OBJ) $(STDLIB_MOBJ) $(STDLIB_MOBJx) + +$(STDLIB_MOBJ1) $(STDLIB_MOBJ1:.o=.os): $(STDLIB_MSRC1) + $(compile.m) + +$(STDLIB_MOBJ2) $(STDLIB_MOBJ2:.o=.os): $(STDLIB_MSRC2) + $(compile.m) + +$(STDLIB_MOBJ3) $(STDLIB_MOBJ3:.o=.os) $(STDLIB_OUT)/atexit.os: $(STDLIB_MSRC3) + $(compile.m) + +$(STDLIB_MOBJ1x) $(STDLIB_MOBJ1x:.o=.os): $(STDLIB_MSRC1) + $(compile.m) -D__UCLIBC_DO_XLOCALE + +$(STDLIB_MOBJ2x) $(STDLIB_MOBJ2x:.o=.os): $(STDLIB_MSRC2) + $(compile.m) -D__UCLIBC_DO_XLOCALE + +libc-a-y+=$(STDLIB_OBJS) $(STDLIB_OUT)/atexit.o +libc-a-pic-y+=$(STDLIB_OBJS:.o=.os) $(STDLIB_OUT)/atexit.os +libc-so-y+=$(STDLIB_OBJS:.o=.os) +# this should always be the PIC version, because it could be used in shared libs +libc-nonshared-y+=$(STDLIB_OUT)/atexit.os + +CFLAGS-multi-y+=$(STDLIB_DEF) +libc-multi-y+=$(STDLIB_SRC) $(STDLIB_MSRC) +libc-nomulti-y+=$(STDLIB_MOBJx) + +objclean-y+=stdlib_objclean + +stdlib_objclean: + $(RM) $(STDLIB_OUT)/*.{o,os} diff --git a/libc/stdlib/malloc-simple/Makefile.in b/libc/stdlib/malloc-simple/Makefile.in new file mode 100644 index 000000000..42b302071 --- /dev/null +++ b/libc/stdlib/malloc-simple/Makefile.in @@ -0,0 +1,31 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC:=alloc.c +MOBJ:=malloc.o realloc.o free.o calloc.o memalign.o + +STDLIB_MALLOC_SIMPLE_DIR:=$(top_srcdir)libc/stdlib/malloc-simple +STDLIB_MALLOC_SIMPLE_OUT:=$(top_builddir)libc/stdlib/malloc-simple + +STDLIB_MALLOC_SIMPLE_MSRC:=$(STDLIB_MALLOC_SIMPLE_DIR)/$(MSRC) +STDLIB_MALLOC_SIMPLE_MOBJ:=$(patsubst %.o,$(STDLIB_MALLOC_SIMPLE_OUT)/%.o,$(MOBJ)) +STDLIB_MALLOC_SIMPLE_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(STDLIB_MALLOC_SIMPLE_MOBJ)))) + +libc-a-$(MALLOC_SIMPLE)+=$(STDLIB_MALLOC_SIMPLE_MOBJ) +libc-a-pic-$(MALLOC_SIMPLE)+=$(STDLIB_MALLOC_SIMPLE_MOBJ:.o=.os) +libc-so-$(MALLOC_SIMPLE)+=$(STDLIB_MALLOC_SIMPLE_MOBJ:.o=.os) + +CFLAGS-multi-$(MALLOC_SIMPLE)+=$(STDLIB_MALLOC_SIMPLE_DEF) +libc-multi-$(MALLOC_SIMPLE)+=$(STDLIB_MALLOC_SIMPLE_MSRC) + +$(STDLIB_MALLOC_SIMPLE_MOBJ) $(STDLIB_MALLOC_SIMPLE_MOBJ:.o=.os): $(STDLIB_MALLOC_SIMPLE_MSRC) + $(compile.m) + +objclean-y+=stdlib_malloc_simple_objclean + +stdlib_malloc_simple_objclean: + $(RM) $(STDLIB_MALLOC_SIMPLE_OUT)/*.{o,os} diff --git a/libc/stdlib/malloc-standard/Makefile.in b/libc/stdlib/malloc-standard/Makefile.in new file mode 100644 index 000000000..e8c34b544 --- /dev/null +++ b/libc/stdlib/malloc-standard/Makefile.in @@ -0,0 +1,33 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +# Turn on malloc debugging if requested +ifeq ($(UCLIBC_MALLOC_DEBUGGING),y) +CFLAGS+=-D__MALLOC_DEBUGGING +endif + +# calloc.c can be found at uClibc/libc/stdlib/calloc.c +# valloc.c can be found at uClibc/libc/stdlib/valloc.c +CSRC:=malloc.c calloc.c realloc.c free.c memalign.c mallopt.c mallinfo.c + +STDLIB_MALLOC_STANDARD_DIR:=$(top_srcdir)libc/stdlib/malloc-standard +STDLIB_MALLOC_STANDARD_OUT:=$(top_builddir)libc/stdlib/malloc-standard + +STDLIB_MALLOC_STANDARD_SRC:=$(patsubst %.c,$(STDLIB_MALLOC_STANDARD_DIR)/%.c,$(CSRC)) +STDLIB_MALLOC_STANDARD_OBJ:=$(patsubst %.c,$(STDLIB_MALLOC_STANDARD_OUT)/%.o,$(CSRC)) + +libc-a-$(MALLOC_STANDARD)+=$(STDLIB_MALLOC_STANDARD_OBJ) +libc-a-pic-$(MALLOC_STANDARD)+=$(STDLIB_MALLOC_STANDARD_OBJ:.o=.os) +libc-so-$(MALLOC_STANDARD)+=$(STDLIB_MALLOC_STANDARD_OBJ:.o=.os) + +libc-multi-$(MALLOC_STANDARD)+=$(STDLIB_MALLOC_STANDARD_SRC) + +objclean-y+=stdlib_malloc_standard_objclean + +stdlib_malloc_standard_objclean: + $(RM) $(STDLIB_MALLOC_STANDARD_OUT)/*.{o,os} diff --git a/libc/stdlib/malloc/Makefile.in b/libc/stdlib/malloc/Makefile.in new file mode 100644 index 000000000..6a0e3cee3 --- /dev/null +++ b/libc/stdlib/malloc/Makefile.in @@ -0,0 +1,42 @@ +# Makefile for uClibc +# +# Copyright (C) 2002-2003 NEC Electronics Corporation +# Copyright (C) 2002-2003 Miles Bader <miles@gnu.org> +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:= malloc.c calloc.c free.c realloc.c memalign.c \ + heap_alloc.c heap_alloc_at.c heap_free.c + +# Turn on malloc debugging if requested +ifeq ($(UCLIBC_MALLOC_DEBUGGING),y) +CSRC+=malloc_debug.c heap_debug.c +CFLAGS+=-DMALLOC_DEBUGGING -DHEAP_DEBUGGING +ifeq ($(UCLIBC_UCLINUX_BROKEN_MUNMAP),y) +CFLAGS+=-DMALLOC_MMB_DEBUGGING +endif +endif + +STDLIB_MALLOC_DIR:=$(top_srcdir)libc/stdlib/malloc +STDLIB_MALLOC_OUT:=$(top_builddir)libc/stdlib/malloc + +STDLIB_MALLOC_SRC:=$(patsubst %.c,$(STDLIB_MALLOC_DIR)/%.c,$(CSRC)) +STDLIB_MALLOC_OBJ:=$(patsubst %.c,$(STDLIB_MALLOC_OUT)/%.o,$(CSRC)) + +libc-a-$(MALLOC)+=$(STDLIB_MALLOC_OBJ) +libc-a-pic-$(MALLOC)+=$(STDLIB_MALLOC_OBJ:.o=.os) +libc-so-$(MALLOC)+=$(STDLIB_MALLOC_OBJ:.o=.os) + +#libc-multi-$(MALLOC)+=$(STDLIB_MALLOC_SRC) +libc-nomulti-$(MALLOC)+=$(STDLIB_MALLOC_OBJ) + +objclean-y+=stdlib_malloc_objclean + +stdlib_malloc_objclean: + $(RM) $(STDLIB_MALLOC_OUT)/*.{o,os} + +malloc.o free.o realloc.o memalign.o: malloc.h +# Depend on uClinux_config.h to cache changes in __UCLIBC_MALLOC_DEBUGGING__ +$(STDLIB_MALLOC_OBJ): heap.h $(top_builddir)include/bits/uClibc_config.h diff --git a/libc/string/Makefile.in b/libc/string/Makefile.in new file mode 100644 index 000000000..16acafbe1 --- /dev/null +++ b/libc/string/Makefile.in @@ -0,0 +1,95 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +# order is relevant +-include $(top_srcdir)libc/string/$(TARGET_ARCH)/Makefile.in +include $(top_srcdir)libc/string/generic/Makefile.in + +MSRC:=wstring.c +MOBJ:= basename.o bcopy.o bzero.o dirname.o ffs.o memccpy.o memchr.o memcmp.o \ + memcpy.o memmove.o mempcpy.o memrchr.o memset.o rawmemchr.o stpcpy.o \ + stpncpy.o strcasecmp.o strcasestr.o strcat.o strchrnul.o strchr.o \ + strcmp.o strcpy.o strcspn.o strdup.o strlen.o strncasecmp.o strncat.o \ + strncmp.o strncpy.o strndup.o strnlen.o strpbrk.o strrchr.o strsep.o \ + strspn.o strstr.o strtok.o strtok_r.o strerror.o __xpg_strerror_r.o \ + _string_syserrmsgs.o __glibc_strerror_r.o \ + _string_syssigmsgs.o sys_siglist.o strsignal.o psignal.o \ + __xpg_basename.o strlcat.o strlcpy.o sys_errlist.o memmem.o + +MOBJW= +ifeq ($(UCLIBC_HAS_WCHAR),y) +MOBJW= wcscasecmp.o wcscat.o wcschrnul.o wcschr.o wcscmp.o wcscpy.o wcscspn.o \ + wcsdup.o wcslen.o wcsncasecmp.o wcsncat.o wcsncmp.o wcsncpy.o \ + wcsnlen.o wcspbrk.o wcsrchr.o wcsspn.o wcsstr.o wcstok.o wmemchr.o \ + wmemcmp.o wmemcpy.o wmemmove.o wmempcpy.o wmemset.o wcpcpy.o wcpncpy.o \ + __wcslcpy.o \ + wcsxfrm.o strxfrm.o # wcscoll strcoll.o +endif + +MOBJx= +MOBJWx= +ifeq ($(UCLIBC_HAS_XLOCALE),y) +MOBJx+=strcasecmp_l.o strncasecmp_l.o +ifeq ($(UCLIBC_HAS_WCHAR),y) +MOBJWx+=wcscasecmp_l.o wcsncasecmp_l.o wcsxfrm_l.o strxfrm_l.o +endif +endif + +#ffsl ffsll + +ifeq ($(UCLIBC_HAS_STRING_ARCH_OPT),y) +ifneq ($(strip $(STRING_ARCH_OBJS)),) +MOBJ:=$(filter-out $(notdir $(STRING_ARCH_OBJS)),$(MOBJ)) +endif +endif + +ifeq ($(UCLIBC_HAS_STRING_GENERIC_OPT),y) +ifneq ($(strip $(STRING_GENERIC_OBJS)),) +MOBJ:=$(filter-out $(notdir $(STRING_GENERIC_OBJS)),$(MOBJ)) +endif +endif + +STRING_DIR:=$(top_srcdir)libc/string +STRING_OUT:=$(top_builddir)libc/string + +STRING_MSRC:=$(patsubst %.c,$(STRING_DIR)/%.c,$(MSRC)) +STRING_MOBJ:=$(patsubst %.o,$(STRING_OUT)/%.o,$(MOBJ)) +STRING_MOBJW=$(patsubst %.o,$(STRING_OUT)/%.o,$(MOBJW)) +STRING_MOBJx=$(patsubst %.o,$(STRING_OUT)/%.o,$(MOBJx)) +STRING_MOBJWx=$(patsubst %.o,$(STRING_OUT)/%.o,$(MOBJWx)) + +#STRING_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(STRING_MOBJ)))) + +STRING_Wx=$(STRING_MOBJW) $(STRING_MOBJx) $(STRING_MOBJWx) +STRING_OBJS:=$(STRING_MOBJ) $(STRING_Wx) + +$(STRING_MOBJ) $(STRING_MOBJ:.o=.os): $(STRING_MSRC) + $(compile.m) + +$(STRING_MOBJW) $(STRING_MOBJW:.o=.os): $(STRING_MSRC) + $(compile.m) -DWANT_WIDE + +$(STRING_MOBJx) $(STRING_MOBJx:.o=.os): $(STRING_MSRC) + $(compile.m) -D__UCLIBC_DO_XLOCALE + +$(STRING_MOBJWx) $(STRING_MOBJWx:.o=.os): $(STRING_MSRC) + $(compile.m) -DWANT_WIDE -D__UCLIBC_DO_XLOCALE + +libc-a-y+=$(STRING_OBJS) +libc-a-pic-y+=$(STRING_OBJS:.o=.os) +libc-so-y+=$(STRING_OBJS:.o=.os) + +# multi does not work here, because arch/Makefile.in uses the same L_* defines +#CFLAGS-multi-y+=$(STRING_DEF) +#libc-multi-y+=$(STRING_MSRC) +#libc-nomulti-y+=$(STRING_Wx) +libc-nomulti-y+=$(STRING_OBJS) + +objclean-y+=string_objclean + +string_objclean: + $(RM) $(STRING_OUT)/{,*/}*.{o,os} diff --git a/libc/string/arm/Makefile.in b/libc/string/arm/Makefile.in new file mode 100644 index 000000000..0f9502d14 --- /dev/null +++ b/libc/string/arm/Makefile.in @@ -0,0 +1,28 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +SSRC:= _memcpy.S bcopy.S bzero.S memcmp.S memcpy.S memmove.S memset.S \ + strcmp.S strlen.S strncmp.S + +STRING_ARCH_DIR:=$(top_srcdir)libc/string/arm +STRING_ARCH_OUT:=$(top_builddir)libc/string/arm + +STRING_ARCH_SRC:=$(patsubst %.S,$(STRING_ARCH_DIR)/%.S,$(SSRC)) +STRING_ARCH_OBJ:=$(patsubst %.S,$(STRING_ARCH_OUT)/%.o,$(SSRC)) + +STRING_ARCH_OBJS:=$(STRING_ARCH_OBJ) + +libc-a-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS) +libc-a-pic-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) +libc-so-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) + +libc-multi-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_SRC) + +objclean-y+=string_arch_objclean + +string_arch_objclean: + $(RM) $(STRING_ARCH_OUT)/*.{o,os} diff --git a/libc/string/frv/Makefile.in b/libc/string/frv/Makefile.in new file mode 100644 index 000000000..649998325 --- /dev/null +++ b/libc/string/frv/Makefile.in @@ -0,0 +1,28 @@ +# Makefile for uClibc +# +# Copyright (C) 2004 Alexandre Oliva <aoliva@redhat.com> +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +SSRC:=memcpy.S memset.S + +STRING_ARCH_DIR:=$(top_srcdir)libc/string/frv +STRING_ARCH_OUT:=$(top_builddir)libc/string/frv + +STRING_ARCH_SRC:=$(patsubst %.S,$(STRING_ARCH_DIR)/%.S,$(SSRC)) +STRING_ARCH_OBJ:=$(patsubst %.S,$(STRING_ARCH_OUT)/%.o,$(SSRC)) + +STRING_ARCH_OBJS:=$(STRING_ARCH_OBJ) + +libc-a-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS) +libc-a-pic-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) +libc-so-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) + +libc-multi-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_SRC) + +objclean-y+=string_arch_objclean + +string_arch_objclean: + $(RM) $(STRING_ARCH_OUT)/*.{o,os} diff --git a/libc/string/generic/Makefile.in b/libc/string/generic/Makefile.in new file mode 100644 index 000000000..aef1ac882 --- /dev/null +++ b/libc/string/generic/Makefile.in @@ -0,0 +1,34 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +STRING_GENERIC_DIR:=$(top_srcdir)libc/string/generic +STRING_GENERIC_OUT:=$(top_builddir)libc/string/generic + +STRING_GENERIC_SRC:=$(wildcard $(STRING_GENERIC_DIR)/*.c) +MOBJ:=$(patsubst $(STRING_GENERIC_DIR)/%.c,%.o,$(STRING_GENERIC_SRC)) + +ifeq ($(UCLIBC_HAS_STRING_ARCH_OPT),y) +ifneq ($(strip $(STRING_ARCH_OBJS)),) +MOBJ:=$(filter-out $(notdir $(STRING_ARCH_OBJS)),$(MOBJ)) +endif +endif + +STRING_GENERIC_OBJ:=$(patsubst %.o,$(STRING_GENERIC_OUT)/%.o,$(MOBJ)) + +STRING_GENERIC_OBJS:=$(STRING_GENERIC_OBJ) + +libc-a-$(UCLIBC_HAS_STRING_GENERIC_OPT)+=$(STRING_GENERIC_OBJS) +libc-a-pic-$(UCLIBC_HAS_STRING_GENERIC_OPT)+=$(STRING_GENERIC_OBJS:.o=.os) +libc-so-$(UCLIBC_HAS_STRING_GENERIC_OPT)+=$(STRING_GENERIC_OBJS:.o=.os) + +#libc-multi-$(UCLIBC_HAS_STRING_GENERIC_OPT)+=$(STRING_GENERIC_SRC) +libc-nomulti-$(UCLIBC_HAS_STRING_GENERIC_OPT)+=$(STRING_GENERIC_OBJS) + +objclean-y+=string_generic_objclean + +string_generic_objclean: + $(RM) $(STRING_GENERIC_OUT)/*.{o,os} diff --git a/libc/string/i386/Makefile.in b/libc/string/i386/Makefile.in new file mode 100644 index 000000000..2935c8355 --- /dev/null +++ b/libc/string/i386/Makefile.in @@ -0,0 +1,36 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC:=string.c +MOBJ:= strcpy.o strncpy.o strcat.o strncat.o strcmp.o \ + strncmp.o strchr.o strrchr.o strlen.o strnlen.o \ + memcpy.o memmove.o memchr.o memset.o + +STRING_ARCH_DIR:=$(top_srcdir)libc/string/i386 +STRING_ARCH_OUT:=$(top_builddir)libc/string/i386 + +STRING_ARCH_MSRC:=$(patsubst %.c,$(STRING_ARCH_DIR)/%.c,$(MSRC)) +STRING_ARCH_MOBJ:=$(patsubst %.o,$(STRING_ARCH_OUT)/%.o,$(MOBJ)) + +STRING_ARCH_OBJS:=$(STRING_ARCH_MOBJ) + +STRING_ARCH_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(STRING_ARCH_OBJS)))) + +$(STRING_ARCH_MOBJ) $(STRING_ARCH_MOBJ:.o=.os): $(STRING_ARCH_MSRC) + $(compile.m) + +libc-a-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS) +libc-a-pic-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) +libc-so-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) + +CFLAGS-multi-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_DEF) +libc-multi-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_MSRC) + +objclean-y+=string_arch_objclean + +string_arch_objclean: + $(RM) $(STRING_ARCH_OUT)/*.{o,os} diff --git a/libc/string/mips/Makefile.in b/libc/string/mips/Makefile.in new file mode 100644 index 000000000..2ba596b95 --- /dev/null +++ b/libc/string/mips/Makefile.in @@ -0,0 +1,27 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +SSRC:=memcpy.S memset.S + +STRING_ARCH_DIR:=$(top_srcdir)libc/string/mips +STRING_ARCH_OUT:=$(top_builddir)libc/string/mips + +STRING_ARCH_SRC:=$(patsubst %.S,$(STRING_ARCH_DIR)/%.S,$(SSRC)) +STRING_ARCH_OBJ:=$(patsubst %.S,$(STRING_ARCH_OUT)/%.o,$(SSRC)) + +STRING_ARCH_OBJS:=$(STRING_ARCH_OBJ) + +libc-a-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS) +libc-a-pic-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) +libc-so-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) + +libc-multi-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_SRC) + +objclean-y+=string_arch_objclean + +string_arch_objclean: + $(RM) $(STRING_ARCH_OUT)/*.{o,os} diff --git a/libc/string/powerpc/Makefile.in b/libc/string/powerpc/Makefile.in new file mode 100644 index 000000000..d22312fe0 --- /dev/null +++ b/libc/string/powerpc/Makefile.in @@ -0,0 +1,34 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +MSRC:=string.c +MOBJ:=memcpy.o memmove.o memset.o bzero.o + +STRING_ARCH_DIR:=$(top_srcdir)libc/string/powerpc +STRING_ARCH_OUT:=$(top_builddir)libc/string/powerpc + +STRING_ARCH_MSRC:=$(patsubst %.c,$(STRING_ARCH_DIR)/%.c,$(MSRC)) +STRING_ARCH_MOBJ:=$(patsubst %.o,$(STRING_ARCH_OUT)/%.o,$(MOBJ)) + +STRING_ARCH_OBJS:=$(STRING_ARCH_MOBJ) + +STRING_ARCH_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(STRING_ARCH_MOBJ)))) + +$(STRING_ARCH_MOBJ) $(STRING_ARCH_MOBJ:.o=.os): $(STRING_ARCH_MSRC) + $(compile.m) + +libc-a-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS) +libc-a-pic-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) +libc-so-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) + +CFLAGS-multi-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_DEF) +libc-multi-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_MSRC) + +objclean-y+=string_arch_objclean + +string_arch_objclean: + $(RM) $(STRING_ARCH_OUT)/*.{o,os} diff --git a/libc/string/sh64/Makefile.in b/libc/string/sh64/Makefile.in new file mode 100644 index 000000000..1b728958a --- /dev/null +++ b/libc/string/sh64/Makefile.in @@ -0,0 +1,28 @@ +# Makefile for uClibc +# +# Copyright (C) 2003 Paul Mundt <lethal@linux-sh.org> +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +SSRC:=memcpy.S memset.S strcpy.S strlen.S + +STRING_ARCH_DIR:=$(top_srcdir)libc/string/sh64 +STRING_ARCH_OUT:=$(top_builddir)libc/string/sh64 + +STRING_ARCH_SRC:=$(patsubst %.S,$(STRING_ARCH_DIR)/%.S,$(SSRC)) +STRING_ARCH_OBJ:=$(patsubst %.S,$(STRING_ARCH_OUT)/%.o,$(SSRC)) + +STRING_ARCH_OBJS:=$(STRING_ARCH_OBJ) + +libc-a-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS) +libc-a-pic-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) +libc-so-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) + +libc-multi-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_SRC) + +objclean-y+=string_arch_objclean + +string_arch_objclean: + $(RM) $(STRING_ARCH_OUT)/*.{o,os} diff --git a/libc/string/sparc/Makefile.in b/libc/string/sparc/Makefile.in new file mode 100644 index 000000000..563271518 --- /dev/null +++ b/libc/string/sparc/Makefile.in @@ -0,0 +1,28 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +STRING_ARCH_DIR:=$(top_srcdir)libc/string/sparc +STRING_ARCH_OUT:=$(top_builddir)libc/string/sparc + +STRING_ARCH_SRC:=$(wildcard $(STRING_ARCH_DIR)/*.c) +STRING_ARCH_OBJ:=$(patsubst $(STRING_ARCH_DIR)/%.c,$(STRING_ARCH_OUT)/%.o,$(STRING_ARCH_SRC)) + +STRING_ARCH_SSRC:=$(wildcard $(STRING_ARCH_DIR)/*.S) +STRING_ARCH_SOBJ:=$(patsubst $(STRING_ARCH_DIR)/%.S,$(STRING_ARCH_OUT)/%.o,$(STRING_ARCH_SSRC)) + +STRING_ARCH_OBJS:=$(STRING_ARCH_OBJ) $(STRING_ARCH_SOBJ) + +libc-a-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS) +libc-a-pic-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) +libc-so-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) + +libc-multi-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_SRC) $(STRING_ARCH_SSRC) + +objclean-y+=string_arch_objclean + +string_arch_objclean: + $(RM) $(STRING_ARCH_OUT)/*.{o,os} diff --git a/libc/string/x86_64/Makefile.in b/libc/string/x86_64/Makefile.in new file mode 100644 index 000000000..83cc470c9 --- /dev/null +++ b/libc/string/x86_64/Makefile.in @@ -0,0 +1,28 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +STRING_ARCH_DIR:=$(top_srcdir)libc/string/x86_64 +STRING_ARCH_OUT:=$(top_builddir)libc/string/x86_64 + +STRING_ARCH_SRC:=$(wildcard $(STRING_ARCH_DIR)/*.c) +STRING_ARCH_OBJ:=$(patsubst $(STRING_ARCH_DIR)/%.c,$(STRING_ARCH_OUT)/%.o,$(STRING_ARCH_SRC)) + +STRING_ARCH_SSRC:=$(wildcard $(STRING_ARCH_DIR)/*.S) +STRING_ARCH_SOBJ:=$(patsubst $(STRING_ARCH_DIR)/%.S,$(STRING_ARCH_OUT)/%.o,$(STRING_ARCH_SSRC)) + +STRING_ARCH_OBJS:=$(STRING_ARCH_OBJ) $(STRING_ARCH_SOBJ) + +libc-a-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS) +libc-a-pic-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) +libc-so-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_OBJS:.o=.os) + +libc-multi-$(UCLIBC_HAS_STRING_ARCH_OPT)+=$(STRING_ARCH_SRC) $(STRING_ARCH_SSRC) + +objclean-y+=string_x86_64_objclean + +string_x86_64_objclean: + $(RM) $(STRING_ARCH_OUT)/*.{o,os} diff --git a/libc/sysdeps/Makefile.in b/libc/sysdeps/Makefile.in new file mode 100644 index 000000000..686cb7279 --- /dev/null +++ b/libc/sysdeps/Makefile.in @@ -0,0 +1,8 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +include $(top_srcdir)libc/sysdeps/linux/Makefile.in diff --git a/libc/sysdeps/linux/Makefile.in b/libc/sysdeps/linux/Makefile.in new file mode 100644 index 000000000..a8ae79edd --- /dev/null +++ b/libc/sysdeps/linux/Makefile.in @@ -0,0 +1,10 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +# order is relevant +include $(top_srcdir)libc/sysdeps/linux/$(TARGET_ARCH)/Makefile.in +include $(top_srcdir)libc/sysdeps/linux/common/Makefile.in diff --git a/libc/sysdeps/linux/arm/Makefile.in b/libc/sysdeps/linux/arm/Makefile.in new file mode 100644 index 000000000..87339cd0d --- /dev/null +++ b/libc/sysdeps/linux/arm/Makefile.in @@ -0,0 +1,38 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=brk.c syscall.c ioperm.c iopl.c sigaction.c __syscall_error.c +SSRC:= __longjmp.S vfork.S clone.S setjmp.S bsd-setjmp.S \ + bsd-_setjmp.S sigrestorer.S mmap64.S + +ARCH_DIR:=$(top_srcdir)libc/sysdeps/linux/arm +ARCH_OUT:=$(top_builddir)libc/sysdeps/linux/arm + +ARCH_CSRC:=$(patsubst %.c,$(ARCH_DIR)/%.c,$(CSRC)) +ARCH_COBJ:=$(patsubst %.c,$(ARCH_OUT)/%.o,$(CSRC)) +ARCH_SSRC:=$(patsubst %.S,$(ARCH_DIR)/%.S,$(SSRC)) +ARCH_SOBJ:=$(patsubst %.S,$(ARCH_OUT)/%.o,$(SSRC)) + +ARCH_OBJS:=$(ARCH_COBJ) $(ARCH_SOBJ) + +crt-y:=create +libc-a-y+=$(ARCH_OBJS) +libc-a-pic-y+=$(ARCH_OBJS:.o=.os) +libc-so-y+=$(ARCH_OBJS:.o=.os) + +#libc-multi-y+=$(ARCH_CSRC) +libc-nomulti-y+=$(ARCH_OBJS) + +objclean-y+=arch_objclean + +arch_objclean: + $(RM) $(ARCH_OUT)/*.{o,os} + +headers-y+=arch_headers + +arch_headers: + $(LN) -fs ../libc/sysdeps/linux/arm/fpu_control.h $(top_builddir)include/ diff --git a/libc/sysdeps/linux/common/Makefile.in b/libc/sysdeps/linux/common/Makefile.in new file mode 100644 index 000000000..85826913e --- /dev/null +++ b/libc/sysdeps/linux/common/Makefile.in @@ -0,0 +1,52 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +COMMON_DIR:=$(top_srcdir)libc/sysdeps/linux/common +COMMON_OUT:=$(top_builddir)libc/sysdeps/linux/common + +CSRC:=$(patsubst $(COMMON_DIR)/%.c,%.c,$(wildcard $(COMMON_DIR)/*.c)) + +ifeq ($(EXCLUDE_BRK),y) +CSRC:=$(filter-out sbrk.c,$(CSRC)) +endif + +CSRC:=$(filter-out ssp-local.c,$(CSRC)) +ifneq ($(UCLIBC_HAS_SSP),y) +CSRC:=$(filter-out ssp.c,$(CSRC)) +endif + +# fails for some reason +ifneq ($(strip $(ARCH_OBJS)),) +CSRC:=$(filter-out $(notdir $(ARCH_OBJS:.o=.c)),$(CSRC)) +endif + +CFLAGS-ssp.c=$(SSP_DISABLE_FLAGS) +CFLAGS-ssp-local.c=$(SSP_DISABLE_FLAGS) + +COMMON_SRC:=$(patsubst %.c,$(COMMON_DIR)/%.c,$(CSRC)) +COMMON_OBJ:=$(patsubst %.c,$(COMMON_OUT)/%.o,$(CSRC)) + +libc-a-y+=$(COMMON_OBJ) +libc-a-$(UCLIBC_HAS_SSP)+=$(COMMON_OUT)/ssp-local.o +libc-a-pic-y+=$(COMMON_OBJ:.o=.os) +libc-a-pic-$(UCLIBC_HAS_SSP)+=$(COMMON_OUT)/ssp-local.os +libc-so-y+=$(COMMON_OBJ:.o=.os) +libc-nonshared-$(UCLIBC_HAS_SSP)+=$(COMMON_OUT)/ssp-local.os + +#libc-multi-y+=$(filter-out $(COMMON_DIR)/ssp.c,$(COMMON_SRC)) +#libc-nomulti-$(UCLIBC_HAS_SSP)+=$(COMMON_OUT)/ssp.o +libc-nomulti-y+=$(COMMON_OBJ) + +objclean-y+=common_objclean + +common_objclean: + $(RM) $(COMMON_OUT)/*.{o,os} + +headers-y+=common_headers + +common_headers: + $(LN) -fs ../libc/sysdeps/linux/common/fpu_control.h $(top_builddir)include/ diff --git a/libc/sysdeps/linux/i386/Makefile.in b/libc/sysdeps/linux/i386/Makefile.in new file mode 100644 index 000000000..9593b7405 --- /dev/null +++ b/libc/sysdeps/linux/i386/Makefile.in @@ -0,0 +1,39 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=brk.c sigaction.c __syscall_error.c + +SSRC:= __longjmp.S vfork.S clone.S setjmp.S bsd-setjmp.S \ + bsd-_setjmp.S syscall.S mmap.S mmap64.S + +ARCH_DIR:=$(top_srcdir)libc/sysdeps/linux/i386 +ARCH_OUT:=$(top_builddir)libc/sysdeps/linux/i386 + +ARCH_CSRC:=$(patsubst %.c,$(ARCH_DIR)/%.c,$(CSRC)) +ARCH_COBJ:=$(patsubst %.c,$(ARCH_OUT)/%.o,$(CSRC)) +ARCH_SSRC:=$(patsubst %.S,$(ARCH_DIR)/%.S,$(SSRC)) +ARCH_SOBJ:=$(patsubst %.S,$(ARCH_OUT)/%.o,$(SSRC)) + +ARCH_OBJS:=$(ARCH_COBJ) $(ARCH_SOBJ) + +crt-y:=create +libc-a-y+=$(ARCH_OBJS) +libc-a-pic-y+=$(ARCH_OBJS:.o=.os) +libc-so-y+=$(ARCH_OBJS:.o=.os) + +#libc-multi-y+=$(ARCH_CSRC) +libc-nomulti-y+=$(ARCH_OBJS) + +objclean-y+=arch_objclean + +arch_objclean: + $(RM) $(ARCH_OUT)/*.{o,os} + +headers-y+=arch_headers + +arch_headers: + $(LN) -fs ../libc/sysdeps/linux/i386/fpu_control.h $(top_builddir)include/ diff --git a/libc/sysdeps/linux/mips/Makefile.in b/libc/sysdeps/linux/mips/Makefile.in new file mode 100644 index 000000000..e6075d7f6 --- /dev/null +++ b/libc/sysdeps/linux/mips/Makefile.in @@ -0,0 +1,42 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:= __longjmp.c brk.c setjmp_aux.c mmap.c __syscall_error.c \ + cacheflush.c pread_write.c sysmips.c _test_and_set.c sigaction.c + +SSRC:=bsd-_setjmp.S bsd-setjmp.S setjmp.S clone.S syscall.S pipe.S + + +ARCH_DIR:=$(top_srcdir)libc/sysdeps/linux/mips +ARCH_OUT:=$(top_builddir)libc/sysdeps/linux/mips + +ARCH_CSRC:=$(patsubst %.c,$(ARCH_DIR)/%.c,$(CSRC)) +ARCH_COBJ:=$(patsubst %.c,$(ARCH_OUT)/%.o,$(CSRC)) +ARCH_SSRC:=$(patsubst %.S,$(ARCH_DIR)/%.S,$(SSRC)) +ARCH_SOBJ:=$(patsubst %.S,$(ARCH_OUT)/%.o,$(SSRC)) + +ARCH_OBJS:=$(ARCH_COBJ) $(ARCH_SOBJ) + +crt-y:=create +libc-a-y+=$(ARCH_OBJS) +libc-a-pic-y+=$(ARCH_OBJS:.o=.os) +libc-so-y+=$(ARCH_OBJS:.o=.os) + +#libc-multi-y+=$(ARCH_CSRC) +libc-nomulti-y+=$(ARCH_OBJS) + +objclean-y+=arch_objclean + +arch_objclean: + $(RM) $(ARCH_OUT)/*.{o,os} $(top_builddir)include/sgidefs.h + +headers-y+=arch_headers + +arch_headers: + $(LN) -fs ../libc/sysdeps/linux/mips/sgidefs.h $(top_builddir)include/ +# $(LN) -fs ../libc/sysdeps/linux/mips/regdef.h $(top_builddir)include/ + $(LN) -fs ../libc/sysdeps/linux/mips/fpu_control.h $(top_builddir)include/ diff --git a/libc/sysdeps/linux/powerpc/Makefile.in b/libc/sysdeps/linux/powerpc/Makefile.in new file mode 100644 index 000000000..3cc5ca539 --- /dev/null +++ b/libc/sysdeps/linux/powerpc/Makefile.in @@ -0,0 +1,38 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=mmap.c __syscall_error.c pread_write.c ioctl.c +SSRC:= __longjmp.S setjmp.S bsd-setjmp.S bsd-_setjmp.S brk.S \ + clone.S __uClibc_syscall.S syscall.S vfork.S + +ARCH_DIR:=$(top_srcdir)libc/sysdeps/linux/powerpc +ARCH_OUT:=$(top_builddir)libc/sysdeps/linux/powerpc + +ARCH_CSRC:=$(patsubst %.c,$(ARCH_DIR)/%.c,$(CSRC)) +ARCH_COBJ:=$(patsubst %.c,$(ARCH_OUT)/%.o,$(CSRC)) +ARCH_SSRC:=$(patsubst %.S,$(ARCH_DIR)/%.S,$(SSRC)) +ARCH_SOBJ:=$(patsubst %.S,$(ARCH_OUT)/%.o,$(SSRC)) + +ARCH_OBJS:=$(ARCH_COBJ) $(ARCH_SOBJ) + +crt-y:=create +libc-a-y+=$(ARCH_OBJS) +libc-a-pic-y+=$(ARCH_OBJS:.o=.os) +libc-so-y+=$(ARCH_OBJS:.o=.os) + +#libc-multi-y+=$(ARCH_CSRC) +libc-nomulti-y+=$(ARCH_OBJS) + +objclean-y+=arch_objclean + +arch_objclean: + $(RM) $(ARCH_OUT)/*.{o,os} + +headers-y+=arch_headers + +arch_headers: + $(LN) -fs ../libc/sysdeps/linux/powerpc/fpu_control.h $(top_builddir)include/ diff --git a/libc/sysdeps/linux/x86_64/Makefile.in b/libc/sysdeps/linux/x86_64/Makefile.in new file mode 100644 index 000000000..a167993a2 --- /dev/null +++ b/libc/sysdeps/linux/x86_64/Makefile.in @@ -0,0 +1,38 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=brk.c sigaction.c __syscall_error.c mmap.c + +SSRC:=__longjmp.S vfork.S setjmp.S syscall.S bsd-setjmp.S bsd-_setjmp.S clone.S + +ARCH_DIR:=$(top_srcdir)libc/sysdeps/linux/x86_64 +ARCH_OUT:=$(top_builddir)libc/sysdeps/linux/x86_64 + +ARCH_CSRC:=$(patsubst %.c,$(ARCH_DIR)/%.c,$(CSRC)) +ARCH_COBJ:=$(patsubst %.c,$(ARCH_OUT)/%.o,$(CSRC)) +ARCH_SSRC:=$(patsubst %.S,$(ARCH_DIR)/%.S,$(SSRC)) +ARCH_SOBJ:=$(patsubst %.S,$(ARCH_OUT)/%.o,$(SSRC)) + +ARCH_OBJS:=$(ARCH_COBJ) $(ARCH_SOBJ) + +crt-y:=create +libc-a-y+=$(ARCH_OBJS) +libc-a-pic-y+=$(ARCH_OBJS:.o=.os) +libc-so-y+=$(ARCH_OBJS:.o=.os) + +#libc-multi-y+=$(ARCH_CSRC) +libc-nomulti-y+=$(ARCH_OBJS) + +objclean-y+=arch_objclean + +arch_objclean: + $(RM) $(ARCH_OUT)/*.{o,os} + +headers-y+=arch_headers + +arch_headers: + $(LN) -fs ../libc/sysdeps/linux/x86_64/fpu_control.h $(top_builddir)include/ diff --git a/libc/termios/Makefile.in b/libc/termios/Makefile.in new file mode 100644 index 000000000..8e32e1ae6 --- /dev/null +++ b/libc/termios/Makefile.in @@ -0,0 +1,41 @@ +# Makefile for uClibc +# +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:=tcgetattr.c tcgetsid.c tcsetattr.c ttyname.c + +MSRC:= termios.c +MOBJ:= tcdrain.o tcflow.o tcflush.o tcsendbreak.o tcsetpgrp.o tcgetpgrp.o \ + isatty.o cfgetospeed.o cfgetispeed.o cfsetospeed.o cfsetispeed.o \ + cfmakeraw.o cfsetspeed.o + +TERMIOS_DIR:=$(top_srcdir)libc/termios +TERMIOS_OUT:=$(top_builddir)libc/termios + +TERMIOS_SRC:=$(patsubst %.c,$(TERMIOS_DIR)/%.c,$(CSRC)) +TERMIOS_OBJ:=$(patsubst %.c,$(TERMIOS_OUT)/%.o,$(CSRC)) + +TERMIOS_MSRC:=$(patsubst %.c,$(TERMIOS_DIR)/%.c,$(MSRC)) +TERMIOS_MOBJ:=$(patsubst %.o,$(TERMIOS_OUT)/%.o,$(MOBJ)) +TERMIOS_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(TERMIOS_MOBJ)))) + +TERMIOS_OBJS:=$(TERMIOS_OBJ) $(TERMIOS_MOBJ) + +$(TERMIOS_MOBJ) $(TERMIOS_MOBJ:.o=.os): $(TERMIOS_MSRC) + $(compile.m) + +libc-a-y+=$(TERMIOS_OBJS) +libc-a-pic-y+=$(TERMIOS_OBJS:.o=.os) +libc-so-y+=$(TERMIOS_OBJS:.o=.os) + +CFLAGS-multi-y+=$(TERMIOS_DEF) +libc-multi-y+=$(TERMIOS_SRC) $(TERMIOS_MSRC) + +objclean-y+=termios_objclean + +termios_objclean: + $(RM) $(TERMIOS_OUT)/*.{o,os} diff --git a/libc/unistd/Makefile.in b/libc/unistd/Makefile.in new file mode 100644 index 000000000..a72b2d9ed --- /dev/null +++ b/libc/unistd/Makefile.in @@ -0,0 +1,51 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +CSRC:= sleep.c usleep.c ualarm.c getpass.c sysconf.c getlogin.c \ + fpathconf.c confstr.c pathconf.c swab.c usershell.c \ + getsubopt.c daemon.c + +MSRC:=exec.c +MOBJ:=execl.o execv.o execle.o execlp.o execvp.o + +ifneq ($(ARCH_HAS_MMU),y) +MOBJ+=__exec_alloc.o +endif + +ifeq ($(UCLIBC_HAS_GNU_GETOPT),y) +CSRC+=getopt.c +else +CSRC+=getopt-susv3.c +endif + +UNISTD_DIR:=$(top_srcdir)libc/unistd +UNISTD_OUT:=$(top_builddir)libc/unistd + +UNISTD_SRC:=$(patsubst %.c,$(UNISTD_DIR)/%.c,$(CSRC)) +UNISTD_OBJ:=$(patsubst %.c,$(UNISTD_OUT)/%.o,$(CSRC)) + +UNISTD_MSRC:=$(patsubst %.c,$(UNISTD_DIR)/%.c,$(MSRC)) +UNISTD_MOBJ:=$(patsubst %.o,$(UNISTD_OUT)/%.o,$(MOBJ)) + +UNISTD_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(UNISTD_MOBJ)))) + +UNISTD_OBJS:=$(UNISTD_OBJ) $(UNISTD_MOBJ) + +$(UNISTD_MOBJ) $(UNISTD_MOBJ:.o=.os): $(UNISTD_MSRC) + $(compile.m) + +libc-a-y+=$(UNISTD_OBJS) +libc-a-pic-y+=$(UNISTD_OBJS:.o=.os) +libc-so-y+=$(UNISTD_OBJS:.o=.os) + +CFLAGS-multi-y+=$(UNISTD_DEF) +libc-multi-y+=$(UNISTD_SRC) $(UNISTD_MSRC) + +objclean-y+=unistd_objclean + +unistd_objclean: + $(RM) $(UNISTD_OUT)/*.{o,os} diff --git a/libcrypt/Makefile.in b/libcrypt/Makefile.in index e5c4bcfa7..5394a0538 100644 --- a/libcrypt/Makefile.in +++ b/libcrypt/Makefile.in @@ -1,16 +1,31 @@ -# Makefile.in for uClibc +# Makefile for uClibc # -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # CFLAGS+=$(SSP_ALL_CFLAGS) +#DOMULTI=y + LIB_NAME:=libcrypt -srcdir=$(top_srcdir)$(LIB_NAME) +libcrypt_DIR:=$(top_srcdir)libcrypt +libcrypt_OUT:=$(top_builddir)libcrypt + +libcrypt_SRC:=$(wildcard $(libcrypt_DIR)/*.c) +libcrypt_OBJ:=$(patsubst $(libcrypt_DIR)/%.c,$(libcrypt_OUT)/%.o,$(libcrypt_SRC)) + +libcrypt-a-y:=$(libcrypt_OBJ) +libcrypt-a-pic-y:=$(libcrypt_OBJ:.o=.os) +libcrypt-so-y:=$(libcrypt_OBJ:.o=.os) + +libcrypt-multi-y:=$(libcrypt_SRC) -libso-y+=$(top_builddir)lib/$(LIB_NAME).so -liba-y+=$(top_builddir)lib/$(LIB_NAME).a -libclean-y+=$(LIB_NAME)_clean +objclean-y+=libcrypt_clean -include $(top_srcdir)Makefile.libs +lib-a-y+=$(top_builddir)lib/libcrypt.a +lib-a-pic-y+=$(top_builddir)lib/libcrypt.a +lib-so-y+=$(top_builddir)lib/libcrypt.so diff --git a/libintl/Makefile.in b/libintl/Makefile.in index cb0627dd7..8f5a75adc 100644 --- a/libintl/Makefile.in +++ b/libintl/Makefile.in @@ -1,23 +1,41 @@ -# Makefile.in for uClibc +# Makefile for uClibc # -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# Copyright (C) 2000 by Lineo, inc. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # CFLAGS+=$(SSP_ALL_CFLAGS) -LIB_NAME:=libintl +#DOMULTI=y -srcdir=$(top_srcdir)$(LIB_NAME) -$(LIB_NAME)_DIR:=$(top_builddir)$(LIB_NAME) +LIB_NAME:=libintl -$(LIB_NAME)_MSRC:=$(srcdir)/intl.c MOBJ:=gettext.o ngettext.o dgettext.o dcgettext.o dngettext.o dcngettext.o \ textdomain.o bindtextdomain.o bind_textdomain_codeset.o \ _nl_expand_alias.o _nl_msg_cat_cntr.o # glibc-isms -$(LIB_NAME)_MOBJ:=$(patsubst %.o,$($(LIB_NAME)_DIR)/%.o,$(MOBJ)) -libso-$(UCLIBC_HAS_GETTEXT_AWARENESS)+=$(top_builddir)lib/$(LIB_NAME).so -liba-$(UCLIBC_HAS_GETTEXT_AWARENESS)+=$(top_builddir)lib/$(LIB_NAME).a -libclean-y+=$(LIB_NAME)_clean +libintl_DIR:=$(top_srcdir)libintl +libintl_OUT:=$(top_builddir)libintl + +libintl_MSRC:=$(libintl_DIR)/intl.c +libintl_MOBJ:=$(patsubst %.o,$(libintl_OUT)/%.o,$(MOBJ)) + +libintl_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(libintl_MOBJ)))) + +$(libintl_MOBJ) $(libintl_MOBJ:.o=.os): $(libintl_MSRC) + $(compile.m) + +libintl-a-$(UCLIBC_HAS_GETTEXT_AWARENESS):=$(libintl_MOBJ) +libintl-a-pic-$(UCLIBC_HAS_GETTEXT_AWARENESS):=$(libintl_MOBJ:.o=.os) +libintl-so-$(UCLIBC_HAS_GETTEXT_AWARENESS):=$(libintl_MOBJ:.o=.os) + +CFLAGS-multi-$(UCLIBC_HAS_GETTEXT_AWARENESS):=$(libintl_DEF) +libintl-multi-$(UCLIBC_HAS_GETTEXT_AWARENESS):=$(libintl_MSRC) + +objclean-y+=libintl_clean -include $(top_srcdir)Makefile.libs +lib-a-$(UCLIBC_HAS_GETTEXT_AWARENESS)+=$(top_builddir)lib/libintl.a +lib-a-pic-$(UCLIBC_HAS_GETTEXT_AWARENESS)+=$(top_builddir)lib/libintl.a +lib-so-$(UCLIBC_HAS_GETTEXT_AWARENESS)+=$(top_builddir)lib/libintl.so diff --git a/libm/Makefile.in b/libm/Makefile.in index 1a90c567c..a61ceb2d2 100644 --- a/libm/Makefile.in +++ b/libm/Makefile.in @@ -1,16 +1,36 @@ -# Makefile.in for uClibc +# Makefile for uClibc # -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# +# The routines included in this math library are derived from the +# math library for Apple's MacOS X/Darwin math library, which was +# itself swiped from FreeBSD. The original copyright information +# is as follows: +# +# Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved. +# +# Developed at SunPro, a Sun Microsystems, Inc. business. +# Permission to use, copy, modify, and distribute this +# software is freely granted, provided that this notice +# is preserved. +# +# It has been ported to work with uClibc and generally behave +# by Erik Andersen <andersen@codepoet.org> # CFLAGS+=$(SSP_ALL_CFLAGS) CFLAGS+=-D_IEEE_LIBM -D_ISOC99_SOURCE -D_SVID_SOURCE +#DOMULTI=y + LIB_NAME:=libm -srcdir=$(top_srcdir)$(LIB_NAME) -$(LIB_NAME)_DIR:=$(top_builddir)$(LIB_NAME) +ifeq ($(HAS_FPU),y) +-include $(top_srcdir)libm/$(TARGET_ARCH)/Makefile.in +endif FL_MSRC:=float_wrappers.c @@ -52,33 +72,49 @@ CSRC:= w_acos.c w_asin.c s_atan.c w_atan2.c s_ceil.c s_cos.c \ FL_MOBJ:=sqrtf.o endif -$(LIB_NAME)_SRC:=$(patsubst %.c,$(srcdir)/%.c,$(CSRC)) - -$(LIB_NAME)_MSRC:=$(srcdir)/$(FL_MSRC) -$(LIB_NAME)_MOBJ:=$(patsubst %.o,$($(LIB_NAME)_DIR)/%.o,$(FL_MOBJ)) +libm_DIR:=$(top_srcdir)libm +libm_OUT:=$(top_builddir)libm +# assume that arch specific versions are provided as single sources/objects ifeq ($(HAS_FPU),y) -ifeq ($(DO_C99_MATH),y) -$(LIB_NAME)_ARCH_SRC:=$(wildcard $(srcdir)/$(TARGET_ARCH)/*.c) -$(LIB_NAME)_ARCH_OBJ:=$(patsubst $(srcdir)/$(TARGET_ARCH)/%.c,$($(LIB_NAME)_DIR)/$(TARGET_ARCH)/%.o,$($(LIB_NAME)_ARCH_SRC)) +ifneq ($(strip $(libm_ARCH_OBJS)),) # remove generic sources, if arch specific version is present -$(LIB_NAME)_NO_SRC:=$(patsubst $(srcdir)/$(TARGET_ARCH)/%.c,$(srcdir)/%.c,$($(LIB_NAME)_ARCH_SRC)) -$(LIB_NAME)_SRC:=$(filter-out $($(LIB_NAME)_NO_SRC),$($(LIB_NAME)_SRC)) -# add arch specific sources (assumed that these are not multi-sources) -$(LIB_NAME)_SRC+=$($(LIB_NAME)_ARCH_SRC) - -# remove generic objects produced from multi-sources, if arch specific version is present -$(LIB_NAME)_NO_MOBJ:=$(patsubst $($(LIB_NAME)_DIR)/$(TARGET_ARCH)/%.o,$($(LIB_NAME)_DIR)/%.o,$($(LIB_NAME)_ARCH_OBJ)) -$(LIB_NAME)_MOBJ:=$(filter-out $($(LIB_NAME)_NO_MOBJ),$($(LIB_NAME)_MOBJ)) +ifneq ($(strip $(libm_ARCH_SRC)),) +CSRC:=$(filter-out $(notdir $(libm_ARCH_SRC)),$(CSRC)) +endif + +# remove generic objects built from multi-sources, if arch specific version is present +FL_MOBJ:=$(filter-out $(notdir $(libm_ARCH_OBJS)),$(FL_MOBJ)) + +# we also try to remove % if s_% is in arch specific subdir +FL_MOBJ:=$(filter-out $(patsubst s_%.o,%.o,$(notdir $(libm_ARCH_OBJS))),$(FL_MOBJ)) endif endif -$(LIB_NAME)_arch_clean: - $(RM) $($(LIB_NAME)_DIR)/$(TARGET_ARCH)/*.{o,os} +libm_SRC:=$(patsubst %.c,$(libm_DIR)/%.c,$(CSRC)) +libm_OBJ:=$(patsubst $(libm_DIR)/%.c,$(libm_OUT)/%.o,$(libm_SRC)) + +libm_MSRC:=$(libm_DIR)/$(FL_MSRC) +libm_MOBJ:=$(patsubst %.o,$(libm_OUT)/%.o,$(FL_MOBJ)) + +libm_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(libm_MOBJ)))) + +libm_OBJS:=$(libm_OBJ) $(libm_MOBJ) + +$(libm_MOBJ) $(libm_MOBJ:.o=.os): $(libm_MSRC) + $(compile.m) + +libm-a-$(UCLIBC_HAS_FLOATS)+=$(libm_OBJS) +libm-a-pic-$(UCLIBC_HAS_FLOATS)+=$(libm_OBJS:.o=.os) +libm-so-$(UCLIBC_HAS_FLOATS)+=$(libm_OBJS:.o=.os) + +CFLAGS-multi-$(UCLIBC_HAS_FLOATS)+=$(libm_DEF) +libm-multi-$(UCLIBC_HAS_FLOATS)+=$(libm_MSRC) +libm-nomulti-$(UCLIBC_HAS_FLOATS)+=$(libm_OBJ) -libso-$(UCLIBC_HAS_FLOATS)+=$(top_builddir)lib/$(LIB_NAME).so -liba-$(UCLIBC_HAS_FLOATS)+=$(top_builddir)lib/$(LIB_NAME).a -libclean-y+=$(LIB_NAME)_clean $(LIB_NAME)_arch_clean +objclean-y+=libm_clean -include $(top_srcdir)Makefile.libs +lib-a-$(UCLIBC_HAS_FLOATS)+=$(top_builddir)lib/libm.a +lib-a-pic-$(UCLIBC_HAS_FLOATS)+=$(top_builddir)lib/libm.a +lib-so-$(UCLIBC_HAS_FLOATS)+=$(top_builddir)lib/libm.so diff --git a/libm/powerpc/Makefile.in b/libm/powerpc/Makefile.in new file mode 100644 index 000000000..bb0dfc9d0 --- /dev/null +++ b/libm/powerpc/Makefile.in @@ -0,0 +1,25 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +libm_ARCH_DIR:=$(top_srcdir)libm/powerpc +libm_ARCH_OUT:=$(top_builddir)libm/powerpc + +libm_ARCH_SRC:=$(wildcard $(libm_ARCH_DIR)/*.c) +libm_ARCH_OBJ:=$(patsubst $(libm_ARCH_DIR)/%.c,$(libm_ARCH_OUT)/%.o,$(libm_ARCH_SRC)) + +libm_ARCH_OBJS:=$(libm_ARCH_OBJ) + +libm-a-$(DO_C99_MATH)+=$(libm_ARCH_OBJS) +libm-a-pic-$(DO_C99_MATH)+=$(libm_ARCH_OBJS:.o=.os) +libm-so-$(DO_C99_MATH)+=$(libm_ARCH_OBJS:.o=.os) + +libm-multi-$(DO_C99_MATH)+=$(libm_ARCH_SRC) + +objclean-y+=libm_arch_objclean + +libm_arch_objclean: + $(RM) $(libm_ARCH_OUT)/*.{o,os} diff --git a/libnsl/Makefile.in b/libnsl/Makefile.in index 678e4c530..076eb49dd 100644 --- a/libnsl/Makefile.in +++ b/libnsl/Makefile.in @@ -1,16 +1,31 @@ -# Makefile.in for uClibc +# Makefile for uClibc # -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # CFLAGS+=$(SSP_ALL_CFLAGS) +# useless, only 1 source file +DOMULTI=n + LIB_NAME:=libnsl -srcdir=$(top_srcdir)$(LIB_NAME) +libnsl_DIR:=$(top_srcdir)libnsl +libnsl_OUT:=$(top_builddir)libnsl + +libnsl_SRC:=$(libnsl_DIR)/nsl.c +libnsl_OBJ:=$(patsubst $(libnsl_DIR)/%.c,$(libnsl_OUT)/%.o,$(libnsl_SRC)) + +libnsl-a-y:=$(libnsl_OBJ) +libnsl-a-pic-y:=$(libnsl_OBJ:.o=.os) +libnsl-so-y:=$(libnsl_OBJ:.o=.os) + +#libnsl-multi-y:=$(libnsl_SRC) -libso-y+=$(top_builddir)lib/$(LIB_NAME).so -liba-y+=$(top_builddir)lib/$(LIB_NAME).a -libclean-y+=$(LIB_NAME)_clean +objclean-y+=libnsl_clean -include $(top_srcdir)Makefile.libs +lib-a-y+=$(top_builddir)lib/libnsl.a +lib-a-pic-y+=$(top_builddir)lib/libnsl.a +lib-so-y+=$(top_builddir)lib/libnsl.so diff --git a/libpthread/Makefile.in b/libpthread/Makefile.in new file mode 100644 index 000000000..17a5adca9 --- /dev/null +++ b/libpthread/Makefile.in @@ -0,0 +1,57 @@ +# Makefile for uClibc +# +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. +# + +ifeq ($(PTHREADS_DEBUG_SUPPORT),y) +DIRS:= $(PTNAME) $(PTNAME)_db +libs: subdirs +else +# both do not work at once +include $(PTDIR)/Makefile.in +#include $(PTDIR)_db/Makefile.in +endif + +headers-y+=threads_headers + +# NPTL does not have a generic pthreadtypes.h +# and each arch has to have both semaphore.h/pthreadtypes.h ? +threads_headers: + $(LN) -sf $(PTDIR)/sysdeps/pthread/pthread.h $(top_builddir)include/ + $(LN) -sf $(PTDIR)/semaphore.h $(top_builddir)include/ +ifeq ($(PTHREADS_DEBUG_SUPPORT),y) + $(LN) -sf $(PTDIR)_db/thread_db.h $(top_builddir)include/ +endif +ifeq ($(UCLIBC_HAS_THREADS_NATIVE),y) + $(LN) -sf ../$(PTDIR)/sysdeps/unix/sysv/linux/$(TARGET_ARCH)/bits/semaphore.h $(top_builddir)include/bits/ + $(LN) -sf ../$(PTDIR)/sysdeps/unix/sysv/linux/$(TARGET_ARCH)/bits/pthreadtypes.h $(top_builddir)include/bits/ + $(LN) -sf ../$(PTDIR)/sysdeps/pthread/bits/libc-lock.h $(top_builddir)include/bits/ + $(LN) -sf ../$(PTDIR)/sysdeps/pthread/bits/stdio-lock.h $(top_builddir)include/bits/ +else + $(LN) -sf ../$(PTDIR)/sysdeps/pthread/bits/pthreadtypes.h $(top_builddir)include/bits/ +endif + +headers_clean-y+=threads_headers_clean + +threads_headers_clean: + $(RM) $(top_builddir)include/pthread.h $(top_builddir)include/semaphore.h \ + $(top_builddir)include/thread_db.h \ + $(top_builddir)include/bits/pthreadtypes.h $(top_builddir)include/bits/semaphore.h \ + $(top_builddir)include/bits/libc-lock.h $(top_builddir)include/bits/stdio-lock +ifeq ($(UCLIBC_HAS_THREADS_NATIVE),y) + $(RM) $(PTNAME)/version.h $(PTDIR)/banner.h \ + $(PTDIR)/sysdeps/unix/sysv/linux/rtld-libc-lowlevellock.c +endif + +objclean-y+=libpthread_gen_clean + +libpthread_gen_clean: + $(RM) $(top_builddir)libpthread/*/*.{o,os,a} + +ifeq ($(PTHREADS_DEBUG_SUPPORT),y) +subdirs: $(patsubst %, _dir_%, $(DIRS)) +$(patsubst %, _dir_%, $(DIRS)): + $(MAKE) -C $(patsubst _dir_%, %, $@) +endif diff --git a/libpthread/linuxthreads/Makefile.in b/libpthread/linuxthreads/Makefile.in index ed24d3f5c..026fd1452 100644 --- a/libpthread/linuxthreads/Makefile.in +++ b/libpthread/linuxthreads/Makefile.in @@ -1,55 +1,56 @@ -# Makefile.in for uClibc +# Makefile for uClibc's pthread library # -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# Copyright (C) 2003 Paul Mundt <lethal@linux-sh.org> +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # CFLAGS+=$(SSP_ALL_CFLAGS) -# Get the thread include dependencies -CFLAGS+=$(PTINC) - # This stuff will not compile without at least -O1 CFLAGS:=$(CFLAGS:-O0=-O1) -ARCH_CFLAGS:=$(CFLAGS) - LDFLAGS:=$(LDFLAGS_NOSTRIP) ifeq ($(UCLIBC_CTOR_DTOR),y) -SHARED_START_FILES=$(top_builddir)lib/crti.o $(LIBGCC_DIR)crtbeginS.o -SHARED_END_FILES = $(LIBGCC_DIR)crtendS.o $(top_builddir)lib/crtn.o +SHARED_START_FILES:=$(top_builddir)lib/crti.o $(LIBGCC_DIR)crtbeginS.o +SHARED_END_FILES:=$(LIBGCC_DIR)crtendS.o $(top_builddir)lib/crtn.o endif ifeq ($(PTHREADS_DEBUG_SUPPORT),y) STRIP_FLAGS:=-X --strip-debug -R .note -R .comment endif +DOMULTI=n + LIB_NAME:=libpthread -srcdir=$(top_srcdir)$(LIB_NAME)/linuxthreads -$(LIB_NAME)_DIR:=$(top_builddir)$(LIB_NAME)/linuxthreads -$(LIB_NAME)_SRC:=$(wildcard $(srcdir)/*.c) -ifneq ($(UCLIBC_HAS_XLOCALE),y) -$(LIB_NAME)_SRC:=$(filter-out $(srcdir)/locale.c,$($(LIB_NAME)_SRC)) -endif +libpthread_DIR:=$(top_srcdir)libpthread/linuxthreads +libpthread_OUT:=$(top_builddir)libpthread/linuxthreads -ARCH_DIR:=sysdeps/$(TARGET_ARCH) --include $(srcdir)/$(ARCH_DIR)/Makefile.in +ARCH_CFLAGS:=$(CFLAGS) +-include $(libpthread_DIR)/sysdeps/$(TARGET_ARCH)/Makefile.in +CFLAGS:=$(ARCH_CFLAGS) -$(LIB_NAME)_ARCH_SRC:=$(wildcard $(srcdir)/$(ARCH_DIR)/*.c) -$(LIB_NAME)_ARCH_OBJ:=$(patsubst $(srcdir)/$(ARCH_DIR)/%.c,$($(LIB_NAME)_DIR)/$(ARCH_DIR)/%.o,$($(LIB_NAME)_ARCH_SRC)) +libpthread_SRC:=$(wildcard $(libpthread_DIR)/*.c) +ifneq ($(UCLIBC_HAS_XLOCALE),y) +libpthread_SRC:=$(filter-out $(libpthread_DIR)/locale.c,$(libpthread_SRC)) +endif # remove generic sources, if arch specific version is present -$(LIB_NAME)_NO_SRC:=$(patsubst $(srcdir)/$(ARCH_DIR)/%.c,$(srcdir)/%.c,$($(LIB_NAME)_ARCH_SRC)) -$(LIB_NAME)_SRC:=$(filter-out $($(LIB_NAME)_NO_SRC),$($(LIB_NAME)_SRC)) -# add arch specific sources (assumed that these are not multi-sources) -$(LIB_NAME)_SRC+=$($(LIB_NAME)_ARCH_SRC) +ifneq ($(strip $(libpthread_ARCH_SRC)),) +libpthread_SRC:=$(filter-out $(patsubst %.c,$(libpthread_DIR)/%.c,$(notdir $(libpthread_ARCH_SRC))),$(libpthread_SRC)) +endif + +libpthread_OBJ:=$(patsubst $(libpthread_DIR)/%.c,$(libpthread_OUT)/%.o,$(libpthread_SRC)) -$(LIB_NAME)_arch_clean: - $(RM) $($(LIB_NAME)_DIR)/sysdeps/*/*.{o,os} +libpthread-a-$(UCLIBC_HAS_THREADS)+=$(libpthread_OBJ) +libpthread-a-pic-$(UCLIBC_HAS_THREADS)+=$(libpthread_OBJ:.o=.os) +libpthread-so-$(UCLIBC_HAS_THREADS)+=$(libpthread_OBJ:.o=.os) -libso-$(UCLIBC_HAS_THREADS)+=$(top_builddir)lib/$(LIB_NAME).so -liba-$(UCLIBC_HAS_THREADS)+=$(top_builddir)lib/$(LIB_NAME).a -libclean-y+=$(LIB_NAME)_clean $(LIB_NAME)_arch_clean +libpthread-multi-$(UCLIBC_HAS_THREADS)+=$(libpthread_SRC) -include $(top_srcdir)Makefile.libs +lib-a-$(UCLIBC_HAS_THREADS)+=$(top_builddir)lib/libpthread.a +lib-a-pic-$(UCLIBC_HAS_THREADS)+=$(top_builddir)lib/libpthread.a +lib-so-$(UCLIBC_HAS_THREADS)+=$(top_builddir)lib/libpthread.so diff --git a/libpthread/linuxthreads/sysdeps/sh64/Makefile.in b/libpthread/linuxthreads/sysdeps/sh64/Makefile.in index fed7a83b7..5aa54a64f 100644 --- a/libpthread/linuxthreads/sysdeps/sh64/Makefile.in +++ b/libpthread/linuxthreads/sysdeps/sh64/Makefile.in @@ -1,20 +1,27 @@ # Makefile for uClibc's sh64 pthread backend # # Copyright (C) 2003 Paul Mundt <lethal@linux-sh.org> +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> # -# This program is free software; you can redistribute it and/or modify it under -# the terms of the GNU Library General Public License as published by the Free -# Software Foundation; either version 2 of the License, or (at your option) any -# later version. +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # -# This program is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS -# FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more -# details. -# -# You should have received a copy of the GNU Library General Public License -# along with this program; if not, write to the Free Software Foundation, Inc., -# 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # We need to build as SHcompact for tas.. -ARCH_CFLAGS := $(subst 32media,compact,$(ARCH_CFLAGS)) +ARCH_CFLAGS:=$(subst 32media,compact,$(ARCH_CFLAGS)) + +libpthread_ARCH_DIR:=$(top_srcdir)libpthread/linuxthreads/sysdeps/sh64 +libpthread_ARCH_OUT:=$(top_builddir)libpthread/linuxthreads/sysdeps/sh64 + +libpthread_ARCH_SRC:=$(wildcard $(libpthread_ARCH_DIR)/*.c) +libpthread_ARCH_OBJ:=$(patsubst $(libpthread_ARCH_DIR)/%.c,$(libpthread_ARCH_OUT)/%.o,$(libpthread_ARCH_SRC)) + +libpthread-a-$(UCLIBC_HAS_THREADS)+=$(libpthread_ARCH_OBJ) +libpthread-a-pic-$(UCLIBC_HAS_THREADS)+=$(libpthread_ARCH_OBJ:.o=.os) +libpthread-so-$(UCLIBC_HAS_THREADS)+=$(libpthread_ARCH_OBJ:.o=.os) + +libpthread-multi-$(UCLIBC_HAS_THREADS)+=$(libpthread_ARCH_SRC) + +objclean-y+=libpthread_arch_objclean + +libpthread_arch_objclean: + $(RM) $(libpthread_ARCH_OUT)/*.{o,os} diff --git a/libpthread/linuxthreads_db/Makefile.in b/libpthread/linuxthreads_db/Makefile.in index 8a95e402a..18558089f 100644 --- a/libpthread/linuxthreads_db/Makefile.in +++ b/libpthread/linuxthreads_db/Makefile.in @@ -1,13 +1,15 @@ -# Makefile for uClibc's pthread library +# Makefile for uClibc # -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # #CFLAGS+=$(SSP_ALL_CFLAGS) PT_MAJOR_VERSION:=$(MAJOR_VERSION) # Get the thread include dependencies and shared object name -CFLAGS+=$(PTINC) -DLIBPTHREAD_SO="\"libpthread.so.$(PT_MAJOR_VERSION)\"" +CFLAGS+=-DLIBPTHREAD_SO="\"libpthread.so.$(PT_MAJOR_VERSION)\"" # Remove any -z defs since this lib will have undefined symbols LDFLAGS:=$(subst -z defs,,$(LDFLAGS)) --warn-unresolved-symbols @@ -16,13 +18,26 @@ ifeq ($(PTHREADS_DEBUG_SUPPORT),y) STRIP_FLAGS:=-X --strip-debug -R .note -R .comment endif +#DOMULTI=y + LIB_NAME:=libthread_db -srcdir=$(top_srcdir)libpthread/linuxthreads_db -$(LIB_NAME)_DIR:=$(top_builddir)libpthread/linuxthreads_db +libthread_db_FULL_NAME:=$(LIB_NAME)-$(MAJOR_VERSION).$(MINOR_VERSION).$(SUBLEVEL).so + MAJOR_VERSION:=1 -libso-$(PTHREADS_DEBUG_SUPPORT)+=$(top_builddir)lib/$(LIB_NAME).so -liba-$(PTHREADS_DEBUG_SUPPORT)+=$(top_builddir)lib/$(LIB_NAME).a -libclean-y+=$(LIB_NAME)_clean +libthread_db_DIR:=$(top_srcdir)libpthread/linuxthreads_db +libthread_db_OUT:=$(top_builddir)libpthread/linuxthreads_db + +libthread_db_SRC:=$(wildcard $(libthread_db_DIR)/*.c) + +libthread_db_OBJ:=$(patsubst $(libthread_db_DIR)/%.c,$(libthread_db_OUT)/%.o,$(libthread_db_SRC)) + +libthread_db-a-$(PTHREADS_DEBUG_SUPPORT)+=$(libthread_db_OBJ) +libthread_db-a-pic-$(PTHREADS_DEBUG_SUPPORT)+=$(libthread_db_OBJ:.o=.os) +libthread_db-so-$(PTHREADS_DEBUG_SUPPORT)+=$(libthread_db_OBJ:.o=.os) + +libthread_db-multi-$(PTHREADS_DEBUG_SUPPORT)+=$(libthread_db_SRC) -include $(top_srcdir)Makefile.libs +lib-a-$(PTHREADS_DEBUG_SUPPORT)+=$(top_builddir)lib/libthread_db.a +lib-a-pic-$(PTHREADS_DEBUG_SUPPORT)+=$(top_builddir)lib/libthread_db.a +lib-so-$(PTHREADS_DEBUG_SUPPORT)+=$(top_builddir)lib/libthread_db.so diff --git a/libresolv/Makefile.in b/libresolv/Makefile.in index b4d03fe66..8966f95a3 100644 --- a/libresolv/Makefile.in +++ b/libresolv/Makefile.in @@ -1,16 +1,31 @@ -# Makefile.in for uClibc +# Makefile for uClibc # -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # CFLAGS+=$(SSP_ALL_CFLAGS) +# useless, only 1 source file +DOMULTI=n + LIB_NAME:=libresolv -srcdir=$(top_srcdir)$(LIB_NAME) +libresolv_DIR:=$(top_srcdir)libresolv +libresolv_OUT:=$(top_builddir)libresolv + +libresolv_SRC:=$(libresolv_DIR)/resolv.c +libresolv_OBJ:=$(patsubst $(libresolv_DIR)/%.c,$(libresolv_OUT)/%.o,$(libresolv_SRC)) + +libresolv-a-y:=$(libresolv_OBJ) +libresolv-a-pic-y:=$(libresolv_OBJ:.o=.os) +libresolv-so-y:=$(libresolv_OBJ:.o=.os) + +#libresolv-multi-y:=$(libresolv_SRC) -libso-y+=$(top_builddir)lib/$(LIB_NAME).so -liba-y+=$(top_builddir)lib/$(LIB_NAME).a -libclean-y+=$(LIB_NAME)_clean +objclean-y+=libresolv_clean -include $(top_srcdir)Makefile.libs +lib-a-y+=$(top_builddir)lib/libresolv.a +lib-a-pic-y+=$(top_builddir)lib/libresolv.a +lib-so-y+=$(top_builddir)lib/libresolv.so diff --git a/librt/Makefile.in b/librt/Makefile.in index 7f3a311a3..aada591d9 100644 --- a/librt/Makefile.in +++ b/librt/Makefile.in @@ -1,16 +1,31 @@ -# Makefile.in for uClibc +# Makefile for uClibc # -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # CFLAGS+=$(SSP_ALL_CFLAGS) +# all files are syscall related +DOMULTI=n + LIB_NAME:=librt -srcdir=$(top_srcdir)$(LIB_NAME) +librt_DIR:=$(top_srcdir)librt +librt_OUT:=$(top_builddir)librt + +librt_SRC:=$(wildcard $(librt_DIR)/*.c) +librt_OBJ:=$(patsubst $(librt_DIR)/%.c,$(librt_OUT)/%.o,$(librt_SRC)) + +librt-a-y:=$(librt_OBJ) +librt-a-pic-y:=$(librt_OBJ:.o=.os) +librt-so-y:=$(librt_OBJ:.o=.os) + +#librt-multi-y+=$(librt_SRC) -libso-y+=$(top_builddir)lib/$(LIB_NAME).so -liba-y+=$(top_builddir)lib/$(LIB_NAME).a -libclean-y+=$(LIB_NAME)_clean +objclean-y+=librt_clean -include $(top_srcdir)Makefile.libs +lib-a-y+=$(top_builddir)lib/librt.a +lib-a-pic-y+=$(top_builddir)lib/librt.a +lib-so-y+=$(top_builddir)lib/librt.so diff --git a/libutil/Makefile.in b/libutil/Makefile.in index 8c5846400..6f6b03ea1 100644 --- a/libutil/Makefile.in +++ b/libutil/Makefile.in @@ -1,21 +1,33 @@ -# Makefile.in for uClibc +# Makefile for uClibc # -# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details. +# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org> +# +# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # CFLAGS+=$(SSP_ALL_CFLAGS) +#DOMULTI=y + LIB_NAME:=libutil -srcdir=$(top_srcdir)$(LIB_NAME) +libutil_DIR:=$(top_srcdir)libutil +libutil_OUT:=$(top_builddir)libutil -$(LIB_NAME)_SRC:=$(wildcard $(srcdir)/*.c) +libutil_SRC:=$(wildcard $(libutil_DIR)/*.c) ifneq ($(ARCH_HAS_MMU),y) -$(LIB_NAME)_SRC:=$(filter-out $(srcdir)/forkpty.c,$($(LIB_NAME)_SRC)) +libutil_SRC:=$(filter-out $(libutil_DIR)/forkpty.c,$(libutil_SRC)) endif +libutil_OBJ:=$(patsubst $(libutil_DIR)/%.c,$(libutil_OUT)/%.o,$(libutil_SRC)) + +libutil-a-y:=$(libutil_OBJ) +libutil-a-pic-y:=$(libutil_OBJ:.o=.os) +libutil-so-y:=$(libutil_OBJ:.o=.os) + +libutil-multi-y:=$(libutil_SRC) -libso-y+=$(top_builddir)lib/$(LIB_NAME).so -liba-y+=$(top_builddir)lib/$(LIB_NAME).a -libclean-y+=$(LIB_NAME)_clean +objclean-y+=libutil_clean -include $(top_srcdir)Makefile.libs +lib-a-y+=$(top_builddir)lib/libutil.a +lib-a-pic-y+=$(top_builddir)lib/libutil.a +lib-so-y+=$(top_builddir)lib/libutil.so |