Added Visual C++ 7 (.NET) projects (thanks James!)
authorSam Lantinga <slouken@libsdl.org>
Tue, 08 Oct 2002 15:43:40 +0000
changeset 521136d97397288
parent 520 26eb0f877ce6
child 522 6b3998ddee6d
Added Visual C++ 7 (.NET) projects (thanks James!)
Makefile.am
VisualC.html
VisualC7.zip
docs.html
     1.1 --- a/Makefile.am	Tue Oct 08 15:34:19 2002 +0000
     1.2 +++ b/Makefile.am	Tue Oct 08 15:43:40 2002 +0000
     1.3 @@ -40,6 +40,7 @@
     1.4  	Borland.zip	\
     1.5  	VisualC.html	\
     1.6  	VisualC.zip	\
     1.7 +	VisualC7.zip	\
     1.8  	VisualCE.zip	\
     1.9  	Makefile.dc	\
    1.10  	MPWmake.sea.bin	\
     2.1 --- a/VisualC.html	Tue Oct 08 15:34:19 2002 +0000
     2.2 +++ b/VisualC.html	Tue Oct 08 15:43:40 2002 +0000
     2.3 @@ -1,193 +1,139 @@
     2.4  <HTML>
     2.5 -
     2.6 -
     2.7 -
     2.8 -<HEAD>
     2.9 -
    2.10 -
    2.11 -
    2.12 -<TITLE> Using SDL with Microsoft Visual C++ 5 and 6 </TITLE>
    2.13 -
    2.14 -
    2.15 -
    2.16 -</HEAD>
    2.17 -
    2.18 -
    2.19 -
    2.20 -<BODY>
    2.21 -
    2.22 -
    2.23 -
    2.24 -<H1> Using SDL with Microsoft Visual C++ 5 and 6 </H1>
    2.25 -
    2.26 -<H3>
    2.27 -     by <A HREF="mailto:snowlion@sprynet.com"> Lion Kimbro </A>
    2.28 -</H3>
    2.29 -
    2.30 -
    2.31 -
    2.32 -<p>
    2.33 -    You can either use the precompiled libraries from
    2.34 -    <A HREF="http://www.libsdl.org/download.php">
    2.35 -    the SDL Download web site </A>,
    2.36 -    or you can build SDL yourself.
    2.37 -</p>
    2.38 -
    2.39 -
    2.40 -<H3> Building SDL </H3>
    2.41 -
    2.42 -<P>
    2.43 -     Unzip the <CODE>VisualC.zip</CODE> file into the directory
    2.44 -     that contains this file (<CODE>VisualC.html</CODE>).
    2.45 -</P>
    2.46 -
    2.47 -<P>
    2.48 -     Be certain that you unzip <CODE> VisualC.zip </CODE>
    2.49 -     into <strong>this</strong> directory and not any other
    2.50 -     directory. If you are using WinZip, be careful to
    2.51 -     make sure that it extracts to <strong>this</strong>
    2.52 -     folder, because it's convenient feature of
    2.53 -     unzipping to a folder with the name of the
    2.54 -     file currently being unzipped will get you in
    2.55 -     trouble if you use it right now. And that's all
    2.56 -     I have to say about that.
    2.57 -</P>
    2.58 -
    2.59 -<P>
    2.60 -     Now that it's unzipped, go into the VisualC directory
    2.61 -     that is created, and double-click on the VC++
    2.62 -     workspace file &quot;<CODE>SDL.dsw</CODE>&quot;.
    2.63 -     This should open up VisualC.
    2.64 -</P>
    2.65 -
    2.66 -<P>
    2.67 -     You may be prompted at this point to upgrade the
    2.68 -     workspace, should you be using a more recent version
    2.69 -     of Visual C++. If so, allow the workspace to be
    2.70 -     upgraded.
    2.71 -</P>
    2.72 -
    2.73 -
    2.74 -<P>
    2.75 -     Build the <CODE>.dll</CODE> and <CODE>.lib</CODE> files.
    2.76 -</P>
    2.77 -
    2.78 -<P>
    2.79 -     This is done by right clicking on each project in turn
    2.80 -     (Projects are listed in the Workspace panel in the
    2.81 -     FileView tab), and selecting &quot;Build&quot;.
    2.82 -</P>
    2.83 -
    2.84 -<P>
    2.85 -     You may get a few warnings, but you should not get
    2.86 -     any errors. You do have to have at least the DirectX
    2.87 -     5 SDK installed, however. (I believe...) The latest
    2.88 -     version of DirectX can be downloaded or purchased
    2.89 -     on a cheap CD (my recommendation) from
    2.90 -     <A HREF="http://www.microsoft.com"> Microsoft </A>.
    2.91 -</P>
    2.92 -
    2.93 -<P>
    2.94 -    Later, we will refer to the following .lib and .dll
    2.95 -    files that have just been generated:
    2.96 -</P>
    2.97 -
    2.98 -    <list>
    2.99 -    <li> SDL.dll
   2.100 -    <li> SDL.lib
   2.101 -    <li> SDLmain.lib
   2.102 -    </list>
   2.103 -
   2.104 -<P>
   2.105 -    Search for these using the Windows Find (Windows-F)
   2.106 -    utility, if you don't already know where they should be.
   2.107 -    For those of you with a clue, look inside the Debug
   2.108 -    or Release directories of the subdirectories of the
   2.109 -    VisualC folder. (It might be easier to just use
   2.110 -    Windows Find if this sounds confusing. And don't worry
   2.111 -    about needing a clue; we all need visits from the
   2.112 -    clue fairy frequently.)
   2.113 -</P>
   2.114 -
   2.115 -
   2.116 -
   2.117 -<H3> Creating a Project with SDL </H3>
   2.118 -
   2.119 -<P>
   2.120 -     Create a project as a Win32 Application.
   2.121 -</P>
   2.122 -
   2.123 -<P>
   2.124 -     Create a C++ file for your project.
   2.125 -</P>
   2.126 -
   2.127 -<P>
   2.128 -     Set the C runtime to "Multi-threaded DLL" in the menu:
   2.129 -     <CODE> Project|Settings|C/C++ tab|Code Generation|Runtime Library </CODE>.
   2.130 -</P>
   2.131 -
   2.132 -<P>
   2.133 -     Add the SDL <CODE>include</CODE> directory to your list
   2.134 -     of includes in the menu:
   2.135 -     <CODE> Project|Settings|C/C++ tab|Preprocessor|Additional include directories </CODE>.
   2.136 -</P>
   2.137 -
   2.138 -<P>
   2.139 -     The &quot;include directory&quot; I am referring to is the
   2.140 -     <CODE>include</CODE> folder within the main SDL
   2.141 -     directory (the one that this HTML file located
   2.142 -     within.
   2.143 -</P>
   2.144 -
   2.145 -<P>
   2.146 -     Now we're going to use the files that we had created
   2.147 -     earlier in the Build SDL step.
   2.148 -</P>
   2.149 -
   2.150 -<P>
   2.151 -     Copy the following files into your Project directory:
   2.152 -</P>
   2.153 -
   2.154 -     <list>
   2.155 -     <li> SDL.dll </li>
   2.156 -     </list>
   2.157 -
   2.158 -<P>
   2.159 -     Copy the following files into your Project directory,
   2.160 -     and <em>add them to your Project</em> as well:
   2.161 -</P>
   2.162 -
   2.163 -     <list>
   2.164 +	<HEAD>
   2.165 +		<TITLE>Using SDL with Microsoft Visual C++</TITLE>
   2.166 +	</HEAD>
   2.167 +	<BODY>
   2.168 +		<H1>
   2.169 +			Using SDL with Microsoft Visual C++ 5,6&nbsp;and 7
   2.170 +		</H1>
   2.171 +		<H3>
   2.172 +			by <A HREF="mailto:snowlion@sprynet.com">Lion Kimbro </A>and additions by <A HREF="mailto:james@conceptofzero.net">
   2.173 +				James Turk</A>
   2.174 +		</H3>
   2.175 +		<p>
   2.176 +			You can either use the precompiled libraries from <A HREF="http://www.libsdl.org/download.php">
   2.177 +				the SDL Download web site </A>, or you can build SDL yourself.
   2.178 +		</p>
   2.179 +		<H3>
   2.180 +			Building SDL
   2.181 +		</H3>
   2.182 +		<P>
   2.183 +			Unzip the <CODE>VisualC.zip</CODE> file into the directory that contains this 
   2.184 +			file (<CODE>VisualC.html</CODE>). <STRONG><FONT color="#009900">If you are using Visual 
   2.185 +					C++ 7 (.NET) you will need to use the file <code>VisualC7.zip.</code></FONT></STRONG>
   2.186 +		</P>
   2.187 +		<P>
   2.188 +			Be certain that you unzip the zip file for your compiler into <strong>this</strong>
   2.189 +			directory and not any other directory. If you are using WinZip, be careful to 
   2.190 +			make sure that it extracts to <strong>this</strong> folder, because it's 
   2.191 +			convenient feature of unzipping to a folder with the name of the file currently 
   2.192 +			being unzipped will get you in trouble if you use it right now. And that's all 
   2.193 +			I have to say about that.
   2.194 +		</P>
   2.195 +		<P>
   2.196 +			Now that it's unzipped, go into the VisualC <STRONG><FONT color="#009900">(VisualC7)</FONT></STRONG>
   2.197 +			directory that is created, and double-click on the VC++ file "<CODE>SDL.dsw</CODE>"<STRONG><FONT color="#009900">
   2.198 +					("<CODE>SDL.sln</CODE>").</FONT></STRONG> This should open up the IDE.
   2.199 +		</P>
   2.200 +		<P>
   2.201 +			You may be prompted at this point to upgrade the workspace, should you be using 
   2.202 +			a more recent version of Visual C++. If so, allow the workspace to be upgraded.
   2.203 +		</P>
   2.204 +		<P>
   2.205 +			Build the <CODE>.dll</CODE> and <CODE>.lib</CODE> files.
   2.206 +		</P>
   2.207 +		<P>
   2.208 +			This is done by right clicking on each project in turn (Projects are listed in 
   2.209 +			the Workspace panel in the FileView tab), and selecting "Build".
   2.210 +		</P>
   2.211 +		<P>
   2.212 +			You may get a few warnings, but you should not get any errors. You do have to 
   2.213 +			have at least the DirectX 5 SDK installed, however. The latest 
   2.214 +			version of DirectX can be downloaded or purchased on a cheap CD (my 
   2.215 +			recommendation) from <A HREF="http://www.microsoft.com">Microsoft </A>.
   2.216 +		</P>
   2.217 +		<P>
   2.218 +			Later, we will refer to the following .lib and .dll files that have just been 
   2.219 +			generated:
   2.220 +		</P>
   2.221 +		<ul>
   2.222 +    <li> SDL.dll</li>
   2.223 +    <li> SDL.lib</li>
   2.224 +    <li> SDLmain.lib</li>
   2.225 +    </ul>
   2.226 +		<P>
   2.227 +			Search for these using the Windows Find (Windows-F) utility, if you don't 
   2.228 +			already know where they should be. For those of you with a clue, look inside 
   2.229 +			the Debug or Release directories of the subdirectories of the Project folder. 
   2.230 +			(It might be easier to just use Windows Find if this sounds confusing. And 
   2.231 +			don't worry about needing a clue; we all need visits from the clue fairy 
   2.232 +			frequently.)
   2.233 +		</P>
   2.234 +		<H3>
   2.235 +			Creating a Project with SDL
   2.236 +		</H3>
   2.237 +		<P>
   2.238 +			Create a project as a Win32 Application.
   2.239 +		</P>
   2.240 +		<P>
   2.241 +			Create a C++ file for your project.
   2.242 +		</P>
   2.243 +		<P>
   2.244 +			Set the C runtime to "Multi-threaded DLL" in the menu: <CODE>Project|Settings|C/C++ 
   2.245 +				tab|Code Generation|Runtime Library </CODE>.
   2.246 +		</P>
   2.247 +		<P>
   2.248 +			Add the SDL <CODE>include</CODE> directory to your list of includes in the 
   2.249 +			menu: <CODE>Project|Settings|C/C++ tab|Preprocessor|Additional include directories </CODE>
   2.250 +			.
   2.251 +			<br>
   2.252 +			<STRONG><FONT color="#009900">VC7 Specific: Instead of doing this I find it easier to 
   2.253 +					add the include and library directories to the list that VC7 keeps. Do this by 
   2.254 +					selecting Tools|Options|Projects|VC++ Directories and under the "Show 
   2.255 +					Directories For:" dropbox select "Include Files", and click the "New Directory 
   2.256 +					Icon" and add the [SDLROOT]\include directory (ex. If you installed to 
   2.257 +					c:\SDL-1.2.5\ add c:\SDL-1.2.5\include).&nbsp;Proceed to&nbsp;change the 
   2.258 +					dropbox selection to "Library Files" and add [SDLROOT]\lib.</FONT></STRONG>
   2.259 +		</P>
   2.260 +			<P>
   2.261 +				The "include directory" I am referring to is the <CODE>include</CODE> folder 
   2.262 +				within the main SDL directory (the one that this HTML file located within).
   2.263 +			</P>
   2.264 +			<P>
   2.265 +				Now we're going to use the files that we had created earlier in the Build SDL 
   2.266 +				step.
   2.267 +			</P>
   2.268 +			<P>
   2.269 +				Copy the following files into your Project directory:
   2.270 +			</P>
   2.271 +			<ul>
   2.272 +     <li> SDL.dll</li>
   2.273 +     </ul>
   2.274 +			<P>
   2.275 +				Add the following files to your project (It is not necessary to copy them to 
   2.276 +				your project directory):
   2.277 +			</P>
   2.278 +			<ul>
   2.279       <li> SDL.lib </li>
   2.280 -     <li> SDLmain.lib </li>
   2.281 -     </list>
   2.282 -
   2.283 -<P>
   2.284 -     (To add them to your project, right click on your
   2.285 -     project, and select &quot;Add files to project&quot;)
   2.286 -</P>
   2.287 -
   2.288 -<P>
   2.289 -     (I believe that it's not necessary to actually
   2.290 -     copy the .lib files into your directory; you only
   2.291 -     have to be certain that you add them to your Project.
   2.292 -     If someone is so inclined, correct this document, or
   2.293 -     <A HREF="mailto:snowlion@sprynet.com">
   2.294 -     e-mail me </A>,
   2.295 -     and I'll fix this document.)
   2.296 -</P>
   2.297 -
   2.298 -
   2.299 -
   2.300 -<H3> SDL 101, First Day of Class </H3>
   2.301 -
   2.302 -<P>
   2.303 -     Now create the basic body of your project.
   2.304 -     The body of your program should take the following form:
   2.305 -
   2.306 -<CODE>
   2.307 -<PRE>
   2.308 -#include &quot;SDL.h&quot;
   2.309 +     <li> SDLmain.lib</li>
   2.310 +     </ul>
   2.311 +			<P>
   2.312 +				(To add them to your project, right click on your project, and select "Add 
   2.313 +				files to project")
   2.314 +			</P>
   2.315 +		<P><STRONG><FONT color="#009900">Instead of adding the files to your project it is more 
   2.316 +					desireable to add them to the linker options: Project|Properties|Linker|Command 
   2.317 +					Line and type the names of the libraries to link with in the "Additional 
   2.318 +					Options:" box.&nbsp; Note: This must be done&nbsp;for&nbsp;each&nbsp;build 
   2.319 +					configuration (eg. Release,Debug).</FONT></STRONG></P>
   2.320 +		<H3>
   2.321 +			SDL 101, First Day of Class
   2.322 +		</H3>
   2.323 +		<P>
   2.324 +			Now create the basic body of your project. The body of your program should take 
   2.325 +			the following form: <CODE>
   2.326 +				<PRE>
   2.327 +#include "SDL.h"
   2.328  
   2.329  int main( int argc, char* argv[] )
   2.330  {
   2.331 @@ -195,41 +141,28 @@
   2.332    return 0;
   2.333  }
   2.334  </PRE>
   2.335 -</CODE>
   2.336 -</P>
   2.337 -
   2.338 -<H3> That's it! </H3>
   2.339 -
   2.340 -<P>
   2.341 -     I hope that this document has helped you get
   2.342 -     through the most difficult part of using the
   2.343 -     SDL: installing it. Suggestions for improvements
   2.344 -     to this document should be sent to the writers
   2.345 -     of this document.
   2.346 -</P>
   2.347 -
   2.348 -<P>
   2.349 -     Thanks to Paulus Esterhazy (pesterhazy@gmx.net), for the work on VC++ port.
   2.350 -</P>
   2.351 -
   2.352 -<P>
   2.353 -     This document was originally called &quot;VisualC.txt&quot;,
   2.354 -     and was written by 
   2.355 -     <A HREF="mailto:slouken@libsdl.org">Sam Lantinga</A>.
   2.356 -</P>
   2.357 -
   2.358 -<P>
   2.359 -     Later, it was converted to HTML and expanded into
   2.360 -     the document that you see today by 
   2.361 -     <A HREF="mailto:snowlion@sprynet.com">Lion Kimbro</A>.
   2.362 -</P>
   2.363 -
   2.364 -
   2.365 -
   2.366 -</BODY>
   2.367 -
   2.368 -
   2.369 -
   2.370 +			</CODE>
   2.371 +		<P></P>
   2.372 +		<H3>
   2.373 +			That's it!
   2.374 +		</H3>
   2.375 +		<P>
   2.376 +			I hope that this document has helped you get through the most difficult part of 
   2.377 +			using the SDL: installing it. Suggestions for improvements to this document 
   2.378 +			should be sent to the writers of this document.
   2.379 +		</P>
   2.380 +		<P>
   2.381 +			Thanks to Paulus Esterhazy (pesterhazy@gmx.net), for the work on VC++ port.
   2.382 +		</P>
   2.383 +		<P>
   2.384 +			This document was originally called "VisualC.txt", and was written by <A HREF="mailto:slouken@libsdl.org">
   2.385 +				Sam Lantinga</A>.
   2.386 +		</P>
   2.387 +		<P>
   2.388 +			Later, it was converted to HTML and expanded into the document that you see 
   2.389 +			today by <A HREF="mailto:snowlion@sprynet.com">Lion Kimbro</A>.
   2.390 +		</P>
   2.391 +		<P>Minor Fixes and Visual C++ 7 Information (In Green) was added by <A HREF="mailto:james@conceptofzero.net">James Turk</A>
   2.392 +		</P>
   2.393 +	</BODY>
   2.394  </HTML>
   2.395 -
   2.396 -
     3.1 Binary file VisualC7.zip has changed
     4.1 --- a/docs.html	Tue Oct 08 15:34:19 2002 +0000
     4.2 +++ b/docs.html	Tue Oct 08 15:43:40 2002 +0000
     4.3 @@ -20,6 +20,7 @@
     4.4  Major changes since SDL 1.0.0:
     4.5  </H2>
     4.6  <UL>
     4.7 +	<LI> 1.2.6: Added Visual C++ 7 (.NET) projects (thanks James!)
     4.8  	<LI> 1.2.5: Added an environment variable SDL_HAS3BUTTONMOUSE for Quartz
     4.9  	<LI> 1.2.5: Added initial support for Dreamcast (thanks HERO!) 
    4.10  	<LI> 1.2.5: Implemented resizing Cocoa windows (thanks Darrell!)