ports

morpheus ports
git clone git://git.2f30.org/ports
Log | Files | Refs | LICENSE

openssl-1.0.0d-windres.patch (2902B)


      1 URL: http://rt.openssl.org/Ticket/Display.html?id=2558
      2 Subject: make windres controllable via build env var settings
      3 
      4 atm, the windres code in openssl is only usable via the cross-compile prefix 
      5 option unlike all the other build tools. so add support for the standard $RC 
      6 / $WINDRES env vars as well.
      7 
      8 Index: Configure
      9 ===================================================================
     10 RCS file: /usr/local/src/openssl/CVSROOT/openssl/Configure,v
     11 retrieving revision 1.621.2.40
     12 diff -u -p -r1.621.2.40 Configure
     13 --- a/Configure	30 Nov 2010 22:19:26 -0000	1.621.2.40
     14 +++ b/Configure	4 Jul 2011 23:12:32 -0000
     15 @@ -1094,6 +1094,7 @@ my $shared_extension = $fields[$idx_shar
     16  my $ranlib = $ENV{'RANLIB'} || $fields[$idx_ranlib];
     17  my $ar = $ENV{'AR'} || "ar";
     18  my $arflags = $fields[$idx_arflags];
     19 +my $windres = $ENV{'RC'} || $ENV{'WINDRES'} || "windres";
     20  my $multilib = $fields[$idx_multilib];
     21  
     22  # if $prefix/lib$multilib is not an existing directory, then
     23 @@ -1511,12 +1512,14 @@ while (<IN>)
     24  		s/^AR=\s*/AR= \$\(CROSS_COMPILE\)/;
     25  		s/^NM=\s*/NM= \$\(CROSS_COMPILE\)/;
     26  		s/^RANLIB=\s*/RANLIB= \$\(CROSS_COMPILE\)/;
     27 +		s/^WINDRES=\s*/WINDRES= \$\(CROSS_COMPILE\)/;
     28  		s/^MAKEDEPPROG=.*$/MAKEDEPPROG= \$\(CROSS_COMPILE\)$cc/ if $cc eq "gcc";
     29  		}
     30  	else	{
     31  		s/^CC=.*$/CC= $cc/;
     32  		s/^AR=\s*ar/AR= $ar/;
     33  		s/^RANLIB=.*/RANLIB= $ranlib/;
     34 +		s/^WINDRES=.*/WINDRES= $windres/;
     35  		s/^MAKEDEPPROG=.*$/MAKEDEPPROG= $cc/ if $cc eq "gcc";
     36  		}
     37  	s/^CFLAG=.*$/CFLAG= $cflags/;
     38 Index: Makefile.org
     39 ===================================================================
     40 RCS file: /usr/local/src/openssl/CVSROOT/openssl/Makefile.org,v
     41 retrieving revision 1.295.2.10
     42 diff -u -p -r1.295.2.10 Makefile.org
     43 --- a/Makefile.org	27 Jan 2010 16:06:58 -0000	1.295.2.10
     44 +++ b/Makefile.org	4 Jul 2011 23:13:08 -0000
     45 @@ -66,6 +66,7 @@ EXE_EXT= 
     46  ARFLAGS=
     47  AR=ar $(ARFLAGS) r
     48  RANLIB= ranlib
     49 +WINDRES= windres
     50  NM= nm
     51  PERL= perl
     52  TAR= tar
     53 @@ -180,6 +181,7 @@ BUILDENV=	PLATFORM='$(PLATFORM)' PROCESS
     54  		CC='$(CC)' CFLAG='$(CFLAG)' 			\
     55  		AS='$(CC)' ASFLAG='$(CFLAG) -c'			\
     56  		AR='$(AR)' NM='$(NM)' RANLIB='$(RANLIB)'	\
     57 +		WINDRES='$(WINDRES)'				\
     58  		CROSS_COMPILE='$(CROSS_COMPILE)'	\
     59  		PERL='$(PERL)' ENGDIRS='$(ENGDIRS)'		\
     60  		SDIRS='$(SDIRS)' LIBRPATH='$(INSTALLTOP)/$(LIBDIR)'	\
     61 Index: Makefile.shared
     62 ===================================================================
     63 RCS file: /usr/local/src/openssl/CVSROOT/openssl/Makefile.shared,v
     64 retrieving revision 1.72.2.4
     65 diff -u -p -r1.72.2.4 Makefile.shared
     66 --- a/Makefile.shared	21 Aug 2010 11:36:49 -0000	1.72.2.4
     67 +++ b/Makefile.shared	4 Jul 2011 23:13:52 -0000
     68 @@ -293,7 +293,7 @@ link_a.cygwin:
     69  	fi; \
     70  	dll_name=$$SHLIB$$SHLIB_SOVER$$SHLIB_SUFFIX; \
     71  	$(PERL) util/mkrc.pl $$dll_name | \
     72 -		$(CROSS_COMPILE)windres -o rc.o; \
     73 +		$(WINDRES) -o rc.o; \
     74  	extras="$$extras rc.o"; \
     75  	ALLSYMSFLAGS='-Wl,--whole-archive'; \
     76  	NOALLSYMSFLAGS='-Wl,--no-whole-archive'; \