From 9fc0c8c3f1225f81379a28b84fcfe122113ec0cf Mon Sep 17 00:00:00 2001 From: Eliot Horowitz Date: Thu, 26 Mar 2009 14:55:00 -0400 Subject: [PATCH] solaris fixes --- SConstruct | 4 ++-- db/db.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/SConstruct b/SConstruct index ffe4ef9c626..114565f21fe 100644 --- a/SConstruct +++ b/SConstruct @@ -258,7 +258,7 @@ elif "sunos5" == os.sys.platform: useJavaHome = True javaHome = "/usr/lib/jvm/java-6-sun/" javaOS = "solaris" - env.Append( CPPDEFINES=[ "__linux__" ] ) + env.Append( CPPDEFINES=[ "__linux__" , "__sunos__" ] ) elif "win32" == os.sys.platform: windows = True @@ -714,7 +714,7 @@ def jsDirTestSpec( dir ): return mongo[0].abspath + " --nodb " + jsSpec( [ dir, "*.js" ] ) # These tests require the mongo shell -if not onlyServer: +if not onlyServer and not noshell: addSmoketest( "smokeJs", [ "mongo" ], [ mongo[0].abspath + " " + jsSpec( [ "_runner.js" ] ) ] ) addSmoketest( "smokeClone", [ "mongo", "mongod" ], [ jsDirTestSpec( "clone" ) ] ) addSmoketest( "smokeRepl", [ "mongo", "mongod" ], [ jsDirTestSpec( "repl" ) ] ) diff --git a/db/db.cpp b/db/db.cpp index 892efc32158..6632e904dc3 100644 --- a/db/db.cpp +++ b/db/db.cpp @@ -327,7 +327,7 @@ namespace mongo { Timer startupSrandTimer; void acquirePathLock() { -#if !defined(_WIN32) +#if !defined(_WIN32) and !defined(__sunos__) string name = ( boost::filesystem::path( dbpath ) / "mongod.lock" ).native_file_string(); int f = open( name.c_str(), O_RDONLY | O_CREAT, S_IRWXU | S_IRWXG | S_IRWXO ); massert( "Unable to create / open lock file for dbpath: " + name, f > 0 );