Added better support for debugging.

Reviewed by me.
This commit is contained in:
Francisco Tolmasky committed 2008-12-09 14:08:57 -08:00
1 parent f6b3afa75c
commit a966e7520f
6 files changed
+95 -10

No files matched your search

+23
View File
@@ -0,0 +1,23 @@
/*
* bootstrap.js
* Objective-J
*
* Created by Francisco Tolmasky.
* Copyright 2008, 280 North, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
objj_import("main.j", YES, function() { main(); });
+1
View File
@@ -18,6 +18,7 @@
<file name = "evaluate.js" />
<file name = "static.js" />
<file name = "debug.js" />
<file name = "bootstrap.js" />
</filelist>
+5 -3
View File
@@ -37,9 +37,11 @@ var objj_files = { },
objj_bundlesForClass = { },
objj_searches = { };
var OBJJ_NO_FILE = {},
OBJJ_INCLUDE_PATHS = ["Frameworks", "SomethingElse"];
var OBJJ_NO_FILE = {};
if (!window.OBJJ_INCLUDE_PATHS)
var OBJJ_INCLUDE_PATHS = ["Frameworks", "SomethingElse"];
var OBJJ_BASE_URI = "";
IF (OPERA)
+35
View File
@@ -0,0 +1,35 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns = "http://www.w3.org/1999/xhtml" xml:lang = "en" lang = "en">
<!--
//
// index-debug.html
//
// Created by __Me__ on __Date__.
// Copyright 2008 __MyCompanyName__. All rights reserved.
//
-->
<head>
<title>Hello World</title>
<script type = "text/javascript">
OBJJ_MAIN_FILE = "main.j";
OBJJ_INCLUDE_PATHS = ["Frameworks/Debug", "Frameworks", "SomethingElse"];
</script>
<script src = "Frameworks/Debug/Objective-J/Objective-J.js" type = "text/javascript"></script>
</head>
<body>
<div style="position: absolute; left: 50%; top: 50%;">
<center>
<img src = "Frameworks/AppKit/Resources/CPProgressIndicator/CPProgressIndicatorSpinningStyleRegular.gif" style="left: -32px; position: relative; top: -32px;" />
</center>
</div>
</body>
</html>
+4 -3
View File
@@ -15,11 +15,12 @@
<title>Hello World</title>
<script type = "text/javascript">
OBJJ_MAIN_FILE = "main.j";
</script>
<script src = "Frameworks/Objective-J/Objective-J.js" type = "text/javascript"></script>
<script type = "text/javascript">
objj_import("main.j", YES, function() { main(); });
</script>
</head>
+27 -4
View File
@@ -404,7 +404,7 @@ function mainCreate()
sourceFrameworks = new File(OBJJ_HOME + "/lib/Frameworks"),
sourceDebugFrameworks = new File(OBJJ_HOME + "/lib/Frameworks-Debug"),
destinationFrameworks = new File(destination + "/Frameworks"),
destinationDebugFrameworks = new File(destination + "/Frameworks-Debug");
destinationDebugFrameworks = new File(destination + "/Frameworks/Debug");
System.out.println(sourceNewApplication.getCanonicalPath() + "," + destinationNewApplication.getCanonicalPath() + "," + sourceFrameworks.getCanonicalPath() + "," + destinationFrameworks.getCanonicalPath());
@@ -414,13 +414,36 @@ function mainCreate()
if (!link)
{
exec(["cp", "-vR", sourceDebugFrameworks.getCanonicalPath(), destinationDebugFrameworks.getCanonicalPath()], true);
exec(["cp", "-vR", sourceFrameworks.getCanonicalPath(), destinationFrameworks.getCanonicalPath()], true);
exec(["cp", "-vR", sourceDebugFrameworks.getCanonicalPath(), destinationDebugFrameworks.getCanonicalPath()], true);
}
else
{
exec(["ln", "-s", new File(System.getenv("STEAM_BUILD") + "/Debug").getCanonicalPath(), destinationDebugFrameworks.getCanonicalPath()], true);
exec(["ln", "-s", new File(System.getenv("STEAM_BUILD") + "/Release").getCanonicalPath(), destinationFrameworks.getCanonicalPath()], true);
var STEAM_BUILD = System.getenv("STEAM_BUILD");
// Release Frameworks
new File(destinationFrameworks).mkdir();
exec(["ln", "-s", new File(STEAM_BUILD + "/Release/Objective-J").getCanonicalPath(),
new File(destination + "/Frameworks/Objective-J").getCanonicalPath()], true);
exec(["ln", "-s", new File(STEAM_BUILD + "/Release/Foundation").getCanonicalPath(),
new File(destination + "/Frameworks/Foundation").getCanonicalPath()], true);
exec(["ln", "-s", new File(STEAM_BUILD + "/Release/AppKit").getCanonicalPath(),
new File(destination + "/Frameworks/AppKit").getCanonicalPath()], true);
// Debug Frameworks
new File(destinationDebugFrameworks).mkdir();
exec(["ln", "-s", new File(STEAM_BUILD + "/Debug/Objective-J").getCanonicalPath(),
new File(destination + "/Frameworks/Debug/Objective-J").getCanonicalPath()], true);
exec(["ln", "-s", new File(STEAM_BUILD + "/Debug/Foundation").getCanonicalPath(),
new File(destination + "/Frameworks/Debug/Foundation").getCanonicalPath()], true);
exec(["ln", "-s", new File(STEAM_BUILD + "/Debug/AppKit").getCanonicalPath(),
new File(destination + "/Frameworks/Debug/AppKit").getCanonicalPath()], true);
}
}
else