Saturday, 8 June 2013

Precompiled Headers?

Precompiled Headers?

In an attempt to narrow down an OpenGL error I've encountered the following error:
fatal error: can't create precompiled header triangles.exe: Permission denied
My code consists of including two headers:
#include <iostream>
using namespace std;

#include "vgl.h"
#include "LoadShaders.h"

int main()
{
    return 0;
}
Which are as follows:
#ifndef __VGL_H__
#define __VGL_H__

// #define USE_GL3W

#ifdef USE_GL3W

#include <GL3/gl3.h>
#include <GL3/gl3w.h>

#else

#define GLEW_STATIC

#include <GL/glew.h>

#ifdef _MSC_VER
#  ifdef _DEBUG
#    if (_MSC_VER >= 1600)
#      pragma comment (lib, "glew_static_vs2010_d.lib")
#    else
#      pragma comment (lib, "glew_static_d.lib")
#    endif
#  else
#    if (_MSC_VER >= 1600)
#      pragma comment (lib, "glew_static_vs2010.lib")
#    else
#      pragma comment (lib, "glew_static.lib")
#    endif
#  endif
#endif

#endif

#define FREEGLUT_STATIC

#include <GL/freeglut.h>

#ifdef _MSC_VER
#  ifdef _DEBUG
#    if (_MSC_VER >= 1600)
#      pragma comment (lib, "freeglut_static_vs2010_d.lib")
#    else
#      pragma comment (lib, "freeglut_static_d.lib")
#    endif
#  else
#    if (_MSC_VER >= 1600)
#      pragma comme

No comments:

Post a Comment