OSX build fixes

metadata
Wenzel Jakob 2010-10-22 12:28:38 +02:00
parent 098d3a6e3f
commit f2387696d1
4 changed files with 17 additions and 5 deletions

View File

@ -409,7 +409,6 @@ if sys.platform == 'win32':
# Build the command-line+GUI interface
mainEnv.Program('mtssrv', resources + ['src/mitsuba/mtssrv.cpp'])
mainEnv.Program('mitsuba', resources + ['src/mitsuba/mitsuba.cpp'])
mainEnv.Program('mtsutil', resources + ['src/mitsuba/mtsutil.cpp'])
if sys.platform == 'darwin':
mainEnv_osx = mainEnv.Clone();
@ -418,6 +417,8 @@ if sys.platform == 'darwin':
mainEnv_osx['CXXFLAGS'].append('-fno-strict-aliasing');
darwinStub += [mainEnv_osx.StaticObject('src/mitsuba/darwin_stub.mm')]
mainEnv.Program('mtsutil', resources + darwinStub + ['src/mitsuba/mtsutil.cpp'])
env.Program('src/utils/joinrgb', ['src/utils/joinrgb.cpp'])
env.Program('src/utils/ttest', ['src/utils/ttest.cpp'])
env.Program('src/utils/createvol', ['src/utils/createvol.cpp'])

View File

@ -24,6 +24,7 @@ int main(int argc, char **argv) {
// return NSApplicationMain(argc, (const char **) argv);
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
[NSApplication sharedApplication]; /* Creates a connection to the windowing environment */
[NSApp activateIgnoringOtherApps:YES]; /* Pop to front */
int retval = ubi_main(argc, argv);
[pool release];
return retval;

View File

@ -121,7 +121,7 @@ void help() {
}
int ubi_main(int argc, char **argv) {
int mtsutil(int argc, char **argv) {
char optchar, *end_ptr = NULL;
try {
@ -356,7 +356,7 @@ int ubi_main(int argc, char **argv) {
return 0;
}
int main(int argc, char **argv) {
int ubi_main(int argc, char **argv) {
/* Initialize the core framework */
Class::staticInitialization();
PluginManager::staticInitialization();
@ -390,7 +390,7 @@ int main(int argc, char **argv) {
return -1;
}
int retval = ubi_main(argc, argv);
int retval = mtsutil(argc, argv);
XMLPlatformUtils::Terminate();
@ -411,3 +411,11 @@ int main(int argc, char **argv) {
return retval;
}
#if !defined(__OSX__)
int main(int argc, char **argv) {
return ubi_main(argc, argv);
}
#endif

View File

@ -40,7 +40,9 @@ LoadDialog::LoadDialog(QWidget *parent) :
font.setStyleHint(QFont::TypeWriter);
#if defined(__OSX__)
font.setPointSize(10);
ui->heading->font().setPointSize(14);
QFont headingFont = ui->heading->font();
headingFont.setPointSize(14);
ui->heading->setFont(headingFont);
#else
font.setPointSize(8);
#endif