forked from Thyodas/rtype
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #101 from NexoEngine/fix/windows-build
fix(windows-build): fix symlink error on Windows + CI not working for Windows
- Loading branch information
Showing
19 changed files
with
214 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
\page troubleshooting Troubleshooting | ||
|
||
# Build Troubleshooting | ||
|
||
## Table of Contents | ||
|
||
- [Common Issues](#common-issues) | ||
- [Couldn't create symlink](#couldnt-create-symlink) | ||
- [CPackDeb: file utility is not available](#cpackdeb-file-utility-is-not-available) | ||
- [CMake configure/build infinite loop](#cmake-configurebuild-infinite-loop) | ||
- [Still having issues? Any other questions?](#still-having-issues-any-other-questions) | ||
|
||
## Common Issues | ||
|
||
### Couldn't create symlink | ||
|
||
If you encounter the following error message when packing with `cpack -G DEB`: | ||
|
||
```bash | ||
NEXO Engine symlink couldn't be created. Required for the DEB package generator. See README's troubleshooting section. | ||
``` | ||
|
||
To create an installer using the cpack DEB generator, our scripts try to create | ||
a symlink to NEXO's binary. This symlink is | ||
required for installing NEXO in the path of a DEB compatible linux distribution. | ||
|
||
#### Solution | ||
|
||
If you are running Windows: | ||
- Either ignore this message, since you may not want to generate a DEB package. | ||
- If you still want to generate a DEB package, you should enable Windows Developer Mode, | ||
see [Microsoft Documentation](https://learn.microsoft.com/en-us/windows/apps/get-started/enable-your-device-for-development). | ||
And rerun the cmake configure, build and cpack commands. | ||
|
||
> [!WARNING] | ||
> If you are running Windows, you may not want to generate a DEB package. It may not be supported. | ||
If you are running another OS, it is unexpected, so please submit an issue [here](https://github.com/NexoEngine/game-engine/issues) | ||
with the details of your OS and the error message; we will help you from there. | ||
|
||
### CPackDeb: file utility is not available | ||
|
||
If you encounter the following error message when packing with `cpack -G DEB`: | ||
|
||
```bash | ||
CPackDeb: file utility is not available. CPACK_DEBIAN_PACKAGE_SHLIBDEPS | ||
and CPACK_DEBIAN_PACKAGE_GENERATE_SHLIBS options are not available. | ||
``` | ||
|
||
The DEB generator couldn't find the `file` command. | ||
|
||
#### Solution | ||
|
||
You need to install the `file` command on your system. | ||
|
||
On Ubuntu/Debian, you can install it with the following command: | ||
|
||
```bash | ||
sudo apt update && sudo apt install file | ||
``` | ||
|
||
On Windows (using chocolatey), you can install it with the following command on an elevated PowerShell: | ||
|
||
```bash | ||
choco install file | ||
``` | ||
|
||
> [!WARNING] | ||
> If you are running Windows, you may not want to generate a DEB package. It may not be supported. | ||
### CMake configure/build infinite loop | ||
|
||
If you encounter an infinite loop when running the `cmake` command, it may be due to various reasons. | ||
|
||
#### Solution | ||
|
||
- Check if date and time are set correctly on your system. | ||
- Something is modifying cmake files after each run. Check if you have any scripts or tools that modify the CMake files. | ||
- Try to delete the `build` (might be another name) directory and rerun the `cmake` command. | ||
|
||
## Still having issues? Any other questions? | ||
|
||
If you are still having issues, please submit an issue [here](https://github.com/NexoEngine/game-engine/issues) | ||
with the details of your problem. Thank you! | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
function(is_win_developer_mode_enabled result) | ||
if (WIN32) | ||
cmake_host_system_information(RESULT result_var | ||
QUERY WINDOWS_REGISTRY "HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\AppModelUnlock" | ||
VALUE "AllowDevelopmentWithoutDevLicense" | ||
ERROR_VARIABLE error_var) | ||
|
||
if (${result_var}) | ||
set(${result} TRUE PARENT_SCOPE) | ||
else () | ||
message(DEBUG "Developer mode is not enabled on Windows: ${error_var}") | ||
set(${result} FALSE PARENT_SCOPE) | ||
endif () | ||
else () | ||
message(WARNING "Developer mode is only supported on Windows") | ||
set(${result} FALSE PARENT_SCOPE) | ||
endif () | ||
endfunction() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.