1 | Installation Instructions for Linux
|
---|
2 | ---------------------------------------
|
---|
3 |
|
---|
4 | sudo apt-get install xorg-dev libglew-dev libglm-dev
|
---|
5 |
|
---|
6 | make newgame && ./newgame
|
---|
7 |
|
---|
8 | (Old Linux instructions for compiling game.cpp)
|
---|
9 | -sudo apt-get install cmake xorg-dev libglew-dev libglu1-mesa-dev freeglut3-dev mesa-common-dev
|
---|
10 |
|
---|
11 | -Compile GLFW3 from source
|
---|
12 | (cmake . && make && sudo make install)
|
---|
13 |
|
---|
14 | Installation Instructions for OSX
|
---|
15 | ---------------------------------------
|
---|
16 |
|
---|
17 | brew install glew
|
---|
18 | brew install glfw --without-shared-library
|
---|
19 | brew install glm
|
---|
20 |
|
---|
21 | This should place all necessary files (or possibly symlinks to them) in
|
---|
22 | /usr/loca/include and /usr/local/lib.
|
---|
23 |
|
---|
24 | Run 'xcode-select --install'
|
---|
25 | This should make g++ check for libraries in /usr/local/
|
---|
26 |
|
---|
27 | If the above command gives you the following error, you should be able to move on and compile the game.
|
---|
28 | "xcode-select: error: command line tools are already installed, use "Software Update" to install updates"
|
---|
29 |
|
---|
30 | make newgame && ./newgame
|
---|
31 |
|
---|
32 | Installation Instructions for Windows
|
---|
33 | ---------------------------------------
|
---|
34 |
|
---|
35 | Download the precompiled 32bit binaries of GLFW and GLEW. Create lib/ and
|
---|
36 | include/ folders in the root opengl-game directory you cloned.
|
---|
37 | Copy the include/GL/ and include/GLFW/ folders into your include/ folder.
|
---|
38 |
|
---|
39 | For GLEW, copy lib/RELEASE/Win32/glew32s.lib into your lib folder.
|
---|
40 | For GLFW, copy lib-vc2015/glfw3.lib into your lib folder.
|
---|
41 |
|
---|
42 | Download GLM and copy the glm folder (the one with all the .hpp files) into the include/ folder you made above.
|
---|
43 | GLM is a header-only library, so there is nothing to copy into the lib/ folder.
|
---|
44 |
|
---|
45 | Open and run NewOpenGLGame.sln in Visual Studio 2017 and run it.
|
---|
46 |
|
---|
47 |
|
---|
48 | --------------------
|
---|
49 | VULKAN INSTRUCTIOS
|
---|
50 | --------------------
|
---|
51 |
|
---|
52 | Windows
|
---|
53 | --------
|
---|
54 |
|
---|
55 | Create an include directory inside the opengl-game folder
|
---|
56 |
|
---|
57 | Download GLM and copy the glm folder into /include
|
---|
58 | Download the SDL2 pre-built Windows binaries
|
---|
59 | - Copy the SDL2 include folder into /include and rename it SDL2
|
---|
60 | - Add the location of the lib/x64 folder to the VS2019 project properties under Linker/General/Addition Library DIrectories
|
---|
61 |
|
---|
62 | Download the vulkan sdk
|
---|
63 | - Add the location of the Include folder to the VS2019 project properties under C/C++ -> General -> Addition Include DIrectories
|
---|
64 | - Add the location of the Lib folder to the VS2019 project properties under Linker -> General -> Addition Library DIrectories
|
---|
65 |
|
---|
66 | Linux:
|
---|
67 | --------
|
---|
68 |
|
---|
69 | Download the vulkan sdk (make sure VULKAN_SDK_PATH in the makefile points to it)
|
---|
70 |
|
---|
71 | sudo apt-get install libxcb1-dev xorg-dev libsdl2-dev libglm-dev
|
---|
72 |
|
---|
73 | source setup-env.sh into your current shell
|
---|
74 |
|
---|
75 | make vulkangame && ./vulkangame
|
---|
76 |
|
---|
77 | OSX
|
---|
78 | --------
|
---|
79 |
|
---|
80 | Download the vulkan sdk (make sure VULKAN_SDK_PATH in the makefile points to it)
|
---|
81 |
|
---|
82 | brew install sdl2 (might need 'brew install sdl2 --HEAD')
|
---|
83 |
|
---|
84 | make vulkangame && ./vulkangame
|
---|