-
Notifications
You must be signed in to change notification settings - Fork 2
Build for Windows
Daijiro Fukuda edited this page Dec 16, 2022
·
6 revisions
Install the following tools.
- cmake: https://cmake.org/download/
- mingw32-make: https://sourceforge.net/projects/mingw-w64/files/
- freetype binaries: https://github.com/ubawurinna/freetype-windows-binaries
$ git clone https://github.com/ubawurinna/freetype-windows-binaries.git
- Build the forked GLFW in which we are developing IME support: https://github.com/clear-code/glfw/tree/3.4-2022-09-21+im-support-all
$ git clone --branch=3.4-2022-09-21+im-support-all https://github.com/clear-code/glfw.git
$ cd glfw
$ cmake -B build -G "MinGW Makefiles" -D CMAKE_INSTALL_PREFIX=bin
$ mingw32-make -C build install
- Build the forked raylib in which we are developing IME support: https://github.com/clear-code/raylib/tree/4.2-2022-12-14+better-ime-support-all
- Set
USE_EXTERNAL_GLFW
ON
- Specify the path of GLFW built in step-2 to
CMAKE_PREFIX_PATH
- Ex:
-D CMAKE_PREFIX_PATH=C:/test/glfw/bin
- Ex:
- Set
$ git clone --branch=4.2-2022-12-14+better-ime-support-all https://github.com/clear-code/raylib.git
$ cd raylib
$ cmake -B build -G "MinGW Makefiles" -D CMAKE_INSTALL_PREFIX=bin -D USE_EXTERNAL_GLFW=ON -D CMAKE_PREFIX_PATH="{...}"
$ mingw32-make -C build install
- Build and run this app
- Set
USE_EXTERNAL_GLFW
ON
- Set
USE_SOFT_FULLSCREEN
ON
- Specify the path of freetype to
FREETYPE
- Ex:
-D FREETYPE="C:/test/freetype-windows-binaries"
- Ex:
- Specify the path of GLFW built in step-2 to
GLFW
- Ex:
-D GLFW="C:/test/glfw/bin"
- Ex:
- Specify the path of raylib built in step-3 to
RAYLIB
- Ex:
-D RAYLIB="C:/test/raylib/bin"
- Ex:
- (Optional) Set MANAGE_PREEDIT_CANDIDATE
ON
to use this feature
- Set
$ cmake -B build -G "MinGW Makefiles" -D CMAKE_INSTALL_PREFIX=bin -D USE_EXTERNAL_GLFW=ON -D USE_SOFT_FULLSCREEN=ON -D FREETYPE="{...}" -D GLFW="{...}" -D RAYLIB="{...}"
$ mingw32-make -C build install
$ bin/RaylibIMEInputSampleApp.exe
In your environment, this will not be a problem, but you need to be careful when distributing the application.
The following method allows you to create an application for Windows that does not depend on libwinpthread-1.dll
.
We are not currently developing in this way.
- Build the forked raylib in which we are developing IME support: https://github.com/clear-code/raylib/tree/better-ime-support-for-internal-glfw
$ git clone --branch=better-ime-support-for-internal-glfw https://github.com/clear-code/raylib.git
$ cd raylib
$ cmake -B build -G "MinGW Makefiles" -D CMAKE_INSTALL_PREFIX=bin
$ mingw32-make -C build install
- Build and run this app
- Specify the path of raylib built in step-1 to
RAYLIB
- Ex:
-D RAYLIB="C:/test/raylib/bin"
- Ex:
- Specify the path of freetype to
FREETYPE
- Ex:
-D FREETYPE="C:/test/freetype-windows-binaries"
- Ex:
- Specify the path of raylib built in step-1 to
$ cmake -B build -G "MinGW Makefiles" -D CMAKE_INSTALL_PREFIX=bin -D RAYLIB="{...}" -D FREETYPE="{...}"
$ mingw32-make -C build install
$ cd bin
$ .\RaylibIMEInputSampleApp.exe