mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-11-09 16:38:45 +00:00
2. Prepared Foundation and Appkit for clean and clobber 3. Placed built-necessary requires in bundletask in the calling functions so that it can be included without being built for clean and clobber. 4. Made common.jake include unbuilt CommonJS files if built ones aren't present. Reviewed by me.
51 lines
1.8 KiB
JavaScript
51 lines
1.8 KiB
JavaScript
#!/usr/bin/env narwhal
|
|
|
|
require("../common.jake");
|
|
|
|
|
|
$BUILD_PATH = FILE.join($BUILD_DIR, $CONFIGURATION, 'AppKit');
|
|
|
|
AppKitFiles = new FileList("**/*.j").exclude('CoreGraphics/CGContextCanvas.j', 'CoreGraphics/CGContextVML.j', 'Themes/**/*', 'Tools/**/*');
|
|
|
|
appKitTask = framework ("AppKit", function(appKitTask)
|
|
{
|
|
appKitTask.setBuildIntermediatesPath(FILE.join($BUILD_DIR, "AppKit.build", $CONFIGURATION))
|
|
appKitTask.setBuildPath(FILE.join($BUILD_DIR, $CONFIGURATION));
|
|
|
|
appKitTask.setAuthor("280 North, Inc.");
|
|
appKitTask.setEmail("feedback @nospam@ 280north.com");
|
|
appKitTask.setSummary("AppKit classes for Cappuccino");
|
|
appKitTask.setIdentifier("com.280n.AppKit");
|
|
appKitTask.setLicense(BundleTask.License.LGPL_v2_1);
|
|
appKitTask.setSources(AppKitFiles);
|
|
appKitTask.setResources(new FileList("Resources/**/*"));
|
|
appKitTask.setPlatforms([BundleTask.Platform.Browser, BundleTask.Platform.CommonJS]);
|
|
appKitTask.setFlattensSources(true);
|
|
|
|
if ($CONFIGURATION === "Release")
|
|
appKitTask.setCompilerFlags("-O");
|
|
else
|
|
appKitTask.setCompilerFlags("-DDEBUG -g");
|
|
});
|
|
|
|
$COMMONJS_PRODUCT_APPKIT = FILE.join($COMMONJS_PRODUCT_FRAMEWORKS, "AppKit");
|
|
|
|
filedir ($COMMONJS_PRODUCT_APPKIT, ["AppKit"], function()
|
|
{
|
|
cp_r(appKitTask.buildProductPath(), $COMMONJS_PRODUCT_APPKIT);
|
|
});
|
|
|
|
//subtasks (["Themes"], ["clean", "clobber"]);
|
|
|
|
task ("Theme", [$COMMONJS_PRODUCT_APPKIT], function()
|
|
{
|
|
subjake(["Themes"], "build");
|
|
|
|
cp_r(FILE.join($BUILD_DIR, $CONFIGURATION, 'Aristo.blend'), FILE.join($BUILD_PATH, 'Resources', 'Aristo.blend'));
|
|
cp_r(FILE.join($BUILD_DIR, $CONFIGURATION, 'Aristo.blend'), FILE.join($COMMONJS_PRODUCT_APPKIT, "Resources", "Aristo.blend"));
|
|
});
|
|
|
|
task ("build", ["AppKit", $COMMONJS_PRODUCT_APPKIT, "Theme"]);
|
|
|
|
CLOBBER.include($COMMONJS_PRODUCT_APPKIT);
|