Difference between revisions of "Compiling TPT++ on debian/ubuntu"

From The Powder Toy
Jump to: navigation, search
(fix apt-get command here)
m (double dashes look terrible in '''bold''', replaced with <code>code tags</code>)
Line 5: Line 5:
 
''1)'' Open your Terminal and type:
 
''1)'' Open your Terminal and type:
  
'''sudo apt-get install build-essential libsdl1.2-dev libbz2-dev zlib1g-dev liblua5.1.0-dev git scons libfftw3-dev''' (64 bit systems use lib64bz2-dev, also you might have some of these packages installed, so if you see "X is already newest version" just ignore it)
+
<code>sudo apt-get install build-essential libsdl1.2-dev libbz2-dev zlib1g-dev liblua5.1.0-dev git scons libfftw3-dev</code> (64 bit systems use lib64bz2-dev, also you might have some of these packages installed, so if you see "X is already newest version" just ignore it)
  
 
'''You MUST have Python installed and working in order for scons to work! (Python 2.7 is recommended)'''
 
'''You MUST have Python installed and working in order for scons to work! (Python 2.7 is recommended)'''
  
''2)'' Run '''<nowiki>git clone git://github.com/FacialTurd/The-Powder-Toy.git</nowiki>'''
+
''2)'' Run <code><nowiki>git clone git://github.com/FacialTurd/The-Powder-Toy.git</nowiki></code>
  
 
''3)'' Navigate to your folder containing the TPT++ source code (The-Powder-Toy) and type:
 
''3)'' Navigate to your folder containing the TPT++ source code (The-Powder-Toy) and type:
  
'''scons --lin --release''' (You need to add '''--64bit''' if you are compiling for 64 bit)
+
<code>scons --lin --release</code> (You need to add <code>--64bit</code> if you are compiling for 64 bit)
  
You can also use '''--sse2''' or '''--sse3''' for sse optimizations if you have a recent (not ancient) computer.
+
You can also use <code>--sse2</code> or <code>--sse3</code> for sse optimizations if you have a recent (not ancient) computer.
  
''4)'' Once scons has finished compiling (it will say "Done building targets" in the terminal), Run TPT++ by typing '''build/powder<tab>''' and seeing what completions are availiable
+
''4)'' Once scons has finished compiling (it will say "Done building targets" in the terminal), you'll find TPT executable in build/ folder, it will be named either powder, powder-legacy, powder64, or powder64-legacy, depending on the options you used.
  
 
[[Category:Development]]
 
[[Category:Development]]
 
[[Category:Compiling]]
 
[[Category:Compiling]]

Revision as of 11:46, 2 September 2013

If you want to see the old guide, or compile for the old c version of tpt with the makefile, see Compiling for Linux

To compile TPT++ you need to do the following:

1) Open your Terminal and type:

sudo apt-get install build-essential libsdl1.2-dev libbz2-dev zlib1g-dev liblua5.1.0-dev git scons libfftw3-dev (64 bit systems use lib64bz2-dev, also you might have some of these packages installed, so if you see "X is already newest version" just ignore it)

You MUST have Python installed and working in order for scons to work! (Python 2.7 is recommended)

2) Run git clone git://github.com/FacialTurd/The-Powder-Toy.git

3) Navigate to your folder containing the TPT++ source code (The-Powder-Toy) and type:

scons --lin --release (You need to add --64bit if you are compiling for 64 bit)

You can also use --sse2 or --sse3 for sse optimizations if you have a recent (not ancient) computer.

4) Once scons has finished compiling (it will say "Done building targets" in the terminal), you'll find TPT executable in build/ folder, it will be named either powder, powder-legacy, powder64, or powder64-legacy, depending on the options you used.