Permalink
Browse files

- removed error message if icu-config does not exists

- added a note that icu autodetection will not work if you specifiy any other ICU command line option


git-svn-id: https://svn.parrot.org/parrot/trunk@6725 d31e2699-5ff4-0310-a27c-f18f2fbe73fe
  • Loading branch information...
1 parent 1c034c7 commit a19497564bb504509d945ca19c2e023e75aa014b Jens Rieks committed Sep 30, 2004
Showing with 22 additions and 2 deletions.
  1. +3 −0 Configure.pl
  2. +19 −2 config/gen/icu.pl
View
@@ -188,6 +188,9 @@ =head2 Command-line Options
Use --icu-config=none to disable the autodetect feature. Parrot will
then be build with its own ICU.
+B<Note:> If you specifiy another ICU option than --icu-config, the
+autodetection functionality will be disabled.
+
=item C<--icuplatform=(platform)>
Use the given platform name to pass to ICU's runConfigureICU. (See icu/source/runConfigureICU for the list of available "platform" names, which specify both operating system and compiler.)
View
@@ -39,8 +39,25 @@ sub runstep {
print "specified a icu config parameter,\nICU autodetection disabled.\n"
if $verbose;
} elsif (!defined $icuconfig || !$icuconfig) {
- `icu-config --exists`;
- if (($? == -1) || ($? >> 8) != 0 ) {
+ my $notfound = 1;
+
+ {
+ # disable STDERR
+ open OLDERR, ">&", \*STDERR;
+ open STDERR, ">d8e622ad2.log";
+
+ # check if ICU is installed
+ system("icu-config", "--exists");
+ $notfound = ($? == -1);
+ $notfound ||= ($? >> 8) != 0;
+
+ # reenable STDERR
+ close STDERR;
+ unlink "d8e622ad2.log";
+ open STDERR, ">&", \*OLDERR;
+ }
+
+ if ($notfound) {
undef $icuconfig;
print "icu-config not found.\n" if $verbose;
} else {

0 comments on commit a194975

Please sign in to comment.