Mac OS X: moved startlazarus into lazarus bundle, patches from Dmitry (issue #12069)

git-svn-id: trunk@20437 -
This commit is contained in:
vincents 2009-06-05 13:30:47 +00:00
parent acd8f1f8dc
commit 7a0277395a
3 changed files with 50 additions and 39 deletions

View File

@ -9766,6 +9766,9 @@ end;
procedure TMainIDE.DoRestart;
const
DarwinStartlazBundlePath = 'Resources/startlazarus.app/Contents/MacOS/';
procedure StartStarter;
var
StartLazProcess : TProcessUTF8;
@ -9782,8 +9785,14 @@ procedure TMainIDE.DoRestart;
Params := TStringList.Create;
ParseCommandLine(Params, Dummy);
//DebugLn('Done parsing CommandLine');
{$ifndef darwin}
ExeName := AppendPathDelim(StartLazProcess.CurrentDirectory) +
'startlazarus' + GetExecutableExt;
{$else}
ExeName := ExpandUNCFileNameUTF8(StartLazProcess.CurrentDirectory);
ExeName := AppendPathDelim( ExtractFilePath(ExeName) ) +
DarwinStartlazBundlePath + 'startlazarus' + GetExecutableExt;
{$endif}
if not FileExistsUTF8(ExeName) then begin
IDEMessageDialog('Error',Format(lisCannotFindLazarusStarter,
[LineEnding, ExeName]),mtError,[mbCancel]);

View File

@ -1,43 +1,45 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleExecutable</key>
<string>startlazarus</string>
<key>CFBundleName</key>
<string>startlazarus</string>
<key>CFBundleIdentifier</key>
<string>startlazarus</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleSignature</key>
<string>star</string>
<key>CFBundleShortVersionString</key>
<string>0.1</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>CSResourcesFileMapped</key>
<true/>
<key>CFBundleDocumentTypes</key>
<array>
<dict>
<key>CFBundleTypeRole</key>
<string>Viewer</string>
<key>CFBundleTypeExtensions</key>
<array>
<string>*</string>
</array>
<key>CFBundleTypeOSTypes</key>
<array>
<string>fold</string>
<string>disk</string>
<string>****</string>
</array>
</dict>
</array>
<key>LSUIElement</key>
<true/>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleExecutable</key>
<string>startlazarus</string>
<key>CFBundleName</key>
<string>startlazarus</string>
<key>CFBundleIdentifier</key>
<string>com.company.startlazarus</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleSignature</key>
<string>star</string>
<key>CFBundleShortVersionString</key>
<string>0.1</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>CSResourcesFileMapped</key>
<true/>
<key>CFBundleDocumentTypes</key>
<array>
<dict>
<key>CFBundleTypeRole</key>
<string>Viewer</string>
<key>CFBundleTypeExtensions</key>
<array>
<string>*</string>
</array>
<key>CFBundleTypeOSTypes</key>
<array>
<string>fold</string>
<string>disk</string>
<string>****</string>
</array>
</dict>
</array>
</dict>
</plist>

View File

@ -1 +0,0 @@
../../../startlazarus

View File

@ -0,0 +1 @@
../../../../../../startlazarus