diff options
author | Karl Williamson <khw@khw-desktop.(none)> | 2009-11-24 13:47:37 -0700 |
---|---|---|
committer | Steve Hay <SteveHay@planit.com> | 2009-11-25 18:19:21 +0000 |
commit | 3df51b85ce4a56647cf991297e3b51b9dffe4414 (patch) | |
tree | 0f390baed34059c08f5df180af31ba9962ec8faf /lib | |
parent | 7c76c2a0d87e7bfac7012fb2b38100addc903e9d (diff) | |
download | perl-3df51b85ce4a56647cf991297e3b51b9dffe4414.tar.gz |
wrap uniprops.t; makefile changes for mktables
Message-ID: <4B0C4744.7080401@khwilliamson.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/.gitignore | 1 | ||||
-rw-r--r-- | lib/unicore/Makefile | 2 | ||||
-rw-r--r-- | lib/unicore/mktables | 34 |
3 files changed, 16 insertions, 21 deletions
diff --git a/lib/.gitignore b/lib/.gitignore index 7cbb08f7e3..564bd091ed 100644 --- a/lib/.gitignore +++ b/lib/.gitignore @@ -381,5 +381,6 @@ /unicore/Heavy.pl /unicore/mktables.lst /unicore/Name.pl +unicore/TestProp.pl /unicore/To /unicore/lib diff --git a/lib/unicore/Makefile b/lib/unicore/Makefile index 0dd77b7bb5..4a3cdd373b 100644 --- a/lib/unicore/Makefile +++ b/lib/unicore/Makefile @@ -1,5 +1,5 @@ all: - ../../miniperl -I../../lib ./mktables -P ../../pod -T ../../t/re/uniprops.t -makelist + ../../miniperl -I../../lib ./mktables -P ../../pod -maketest -makelist -p clean: rm -fr *.pl To lib diff --git a/lib/unicore/mktables b/lib/unicore/mktables index 4d5ac6bed2..ee51608f77 100644 --- a/lib/unicore/mktables +++ b/lib/unicore/mktables @@ -549,10 +549,9 @@ while (@ARGV) { elsif ($arg eq '-P' && defined ($pod_directory = shift)) { -d $pod_directory or croak "Directory '$pod_directory' doesn't exist"; } - elsif ($arg eq '-maketest' - || ($arg eq '-T' && defined ($t_path = shift))) { + elsif ($arg eq '-maketest' || ($arg eq '-T' && defined ($t_path = shift))) + { $make_test_script = 1; - $t_path = 'TestProp.pl' unless defined $t_path; } elsif ($arg eq '-makelist') { $make_list = 1; @@ -588,11 +587,12 @@ usage: $0 [-c|-p|-q|-v|-w] [-C dir] [-L filelist] [ -P pod_dir ] except those specified by the -P and -T options will be done with respect to this directory. -P dir : Output $pod_file file to directory 'dir'. - -T path : Create a .t test file as 'path' + -T path : Create a test script as 'path'; overrides -maketest -L filelist : Use alternate 'filelist' instead of standard one -globlist : Take as input all non-Test *.txt files in current and sub directories - -maketest : Make test script + -maketest : Make test script 'TestProp.pl' in current (or -C directory), + overrides -T -makelist : Rewrite the file list $file_list based on current setup -check A B : Executes $0 only if A and B are the same END @@ -605,25 +605,17 @@ my $youngest = -M $0; # Do this before the chdir! # Change directories now, because need to read 'version' early. if ($use_directory) { - if ($pod_directory - && ! File::Spec->file_name_is_absolute($pod_directory)) - { + if ($pod_directory && ! File::Spec->file_name_is_absolute($pod_directory)) { $pod_directory = File::Spec->rel2abs($pod_directory); } - if ($t_path - && ! File::Spec->file_name_is_absolute($t_path)) - { + if ($t_path && ! File::Spec->file_name_is_absolute($t_path)) { $t_path = File::Spec->rel2abs($t_path); } chdir $use_directory or croak "Failed to chdir to '$use_directory':$!"; - if ($pod_directory - && File::Spec->file_name_is_absolute($pod_directory)) - { + if ($pod_directory && File::Spec->file_name_is_absolute($pod_directory)) { $pod_directory = File::Spec->abs2rel($pod_directory); } - if ($t_path - && File::Spec->file_name_is_absolute($t_path)) - { + if ($t_path && File::Spec->file_name_is_absolute($t_path)) { $t_path = File::Spec->abs2rel($t_path); } } @@ -915,8 +907,8 @@ my %ignored_files = ( my $HEADER=<<"EOF"; # !!!!!!! DO NOT EDIT THIS FILE !!!!!!! -# This file is machine-generated by $0 from the Unicode database, -# Version $string_version. Any changes made here will be lost! +# This file is machine-generated by $0 from the Unicode +# database, Version $string_version. Any changes made here will be lost! EOF my $INTERNAL_ONLY=<<"EOF"; @@ -13033,6 +13025,8 @@ sub make_property_test_script() { # tests are added, it will perturb all later ones in the .t file srand 0; + $t_path = 'TestProp.pl' unless defined $t_path; # the traditional name + force_unlink ($t_path); push @files_actually_output, $t_path; my $OUT; @@ -13233,7 +13227,7 @@ my @input_file_objects = ( Handler => \&process_PropertyAliases, ), Input_file->new(undef, v0, # No file associated with this - Progress_Message => 'Finishing Property Setup', + Progress_Message => 'Finishing property setup', Handler => \&finish_property_setup, ), Input_file->new('PropValueAliases.txt', v0, |