diff --git a/winsup/cygwin/Makefile.in b/winsup/cygwin/Makefile.in index c3aa7a186..0add2320b 100644 --- a/winsup/cygwin/Makefile.in +++ b/winsup/cygwin/Makefile.in @@ -105,7 +105,6 @@ RUNTESTFLAGS = DLL_NAME:=cygwin1.dll TEST_DLL_NAME:=${patsubst %1.dll,%0.dll,$(DLL_NAME)} TEST_LIB_NAME:=libcygwin0.a -STATIC_LIB_NAME:=libcygwin_s.a DIN_FILE=@DIN_FILE@ common.din DEF_FILE:=cygwin.def TLSOFFSETS_H:=@TLSOFFSETS_H@ @@ -413,15 +412,6 @@ DLL_OFILES:= \ $(MATH_OFILES) \ $(TZCODE_OFILES) -EXCLUDE_STATIC_OFILES:=$(addprefix --exclude=,\ - cygtls.o \ - dcrt0.o \ - exceptions.o \ - fork.o \ - signal.o \ - spawn.o \ -) - VERSION_OFILES:=version.o winver.o ifeq ($(target_cpu),x86_64) @@ -675,9 +665,6 @@ $(TEST_DLL_NAME): $(LDSCRIPT) dllfixdbg $(DLL_OFILES) $(LIBSERVER) $(LIBC) $(LIB $(LIB_NAME): $(DEF_FILE) $(LIBCOS) | $(TEST_DLL_NAME) ${srcdir}/mkimport ${toolopts} ${NEW_FUNCTIONS} $@ cygdll.a $(wordlist 2,99,$^) -${STATIC_LIB_NAME}: mkstatic ${TEST_DLL_NAME} - perl -d $< -x ${EXCLUDE_STATIC_OFILES} --library=${LIBC} --library=${LIBM} --ar=${AR} $@ cygwin.map - # Rule to make stub library used by testsuite # dependency set to $(LIB_NAME) to accommodate make -j2. $(TEST_LIB_NAME): $(LIB_NAME) diff --git a/winsup/cygwin/mkstatic b/winsup/cygwin/mkstatic deleted file mode 100755 index 1a488f80c..000000000 --- a/winsup/cygwin/mkstatic +++ /dev/null @@ -1,63 +0,0 @@ -#!/usr/bin/perl -use strict; -use Cwd; -use Getopt::Long; -use File::Temp qw/tempdir/; -use File::Basename; - -sub xsystem(@); - -my @exclude = (); -my @library = (); -my $ar; -our $x; -GetOptions('exclude=s'=>\@exclude, 'library=s'=>\@library, 'ar=s'=>\$ar, 'x!'=>\$x); - -die "$0: must specify --ar\n" unless defined $ar; -my $lib = shift or die "$0: missing lib argument\nusage: $0 lib [map-file]\n"; -$lib = Cwd::abs_path($lib); - -my %excludes = map {($_, 1)} @exclude; -my $libraries = join('|', map {quotemeta} @library); - -my %sources = (); -while (<>) { - my ($source, $file, $absfile); - if (m%^($libraries)\(([^)]*)\)%o) { - $source = $1; - $absfile = $file = $2; - } elsif (/^LOAD\s+(.*\.o)$/o) { - $source = '.'; - $file = $1; - $absfile = Cwd::abs_path($file); - } else { - next; - } - push @{$sources{$source}}, $absfile unless $excludes{$file} || $excludes{$source}; -} - -my $here = getcwd(); -my $dir = tempdir(CLEANUP=>1); -chdir $dir; -my @files = (); -for (sort keys %sources) { - if ($_ eq '.') { - xsystem '/bin/cp', '-a', @{$sources{$_}}, '.'; - } else { - xsystem $ar, 'x', $_, @{$sources{$_}}, '.'; - } - push @files, map {basename($_)} @{$sources{$_}}; -} - -unlink $lib; -xsystem $ar, 'crs', $lib, sort @files; -exit 0; - -sub xsystem(@) { - print join(' ', 'x', @_), "\n" if $x; - system(@_) == 0 or die "$0: $_[0] $_[1] $_[2]... exited with non-zero status\n"; -} - -END { - chdir '/tmp'; # Allow $dir directory removal on Windows -}