summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ldso/libdl/Makefile.in51
-rw-r--r--libm/Makefile.in84
2 files changed, 135 insertions, 0 deletions
diff --git a/ldso/libdl/Makefile.in b/ldso/libdl/Makefile.in
new file mode 100644
index 000000000..b3dca7d9c
--- /dev/null
+++ b/ldso/libdl/Makefile.in
@@ -0,0 +1,51 @@
+# Makefile.in for uClibc
+#
+# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details.
+#
+
+CFLAGS+=$(SSP_ALL_CFLAGS) -DUCLIBC_RUNTIME_PREFIX=\"$(RUNTIME_PREFIX)\"
+
+ifeq ($(SUPPORT_LD_DEBUG),y)
+CFLAGS+=-D__SUPPORT_LD_DEBUG__
+endif
+
+# BEWARE!!! At least mips* will die if -O0 is used!!!
+ifeq ($(TARGET_ARCH),mips)
+CFLAGS:=$(CFLAGS:-O0=-O1)
+endif
+
+CFLAGS:=-I$(top_srcdir)ldso/include -I$(top_srcdir)ldso/ldso $(CFLAGS)
+
+CFLAGS-.os=-DSHARED
+# we adapt CFLAGS, because libdl.a has an additional object
+ifeq ($(DOPIC),y)
+CFLAGS-.o=$(PICFLAG)
+resolv:=$(top_builddir)ldso/$(TARGET_ARCH)/resolv.os
+else
+resolv:=$(top_builddir)ldso/$(TARGET_ARCH)/resolv.o
+endif
+
+EXTRA_LINK_OPTS:=-fini dl_cleanup
+#EXTRA_LINK_LIBS:=$(interp) -L$(top_builddir)lib -lc $(LDADD_LIBFLOAT) $(top_builddir)lib/$(UCLIBC_LDSO) $(LIBGCC)
+
+# 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
+
+LIB_NAME:=libdl
+srcdir=$(top_srcdir)ldso/$(LIB_NAME)
+$(LIB_NAME)_DIR:=$(top_builddir)ldso/$(LIB_NAME)
+
+$(LIB_NAME)_SRC:=$(srcdir)/libdl.c
+
+libso-$(HAVE_SHARED)+=$(top_builddir)lib/$(LIB_NAME).so
+liba-$(HAVE_SHARED)+=$(top_builddir)lib/$(LIB_NAME).a
+libclean-y+=$(LIB_NAME)_clean
+
+include $(top_srcdir)Makefile.libs
+
+# !!! these lines have to come after including Makefile.libs !!!
+EXTRA_LINK_LIBS+=$(top_builddir)lib/$(UCLIBC_LDSO)
+
+# should only go into libdl.a, OBJ_PIC is not modified here
+$(LIB_NAME)_OBJ+=$(resolv)
diff --git a/libm/Makefile.in b/libm/Makefile.in
new file mode 100644
index 000000000..1a90c567c
--- /dev/null
+++ b/libm/Makefile.in
@@ -0,0 +1,84 @@
+# Makefile.in for uClibc
+#
+# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details.
+#
+
+CFLAGS+=$(SSP_ALL_CFLAGS)
+
+CFLAGS+=-D_IEEE_LIBM -D_ISOC99_SOURCE -D_SVID_SOURCE
+
+LIB_NAME:=libm
+
+srcdir=$(top_srcdir)$(LIB_NAME)
+$(LIB_NAME)_DIR:=$(top_builddir)$(LIB_NAME)
+
+FL_MSRC:=float_wrappers.c
+
+ifeq ($(DO_C99_MATH),y)
+CSRC:= e_acos.c e_acosh.c e_asin.c e_atan2.c e_atanh.c e_cosh.c \
+ e_exp.c e_fmod.c e_gamma.c e_gamma_r.c e_hypot.c e_j0.c \
+ e_j1.c e_jn.c e_lgamma.c e_lgamma_r.c e_log.c e_log10.c \
+ e_pow.c e_remainder.c e_rem_pio2.c e_scalb.c e_sinh.c \
+ e_sqrt.c k_cos.c k_rem_pio2.c k_sin.c k_standard.c k_tan.c \
+ s_asinh.c s_atan.c s_cbrt.c s_ceil.c s_copysign.c s_cos.c \
+ s_erf.c s_expm1.c s_fabs.c s_finite.c s_floor.c s_frexp.c \
+ s_ilogb.c s_ldexp.c s_lib_version.c s_log1p.c s_logb.c \
+ s_matherr.c s_modf.c s_nextafter.c s_rint.c s_scalbn.c \
+ s_signgam.c s_significand.c s_sin.c s_tan.c s_tanh.c \
+ w_acos.c w_acosh.c w_asin.c w_atan2.c w_atanh.c w_cabs.c \
+ w_cosh.c w_drem.c w_exp.c w_fmod.c w_gamma.c w_gamma_r.c \
+ w_hypot.c w_j0.c w_j1.c w_jn.c w_lgamma.c w_lgamma_r.c \
+ w_log.c w_log10.c w_pow.c w_remainder.c w_scalb.c w_sinh.c \
+ w_sqrt.c fpmacros.c nan.c s_ceilf.c s_floorf.c
+FL_MOBJ:=acosf.o acoshf.o asinf.o asinhf.o atan2f.o atanf.o atanhf.o cbrtf.o \
+ ceilf.o copysignf.o cosf.o coshf.o erfcf.o erff.o exp2f.o expf.o \
+ expm1f.o fabsf.o fdimf.o floorf.o fmaf.o fmaxf.o fminf.o fmodf.o \
+ frexpf.o hypotf.o ilogbf.o ldexpf.o lgammaf.o log10f.o log1pf.o \
+ log2f.o logbf.o logf.o lrintf.o lroundf.o modff.o nearbyintf.o \
+ nextafterf.o powf.o remainderf.o remquof.o rintf.o roundf.o \
+ scalblnf.o scalbnf.o sinf.o sinhf.o sqrtf.o tanf.o tanhf.o \
+ tgammaf.o truncf.o
+else
+# This list of math functions was taken from POSIX/IEEE 1003.1b-1993
+CSRC:= w_acos.c w_asin.c s_atan.c w_atan2.c s_ceil.c s_cos.c \
+ w_cosh.c w_exp.c s_fabs.c s_floor.c w_fmod.c s_frexp.c \
+ s_ldexp.c w_log.c w_log10.c s_modf.c w_pow.c s_sin.c \
+ w_sinh.c w_sqrt.c s_tan.c s_tanh.c \
+ s_expm1.c s_scalbn.c s_copysign.c e_acos.c e_asin.c e_atan2.c \
+ k_cos.c e_cosh.c e_exp.c e_fmod.c e_log.c e_log10.c e_pow.c \
+ k_sin.c e_sinh.c e_sqrt.c k_tan.c e_rem_pio2.c k_rem_pio2.c \
+ s_finite.c
+# We'll add sqrtf to avoid problems with libstdc++
+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))
+
+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))
+
+# 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))
+endif
+endif
+
+$(LIB_NAME)_arch_clean:
+ $(RM) $($(LIB_NAME)_DIR)/$(TARGET_ARCH)/*.{o,os}
+
+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
+
+include $(top_srcdir)Makefile.libs