Makefile: fix samples install
author"Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Sun Jul 31 20:44:10 2011 +0200 (2011-07-31)
changeset 25776fc224df66e8
parent 2576 af55c37bbd84
child 2578 35afb309f957
Makefile: fix samples install

Installing samples was not installing the C library config file
and the reported.by description.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Makefile.in
     1.1 --- a/Makefile.in	Sun Jul 31 00:04:02 2011 +0200
     1.2 +++ b/Makefile.in	Sun Jul 31 20:44:10 2011 +0200
     1.3 @@ -266,12 +266,19 @@
     1.4  #  - change every occurrence of CT_TOP_DIR to CT_LIB_DIR
     1.5  install-lib-samples: $(DESTDIR)$(LIBDIR) install-lib-main
     1.6  	@echo "  INSTDIR 'samples/'"
     1.7 -	@for samp_file in samples/*/crosstool.config; do                        \
     1.8 -	     mkdir -p "$(DESTDIR)$(LIBDIR)/$${samp_file%/*}";                   \
     1.9 +	@for samp_dir in samples/*/; do                                         \
    1.10 +	     mkdir -p "$(DESTDIR)$(LIBDIR)/$${samp_dir}";                       \
    1.11  	     $(sed) -r -e 's:\$$\{CT_TOP_DIR\}:\$$\{CT_LIB_DIR\}:;'             \
    1.12  	               -e 's:^(CT_WORK_DIR)=.*:\1="\$${CT_TOP_DIR}/.build":;'   \
    1.13 -	            $${samp_file}                                               \
    1.14 -	            >"$(DESTDIR)$(LIBDIR)/$${samp_file}";                       \
    1.15 +	            $${samp_dir}/crosstool.config                               \
    1.16 +	            >"$(DESTDIR)$(LIBDIR)/$${samp_dir}/crosstool.config";       \
    1.17 +	     $(install) -m 644 "$${samp_dir}/reported.by"                       \
    1.18 +	                       "$(DESTDIR)$(LIBDIR)/$${samp_dir}";              \
    1.19 +	     for libc_cfg in "$${samp_dir}/"*libc*.config; do                   \
    1.20 +	         [ -f "$${libc_cfg}" ] || continue;                             \
    1.21 +	         $(install) -m 644 "$${libc_cfg}"                               \
    1.22 +	                           "$(DESTDIR)$(LIBDIR)/$${samp_dir}";          \
    1.23 +	     done;                                                              \
    1.24  	 done
    1.25  	@$(install) -m 644 samples/samples.mk "$(DESTDIR)$(LIBDIR)/samples/samples.mk"
    1.26