From 74f6ae493d2b026331a05f1fac94e9954993ae95 Mon Sep 17 00:00:00 2001 From: "sfraser%netscape.com" Date: Wed, 20 Sep 2000 20:03:34 +0000 Subject: [PATCH] Fixes from the jar branch; ensure we launch CodeWarrior before building, so that idepath.txt gets written out. git-svn-id: svn://10.0.0.236/trunk@79644 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/build/mac/CodeWarriorLib.pm | 14 ++++++++++---- mozilla/build/mac/Moz.pm | 8 +++++++- mozilla/build/mac/NGLayoutBuildList.pm | 3 +++ 3 files changed, 20 insertions(+), 5 deletions(-) diff --git a/mozilla/build/mac/CodeWarriorLib.pm b/mozilla/build/mac/CodeWarriorLib.pm index 76fc7918f89..d52b14eefc7 100644 --- a/mozilla/build/mac/CodeWarriorLib.pm +++ b/mozilla/build/mac/CodeWarriorLib.pm @@ -27,6 +27,7 @@ Replaces the AppleScript library I. use strict; use Cwd; use Mac::Types; +use Mac::Events; use Mac::AppleEvents; use Mac::AppleEvents::Simple; use Mac::Processes; @@ -253,10 +254,15 @@ sub activate () { launchAppSpec => $appath, launchControlFlags => launchContinue() + launchNoFileFlags() ); - unless (LaunchApplication($lp)) { - unlink($filepath); - die $^E; - } + unless (LaunchApplication($lp)) { + unlink($filepath); + die $^E; + } + + #call WNE to allow launch/switch to happen + WaitNextEvent(); + WaitNextEvent(); + WaitNextEvent(); } =pod diff --git a/mozilla/build/mac/Moz.pm b/mozilla/build/mac/Moz.pm index 814fe9f46a2..f6f56e60855 100644 --- a/mozilla/build/mac/Moz.pm +++ b/mozilla/build/mac/Moz.pm @@ -37,7 +37,7 @@ use Mac::Processes; use File::Copy; @ISA = qw(Exporter); -@EXPORT = qw(BuildProject BuildProjectClean GetFileModDate OpenErrorLog MakeAlias StopForErrors DontStopForErrors InstallFromManifest InstallResources SetBuildNumber SetAgentString SetTimeBomb Delay ActivateApplication); +@EXPORT = qw(LaunchCodeWarrior BuildProject BuildProjectClean GetFileModDate OpenErrorLog MakeAlias StopForErrors DontStopForErrors InstallFromManifest InstallResources SetBuildNumber SetAgentString SetTimeBomb Delay ActivateApplication); @EXPORT_OK = qw(CloseErrorLog UseCodeWarriorLib QUIET); use Cwd; @@ -499,6 +499,12 @@ sub GetFileModDate($) } +sub LaunchCodeWarrior() +{ + # this both launches and writes idepath.txt + CodeWarriorLib::activate(); +} + sub ActivateApplication($) { my ($appSignature) = @_; diff --git a/mozilla/build/mac/NGLayoutBuildList.pm b/mozilla/build/mac/NGLayoutBuildList.pm index c78389f034a..81e25d7e9e4 100644 --- a/mozilla/build/mac/NGLayoutBuildList.pm +++ b/mozilla/build/mac/NGLayoutBuildList.pm @@ -334,6 +334,9 @@ sub ConfigureBuildSystem() #// In the future, we may want to do configurations based on the actual build system itself. #// _genBuildSystemInfo(); + # launch codewarrior and write idepath.txt + LaunchCodeWarrior(); + #// For now, if we discover a newer header file than existed in Universal Interfaces 3.2, #// we'll assume that 3.3 or later is in use. my($universal_interfaces) = getCodeWarriorPath("MacOS Support:Universal:Interfaces:CIncludes:");