- intro
- installing the psptoolchain on linux
- installing the minimalist pspsdk on linux via minpspw
- installing the minimalist pspsdk on windows via minpspw
- conclusion
this tut should hopefully help anyone who wishes to bother install the psptoolchain or the minimalist pspsdk. for those of you who dont know, the psptoolchain is the "official" sdk used to develop programs for the psp. the minimalist pspsdk is also used to compile programs to run on the psp but does not include everything included in the psptoolchain, only the necessary files.
while there are merits in installing the psptoolchain from scratch, for noobs (or even your average user), the minimalist pspsdk is much easier to install and get up and running and will provide you with everything you need, hence i suggest it for those groups.
at this time i will cover three methods of installation: installing the psptoolchain on linux, installing the minimalist pspsdk on linux via minpspw, and installing the minimalist pspsdk on windows via minpspg. there are other installation methods to get the full psptoolchain on windows, but those methods will not be covered today
note: this tutorial assumes that the reader has basic knowledge of how to use a computer and the appropriate operating system, which includes but is not limited to creating, moving, modifying, and deleting various files, as well as bash (linux) or dos (windows) commands. if you are not familiar with these operations i suggest you read up on them. there are tons of guides all over the internet.
..:: installing the psptoolchain on linux ::..
[spoiler]installing the pspsdk on linux can be particularly difficult, especially if you are not familiar with linux
note: starting this off with the sudo su command may make this easier
step #1 - install necessary packages
the pspsdk requires many additional packages be installed before it can be installed successfully. you may already have some of these packages installed, but it never hurts to check.
so, to get the necessary packages, run this command (all in one line):
note: this command may not work for ALL distros. that being said these are the packages you need, so if this command doesnt work for you just get these packages using your native package manager.sudo apt-get install autoconf automake bison flex gcc libmpfr-dev libncurses5-dev libreadline-dev libusb-dev make patch subversion texinfo wget
once that command has finished executing, you are ready to move on to the next step
step #2 - download the latest psptoolchain
the psptoolchain contains all the files for installing the pspsdk.
the first thing to know is that the original source for the pspsdk, ps2dev.org, has been going on and offline (mostly offline xD) for a while now. that being said, a alternative source can be found at psp.jim.sh.
so, to attempt to download the psptoolchain from ps2dev.org, run this command:
Code: Select all
svn co svn://svn.ps2dev.org/psp/trunk/psptoolchain
if it does: great! but if (and when) it doesnt, use this command to download the psptoolchain from the backup svn:
Code: Select all
svn co http://psp.jim.sh/svn/psp/trunk/psptoolchain
as i said, all the installation scripts are set up for ps2dev.org :\ so, if you followed the steps and were able to download the psptoolchain from ps2dev.org, proceed to step #3. however if you had to resort to the backup at psp.jim.sh (which you more than likely did ), then you will need to proceed to step #2a before heading to step #3 :p
step #2a - modifying the psptoolchain installation scripts
as i said before, all the installation scripts for the pspsdk still reference ps2dev.org. before you proceed you will need to modify those scripts.
these are the scripts you will need to modify:
- 003-pspsdk-stage1.sh
- 006-pspsdk-stage2.sh
- 009-psplinkusb.sh
Code: Select all
## Download the source code.
if test ! -d "pspsdk"; then
svn checkout svn://svn.ps2dev.org/psp/trunk/pspsdk
else
svn update pspsdk
fi
Code: Select all
## Download the source code.
if test ! -d "pspsdk"; then
##svn checkout svn://svn.ps2dev.org/psp/trunk/pspsdk
svn checkout http://psp.jim.sh/svn/psp/trunk/pspsdk
else
svn update pspsdk
fi
the only other thing to notice is that this particular code is for downloading from the the pspsdk directory (which you can tell by the /pspsdk). other scripts may be downloading from a different directory, so make sure to preserve the final location from the end of the code you commented out and add it to the code you added
e.g. , if the code you commented out was like this:
Code: Select all
svn checkout svn://svn.ps2dev.org/psp/trunk/psplinkusb
Code: Select all
svn checkout http://psp.jim.sh/svn/psp/trunk/psplinkusb
step #3 - modifying your login script
now we need to make some changes to your login script. start by running this command:
Code: Select all
gedit ~/.bashrc
Code: Select all
export PSPDEV=/usr/local/pspdev
export PSPSDK=$PSPDEV/psp/sdk
export PATH=$PATH:$PSPDEV/bin:$PSPSDK/bin
step #4 - execute the toolchain script
now everything should be ready to install the psptoolchain. first thing you need to do is change directory to the psptoolchain directory like this:
Code: Select all
cd psptoolchain
Code: Select all
sudo ./toolchain-sudo.sh
note: if you are receiving errors such as "psp-config not found", verify that you set up the environmental variables correctly (see step #3) and that you have the permissions set correctly on the .bashrc file (this happened to me ). for more information on permissions in general, see this thread: viewtopic.php?f=8&t=5240[/spoiler]
..:: installing the minimalist pspsdk on linux via minpspw::..
[spoiler]these steps should work fine on the most popular linux distributions (ubuntu, mint, debian, etc.) i personally tested them on debian.
step #1 - download the latest version of minpspw
visit the minpspw and download the version fitting for your linux distribution and architecture (32-bit or 64-bit).
step #2 - install minpspw
cd to the location you choose to save the minpspw installation package (for example, mine was /home/debian-vm/Downloads) and execute this command:
Code: Select all
sudo dpkg -i minpspw.deb
step #3 - set up the environment variables (in .profile)
cd to /home (simply cd), then run this command:
Code: Select all
gedit .profile
Code: Select all
export PATH=$PATH:/opt/pspsdk/bin
export PSPSDK=/opt/pspsdk
step #4 - install additional packages
afaik there is only one necessary additional package that needs to be installed, so run this command:
Code: Select all
sudo apt-get install zlib1g-dev
Code: Select all
gcc, automake, make, subversion, wget, git
surely i don't need to walk you through this step
once you have rebooted, the process should be complete. to verify, start a new terminal and enter this command:
Code: Select all
psp-gcc --version
Code: Select all
psp-gcc (GCC) 4.3.5
Copyright (C) Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
..:: installing the minimalist pspsdk on windows via minpspw ::..
[spoiler]those of us using windows (i go back and forth xD) cannot simply install the pspsdk natively, but there are alternatives. one of the best (and definitely the easiest ) is called minpspw, the minimalist pspsdk. this package contains everything you need to setup a basic pspsdk in a windows environment.
installation is very simple:
step #1 - download the latest version of minpspw
the latest version (currently 0.11.1) can be downloaded here:
Minimalist PSPSDK | Download Minimalist PSPSDK software for free at SourceForge.net
step #2 - select components for installation
once the download is complete run the installer. click "next", accept the license agreement and click "next" again. you should now be at the "choose components" screen. this screen lets you select what will and will not be installed. by default, "PSP DevKit", "SDK Samples", "PSP Link", "HTML Documentation", and "Basic Devpaks" are selected for installation, while "Visual Studio Support" and "Man/Info Pages" are not.
i suggest you leave all the defaults selected and they are all somewhat essential for developing for the psp. if you are going to be coding using microsoft visual studio then you need to select "Visual Studio Support" for installation. i will leave the installation of "Man/Info Pages" up to you
when you are finished selecting components for installation, click "next".
step #3 - complete installation
this screen is the standard "select destination" screen. you can change the location of installation, but i highly suggest you leave it in its default location when you are done click "install". once it is complete, click "next", then "finish"
step #4 - adding pspsdk environment variables
the last step to installing the pspsdk on windows is adding the pspsdk to the environmental variables. to keep this simple, i am not going to go into much detail concerning getting to menu for modifying environment variables. each version of windows is different, so just google "how to modify environment variables on windows [insert version here]".
once you have reached the environment variables menu, select the variable called "Path" in the "system variables" box and click the "edit" button. once the dialog box pops up, place the cursor at the end of the statement in the "Variable Value" box.
with the cursor at the end of the statement, add this (no spaces): ;C:\pspsdk
once that is done you are set to go. you have successfully completed installing the pspsdk on windows via minpspw! congrats! now get to coding![/spoiler]
..:: conclusion ::..
i hope this tutorial has helped answer your questions concerning installation of the pspsdk. if you still have any questions feel free to post them in this thread.
please note that NONE of this is my work, only the tutorial. all credit goes to the wonderful devs who developed all of these tools, without which there would be no psp homebrew scene. all thanks go to them!
also, im obviously no expert, so if you notice any mistakes (trust me, im sure there are plenty ), feel free to post them and i will get it corrected. thanks!