author Sam Lantinga <>
Thu, 12 Jul 2007 05:32:07 +0000
changeset 2177 4f896c20caf6
parent 1131 e044e7c70a50
child 2207 d63e9f5944ae
child 5893 f3adae5e12cd
permissions -rw-r--r--
     1 <HTML>
     2 	<HEAD>
     4 	</HEAD>
     5 	<BODY>
     6 		<H1>
     8 		</H1>
     9 		<H3>
    11 				James Turk</A>
    12 		</H3>
    13 		<p>
    16 		</p>
    17 		<H3>
    18 			Building SDL
    19 		</H3>
    20 		<P>
    21 			Unzip the <CODE></CODE> file into the directory that contains this 
    22 			file (<CODE>VisualC.html</CODE>).
    23 		</P>
    24 		<P>
    25 			Be certain that you unzip the zip file for your compiler into <strong>this</strong>
    26 			directory and not any other directory. If you are using WinZip, be careful to 
    27 			make sure that it extracts to <strong>this</strong> folder, because it's 
    28 			convenient feature of unzipping to a folder with the name of the file currently 
    30 			I have to say about that.
    31 		</P>
    32 		<P>
    33 			Now that it's unzipped, go into the VisualC 
    35 					("<CODE>SDL.sln</CODE>").</FONT></STRONG> This should open up the IDE.
    36 		</P>
    37 		<P>
    38 			You may be prompted at this point to upgrade the workspace, should you be using 
    40 		</P>
    41 		<P>
    43 		</P>
    44 		<P>
    45 			This is done by right clicking on each project in turn (Projects are listed in 
    46 			the Workspace panel in the FileView tab), and selecting "Build".
    47 		</P>
    48 		<P>
    49 			If you get an error about SDL_config.h being missing, you should
    50 			copy include/SDL_config.h.default to include/SDL_config.h and try again.
    51 		</P>
    52 		<P>
    54 			have at least the DirectX 5 SDK installed, however. The latest 
    55 			version of DirectX can be downloaded or purchased on a cheap CD (my 
    56 			recommendation) from <A HREF="">Microsoft </A>.
    57 		</P>
    58 		<P>
    60 			generated:
    61 		</P>
    62 		<ul>
    63     <li> SDL.dll</li>
    64     <li> SDL.lib</li>
    65     <li> SDLmain.lib</li>
    66     </ul>
    67 		<P>
    70 			the Debug or Release directories of the subdirectories of the Project folder. 
    71 			(It might be easier to just use Windows Find if this sounds confusing. And 
    72 			don't worry about needing a clue; we all need visits from the clue fairy 
    73 			frequently.)
    74 		</P>
    75 		<H3>
    76 			Creating a Project with SDL
    77 		</H3>
    78 		<P>
    79 			Create a project as a Win32 Application.
    80 		</P>
    81 		<P>
    82 			Create a C++ file for your project.
    83 		</P>
    84 		<P>
    86 				tab|Code Generation|Runtime Library </CODE>.
    87 		</P>
    88 		<P>
    91 			.
    92 			<br>
    94 					add the include and library directories to the list that VC7 keeps. Do this by 
    95 					selecting Tools|Options|Projects|VC++ Directories and under the "Show 
   100 		</P>
   101 			<P>
   103 				within the main SDL directory (the one that this HTML file located within).
   104 			</P>
   105 			<P>
   106 				Now we're going to use the files that we had created earlier in the Build SDL 
   107 				step.
   108 			</P>
   109 			<P>
   110 				Copy the following files into your Project directory:
   111 			</P>
   112 			<ul>
   113      <li> SDL.dll</li>
   114      </ul>
   115 			<P>
   116 				Add the following files to your project (It is not necessary to copy them to 
   117 				your project directory):
   118 			</P>
   119 			<ul>
   120      <li> SDL.lib </li>
   121      <li> SDLmain.lib</li>
   122      </ul>
   123 			<P>
   125 				files to project")
   126 			</P>
   128 					desireable to add them to the linker options: Project|Properties|Linker|Command 
   129 					Line and type the names of the libraries to link with in the "Additional 
   132 		<H3>
   133 			SDL 101, First Day of Class
   134 		</H3>
   135 		<P>
   136 			Now create the basic body of your project. The body of your program should take 
   137 			the following form: <CODE>
   138 				<PRE>
   139 #include "SDL.h"
   142 {
   143   // Body of the program goes here.
   144   return 0;
   145 }
   146 </PRE>
   147 			</CODE>
   148 		<P></P>
   149 		<H3>
   150 			That's it!
   151 		</H3>
   152 		<P>
   153 			I hope that this document has helped you get through the most difficult part of 
   154 			using the SDL: installing it. Suggestions for improvements to this document 
   155 			should be sent to the writers of this document.
   156 		</P>
   157 		<P>
   158 			Thanks to Paulus Esterhazy (, for the work on VC++ port.
   159 		</P>
   160 		<P>
   162 				Sam Lantinga</A>.
   163 		</P>
   164 		<P>
   165 			Later, it was converted to HTML and expanded into the document that you see 
   166 			today by <A HREF="">Lion Kimbro</A>.
   167 		</P>
   169 		</P>
   170 	</BODY>
   171 </HTML>