diff options
Diffstat (limited to 'Master/tlpkg/libexec')
-rwxr-xr-x | Master/tlpkg/libexec/ctan2tds | 29 |
1 files changed, 18 insertions, 11 deletions
diff --git a/Master/tlpkg/libexec/ctan2tds b/Master/tlpkg/libexec/ctan2tds index 042a4502146..bf3a6a7662b 100755 --- a/Master/tlpkg/libexec/ctan2tds +++ b/Master/tlpkg/libexec/ctan2tds @@ -6811,9 +6811,18 @@ sub POSTcontext { &mv_with_mkdir ("colors/icc/context", "tex/context/colors/icc"); &mv_with_mkdir ("context-readme.txt", "doc/context"); - print "still POST$package - copy user-level .lua to windows\n"; + print "still POST$package - copy user-level .lua to platforms\n"; + # discern which platforms don't have a luametatex binary from the tlpsrc. + my $ap = "$Master/tlpkg/tlpsrc/00texlive.autopatterns.tlpsrc"; + my $grep = "grep -A 1 global_no_lmtx_platforms $ap"; + chomp (my $no_lmtx_platforms = `$grep | sed -e 1d -e 's/^ *//'`); + die "could not find no_lmtx_platforms in $ap" if ! $no_lmtx_platforms; + my @no_lmtx_platforms = split (/,/, $no_lmtx_platforms); + print "\t no_lmtx_platforms = @no_lmtx_platforms\n"; + # my $w_bindir = "$TOPDEST/bin/windows"; &xmkdir ($w_bindir); + # # because bindirs_symlink uses cwd to determine the link: &xchdir ("$DEST/scripts/$package/lua"); my @exec = qw(context mtxrun); @@ -6822,12 +6831,8 @@ sub POSTcontext { # these should exist. die "POSTcontext: no context lua file $luafile" unless -s $luafile; &SYSTEM ("$CP $luafile $w_bindir/"); - &bindirs_symlink ($luafile, $luafile); + &bindirs_symlink ($luafile, $luafile, @no_lmtx_platforms); } - # but i386-netbsd is not supported in TL. - my $i386_netbsd_bindir = "$TOPDEST/bin/i386-netbsd"; - &SYSTEM ("$RM $i386_netbsd_bindir/context.lua"); - &SYSTEM ("$RM $i386_netbsd_bindir/mtxrun.lua"); print "still POST$package - user-level executable man pages\n"; &xchdir ("$DEST/doc/$package/scripts"); @@ -6880,7 +6885,6 @@ sub POSTcontext_legacy { &tl_man_to_pdf (); } - # Some files we remove from both context and context-legacy. sub context_common_removals { print "\t context_common_removals\n"; @@ -6889,7 +6893,7 @@ sub context_common_removals { # remove files Hans wants in his distribution but are confusing or # problematic in TeX Live. - &SYSTEM ("$RM -rf colors"); # nonfree + &SYSTEM ("$RM -rf colors/icc/profiles"); # nonfree &SYSTEM ("$RM -rf fonts/truetype/hoekwater/lm/");# lmtypewriter10-regular.ttf &SYSTEM ("$RM -rf fonts/data/tests/"); # texmfhome.otf &SYSTEM ("$RM -rf scripts/context/stubs/"); # install/setup @@ -6923,19 +6927,20 @@ sub remove_files_of_pkg { print "\n"; # remove any now-empty directories and cd back. - $RMDIR_EMPTY; + &xsystem ($RMDIR_EMPTY); &xchdir ($cwd); } # Called for the ConTeXt scripts, though conceivably could be used for # other things. Make a symlink in each Unix bindir (Windows is not # handled here) to EXEC, assuming its location is relative to cwd. +# Except also skip any platforms given as @OMIT_PLATFORMS. # # If LINKNAME is not given, the symlink is named as the basename of EXEC -# with any extension removed. +# with any extension removed. # sub bindirs_symlink { - my ($exec,$linkname) = @_; + my ($exec,$linkname,@omit_platforms) = @_; chomp (my $pwd = `pwd`); (my $intermediate_dirs = $pwd) =~ s,^.*/$DEST_TREE/,,; @@ -6954,8 +6959,10 @@ sub bindirs_symlink { chomp (my @platforms = `cd $Master/bin && ls`); print ("\t bindirs_symlink: platforms = @platforms\n"); for my $p (@platforms) { + print ("\t bindirs_symlink: considering platform $p\n"); next if $p =~ /win32|windows/; # windows handled separately next if $p eq "man"; # non-platform pain + next if grep { $_ eq $p } @omit_platforms; my $platdir = "$TOPDEST/bin/$p"; &xmkdir ($platdir); &SYSTEM ("ln -s $linktarget $platdir/$linkname"); |