Page 1 of 2

Can I compile from within Puppy? (Short answer: yes)

Posted: Thu 06 Oct 2005, 08:42
by wireframewolf
Heyo. I was just checking out Puppy Linux because DSL from a USB key seems to cause my mini-ITX board some major issues. In any case, after installing Puppy to a USB drive, I read the HOWTO on writing software for Puppy, and noticed something about not being able to compile C.

Well, the whole point of my mini machine is a light weight computer I can carry and develop on. Right now I'm mainly interested in C, and I hope to learn more about OSS so I can program sound applications. Is it totally impossible to install a C compiler on puppy and program with the OSS packages? I'm still new to Linux, so I'm not really sure what can and can't be done on various distros. But it seems like there should be a way to do these things, and if not, I should probably look for another solution.

Thanks for your time,
Wireframewolf

Posted: Thu 06 Oct 2005, 09:16
by Lobster
Start here
http://www.goosee.com/puppy/development/compileapps.htm

and here
http://www.goosee.com/puppy/wikka/Compiling
(boy that needs updating . . .)

It is possible to compile C in Puppy

Welcome to the kennels :)

Posted: Thu 06 Oct 2005, 14:53
by wireframewolf
Thanks, but I'm still a little confused. That first article says 'compiling within puppy' which is what I want, but seems to use another Linux OS for the creation of applications rather than doing it all 'within' Puppy. Am I missing something here?
Even the second article isn't much help, as those rules for compiling something generally apply to any OS.

Posted: Thu 06 Oct 2005, 15:09
by dvw86
News Page-Aug 20 wrote:To compile applications from within Puppy, just place the usr_devx.sfs file on the hard drive in the same place as the pup001/2 file. Boot Puppy and you are immediately ready to compile. This capability was pioneered with 1.0.5alpha1, further improved in the upcoming alpha2.
I have added a further useful capability: a squashfs file named usr_more.sfs will also get mounted on /usr. A use for this could be anything very big that needs to be in /usr, for example the complete collection of KDE libraries and applications -- just by placing usr_more.sfs in the same hard drive partition as pupxxx, Puppy will have all the KDE apps.

Posted: Thu 06 Oct 2005, 16:21
by rarsa
Bottom line:

- Go to the puppy download page www.puppylinux.com
- Download usr_devx.sfs
- If you are using a pupxxx file: Put usr_devx.sfs in the same place where the pupxxx file is.
- If you have a HDD installation, put usr_devx.sfs under /
- Reboot puppy

that's it!

Posted: Thu 06 Oct 2005, 16:48
by wireframewolf
Alright, cool. I'll try that.

Just out of curiousity, and I don't mean to be a pain but I've never developed in Linux so I'm not sure how its programming libraries work exactly, but why does having that file allow you to compile C with a compiler like, say, gcc?

Posted: Thu 06 Oct 2005, 17:16
by Ian
It contains the tools.

Posted: Thu 06 Oct 2005, 18:47
by rarsa
that file allow you to compile C with a compiler like
Oh, the usr_devx.sfs is not a library and it is not a 'linux thing' it is specific to Puppy, it is a filesystem that gets mounted as a unionfs under /usr.

Think of it as a folder structure that is overlaid on top of /usr, so if the standard puppy /usr has a file /usr/bin/something and the usr_dev.sfs has a file /usr/bin/somethingelse, then, after mounting usr_devx.sfs on top of the standard puppy, if you go to the /usr/bin foder, you will see both files.

After that convoluted explanation: the usr_devx.sfs contains the tools and libraries to compile linux applications.

It was separated that way to keep the standard puppy small while still allowing people that wanted to compile the ability to do it.

Posted: Thu 06 Oct 2005, 23:56
by wireframewolf
Ah. Thanks for the helpful explaination. Knowing that, I'm pretty excited about using this operating system. I really wanted something portable to go with my hard driveless Mini-itx that I could learn to program with OSS in. Of course, I still don't know if I'll be able to use OSS, but I reckon there's some way to do it.

Anyways, now I'm looking foward to using the OS. Thanks for all your help.

Posted: Mon 10 Oct 2005, 06:05
by Royce
This may be a dumb question, But why is it you can't just d/l the gcc build essentials from pupget? This way seems awfully round-about.

Posted: Mon 10 Oct 2005, 08:48
by MU
I extracted it to my harddrive, it is about one gigabyte, as it consists of many very small (header-)files that use the harddrive very ineffieciently.

So what is better: simply copy one file to the harddrive, or install a dotpup that uses 1 Gig?

Greets, Mark

Posted: Sat 15 Oct 2005, 06:20
by Perkins
Perhaps some enterprising soul could create a dotpup that would put that one file in the proper place... :P Not really worth the effort, but then you could say you had it.

Posted: Sat 15 Oct 2005, 10:07
by danleff
Perkins wrote:Perhaps some enterprising soul could create a dotpup that would put that one file in the proper place...
How would the dotpup know what type of install that you have and exactly what partition a type 1 installation was using?

I think we are mssing the point. This file has all the compile tools built into a filesystem structure. Just drop it where you need to and your ready to go. Look at it as a pupget or dotpup file that does not need to be installed.

Creating a dotpup file would be repeating work already done.

I just did this on my hard drive install and compiled Wine. It works very well. Drop the file in the appropriate place and your ready to go. No need to install anything.

Posted: Fri 25 Nov 2005, 23:23
by spiffytech
Where would my pupxxx file be in the LiveCD?

Posted: Sat 26 Nov 2005, 04:15
by rarsa
The pupxxx file is not in the LiveCD.

If your computer has a FAT32, ext2 or ext3 partition, the Live CD will create it there (unless you tell it not to create it).

If you have an Windows XP system with just an NTFS parition, you need to download the zip file and extract it to C:\pup001

Before you ask why can it be created from the LiveCD too: Puppy cannot write to the NTFS partition. It can only write to the pup001 file on the NTFS partition.

There sugestion floating in another post to have a windows tool on the liveCD to create it.

How big is usr_devx.sfs ?

Posted: Sat 26 Nov 2005, 14:58
by kethd
This is a Very Enlightening discussion -- but just how big is this one giant download I have to get somehow?

Re: How big is usr_devx.sfs ?

Posted: Sat 26 Nov 2005, 16:01
by Flash
kethd wrote:...just how big is this one giant download I have to get somehow?
Just over 44 MB. You'll find it here.

Posted: Thu 08 Dec 2005, 15:28
by kethd
See also:
http://puppylinux.org/wikka/ProgrammingLanguage
a growing list of all the languages potentially available in Puppy.

Posted: Wed 21 Dec 2005, 13:51
by shankargopal
And how would all this apply to the multisession CD? Sorry, not able to figure it out...

Posted: Wed 21 Dec 2005, 18:10
by rarsa
shankargopal wrote:And how would all this apply to the multisession CD? Sorry, not able to figure it out...
It has as much to do as the fact that the sky is blue.

This thread is about compiling applications under Puppy.

Puppy's installation/usage method is orthogonal to compiling under puppy. The only relation is that both are puppy topics.

Why did you try to 'apply' this thread to multisession?