mirror of
https://github.com/netwide-assembler/nasm.git
synced 2025-04-06 18:30:21 +08:00
doc/genps: make sure we pick up nasmlogo.eps when building cross-dir
When building in a different directory, we still want to make sure we pick up nasmlogo.eps. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
This commit is contained in:
parent
d31a74e301
commit
984c6011ba
@ -63,7 +63,8 @@ version.src: $(top_srcdir)/version.pl $(top_srcdir)/version
|
||||
|
||||
nasmdoc.ps: nasmdoc.dip genps.pl afmmetrics.ph ttfmetrics.ph \
|
||||
pswidth.ph nasmlogo.eps psfonts.ph head.ps
|
||||
$(PERL) $(srcdir)/genps.pl -headps $(srcdir)/head.ps nasmdoc.dip \
|
||||
$(PERL) $(srcdir)/genps.pl -epsdir "$(srcdir)" \
|
||||
-headps $(srcdir)/head.ps nasmdoc.dip \
|
||||
> nasmdoc.ps
|
||||
|
||||
nasmdoc.pdf: nasmdoc.ps pspdf.pl
|
||||
|
14
doc/genps.pl
14
doc/genps.pl
@ -92,6 +92,10 @@ require 'findfont.ph'; # Find fonts in the system
|
||||
# Canned header file
|
||||
$headps = 'head.ps';
|
||||
|
||||
# Directories
|
||||
$fontsdir = 'fonts';
|
||||
$epsdir = File::Spec->curdir();
|
||||
|
||||
#
|
||||
# Parse the command line
|
||||
#
|
||||
@ -107,11 +111,13 @@ while ( $arg = shift(@ARGV) ) {
|
||||
$psbool{$parm} = $true;
|
||||
} elsif ( $true && defined($psconf{$parm}) ) {
|
||||
$psconf{$parm} = shift(@ARGV);
|
||||
} elsif ( $parm =~ /^(title|subtitle|year|author|license)$/ ) {
|
||||
} elsif ( $true && $parm =~ /^(title|subtitle|year|author|license)$/ ) {
|
||||
$metadata{$parm} = shift(@ARGV);
|
||||
} elsif ( $parm =~ /^fontsdir$/ ) {
|
||||
} elsif ( $true && $parm eq 'fontsdir' ) {
|
||||
$fontsdir = shift(@ARGV);
|
||||
} elsif ( $parm eq 'headps' ) {
|
||||
} elsif ( $true && $parm eq 'epsdir' ) {
|
||||
$epsdir = shift(@ARGV);
|
||||
} elsif ( $true && $parm eq 'headps' ) {
|
||||
$headps = shift(@ARGV);
|
||||
} else {
|
||||
die "$0: Unknown option: $arg\n";
|
||||
@ -1161,7 +1167,7 @@ print "sti show\n";
|
||||
# and DocumentFonts in the header of the EPSF and add those to the
|
||||
# global header.
|
||||
if ( defined($metadata{epslogo}) &&
|
||||
open(EPS, '<', $metadata{epslogo}) ) {
|
||||
open(EPS, '<', File::Spec->catfile($epsdir, $metadata{epslogo})) ) {
|
||||
my @eps = ();
|
||||
my ($bbllx,$bblly,$bburx,$bbury) = (undef,undef,undef,undef);
|
||||
my $line;
|
||||
|
Loading…
x
Reference in New Issue
Block a user