buildrootschalter/package/uclibc/0.9.31.1/0011-startfiles-Make-targets.patch
Vicente Olivert Riera 9e30c5c2b1 uclibc: rename patches to follow the new name structure
Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2014-10-25 11:24:02 +02:00

61 lines
2.5 KiB
Diff

Add startfiles and install_startfiles targets to the top-level Makefile, as
in uClibc 0.9.32 and later.
Signed-off-by: Simon Dawson <spdawson@gmail.com>
diff -Nurp a/Makefile.help b/Makefile.help
--- a/Makefile.help 2011-06-08 19:58:40.000000000 +0100
+++ b/Makefile.help 2013-08-10 21:17:46.572104259 +0100
@@ -14,6 +14,7 @@ help:
@echo 'Build:'
@echo ' all - libraries and generated headers'
@echo ' pregen - generate headers'
+ @echo ' startfiles - build startfiles (crt)'
@echo ' utils - build target utilities'
@echo ' (ldd, ldconfig, locale, iconv)'
@echo ' hostutils - build host utilities (see utils)'
@@ -32,6 +33,7 @@ help:
@echo ' install - install both the runtime and the headers'
@echo ' install_runtime - install the libraries'
@echo ' install_dev - install all headers and static libs'
+ @echo ' install_startfiles - install startfiles (crt)'
@echo ' install_headers - install headers excluding generated ones'
@echo ' install_utils - install target utilities'
@echo ' install_hostutils - install host utilities'
diff -Nurp a/Makefile.in b/Makefile.in
--- a/Makefile.in 2011-06-08 19:58:40.000000000 +0100
+++ b/Makefile.in 2013-08-10 21:10:55.248649101 +0100
@@ -193,6 +193,8 @@ install: install_runtime install_dev
RUNTIME_PREFIX_LIB_FROM_DEVEL_PREFIX_LIB=$(shell $(top_srcdir)extra/scripts/relative_path.sh $(DEVEL_PREFIX)$(MULTILIB_DIR) $(RUNTIME_PREFIX)$(MULTILIB_DIR))
+startfiles: $(crt-y)
+
$(top_builddir)extra/scripts/unifdef: |$(top_builddir)extra/scripts
$(top_builddir)extra/scripts/unifdef: $(top_srcdir)extra/scripts/unifdef.c
$(hcompile.u)
@@ -301,6 +303,10 @@ else
cd $(PREFIX)$(DEVEL_PREFIX)include && $(RM) -f wchar-stub.h
endif
+# Installs startfiles
+install_startfiles: startfiles | $(PREFIX)$(DEVEL_PREFIX)$(MULTILIB_DIR)
+ -$(INSTALL) -m 644 $(startfiles) $(PREFIX)$(DEVEL_PREFIX)$(MULTILIB_DIR)/
+
# Installs development library links.
install_dev: install_headers install_runtime | $(PREFIX)$(DEVEL_PREFIX)$(MULTILIB_DIR)
-$(INSTALL) -m 644 $(top_builddir)lib/*.[ao] $(PREFIX)$(DEVEL_PREFIX)$(MULTILIB_DIR)/
diff -Nurp a/Makerules b/Makerules
--- a/Makerules 2011-06-08 19:58:40.000000000 +0100
+++ b/Makerules 2013-08-10 21:24:21.287583111 +0100
@@ -406,7 +406,8 @@ endif
CRTS_COMPAT :=
#endif
-$(crt-y): $(CRTS) $(CTOR_TARGETS) $(CRTS_COMPAT) $(CRTRELOC)
+startfiles = $(CRTS) $(CTOR_TARGETS) $(CRTS_COMPAT) $(CRTRELOC)
+$(crt-y): $(startfiles)
$(CRTS) $(CTOR_TARGETS) $(CRTS_COMPAT) $(CRTRELOC): | headers
$(top_builddir)lib/$(NONSHARED_LIBNAME): $(libc-nonshared-y)