mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2025-03-24 21:59:45 -04:00
Fixed Linux build.
This commit is contained in:
parent
1621cc851a
commit
f1597ee25c
4 changed files with 22 additions and 21 deletions
|
@ -89,7 +89,7 @@ static const bgfx::Memory* load(const char* _filePath)
|
||||||
|
|
||||||
static const bgfx::Memory* loadShader(const char* _name, const char* _default = NULL)
|
static const bgfx::Memory* loadShader(const char* _name, const char* _default = NULL)
|
||||||
{
|
{
|
||||||
char filePath[_MAX_PATH];
|
char filePath[512];
|
||||||
shaderFilePath(filePath, _name);
|
shaderFilePath(filePath, _name);
|
||||||
BX_UNUSED(_default);
|
BX_UNUSED(_default);
|
||||||
return load(filePath);
|
return load(filePath);
|
||||||
|
|
|
@ -76,7 +76,7 @@ static const bgfx::Memory* load(const char* _filePath)
|
||||||
|
|
||||||
static const bgfx::Memory* loadShader(const char* _name, const char* _default = NULL)
|
static const bgfx::Memory* loadShader(const char* _name, const char* _default = NULL)
|
||||||
{
|
{
|
||||||
char filePath[_MAX_PATH];
|
char filePath[512];
|
||||||
shaderFilePath(filePath, _name);
|
shaderFilePath(filePath, _name);
|
||||||
BX_UNUSED(_default);
|
BX_UNUSED(_default);
|
||||||
return load(filePath);
|
return load(filePath);
|
||||||
|
@ -605,9 +605,9 @@ int _main_(int _argc, char** _argv)
|
||||||
|
|
||||||
// Stats.
|
// Stats.
|
||||||
uint32_t numVertices = 0;
|
uint32_t numVertices = 0;
|
||||||
int64_t profUpdate;
|
int64_t profUpdate = 0;
|
||||||
int64_t profNormal;
|
int64_t profNormal = 0;
|
||||||
int64_t profTriangulate;
|
int64_t profTriangulate = 0;
|
||||||
|
|
||||||
// Allocate 32K vertices in transient vertex buffer.
|
// Allocate 32K vertices in transient vertex buffer.
|
||||||
uint32_t maxVertices = (32<<10);
|
uint32_t maxVertices = (32<<10);
|
||||||
|
|
|
@ -8,6 +8,7 @@
|
||||||
|
|
||||||
#define _USE_MATH_DEFINES
|
#define _USE_MATH_DEFINES
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
inline void vec3Add(float* __restrict _result, const float* __restrict _a, const float* __restrict _b)
|
inline void vec3Add(float* __restrict _result, const float* __restrict _a, const float* __restrict _b)
|
||||||
{
|
{
|
||||||
|
|
32
makefile
32
makefile
|
@ -4,38 +4,38 @@
|
||||||
#
|
#
|
||||||
|
|
||||||
all:
|
all:
|
||||||
premake --file=premake\premake4.lua vs2008
|
premake --file=premake/premake4.lua vs2008
|
||||||
premake --file=premake\premake4.lua --gcc=nacl gmake
|
premake --file=premake/premake4.lua --gcc=nacl gmake
|
||||||
premake --file=premake\premake4.lua --gcc=mingw gmake
|
premake --file=premake/premake4.lua --gcc=mingw gmake
|
||||||
premake --file=premake\premake4.lua --gcc=linux gmake
|
premake --file=premake/premake4.lua --gcc=linux gmake
|
||||||
make -s --no-print-directory -C src
|
make -s --no-print-directory -C src
|
||||||
|
|
||||||
nacl-debug32:
|
nacl-debug32:
|
||||||
make -C .build\projects\gmake-nacl config=debug32
|
make -C .build/projects/gmake-nacl config=debug32
|
||||||
nacl-release32:
|
nacl-release32:
|
||||||
make -C .build\projects\gmake-nacl config=release32
|
make -C .build/projects/gmake-nacl config=release32
|
||||||
nacl-debug64:
|
nacl-debug64:
|
||||||
make -C .build\projects\gmake-nacl config=debug64
|
make -C .build/projects/gmake-nacl config=debug64
|
||||||
nacl-release64:
|
nacl-release64:
|
||||||
make -C .build\projects\gmake-nacl config=release64
|
make -C .build/projects/gmake-nacl config=release64
|
||||||
nacl: nacl-debug32 nacl-release32 nacl-debug64 nacl-release64
|
nacl: nacl-debug32 nacl-release32 nacl-debug64 nacl-release64
|
||||||
|
|
||||||
mingw-debug32:
|
mingw-debug32:
|
||||||
make -C .build\projects\gmake-mingw config=debug32
|
make -C .build/projects/gmake-mingw config=debug32
|
||||||
mingw-release32:
|
mingw-release32:
|
||||||
make -C .build\projects\gmake-mingw config=release32
|
make -C .build/projects/gmake-mingw config=release32
|
||||||
mingw-debug64:
|
mingw-debug64:
|
||||||
make -C .build\projects\gmake-mingw config=debug64
|
make -C .build/projects/gmake-mingw config=debug64
|
||||||
mingw-release64:
|
mingw-release64:
|
||||||
make -C .build\projects\gmake-mingw config=release64
|
make -C .build/projects/gmake-mingw config=release64
|
||||||
mingw: mingw-debug32 mingw-release32 mingw-debug64 mingw-release64
|
mingw: mingw-debug32 mingw-release32 mingw-debug64 mingw-release64
|
||||||
|
|
||||||
linux-debug32:
|
linux-debug32:
|
||||||
make -C .build\projects\gmake-linux config=debug32
|
make -C .build/projects/gmake-linux config=debug32
|
||||||
linux-release32:
|
linux-release32:
|
||||||
make -C .build\projects\gmake-linux config=release32
|
make -C .build/projects/gmake-linux config=release32
|
||||||
linux-debug64:
|
linux-debug64:
|
||||||
make -C .build\projects\gmake-linux config=debug64
|
make -C .build/projects/gmake-linux config=debug64
|
||||||
linux-release64:
|
linux-release64:
|
||||||
make -C .build\projects\gmake-linux config=release64
|
make -C .build/projects/gmake-linux config=release64
|
||||||
linux: linux-debug32 linux-release32 linux-debug64 linux-release64
|
linux: linux-debug32 linux-release32 linux-debug64 linux-release64
|
||||||
|
|
Loading…
Add table
Reference in a new issue