Compiler choices: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(The For template can be worded better, the second part especially, but I think it makes sense to have in any case)
(Rewrote article to be based on tools rather than SDK versions)
Line 1: Line 1:
{{LanguageBar}}
{{LanguageBar}}
'''{{For|about=choosing a source code compiler|a list of compiler-related subjects|[[Compiler]]}}'''
'''{{For|about=choosing a C++ code compiler|a list of subjects which use the word "compiler"|[[Compiler]]}}'''
[[File:Visual studio logo.png|right|Visual Studio logo]]
[[File:Gccegg-65.png|right|GCC logo]]


You have several choices for compiling unedited variants of the Source SDK depending on which version you are using.
You have several choices for compiling unedited variants of the Source SDK depending on which version you are using.


== Source SDK 2013 ==
= Visual Studio =
Up-to-date compiler choices for Source SDK 2013 are currently on [[Source SDK 2013|the main Source SDK 2013 page]].
[[File:Icon-VStudio.png|150px|right|Visual Studio logo]]
[[File:Visual studio logo.png|right|thumb|Visual Studio logo used from 2010-2012.]]
{{Industry tool|{{w|Visual Studio}}}}
{{for|about=the IDE recommended for use with the Source engine's C++ code|the rich text editor commonly used with scripts|[[Visual Studio Code]]}}
 
'''Visual Studio''' is an {{w|Integrated development environment}} (IDE) developed and maintained by Microsoft. It is the default IDE recommended for use with the Source SDK on Windows. In {{src13|4}}, the default version of Visual Studio used for Source engine development is '''Visual Studio 2013'''. Older versions of Visual Studio are not compatible with Source 2013, and newer versions of Visual Studio will not work with Source 2013 by default. Please see [[Source_SDK_2013#Step_One:_Installing_Visual_Studio|Installing Visual Studio for Source SDK 2013]] for more information on how to install Visual Studio 2013, as well as how newer versions of Visual Studio can be used.
 
== Availability ==
Different versions of Visual Studio are supported between different versions of the Source SDK.
 
{| class="standard-table plainlinks" style="width:60%"
! Version
! Availability
! Requirements
|-
| Visual Studio 2005
|rowspan="4"| {{astools|4.1|nt=1}}, {{src07|4.1}} and earlier
| See [[Compiling under VS2005]].
|-
| Visual Studio 2008
| See [[Compiling under VS2008]].
|-
| Visual Studio 2010
| See [[Compiling under VS2010]].
|-
| Visual Studio 2012
| See [[Compiling under VS2012]].
|-
| Visual Studio 2013
|rowspan="5"| {{src13|4.1}}
| ''Default''
|-
| Visual Studio 2015
| See [[Compiling under VS2022]].{{confirm}}
|-
| Visual Studio 2017
| See [[Compiling under VS2022]].{{confirm}}
|-
| Visual Studio 2019
| See [[Compiling under VS2022]].{{confirm}}
|-
| Visual Studio 2022
| See [[Compiling under VS2022]].
|}
 
{{confirm|Can changes from [[Compiling under VS2022]] also be used with VS2015—VS2019?}}
 
<br><hr><br>
 
= GCC =
[[File:Gccegg-65.png|right|GCC logo]]
{{Industry tool|{{w|GNU Compiler Collection}}}}
The '''GNU Compiler Collection (GCC)''' is a collection of code compilers maintained by the GNU Project. '''G++''' in particular is the default compiler recommended for use with the Source SDK on Linux.


== Alien Swarm SDK ==
== Availability ==
{{note|{{astools|4.1}} does not support GCC. If you want your Alien Swarm mod to run on Linux, you will need to use Proton.}}
{| class="standard-table plainlinks" style="width:60%"
! Version
! Availability
! Requirements
|-
| GCC 4.2.x or lower
| {{src07|4.1}} and earlier
| See [[Compiling under Linux]].
|-
| GCC 4.6-4.8
|rowspan="2"| {{src13|4.1}}
| See [[Source SDK 2013#Source SDK 2013 on Linux ("container" method)|Source SDK 2013 on Linux ("container" method)]].
|-
| GCC 5 or higher
| See [[Source SDK 2013#Source SDK 2013 on Linux ("container" method)|Source SDK 2013 on Linux ("container" method)]] and optional step for changing the toolchain.
|}


#'''[http://www.microsoft.com/visualstudio/en-us/products/2005-editions/ Visual Studio 2005]''' / '''[http://download.microsoft.com/download/8/3/a/83aad8f9-38ba-4503-b3cd-ba28c360c27b/ENU/vcsetup.exe Visual C++ Express 2005]''' — which are the officially-supported compilers.
<br><hr><br>
#'''[http://www.microsoft.com/visualstudio/en-us/products/2010-editions/ Visual Studio 2010]''' / '''[http://www.microsoft.com/visualstudio/en-us/products/2010-editions/visual-cpp-express Visual C++ Express 2010]''' — needs a [[Compiling under VS2010#Alien Swarm| manual fix]] for [[Alien Swarm SDK]], but works best for it.


== Source SDK 2007 (and earlier) ==
= See also =
* [[Building without Visual Studio]]
* {{vscode|4.1}} — A rich text editor commonly used with scripts outside of the code.


#'''[http://www.microsoft.com/visualstudio/en-us/products/2005-editions/ Visual Studio 2005]''' / '''[http://download.microsoft.com/download/8/3/a/83aad8f9-38ba-4503-b3cd-ba28c360c27b/ENU/vcsetup.exe Visual C++ Express 2005]''' — which are the officially-supported compilers.
== External links ==
#'''[http://www.microsoft.com/visualstudio/en-us/products/2008-editions/ Visual Studio 2008]''' / '''[http://www.microsoft.com/express/Downloads/#2008-Visual-CPP Visual C++ Express 2008]''' — which can be used [[Compiling under VS2008|after a bit of work]].
* [https://visualstudio.microsoft.com/ Visual Studio]
#'''[http://gcc.gnu.org/ GCC]''' — which is used to compile [[Wikipedia:Linux|Linux]] [[Dedicated server|Dedicated Server]]s. See [[Compiling under Linux]].
* [http://gcc.gnu.org/ GCC]


[[Category:Source SDK FAQ]]
[[Category:Source SDK FAQ]]
[[Category:Programming]]
[[Category:Programming]]

Revision as of 14:34, 21 July 2024

English (en)Español (es)Русский (ru)Translate (Translate)
This article is about choosing a C++ code compiler. For a list of subjects which use the word "compiler", see Compiler.

You have several choices for compiling unedited variants of the Source SDK depending on which version you are using.

Visual Studio

Visual Studio logo
Visual Studio logo used from 2010-2012.
Info.png
This article or section is about an external tool that is not directly related to Valve's engines. It is not an exhaustive source of information and may only exist on this wiki for reference purposes.
Please see Wikipedia icon Visual Studio for more information on the tool itself.
This article is about the IDE recommended for use with the Source engine's C++ code. For the rich text editor commonly used with scripts, see Visual Studio Code.

Visual Studio is an Wikipedia icon Integrated development environment (IDE) developed and maintained by Microsoft. It is the default IDE recommended for use with the Source SDK on Windows. In Source 2013 Source 2013, the default version of Visual Studio used for Source engine development is Visual Studio 2013. Older versions of Visual Studio are not compatible with Source 2013, and newer versions of Visual Studio will not work with Source 2013 by default. Please see Installing Visual Studio for Source SDK 2013 for more information on how to install Visual Studio 2013, as well as how newer versions of Visual Studio can be used.

Availability

Different versions of Visual Studio are supported between different versions of the Source SDK.

Confirm:Can changes from Compiling under VS2022 also be used with VS2015—VS2019?




GCC

GCC logo
Info.png
This article or section is about an external tool that is not directly related to Valve's engines. It is not an exhaustive source of information and may only exist on this wiki for reference purposes.
Please see Wikipedia icon GNU Compiler Collection for more information on the tool itself.

The GNU Compiler Collection (GCC) is a collection of code compilers maintained by the GNU Project. G++ in particular is the default compiler recommended for use with the Source SDK on Linux.

Availability

Note.pngNote:Alien Swarm - SDK Alien Swarm - SDK does not support GCC. If you want your Alien Swarm mod to run on Linux, you will need to use Proton.




See also

External links