~ubuntu-branches/ubuntu/maverick/openssl/maverick

« back to all changes in this revision

Viewing changes to util/mk1mf.pl

  • Committer: Bazaar Package Importer
  • Author(s): Christoph Martin
  • Date: 2004-12-16 18:41:29 UTC
  • mto: (11.1.1 lenny)
  • mto: This revision was merged to the branch mainline in revision 3.
  • Revision ID: james.westby@ubuntu.com-20041216184129-z7xjkul57mh1jiha
Tags: upstream-0.9.7e
ImportĀ upstreamĀ versionĀ 0.9.7e

Show diffs side-by-side

added added

removed removed

Lines of Context:
10
10
$ssl_version="";
11
11
$banner="\t\@echo Building OpenSSL";
12
12
 
13
 
open(IN,"<Makefile.ssl") || die "unable to open Makefile.ssl!\n";
 
13
open(IN,"<Makefile") || die "unable to open Makefile!\n";
14
14
while(<IN>) {
15
15
    $ssl_version=$1 if (/^VERSION=(.*)$/);
16
16
    $OPTIONS=$1 if (/^OPTIONS=(.*)$/);
18
18
}
19
19
close(IN);
20
20
 
21
 
die "Makefile.ssl is not the toplevel Makefile!\n" if $ssl_version eq "";
 
21
die "Makefile is not the toplevel Makefile!\n" if $ssl_version eq "";
22
22
 
23
23
$infile="MINFO";
24
24
 
222
222
$cflags.=" -DOPENSSL_NO_SHA1" if $no_sha1;
223
223
$cflags.=" -DOPENSSL_NO_RIPEMD" if $no_ripemd;
224
224
$cflags.=" -DOPENSSL_NO_MDC2" if $no_mdc2;
225
 
$cflags.=" -DOPENSSL_NO_BF"  if $no_bf;
 
225
$cflags.=" -DOPENSSL_NO_BF"   if $no_bf;
226
226
$cflags.=" -DOPENSSL_NO_CAST" if $no_cast;
227
227
$cflags.=" -DOPENSSL_NO_DES"  if $no_des;
228
228
$cflags.=" -DOPENSSL_NO_RSA"  if $no_rsa;
236
236
$cflags.=" -DOPENSSL_NO_EC"   if $no_ec;
237
237
$cflags.=" -DOPENSSL_NO_ENGINE"   if $no_engine;
238
238
$cflags.=" -DOPENSSL_NO_HW"   if $no_hw;
 
239
$cflags.=" -DOPENSSL_FIPS"    if $fips;
239
240
#$cflags.=" -DRSAref"  if $rsaref ne "";
240
241
 
241
242
## if ($unix)
631
632
$rules.= &do_lib_rule("\$(SSLOBJ)","\$(O_SSL)",$ssl,$shlib,"\$(SO_SSL)");
632
633
$rules.= &do_lib_rule("\$(CRYPTOOBJ)","\$(O_CRYPTO)",$crypto,$shlib,"\$(SO_CRYPTO)");
633
634
 
634
 
$rules.=&do_link_rule("\$(BIN_D)$o\$(E_EXE)$exep","\$(E_OBJ)","\$(LIBS_DEP)","\$(L_LIBS) \$(EX_LIBS)");
635
 
 
 
635
if ($fips)
 
636
        {
 
637
        $rules.=&do_link_rule("\$(BIN_D)$o\$(E_EXE)$exep","\$(E_OBJ)","\$(LIBS_DEP)","\$(L_LIBS) \$(EX_LIBS)","\$(BIN_D)$o.sha1","\$(BIN_D)$o\$(E_EXE)$exep");
 
638
        }
 
639
else
 
640
        {
 
641
        $rules.=&do_link_rule("\$(BIN_D)$o\$(E_EXE)$exep","\$(E_OBJ)","\$(LIBS_DEP)","\$(L_LIBS) \$(EX_LIBS)");
 
642
        }
636
643
print $defs;
637
644
 
638
645
if ($platform eq "linux-elf") {
639
646
    print <<"EOF";
640
647
# Generate perlasm output files
641
648
%.cpp:
642
 
        (cd \$(\@D)/..; PERL=perl make -f Makefile.ssl asm/\$(\@F))
 
649
        (cd \$(\@D)/..; PERL=perl make -f Makefile asm/\$(\@F))
643
650
EOF
644
651
}
645
652
print "###################################################################\n";
921
928
                                  $no_aes=1; }
922
929
 
923
930
        elsif (/^rsaref$/)      { }
 
931
        elsif (/^fips$/)        { $fips=1; }
924
932
        elsif (/^gcc$/)         { $gcc=1; }
925
933
        elsif (/^debug$/)       { $debug=1; }
926
934
        elsif (/^profile$/)     { $profile=1; }