game/godot

Godot - Compiling for Windows

C/H 2018. 12. 10. 08:30

Compiling for Windows

Requirements

For compiling under Windows, the following is required:
Windows에서 컴파일하려면 다음이 필요합니다.

  • Visual C++, Visual Studio Community (recommended), version 2013 (12.0) or later. Make sure you read Installing Visual Studio caveats below or you will have to run/download the installer again.
    Visual C ++, Visual Studio 커뮤니티 (권장), 버전 2013 (12.0) 이상 아래에서 Visual Studio주의 사항을 읽으면 설치 프로그램을 다시 실행하거나 다운로드해야합니다.
  • Python 2.7+ or Python 3.5+.
  • Pywin32 Python Extension for parallel builds (which increase the build speed by a great factor).
    병렬 빌드를위한 Pywin32 Python Extension (빌드 속도를 크게 향상 시킴).
  • SCons build system.

Setting up SCons

Python adds the interpreter (python.exe) to the path. It usually installs in C:\Python (or C:\Python[Version]). SCons installs inside the Python install (typically in the Scripts folder) and provides a batch file called scons.bat. The location of this file can be added to the path or it can simply be copied to C:\Python together with the interpreter executable.
파이썬은 인터프리터 (python.exe)를 경로에 추가합니다. 보통 C:\Python (또는 C:\Python[Version])에 설치됩니다. SCons는 Python 설치 (일반적으로 Scripts 폴더)에 설치하고 scons.bat라는 배치 파일을 제공합니다. 이 파일의 위치는 경로에 추가하거나 단순히 인터프리터 실행 파일과 함께 C:\Python에 복사 할 수 있습니다.

To check whether you have installed Python and SCons correctly, you can type python --version and scons --version into the Windows Command Prompt (cmd.exe).
Python과 SCons를 올바르게 설치했는지 확인하려면 python --version과 scons --version을 Windows 명령 프롬프트 (cmd.exe)에 입력하면됩니다.

If commands above do not work, make sure you add Python to your PATH environment variable after installing it, and check again.
위의 명령이 작동하지 않으면 PATH 환경 변수를 설치 한 후에 Python을 추가하고 다시 확인하십시오.

Setting up Pywin32

Pywin32 is required for parallel builds using multiple CPU cores. If SCons is issuing a warning about Pywin32 after parsing SConstruct build instructions, when beginning to build, you need to install it properly from the correct installer executable for your Python version located at Github.
다중 CPU 코어를 사용하는 병렬 빌드에는 Pywin32가 필요합니다. SCons가 SConstruct 빌드 지침을 구문 분석 한 후 Pywin32에 대한 경고를 발행하는 경우 빌드를 시작할 때 Github에있는 Python 버전의 올바른 설치 프로그램 실행 파일에서 제대로 설치해야합니다.

For example, if you installed a 32-bit version of Python 2.7, you would want to install the latest version of Pywin32 that is built for the mentioned version of Python. That executable installer would be named pywin32-221.win32-py2.7.exe.
예를 들어, Python 2.7의 32 비트 버전을 설치 한 경우 언급 된 Python 버전 용으로 빌드 된 Pywin32의 최신 버전을 설치하려고합니다. 실행 가능한 설치 프로그램의 이름은 pywin32-221.win32-py2.7.exe입니다.

The amd64 version of Pywin32 is for a 64-bit version of Python pywin32-221.win-amd64-py2.7.exe. Change the py number to install for your version of Python (check via python --version mentioned above).
Pywin32의 amd64 버전은 Python pywin32-221.win-amd64-py2.7.exe의 64 비트 버전 용입니다. 파이썬 버전에 맞게 파이 번호를 변경하십시오 (위에 언급 된 python --version을 통해 확인하십시오).

Installing Visual Studio caveats

If installing Visual Studio 2015 or later, make sure to run Custom installation, not Typical and select C++ as language there (and any other things you might need). The installer does not install C++ by default. C++ was the only language made optional in Visual Studio 2015.
Visual Studio 2015 이상을 설치하는 경우 일반 설치가 아닌 사용자 지정 설치를 실행하고 거기에 언어로 C++을 선택하십시오 (필요한 경우). 설치 프로그램은 기본적으로 C++을 설치하지 않습니다. Visual Studio 2015에서는 C++만이 선택적 언어로 사용되었습니다.

If you have already made the mistake of installing a Typical, installation, rerun the executable installer you downloaded from internet, it will give you a Modify Button option. Running the install from Add/Remove programs will only give you the “Repair” option, which will do nothing for your problem.
Typical 설치를 실수로 설치 한 경우 인터넷에서 다운로드 한 실행 설치 프로그램을 다시 실행하면 Modify Button 옵션이 제공됩니다. 프로그램 추가/제거에서 설치 프로그램을 실행하면 "복구" 옵션만 제공되며 문제는 해결되지 않습니다.

If you’re using Express, make sure you get/have a version that can compile for *C++, Desktop*.
Express를 사용하는 경우 *C++, Desktop* 용으로 컴파일 할 수있는 버전을 갖거나 갖고 있는지 확인하십시오.

Downloading Godot’s source

Godot’s source is hosted on GitHub. Downloading it (cloning) via Git is recommended.
Godot의 소스는 GitHub에서 호스팅됩니다. Git을 통해 다운로드 (복제)하는 것이 좋습니다.

The tutorial will presume from now on that you placed the source into C:\godot.
자습서에서는 소스를 C:\godot에 배치했다고 가정합니다.

Compiling

SCons will not be able out of the box to compile from the Windows Command Prompt (cmd.exe) because SCons and Visual C++ compiler will not be able to locate environment variables and executables they need for compilation.
SCons 및 Visual C ++ 컴파일러는 컴파일에 필요한 환경 변수 및 실행 파일을 찾을 수 없기 때문에 SCons는 Windows 명령 프롬프트 (cmd.exe)에서 컴파일 할 수 있습니다.

Therefore, you need to start a Visual Studio command prompt. It sets up environment variables needed by SCons to locate the compiler. It should be called similar to one of the below names (for your respective version of Visual Studio):
따라서 Visual Studio 명령 프롬프트를 시작해야합니다. 컴파일러를 찾기 위해 SCons에 필요한 환경 변수를 설정합니다. 다음 이름 중 하나와 비슷하게 호출해야합니다 (Visual Studio의 해당 버전 용).

  • “Developer Command Prompt for VS2013”
  • “VS2013 x64 Native Tools Command Prompt”
  • “VS2013 x86 Native Tools Command Prompt”
  • “VS2013 x64 Cross Tools Command Prompt”
  • “VS2013 x86 Cross Tools Command Prompt”

You should be able to find at least the Developer Command Prompt for your version of Visual Studio in your start menu.
시작 메뉴에서 Visual Studio 버전에 대한 개발자 명령 프롬프트를 적어도 찾을 수 있어야합니다.

However Visual Studio sometimes seems to not install some of the above shortcuts, except the Developer Console at these locations that are automatically searched by the start menu search option:
그러나 Visual Studio는 때때로 시작 메뉴 검색 옵션에 의해 자동으로 검색되는 이러한 위치의 개발자 콘솔을 제외하고 위의 몇 가지 바로 가기를 설치하지 않는 것으로 보입니다.

Win 7:
C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Visual Studio 2015\Visual Studio Tools
C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Visual Studio 2013\Visual Studio Tools

If you found the Developer Console, it will do for now to create a 32-bit version of Godot, but if you want the 64-bit version, you might need to setup the prompts manually for easy access.
개발자 콘솔을 찾은 경우 지금은 Godot의 32 비트 버전을 만들지 만 64 비트 버전을 원할 경우 쉽게 액세스 할 수 있도록 수동으로 프롬프트를 설정해야 할 수 있습니다.

If you don’t see some of the shortcuts, “How the prompts actually work” section below will explain how to setup these prompts if you need them.
일부 바로 가기가 표시되지 않으면 아래의 "프롬프트가 실제로 작동하는 방법"섹션에서 필요한 경우 이러한 프롬프트를 설정하는 방법에 대해 설명합니다.

About the Developer/Tools Command Prompts and the Visual C++ compiler

There is a few things you need to know about these consoles and the Visual C++ compiler.
이 콘솔과 Visual C++ 컴파일러에 대해 알아야 할 몇 가지 사항이 있습니다.

Your Visual Studio installation will ship with several Visual C++ compilers, them being more or less identical, however each cl.exe (Visual C++ compiler) will compile Godot for a different architecture (32-bit x86 or 64-bit x86; the ARM compiler is not supported).
Visual Studio 설치는 여러 Visual C++ 컴파일러와 함께 제공됩니다 (다소 비슷 함). 그러나 각 cl.exe (Visual C ++ 컴파일러)는 Godot을 다른 아키텍처로 컴파일합니다. (32 비트 x86 또는 64 비트 x86, ARM 컴파일러는 지원되지 않음).

The Developer Command Prompt will build a 32-bit version of Godot by using the 32-bit Visual C++ compiler.
Developer Command Prompt는 32 비트 Visual C++ 컴파일러를 사용하여 Godot의 32 비트 버전을 작성합니다.

Native Tools Prompts (mentioned above) are used when you want the 32-bit cl.exe to compile a 32-bit executable (x86 Native Tools Command Prompt). For the 64-bit cl.exe, it will compile a 64-bit executable (x64 Native Tools Command Prompt).
네이티브 도구 프롬프트 (위에서 언급한)는 32 비트 cl.exe가 32 비트 실행 파일 (x86 네이티브 도구 명령 프롬프트)을 컴파일하도록 할 때 사용됩니다. 64 비트 cl.exe의 경우 64 비트 실행 파일 (x64 네이티브 도구 명령 프롬프트)을 컴파일합니다.

The Cross Tools are used when your Windows is using one architecture (32-bit, for example) and you need to compile to a different architecture (64-bit). As you might be familiar, 32-bit Windows can not run 64-bit executables, but you still might need to compile for them.
Cross Tools는 Windows가 하나의 아키텍처 (예 : 32 비트)를 사용하고 다른 아키텍처 (64 비트)로 컴파일해야 할 때 사용됩니다. 32 비트 Windows는 64 비트 실행 파일을 실행할 수 없지만 여전히 컴파일해야 할 수도 있습니다.

For example:

  • “VS2013 x64 Cross Tools Command Prompt” will use a 32-bit cl.exe that will compile a 64 bit application.
    "VS2013 x64 크로스 도구 명령 프롬프트"는 64 비트 응용 프로그램을 컴파일 할 32 비트 cl.exe를 사용합니다.
  • “VS2013 x86 Cross Tools Command Prompt” will use a 64-bit cl.exe that will compile a 32-bit application. This one is useful if you are running a 32-bit Windows.
    "VS2013 x86 교차 도구 명령 프롬프트"는 32 비트 응용 프로그램을 컴파일 할 64 비트 cl.exe를 사용합니다. 이 기능은 32 비트 Windows를 실행하는 경우 유용합니다.

On a 64-bit Windows, you can run any of above prompts and compilers (cl.exe executables) because 64-bit Windows can run any 32-bit application. 32-bit Windows cannot run 64-bit executables, so the Visual Studio installer won’t even install shortcuts for some of these prompts.
64 비트 Windows에서 32 비트 응용 프로그램을 실행할 수 있기 때문에 64 비트 Windows에서 위의 프롬프트와 컴파일러 (cl.exe 실행 파일)를 실행할 수 있습니다. 32 비트 Windows는 64 비트 실행 파일을 실행할 수 없기 때문에 Visual Studio 설치 관리자는 이러한 일부 프롬프트에 대한 바로 가기를 설치하지 않습니다.

Note that you need to choose the Developer Console or the correct Tools Prompt to build Godot for the correct architecture. Use only Native Prompts if you are not sure yet what exactly Cross Compile Prompts do.
올바른 아키텍처를 위해 Godot을 빌드하려면 개발자 콘솔이나 올바른 도구 프롬프트를 선택해야합니다. 정확히 크로스 컴파일 프롬프트가 무엇인지 확실하지 않은 경우 네이티브 프롬프트만 사용하십시오.

Running SCons

Once inside the Developer Console/Tools Console Prompt, go to the root directory of the engine source code and type:
개발자 콘솔/도구 콘솔 프롬프트에서 엔진 소스 코드의 루트 디렉토리로 이동하여 다음을 입력하십시오.

C:\godot> scons platform=windows

Tip: if you installed “Pywin32 Python Extension” you can append the -j command to instruct SCons to run parallel builds like this:
팁 : "Pywin32 Python Extension"을 설치 한 경우 -j 명령을 추가하여 SCons가 다음과 같이 병렬 빌드를 실행하도록 지시 할 수 있습니다:

C:\godot> scons -j6 platform=windows

In general, it is OK to have at least as many threads compiling Godot as you have cores in your CPU, if not one or two more. Feel free to add the -j option to any SCons command you see below if you setup the “Pywin32 Python Extension”.
일반적으로 적어도 하나 또는 두 가지가 아니라면 CPU에 코어를 가지고있는 것처럼 Godot을 컴파일하는 스레드를 적어도 가지고 있으면 좋습니다. "Pywin32 Python Extension"을 설정 한 경우 아래에 표시된 SCons 명령에 -j 옵션을 추가하십시오.

If all goes well, the resulting binary executable will be placed in C:\godot\bin\ with the name of godot.windows.tools.32.exe or godot.windows.tools.64.exe. SCons will automatically detect what compiler architecture the environment (the prompt) is setup for and will build a corresponding executable.
모두 잘 수행되면 바이너리 실행 파일은 godot.windows.tools.32.exe 또는 godot.windows.tools.64.exe라는 이름으로 C :\godot\bin\에 저장됩니다. SCons는 환경 (프롬프트)이 설정된 컴파일러 아키텍처를 자동으로 감지하고 해당 실행 파일을 빌드합니다.

This executable file contains the whole engine and runs without any dependencies. Executing it will bring up the Project Manager.
이 실행 파일은 전체 엔진을 포함하며 종속성없이 실행됩니다. 그것을 실행하면 Project Manager가 나타납니다.

Note

If you are compiling Godot for production use, then you can make the final executable smaller and faster by adding the SCons option target=release_debug.
프로덕션 용도로 Godot을 컴파일하는 경우 SCons 옵션 target=release_debug를 추가하여 최종 실행 파일을 작고 빠르게 만들 수 있습니다.

How the prompts actually work

The Visual Studio command prompts are just shortcuts that call the standard Command Prompt and have it run a batch file before giving you control. The batch file itself is called vcvarsall.bat and it sets up environment variables, including the PATH variable, so that the correct version of the compiler can be run. The Developer Command Prompt calls a different file called VsDevCmd.bat but none of the other tools that this batch file enables are needed by Godot/SCons.
Visual Studio 명령 프롬프트는 표준 명령 프롬프트를 호출하고 컨트롤을 제공하기 전에 배치 파일을 실행하는 바로 가기입니다. 배치 파일 자체는 vcvarsall.bat라고하며 컴파일러의 올바른 버전을 실행할 수 있도록 PATH 변수를 비롯한 환경 변수를 설정합니다. 개발자 명령 프롬프트는 VsDevCmd.bat라는 다른 파일을 호출하지만이 배치 파일에서 사용하는 다른 도구는 Godot/SCons에서 필요하지 않습니다.

Since you are probably using Visual Studio 2013 or 2015, if you need to recreate them manually, use the below folders, or place them on the desktop/taskbar:
Visual Studio 2013 또는 2015를 수동으로 다시 작성해야하는 경우, 아래 폴더를 사용하거나 바탕 화면/작업(desktop/taskbar) 표시 줄에 배치하십시오.

C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Visual Studio 2015\Visual Studio Tools
C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Visual Studio 2013\Visual Studio Tools

Start the creation of the shortcut by pressing the right mouse button/New/Shortcut in an empty place in your desired location.
원하는 위치의 빈 곳에서 마우스 오른쪽 버튼/새로 만들기/바로 가기를 눌러 바로 가기 만들기를 시작하십시오.

Then copy one of these commands below for the corresponding tool you need into the “Path” and “Name” sections of the shortcut creation wizard, and fix the path to the batch file if needed.
그런 다음 바로 가기 생성 마법사의 "경로"및 "이름"섹션에 필요한 해당 도구에 대해 아래 명령 중 하나를 복사하고 필요한 경우 배치 파일의 경로를 수정하십시오.

  • Visual Studio 2013 is in the “Microsoft Visual Studio 12.0” folder.
    Visual Studio 2013은 "Microsoft Visual Studio 12.0"폴더에 있습니다.
  • Visual Studio 2015 is in the “Microsoft Visual Studio 14.0” folder.
    Visual Studio 2015는 "Microsoft Visual Studio 14.0"폴더에 있습니다.
  • etc.
Name: Developer Command Prompt for VS2013
Path: %comspec% /k ""C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\Tools\VsDevCmd.bat""

Name: VS2013 x64 Cross Tools Command Prompt
Path: %comspec% /k ""C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat"" x86_amd64

Name: VS2013 x64 Native Tools Command Prompt
Path: %comspec% /k ""C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat"" amd64

Name: VS2013 x86 Native Tools Command Prompt
Path: %comspec% /k ""C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat"" x86

Name: VS2013 x86 Cross Tools Command Prompt
Path: %comspec% /k ""C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat"" amd64_x86

After you create the shortcut, in the shortcut’s properties, that you can access by right clicking with your mouse on the shortcut itself, you can choose the starting directory of the command prompt (“Start in” field).
단축키의 속성에서 바로 가기를 마우스 오른쪽 버튼으로 클릭하여 액세스 할 수있는 바로 가기를 만든 후 명령 프롬프트의 시작 디렉토리 ("시작"필드)를 선택할 수 있습니다.

Some of these shortcuts (namely the 64-bit compilers) seem to not be available in the Express edition of Visual Studio or Visual C++. Before recreating the commands, make sure that cl.exe executables are present in one of these locations, they are the actual compilers for the architecture you want to build from the command prompt.
이러한 단축키 중 일부 (즉, 64 비트 컴파일러)는 Visual Studio 또는 Visual C++의 Express Edition에서 사용할 수없는 것으로 보입니다. 명령을 다시 만들기 전에 cl.exe 실행 파일이 이 위치 중 하나에 있는지 확인하십시오. 이 명령은 명령 프롬프트에서 빌드 할 아키텍처의 실제 컴파일러입니다.

x86 (32-bit) cl.exe
C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\cl.exe

x86 (32-bit) cl.exe for cross-compiling for 64-bit Windows.
C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\x86_amd64\cl.exe

x64 (64-bit) cl.exe
C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\amd64\cl.exe

x64 (64-bit) cl.exe for cross-compiling for 32-bit Windows.
C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\amd64_x86\cl.exe

In case you are wondering what these prompt shortcuts do, they call cmd.exe with the \k option and have it run a Batch file.
이러한 프롬프트 바로 가기가 무엇인지 궁금해하는 경우 cmd.exe를 \k 옵션과 함께 호출하여 배치 파일을 실행하게합니다.

%comspec% - path to cmd.exe
\k - keep alive option of the command prompt
remainder - command to run via cmd.exe

cmd.exe \k(eep cmd.exe alive after commands behind this option run) ""runme.bat"" with_this_option

How to run an automated build of Godot

If you just need to run the compilation process via a Batch file or directly in the Windows Command Prompt you need to use the following command:
배치 파일을 통해 또는 Windows 명령 프롬프트에서 직접 컴파일 프로세스를 실행해야하는 경우 다음 명령을 사용해야합니다.

"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat" x86

with one of the following parameters:
다음 매개 변수 중 하나를 사용하여:

  • x86 (32-bit cl.exe to compile for the 32-bit architecture)
  • amd64 (64-bit cl.exe to compile for the 64-bit architecture)
  • x86_amd64 (32-bit cl.exe to compile for the 64-bit architecture)
  • amd64_x86 (64-bit cl.exe to compile for the 32-bit architecture)

and after that one, you can run SCons:
그 후 SCons를 실행할 수 있습니다:

scons platform=windows

or you can run them together:
또는 함께 실행할 수 있습니다:

32-bit Godot
"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat" x86 && scons platform=windows

64-bit Godot
"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat" amd64 && scons platform=windows

Development in Visual Studio or other IDEs

For most projects, using only scripting is enough but when development in C++ is needed, for creating modules or extending the engine, working with an IDE is usually desirable.
대부분의 프로젝트에서 스크립팅 만 사용하면 충분하지만 C++로 개발할 때 모듈을 만들거나 엔진을 확장하려면 IDE로 작업하는 것이 일반적입니다.

You can create a Visual Studio solution via SCons by running SCons with the vsproj=yes parameter, like this:
SCons를 실행하려면 다음과 같이 vsproj=yes 매개 변수를 사용하여 SCons를 실행하여 Visual Studio 솔루션을 만들 수 있습니다.

scons p=windows vsproj=yes

You will be able to open Godot’s source in a Visual Studio solution now, and able to build Godot via the Visual Studio Build button. However, make sure that you have installed Pywin32 so that parallel (-j) builds work properly.
이제 Visual Studio 솔루션에서 Godot의 소스를 열 수 있으며 Visual Studio 빌드 버튼을 통해 Godot을 빌드 할 수 있습니다. 그러나 병렬 (-j) 빌드가 올바르게 작동하도록 Pywin32를 설치했는지 확인하십시오.

If you need to edit the compilation commands, they are located in “Godot” project settings, NMAKE sheet. SCons is called at the end of the commands. If you make a mistake, copy the command from one of the other build configurations (debug, release_debug, release) or architectures (Win32/x64). They are equivalent.
편집 명령을 편집해야 할 경우 Nogo 시트의 "Godot"프로젝트 설정에 있습니다. SCons는 명령의 끝에서 호출됩니다. 실수를 한 경우 다른 빌드 구성 (debug, release_debug, release) 또는 아키텍처 (Win32 / x64) 중 하나에서 명령을 복사하십시오. 그들은 동등합니다.

Cross-compiling for Windows from other operating systems

If you are a Linux or macOS user, you need to install MinGW-w64, which typically comes in 32-bit and 64-bit variants. The package names may differ based on your distro, here are some known ones:
Linux 또는 macOS 사용자 인 경우 일반적으로 32 비트 및 64 비트 변형으로 제공되는 MinGW-w64를 설치해야합니다. 패키지 이름은 배포판에 따라 다를 수 있습니다. 여기에 몇 가지 알려진 것들이 있습니다

Arch
pacman -S scons mingw-w64-gcc
Debian / Ubuntu
apt-get install scons mingw-w64
Fedora
dnf install scons mingw32-gcc-c++ mingw64-gcc-c++
macOS
brew install scons mingw-w64
Mageia
urpmi scons mingw32-gcc-c++ mingw64-gcc-c++

Before allowing you to attempt the compilation, SCons will check for the following binaries in your $PATH
컴파일을 시도하기 전에 SCons는 $PATH에서 다음 바이너리를 확인합니다.

i686-w64-mingw32-gcc
x86_64-w64-mingw32-gcc

If the binaries are not located in the $PATH (e.g. /usr/bin), you can define the following environment variables to give a hint to the build system:
바이너리가 $PATH (예: /usr/bin)에 없으면 빌드 시스템에 힌트를 주기 위해 다음 환경 변수를 정의 할 수 있습니다.

export MINGW32_PREFIX="/path/to/i686-w64-mingw32-"
export MINGW64_PREFIX="/path/to/x86_64-w64-mingw32-"

To make sure you are doing things correctly, executing the following in the shell should result in a working compiler (the version output may differ based on your system):
제대로 작동하는지 확인하기 위해 셸에서 다음을 실행하면 컴파일러가 작동합니다 (버전 출력은 시스템에 따라 다를 수 있음).

user@host:~$ ${MINGW32_PREFIX}gcc --version
i686-w64-mingw32-gcc (GCC) 6.1.0 20160427 (Mageia MinGW 6.1.0-1.mga6)

Troubleshooting

Cross-compiling from some versions of Ubuntu may lead to this bug, due to a default configuration lacking support for POSIX threading.
Ubuntu의 일부 버전에서 크로스 컴파일하면 POSIX 스레딩에 대한 지원이 부족한 기본 구성으로 인해이 버그가 발생할 수 있습니다.

You can change that configuration following those instructions, for 32-bit:
다음 지침에 따라 32 비트 용으로 해당 구성을 변경할 수 있습니다.

sudo update-alternatives --config i686-w64-mingw32-gcc
<choose i686-w64-mingw32-gcc-posix from the list>
sudo update-alternatives --config i686-w64-mingw32-g++
<choose i686-w64-mingw32-g++-posix from the list>

And for 64-bit:

sudo update-alternatives --config x86_64-w64-mingw32-gcc
<choose x86_64-w64-mingw32-gcc-posix from the list>
sudo update-alternatives --config x86_64-w64-mingw32-g++
<choose x86_64-w64-mingw32-g++-posix from the list>
Creating Windows export templates

Windows export templates are created by compiling Godot as release, with the following flags:
Windows 내보내기 템플릿은 Godot을 릴리스로 컴파일하고 다음 플래그를 사용하여 만듭니다.

  • (using Mingw32 command prompt, using the bits parameter)
    (비트 매개 변수를 사용하여 Mingw32 명령 프롬프트 사용)
    C:\godot> scons platform=windows tools=no target=release bits=32
    C:\godot> scons platform=windows tools=no target=release_debug bits=32
  • (using Mingw-w64 command prompt, using the bits parameter)
    (비트 매개 변수를 사용하여 Mingw-w64 명령 프롬프트 사용)
    C:\godot> scons platform=windows tools=no target=release bits=64
    C:\godot> scons platform=windows tools=no target=release_debug bits=64
  • (using the Visual Studio command prompts for the correct architecture, notice the lack of bits parameter)
    올바른 아키텍처에 대한 Visual Studio 명령 프롬프트를 사용하면 비트 매개 변수가 부족하다는 것을 알 수 있습니다)
    C:\godot> scons platform=windows tools=no target=release
    C:\godot> scons platform=windows tools=no target=release_debug

If you plan on replacing the standard templates, copy these to:
표준 템플릿을 교체하려는 경우 다음에 복사하십시오.

C:\USERS\YOURUSER\AppData\Roaming\Godot\Templates

With the following names:
다음 이름으로:

windows_32_debug.exe
windows_32_release.exe
windows_64_debug.exe
windows_64_release.exe

However, if you are writing your custom modules or custom C++ code, you might instead want to configure your binaries as custom export templates here:
그러나 사용자 정의 모듈이나 사용자 정의 C++ 코드를 작성하는 경우 여기에 사용자 정의 내보내기 템플리트로 바이너리를 구성 할 수 있습니다.

You don’t even need to copy them, you can just reference the resulting files in the bin\ directory of your Godot source folder, so the next time you build you automatically have the custom templates referenced.
복사 할 필요조차 없으며 Godot 소스 폴더의 bin\ 디렉토리에서 결과 파일을 참조하기만 하면 다음번에 사용자 정의 템플리트가 자동으로 빌드됩니다.

반응형

'game > godot' 카테고리의 다른 글

Godot - Getting the source  (0) 2018.12.12
Godot - Introduction to the buildsystem  (0) 2018.12.11
Godot - Compiling for X11 (Linux, *BSD)  (0) 2018.12.08
Godot - Compiling for macOS  (0) 2018.12.07
Godot - Compiling for iOS  (0) 2018.12.06