FreeBSD patches
This commit is contained in:
parent
78a0e32746
commit
c17384987c
9 changed files with 40 additions and 10 deletions
10
gl_bumpgl2.c
10
gl_bumpgl2.c
|
@ -162,6 +162,7 @@ typedef char GLcharARB;
|
|||
#define GL_ARB_vertex_shader 1
|
||||
|
||||
// Taken from ARB_vertex_program
|
||||
#if !defined(__FreeBSD__)
|
||||
typedef void (APIENTRY * PFNGLVERTEXATTRIB4FVARBPROC) (GLuint index, const GLfloat *v);
|
||||
typedef void (APIENTRY * PFNGLVERTEXATTRIB3FVARBPROC) (GLuint index, const GLfloat *v);
|
||||
typedef void (APIENTRY * PFNGLVERTEXATTRIB2FVARBPROC) (GLuint index, const GLfloat *v);
|
||||
|
@ -205,7 +206,7 @@ typedef void (APIENTRY * PFNGLVERTEXATTRIB4NUIVARBPROC) (GLuint index, const GLu
|
|||
typedef void (APIENTRY * PFNGLVERTEXATTRIBPOINTERARBPROC) (GLuint index, GLint size, GLenum type, GLboolean normalize, GLsizei stride, const GLvoid *pointer);
|
||||
typedef void (APIENTRY * PFNGLENABLEVERTEXATTRIBARRAYARBPROC) (GLuint index);
|
||||
typedef void (APIENTRY * PFNGLDISABLEVERTEXATTRIBARRAYARBPROC) (GLuint index);
|
||||
|
||||
#endif
|
||||
typedef void (APIENTRY * PFNGLBINDATTRIBLOCATIONARBPROC) (GLhandleARB programObj, GLuint index, const GLcharARB *name);
|
||||
typedef void (APIENTRY * PFNGLBINDARRAYGL2PROC) (GLhandleARB shaderObject, GLenum array, const GLcharARB *name, GLint length);
|
||||
typedef GLhandleARB (APIENTRY * PFNGLCREATESHADEROBJECTARBPROC) (GLenum shaderType);
|
||||
|
@ -259,13 +260,17 @@ typedef void (APIENTRY * PFNGLGETUNIFORMFVARBPROC) (GLhandleARB programObj, GLin
|
|||
typedef void (APIENTRY * PFNGLGETUNIFORMIVARBPROC) (GLhandleARB programObj, GLint location, GLint *params);
|
||||
typedef void (APIENTRY * PFNGLGETATTRIBLOCATIONARBPROC) (GLhandleARB programObj, const GLcharARB *name);
|
||||
typedef void (APIENTRY * PFNGLVALIDATEPROGRAMARBPROC) (GLhandleARB programObj);
|
||||
#if !defined (__FreeBSD__)
|
||||
typedef void (APIENTRY * PFNGLGETVERTEXATTRIBPOINTERVARBPROC) (GLuint index, GLenum pname, void **pointer);
|
||||
#endif
|
||||
typedef void (APIENTRY * PFNGLGETOBJECTPARAMETERFVARBPROC)(GLhandleARB obj, GLenum pname, GLfloat *params);
|
||||
typedef void (APIENTRY * PFNGLGETOBJECTPARAMETERIVARBPROC)(GLhandleARB obj, GLenum pname, GLint *params);
|
||||
#if !defined (__FreeBSD__)
|
||||
typedef void (APIENTRY * PFNGLGETVERTEXATTRIBDVARBPROC) (GLuint index, GLenum pname, GLdouble *params);
|
||||
|
||||
typedef void (APIENTRY * PFNGLGETVERTEXATTRIBFVARBPROC) (GLuint index, GLenum pname, GLfloat *params);
|
||||
typedef void (APIENTRY * PFNGLGETVERTEXATTRIBIVARBPROC) (GLuint index, GLenum pname, GLint *params);
|
||||
|
||||
#endif
|
||||
typedef GLhandleARB (APIENTRY * PFNGLGETHANDLEARBPROC) (GLenum pname);
|
||||
typedef GLhandleARB (APIENTRY * PFNGLCREATEVERTEXARRAYOBJECTGL2PROC) (GLhandleARB formatObject, GLsizei count);
|
||||
typedef void (APIENTRY * PFNGLLOADVERTEXARRAYDATAGL2PROC) (GLhandleARB object, GLuint start, GLsizei count, GLvoid *data, GLenum preserve);
|
||||
|
@ -274,6 +279,7 @@ typedef void (APIENTRY * PFNGLADDELEMENTGL2PROC) (GLhandleARB formatObject, GLen
|
|||
typedef void (APIENTRY * PFNGLENABLEVERTEXARRAYOBJECTGL2PROC) (GLhandleARB object);
|
||||
typedef void (APIENTRY * PFNGLDISABLEVERTEXARRAYOBJECTGL2PROC) (GLhandleARB object);
|
||||
typedef void (APIENTRY * PFNGLDRAWINDEXEDARRAYSGL2PROC) (GLenum mode, GLuint first, GLsizei count);
|
||||
|
||||
#endif // End for #ifndef GL_ARB_vertex_shader
|
||||
#endif // End for #ifndef GL_ARB_fragment_shader
|
||||
#endif // End for #ifndef GL_ARB_shader_objects
|
||||
|
|
|
@ -5,8 +5,11 @@
|
|||
#include <dlfcn.h>
|
||||
|
||||
#include <SDL.h>
|
||||
#if defined(__FreeBSD__)
|
||||
#include <SDL11/SDL_opengl.h>
|
||||
#else
|
||||
#include <SDL/SDL_opengl.h>
|
||||
|
||||
#endif
|
||||
#include "quakedef.h"
|
||||
|
||||
viddef_t vid; // global video state
|
||||
|
|
|
@ -50,9 +50,13 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
|
||||
|
||||
// - DC -
|
||||
#if defined (SDL)
|
||||
#if defined (SDL)
|
||||
#if defined(__FreeBSD__)
|
||||
#include <SDL11/SDL_opengl.h>
|
||||
#else
|
||||
#include <SDL/SDL_opengl.h>
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if defined (__glx__)
|
||||
#include <GL/glx.h>
|
||||
|
|
6
net.h
6
net.h
|
@ -240,13 +240,17 @@ extern hostcache_t hostcache[HOSTCACHESIZE];
|
|||
|
||||
#if !defined(_WIN32 ) && !defined (__linux__) && !defined (__sun__)
|
||||
#ifndef htonl
|
||||
#if !defined(__FreeBSD__)
|
||||
extern unsigned long htonl (unsigned long hostlong);
|
||||
#endif
|
||||
#endif
|
||||
#ifndef htons
|
||||
extern unsigned short htons (unsigned short hostshort);
|
||||
#endif
|
||||
#ifndef ntohl
|
||||
extern unsigned long ntohl (unsigned long netlong);
|
||||
#if !defined(__FreeBSD__)
|
||||
extern unsigned long ntohl (unsigned long netlong);
|
||||
#endif
|
||||
#endif
|
||||
#ifndef ntohs
|
||||
extern unsigned short ntohs (unsigned short netshort);
|
||||
|
|
|
@ -39,8 +39,12 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
#if defined(__FreeBSD__)
|
||||
#include <stdlib.h>
|
||||
#else
|
||||
#include <malloc.h>
|
||||
#endif
|
||||
|
||||
//#include <unistd.h>
|
||||
|
||||
/* Use prototypes in function declarations. */
|
||||
|
@ -613,7 +617,6 @@ char *yytext;
|
|||
#line 7 "rc1.0_tokens.l"
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <malloc.h>
|
||||
#include "rc1.0_combiners.h"
|
||||
#include "_rc1.0_parser.h"
|
||||
|
||||
|
|
|
@ -55,8 +55,11 @@ int yylex ( void );
|
|||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
#if defined(__FreeBSD__)
|
||||
#include <stdlib.h>
|
||||
#else
|
||||
#include <malloc.h>
|
||||
|
||||
#endif
|
||||
#include "rc1.0_combiners.h"
|
||||
#include "nvparse_errors.h"
|
||||
#include "nvparse_externs.h"
|
||||
|
|
|
@ -1,4 +1,8 @@
|
|||
#if defined(__FreeBSD__)
|
||||
#include <stdlib.h>
|
||||
#else
|
||||
#include <malloc.h>
|
||||
#endif
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
|
|
|
@ -15,8 +15,11 @@ int yylex ( void );
|
|||
|
||||
|
||||
#include <stdio.h>
|
||||
#if defined(__FreeBSD__)
|
||||
#include <stdlib.h>
|
||||
#else
|
||||
#include <malloc.h>
|
||||
|
||||
#endif
|
||||
#include "rc1.0_combiners.h"
|
||||
#include "nvparse_errors.h"
|
||||
#include "nvparse_externs.h"
|
||||
|
|
|
@ -36,7 +36,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
#include "quakedef.h"
|
||||
#include <errno.h>
|
||||
|
||||
#if !defined(__GLIBC__)
|
||||
#if !defined(__FreeBSD__) && !defined(__GLIBC__)
|
||||
|
||||
#include <dirent.h>
|
||||
#include <fnmatch.h>
|
||||
|
|
Loading…
Reference in a new issue