FreeBSD support
See merge request xonotic/netradiant!75
disable_deprecated(PANGO 0)
endif ()
+IF(${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD")
+ link_directories(
+ /usr/local/lib
+ )
+endif ()
+
if (BUILD_BINARIES)
if (APPLE)
if (BUILD_RADIANT)
-DCMAKE_C_COMPILER=/usr/local/bin/gcc-9 -DCMAKE_CXX_COMPILER=/usr/local/bin/g++-9 -DOPENGL_INCLUDE_DIR=/opt/X11/include -DOPENGL_gl_LIBRARY=/opt/X11/lib/libGL.dylib
```
+On FreeBSD you have to add this to the first cmake call:
+
+```
+cmake -G "Unix Makefiles" -DCMAKE_C_COMPILER=/usr/local/bin/gcc8 -DCMAKE_CXX_COMPILER=/usr/local/bin/g++8
+```
+
## Build and installation details
### Compilation details
return static_cast<__int64>( f + 0.5 );
}
-#elif GDEF_OS_BSD
-
-inline long lrint( double f ){
- return static_cast<long>( f + 0.5 );
-}
-
-inline long long llrint( double f ){
- return static_cast<long long>( f + 0.5 );
-}
-
#elif GDEF_COMPILER_GNU
// lrint is part of ISO C99
#define PATH_MAX 260
#endif // PATH_MAX
+// PATH_MAX
+#if defined( __FreeBSD__ )
+#include <sys/syslimits.h>
+#endif
+
#define VFS_MAXDIRS 64
void vfsInitDirectory( const char *path );