logo C/C++/FreeBasic compiling


Running Puppy with a "pup_save" file

Booting Puppy from live-CD has hardly any limitations compared with a full hard drive installation. You can even compile source packages. That is, you do not have to install Puppy to a hard drive to compile source packages. Come to think of it, what other distro can compile when just running off the live-CD? ...none that I know of.

Ditto when running Puppy from a USB Flash drive or what we call a "frugal" hard drive installation. These modes all store the personal data in a "pup_save" file and the instructions here apply to all these modes of running Puppy...

Puppy has an incredibly simple system for converting into a full C/C++ compiling environment. A single file, devx_xxx.sfs, is all that is required. The "xxx" in the filename is the version number, for example, Puppy 2.10 will be "210".

Running Puppy from live-CD, you will have a personal storage file, named pup_save.3fs, on the hard drive -- you will find it in /mnt/home folder.
All you have to do is download devx_xxx.sfs to the same place, that is, into /mnt/home/. Then reboot, and that's it, you're ready to do all that 'configure', 'make' and 'make install' stuff.

Multisession CD/DVD

This is when Puppy is run from a CD or DVD but instead of having a "pup_save" file for personal data, the personal data is saved back to the CD/DVD. This mode does not need a hard drive at all. A PC with 256MB of RAM is required, but if you want to do source code compiling then heaps of RAM is needed -- this has yet to be determined, but I recommend 1GB minimum.

In this case, download the devx_xxx.sfs file to "/' then reboot. What will happen is that it will get saved to the CD/DVD, then at next bootup Puppy will recognise it and load it as a Unionfs layer. That's it, you are ready to go.

Note however, this only works for Puppy version 4.00 or later.

Full hard drive installation

This is a conventional Linux installation.

Currently, installing the "devx" file in a Type 2 (full) hard drive installation is more complicated, and you can't undo it. It involves some steps....

1. mount the partition that Puppy is installed to (say /mnt/hda2).
2. Copy devx_2xx.sfs to /mnt/hda2/tmp.
3. # cd /mnt/hda2/tmp
4. # losetup /dev/loop2 devx_2xx.sfs
5. # mkdir mntpt
5. # mount -t squashfs /dev/loop2 mntpt
6. # cp -a --remove-destination mntpt/* /mnt/hda2/
7. # sync
8. # umount mntpt
9. # rmdir mntpt
10 # cd /
11 # umount /mnt/hda2
Note1, with recent versions of Puppy (from 3.00 upwards) steps 1 - 5 can be done with a single click -- in a ROX-Filer window just left-click on the devx_xxx.sfs file and it will be automatically mounted. Just click again to unmount, so steps 8 - 11 are also a single click.
Note2, the '--remove-destination' option is essential. If you only use '-f' to force overwrite, it will follow (dereference) a symlink, that can cause unexpected overwrites.

Extra technical notes

One thing I do recommend though. Your hard drive should have a Linux swap partition, as Linux can use this extra storage space if it runs low on physical RAM. Compiling does tend to use a lot of RAM space.

To find out how to compile the Linux kernel: How to compile the kernel

Just a note on the side about hard drive partitions. Windows XP uses the NTFS format for partitions, and Microsoft keeps the format a secret, like every other format and protocol -- which is the main reason Microsoft keeps its monopoly. Therefore, Linux support of NTFS is not perfect. If you really want to embrace open standards, and really give Linux a go, you do need to create a Linux partition and a Linux swap partition, on your hard drive. There are tools to do this -- these tools can safely (no guarantees though!) reduce the size of the NTFS partition and create the new ones -- checkout GParted, to be found in the "Control Panel" menu.
Recently a free native ext2 driver has become available for Windows NT/XP, so Windows can use a ext2 partition just like any other NTFS or VFAT (the older Windows 9x partition format) drive. Link: http://www.fs-driver.org/
If you take the trouble to do this, your play with Puppy will be so much more fruitful.


(c) Copyright Barry Kauler 2006,2008 http://www.puppylinux.com/
No part of this page is to be reproduced anywhere else. I have found that there is a problem where parts of my web pages are being inserted at other sites, then not updated, whereas I am updating my pages regularly. This is not a desirable situation, so please just link to my pages.