AC_CHECK_FUNCS(system)
AC_CHECK_FUNCS(fork execv execve)
AC_CHECK_FUNCS(accept4)
+ AC_CHECK_FUNCS(localtime_r)
AC_CHECK_SIZEOF(size_t)
AC_CHECK_TYPES([blksize_t], [AC_DEFINE(HAVE_BLKSIZE_T)], ,
[#include <sys/types.h>
-d:MOBILE,MOBILE_LEGACY \
-d:FULL_AOT_DESKTOP \
-d:FULL_AOT_RUNTIME \
+ -d:ORBIS \
-d:DISABLE_REMOTING \
-d:DISABLE_COM \
-nowarn:1699 \
MOBILE_PROFILE = yes
NO_VTS_TEST = yes
NO_CONSOLE = yes
+PROFILE_DISABLE_BTLS = yes
# Note need for trailing comma. If you add, keep it
PROFILE_TEST_HARNESS_EXCLUDES = MobileNotWorking,PKITS,
$(xbuild_2_0_dirs) \
Microsoft.Build
+orbis_exclude_dirs := \
+ Microsoft.CSharp \
+ Mono.CSharp \
+ Mono.Data.Sqlite
+
monodroid_SUBDIRS := $(monodroid_dirs)
monotouch_SUBDIRS := $(monotouch_dirs)
monotouch_watch_SUBDIRS := $(monotouch_watch_dirs)
xbuild_12_SUBDIRS := $(xbuild_4_0_dirs)
xbuild_14_SUBDIRS := $(xbuild_4_0_dirs) Microsoft.NuGet.Build.Tasks
winaot_SUBDIRS := $(winaot_dirs)
-orbis_SUBDIRS := $(monotouch_dirs)
+orbis_SUBDIRS := $(filter-out $(orbis_exclude_dirs),$(monotouch_dirs))
include ../build/rules.make
{
#if MONOTOUCH
is_macosx = true;
-#elif MONODROID
+#elif MONODROID || ORBIS
is_macosx = false;
#else
is_macosx = Environment.OSVersion.Platform != PlatformID.Win32NT && System.IO.File.Exists (OSX509Certificates.SecurityLibrary);
}
#else
if (is_macosx) {
+#if !ORBIS
// Attempt to use OSX certificates
// Ideally we should return the SecTrustResult
OSX509Certificates.SecTrustResult trustResult = OSX509Certificates.SecTrustResult.Deny;
status11 = (int)trustResult;
errors |= SslPolicyErrors.RemoteCertificateChainErrors;
}
+#else
+ throw new PlatformNotSupportedException ();
+#endif
} else {
result = BuildX509Chain (certs, chain, ref errors, ref status11);
}
const string LIBNAME = "MonoPosixHelper";
#endif
+#if !ORBIS
[DllImport (LIBNAME, CallingConvention=CallingConvention.Cdecl)]
static extern IntPtr CreateZStream (CompressionMode compress, bool gzip, UnmanagedReadOrWrite feeder, IntPtr data);
[DllImport (LIBNAME, CallingConvention=CallingConvention.Cdecl)]
static extern int WriteZStream (IntPtr stream, IntPtr buffer, int length);
+#else
+ static IntPtr CreateZStream (CompressionMode compress, bool gzip, UnmanagedReadOrWrite feeder, IntPtr data)
+ {
+ throw new PlatformNotSupportedException ();
+ }
+
+ static int CloseZStream (IntPtr stream)
+ {
+ throw new PlatformNotSupportedException ();
+ }
+
+ static int Flush (IntPtr stream)
+ {
+ throw new PlatformNotSupportedException ();
+ }
+
+ static int ReadZStream (IntPtr stream, IntPtr buffer, int length)
+ {
+ throw new PlatformNotSupportedException ();
+ }
+
+ static int WriteZStream (IntPtr stream, IntPtr buffer, int length)
+ {
+ throw new PlatformNotSupportedException ();
+ }
+#endif
+
}
}
[DllImport ("libc")]
static extern int gethostname ([MarshalAs (UnmanagedType.LPArray, SizeParamIndex = 1)] byte [] name, int len);
+#if !ORBIS
[DllImport ("libc")]
static extern int getdomainname ([MarshalAs (UnmanagedType.LPArray, SizeParamIndex = 1)] byte [] name, int len);
+#else
+ static int getdomainname ([MarshalAs (UnmanagedType.LPArray, SizeParamIndex = 1)] byte [] name, int len)
+ {
+ throw new PlatformNotSupportedException ();
+ }
+#endif
public override string DhcpScopeName {
get { return String.Empty; }
static void MaybeCreate ()
{
-#if MONOTOUCH_WATCH
+#if MONOTOUCH_WATCH || ORBIS
throw new PlatformNotSupportedException ("NetworkInformation.NetworkChange is not supported on the current platform.");
#else
if (networkChange != null)
}
}
-#if !MONOTOUCH_WATCH
+#if !MONOTOUCH_WATCH && !ORBIS
internal sealed class MacNetworkChange : INetworkChange
{
const string DL_LIB = "/usr/lib/libSystem.dylib";
}
#endif // !MONOTOUCH_WATCH
-#if !NETWORK_CHANGE_STANDALONE && !MONOTOUCH
+#if !NETWORK_CHANGE_STANDALONE && !MONOTOUCH && !ORBIS
internal sealed class LinuxNetworkChange : INetworkChange {
[Flags]
{
internal abstract class UnixNetworkInterfaceAPI : NetworkInterfaceFactory
{
+#if !ORBIS
[DllImport("libc")]
public static extern int if_nametoindex(string ifname);
[DllImport ("libc")]
protected static extern void freeifaddrs (IntPtr ifap);
+#else
+ public static int if_nametoindex(string ifname)
+ {
+ throw new PlatformNotSupportedException ();
+ }
+
+ protected static int getifaddrs (out IntPtr ifap)
+ {
+ throw new PlatformNotSupportedException ();
+ }
+
+ protected static void freeifaddrs (IntPtr ifap)
+ {
+ throw new PlatformNotSupportedException ();
+ }
+#endif
}
class MacOsNetworkInterfaceAPI : UnixNetworkInterfaceAPI
public event PingCompletedEventHandler PingCompleted;
-#if !MONOTOUCH
+#if !MONOTOUCH && !ORBIS
static Ping ()
{
if (Environment.OSVersion.Platform == PlatformID.Unix) {
identifier = (ushort)(randomIdentifier [0] + (randomIdentifier [1] << 8));
}
-#if !MONOTOUCH
+#if !MONOTOUCH && !ORBIS
[DllImport ("libc", EntryPoint="capget")]
static extern int capget (ref cap_user_header_t header, ref cap_user_data_t data);
isMacOS = true;
checkedOS = true;
}
+
+#elif ORBIS
+ const bool isFreeBSD = true;
+
+ private static void CheckOS() {
+ checkedOS = true;
+ }
+
#else
static bool isFreeBSD;
--- /dev/null
+System.Net/MacProxy.cs
+System.Security.Cryptography.X509Certificates/OSX509Certificates.cs
#if MONO
public static IWebProxy CreateDefaultProxy ()
{
-#if FEATURE_NO_BSD_SOCKETS
+#if FEATURE_NO_BSD_SOCKETS || ORBIS
throw new PlatformNotSupportedException ();
#elif MONOTOUCH
return Mono.Net.CFNetwork.GetDefaultProxy ();
g_error (__VA_ARGS__); \
} } while (0)
-#ifndef HOST_WIN32
+#ifdef HAVE_LOCALTIME_R
# define LOG_TIMESTAMP \
do { \
time_t t; \
pid_t pid;
char logTime [80];
-#ifndef HOST_WIN32
+#ifdef HAVE_LOCALTIME_R
struct tm tod;
time(&t);
localtime_r(&t, &tod);
- pid = getpid();
strftime(logTime, sizeof(logTime), "%Y-%m-%d %H:%M:%S", &tod);
#else
struct tm *tod;
time(&t);
tod = localtime(&t);
- pid = mono_process_current_pid ();
strftime(logTime, sizeof(logTime), "%F %T", tod);
#endif
+
+ pid = mono_process_current_pid ();
+
fprintf (logFile, "%s level[%c] mono[%d]: %s\n", logTime, mapLogFileLevel (level), pid, message);
} else {
fprintf (logFile, "%s%s%s\n",