]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - sys.h
Adding developer_curl to print verbose curl output
[xonotic/darkplaces.git] / sys.h
diff --git a/sys.h b/sys.h
index 0852662d582c70ad9a9b28c4c2684bb78c9f50d7..f6cd464770cce2819cef5eab89c548add25a4f6c 100644 (file)
--- a/sys.h
+++ b/sys.h
@@ -42,14 +42,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 #endif
 # define DP_MOBILETOUCH        1
 # define DP_FREETYPE_STATIC 1
-#elif TARGET_OS_IPHONE /* must come first because it also defines MACOSX */
-# define DP_OS_NAME            "iPhoneOS"
-# define DP_OS_STR             "iphoneos"
-# define USE_GLES2             1
-# define LINK_TO_ZLIB  1
-# define LINK_TO_LIBVORBIS 1
-# define DP_MOBILETOUCH        1
-# define DP_FREETYPE_STATIC 1
 #elif defined(__linux__)
 # define DP_OS_NAME            "Linux"
 # define DP_OS_STR             "linux"
@@ -71,9 +63,19 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 #elif defined(__DragonFly__)
 # define DP_OS_NAME            "DragonFlyBSD"
 # define DP_OS_STR             "dragonflybsd"
-#elif defined(MACOSX)
-# define DP_OS_NAME            "Mac OS X"
-# define DP_OS_STR             "osx"
+#elif defined(__APPLE__)
+# if TARGET_OS_IPHONE
+#  define DP_OS_NAME "iOS"
+#  define DP_OS_STR "ios"
+#  define USE_GLES2              1
+#  define LINK_TO_ZLIB   1
+#  define LINK_TO_LIBVORBIS 1
+#  define DP_MOBILETOUCH 1
+#  define DP_FREETYPE_STATIC 1
+# elif TARGET_OS_MAC
+#  define DP_OS_NAME "macOS"
+#  define DP_OS_STR "macos"
+# endif 
 #elif defined(__MORPHOS__)
 # define DP_OS_NAME            "MorphOS"
 # define DP_OS_STR             "morphos"
@@ -171,19 +173,27 @@ typedef struct dllfunction_s
 }
 dllfunction_t;
 
-/*! Loads a library. 
+qbool Sys_LoadSelf(dllhandle_t *handle);
+
+/*! Loads a dependency library. 
  * \param dllnames a NULL terminated array of possible names for the DLL you want to load.
  * \param handle
  * \param fcts
  */
-qbool Sys_LoadLibrary (const char** dllnames, dllhandle_t* handle, const dllfunction_t *fcts);
-void Sys_UnloadLibrary (dllhandle_t* handle);
+qbool Sys_LoadDependency (const char** dllnames, dllhandle_t* handle, const dllfunction_t *fcts);
+
+/*! Loads a library.
+ * \param name a string of the library filename
+ * \param handle
+ * \return true if library was loaded successfully
+ */
+qbool Sys_LoadLibrary(const char *name, dllhandle_t *handle);
+
+void Sys_FreeLibrary (dllhandle_t* handle);
 void* Sys_GetProcAddress (dllhandle_t handle, const char* name);
 
 int Sys_CheckParm (const char *parm);
 
-/// called early in Host_Init
-void Sys_InitConsole (void);
 /// called after command system is initialized but before first Con_Print
 void Sys_Init_Commands (void);
 
@@ -199,8 +209,8 @@ char *Sys_TimeString(const char *timeformat);
 void Sys_Error (const char *error, ...) DP_FUNC_PRINTF(1) DP_FUNC_NORETURN;
 
 /// (may) output text to terminal which launched program
-void Sys_PrintToTerminal(const char *text);
-void Sys_PrintfToTerminal(const char *fmt, ...);
+void Sys_Print(const char *text);
+void Sys_Printf(const char *fmt, ...);
 
 /// INFO: This is only called by Host_Shutdown so we dont need testing for recursion
 void Sys_Shutdown (void);