fix mac build.

git-svn-id: http://svn.igniterealtime.org/svn/repos/spark/trunk@4916 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
Derek DeMoro 2006-08-15 00:02:59 +00:00 committed by derek
parent 2ee99b037b
commit 82176bff8d

View File

@ -13,13 +13,6 @@ package org.jivesoftware;
import org.jivesoftware.resource.Default;
import org.jivesoftware.resource.SparkRes;
import org.jivesoftware.spark.util.log.Log;
import org.jivesoftware.sparkimpl.settings.JiveInfo;
import java.awt.Color;
import java.awt.Font;
import java.awt.Insets;
import java.io.File;
import java.io.IOException;
import javax.swing.BorderFactory;
import javax.swing.JFrame;
@ -27,6 +20,12 @@ import javax.swing.JOptionPane;
import javax.swing.SwingUtilities;
import javax.swing.UIManager;
import java.awt.Color;
import java.awt.Font;
import java.awt.Insets;
import java.io.File;
import java.io.IOException;
/**
* In many cases, you will need to know the structure of the Spark installation, such as the directory structures, what
* type of system Spark is running on, and also the arguments which were passed into Spark on startup. The <code>Spark</code>
@ -97,7 +96,13 @@ public final class Spark {
RESOURCE_DIRECTORY = new File(workingDir, "resources").getAbsoluteFile();
BIN_DIRECTORY = new File(workingDir, "bin").getAbsoluteFile();
LOG_DIRECTORY = new File(workingDir, "logs").getAbsoluteFile();
if (!Spark.isWindows()) {
LOG_DIRECTORY = new File(USER_HOME, "/Spark/logs").getAbsoluteFile();
}
else {
LOG_DIRECTORY = new File(workingDir, "logs").getAbsoluteFile();
}
LOG_DIRECTORY.mkdirs();
try {
buf.append(RESOURCE_DIRECTORY.getCanonicalPath()).append(";");