From e3e2a2c7151b3b10c0093cb29d76953e1d4a7d72 Mon Sep 17 00:00:00 2001 From: nobu Date: Mon, 27 Feb 2017 05:14:30 +0000 Subject: [PATCH] Makefile.in: verify-static-library * Makefile.in (verify-static-library): separate from LIBRUBY_A. no check every times by default. * lib/mkmf.rb (try_link): remove debugging symbol directory after linking, instead of try_do. * lib/mkmf.rb (try_link): bccwin32 support has been removed long ago. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57722 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- Makefile.in | 4 +++- lib/mkmf.rb | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Makefile.in b/Makefile.in index 569581efef..aceba87a7e 100644 --- a/Makefile.in +++ b/Makefile.in @@ -234,9 +234,11 @@ $(LIBRUBY_A): $(ECHO) linking static-library $@ $(Q) $(AR) $(ARFLAGS) $@ $(LIBRUBY_A_OBJS) $(INITOBJS) @-$(RANLIB) $@ 2> /dev/null || true + +verify-static-library: $(LIBRUBY_A) $(ECHO) verifying static-library $@ @$(PURIFY) $(CC) $(LDFLAGS) $(XLDFLAGS) $(MAINOBJ) $(LIBRUBY_A) $(MAINLIBS) $(EXTLIBS) $(LIBS) $(OUTFLAG)conftest$(EXEEXT) - @$(RM) conftest$(EXEEXT) conftest.c + @$(RMALL) conftest$(EXEEXT) conftest.c conftest.dSYM $(LIBRUBY_SO): @-$(PRE_LIBRUBY_UPDATE) diff --git a/lib/mkmf.rb b/lib/mkmf.rb index 533f3f85ce..42e39ca454 100644 --- a/lib/mkmf.rb +++ b/lib/mkmf.rb @@ -464,7 +464,6 @@ MSG xsystem(command, *opts) ensure log_src(src) - MakeMakefile.rm_rf "#{CONFTEST}.dSYM" end end @@ -556,7 +555,8 @@ MSG def try_link(src, opt="", *opts, &b) try_link0(src, opt, *opts, &b) ensure - MakeMakefile.rm_f "#{CONFTEST}*", "c0x32*" + MakeMakefile.rm_f "#{CONFTEST}*" + MakeMakefile.rm_rf "#{CONFTEST}.dSYM" end # Returns whether or not the +src+ can be compiled as a C source. +opt+ is