# concatenate only if that is true.
depend:
@: {- output_off() if $disabled{makedepend}; "" -}
- @if [ -z "`find $(DEPS) -newer Makefile`" ]; then \
+ @if [ -z "`find $(DEPS) -newer Makefile 2>/dev/null; exit 0`" ]; then \
( sed -e '/^# DO NOT DELETE THIS LINE.*/,$$d' < Makefile; \
echo '# DO NOT DELETE THIS LINE -- make depend depends on it.'; \
echo; \
# A method to extract all names from a .pod file
# The first sed extracts everything between "=head1 NAME" and the next =head1
-# The second sed joins all the lines into one
-# The third sed removes the description and turns all commas into spaces
+# The perl command joins all the lines into one
+# The second sed removes the description and turns all commas into spaces
# VoilĂ , you have a space separated list of names!
EXTRACT_NAMES=sed -e '1,/^=head1 *NAME *$$/d;/^=head1/,$$d' | \
- sed -e ':a;{N;s/\n/ /;ba}' | \
+ $(PERL) -p -0 -e 's/\n/ /g; END {print "\n"}' | \
sed -e 's/ - .*$$//;s/,/ /g'
PROCESS_PODS=\
set -e; \
lint:
lint -DLINT $(INCLUDES) $(SRCS)
-generate_apps: $(SRCDIR)/apps/openssl-vms.cnf $(SRCDIR)/apps/progs.h
+generate_apps: $(SRCDIR)/apps/openssl-vms.cnf
generate_crypto_bn: $(SRCDIR)/crypto/bn/bn_prime.h
$(PERL) $(SRCDIR)/VMS/VMSify-conf.pl \
< $(SRCDIR)/apps/openssl.cnf > $(SRCDIR)/apps/openssl-vms.cnf
-{- # because the program apps/openssl has object files as sources, and
- # they then have the corresponding C files as source, we need to chain
- # the lookups in %unified_info
- my $apps_openssl = catfile("apps","openssl");
- our @openssl_source = map { @{$unified_info{sources}->{$_}} }
- @{$unified_info{sources}->{$apps_openssl}};
- ""; -}
-$(SRCDIR)/apps/progs.h:
- $(RM) $@
- $(PERL) $(SRCDIR)/apps/progs.pl {- join(" ", @openssl_source) -} > $@
-
$(SRCDIR)/crypto/bn/bn_prime.h: $(SRCDIR)/crypto/bn/bn_prime.pl
$(PERL) $(SRCDIR)/crypto/bn/bn_prime.pl > $(SRCDIR)/crypto/bn/bn_prime.h
my %args = @_;
my $generator = join(" ", @{$args{generator}});
my $incs = join("", map { " -I".$_ } @{$args{incs}});
+ my $deps = join(" ", @{$args{deps}});
if ($args{src} !~ /\.[sS]$/) {
return <<"EOF";
-$args{src}: $args{generator}->[0]
+$args{src}: $args{generator}->[0] $deps
\$(PERL) $generator > \$@
EOF
} else {
if ($args{src} =~ /\.S$/) {
(my $target = $args{src}) =~ s|\.S$|.s|;
return <<"EOF";
-$target: $args{generator}->[0]
+$target: $args{generator}->[0] $deps
( trap "rm -f \$@.*" INT 0; \\
$generator \$@.S; \\
\$(CC) \$(CFLAGS) $incs -E -P \$@.S > \$@.i && mv -f \$@.i \$@ )
}
# Otherwise....
return <<"EOF";
-$args{src}: $args{generator}->[0]
+$args{src}: $args{generator}->[0] $deps
$generator \$@
EOF
}
return <<"EOF";
-$args{src}: $args{generator}->[0]
+$args{src}: $args{generator}->[0] $deps
\$(CC) \$(CFLAGS) $incs -E -P \$< > \$@
EOF
}