LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices



Reply
 
Search this Thread
Old 02-01-2012, 06:00 AM   #1
Konphine
Member
 
Registered: Jul 2011
Location: Phoenix, New York
Distribution: Slackware 13.37
Posts: 376

Rep: Reputation: 11
Compiling in RAM, Installing Forever?


Hello, and I apologize for my vague title.

Basically what I've done is I've been installing some files from source on Slackware because I am a bit shallow on hard drive space. It's because I'm using a 64GB SSD. I know the limited writes issue isn't too big of an issue anymore with modern SSD's, however I would still like to minimize the amount of writes I need to do.

Therefore, I have moved /tmp into my RAM disk as so:
Code:
/tmp         /tmp            tmpfs            size=1024m   0  0
I can successfully compile programs and not using up my SSD's writes by simply moving them to /tmp but installing them permanently to my computer is another situation.

Unfortunately my lack of knowledge and my 3 hours of Google search attempts fail me. So I come here as a last resort hoping somebody knows how to install packages to the computer itself. I'm confused as to how the .SlackBuild binaries create the .txz or .tgz files. I see the code:

Code:
/sbin/makepkg -l y -c n -p $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
So I"m assuming the makepkg does most of this for me, but my main concern is the code before the makepkg part as "makepkg" doesn't appear to work by itself.

The exception is flash player, I know I have to move libflashplayer.ko or whatever the file was called to the plugins section of my browser.
 
Old 02-01-2012, 06:18 AM   #2
Cedrik
Senior Member
 
Registered: Jul 2004
Distribution: Slackware
Posts: 2,140

Rep: Reputation: 242Reputation: 242Reputation: 242
To install a package, you use installpkg:
Code:
installpkg /path/to/<package name>
It seems so simple that I must miss something

[edit]
I don't understand your first comment..
You install software from source in hope that it saves some space ?

Last edited by Cedrik; 02-01-2012 at 06:22 AM.
 
Old 02-01-2012, 07:35 AM   #3
Konphine
Member
 
Registered: Jul 2011
Location: Phoenix, New York
Distribution: Slackware 13.37
Posts: 376

Original Poster
Rep: Reputation: 11
I know how to install a package. However, what I'm trying to do is compile programs in RAM and then install them permanently whereas if I did everything in RAM the program installs in the RAM and would be deleted on a reboot.

On the other hand, if I use the *.SlackBuild files, even in /tmp which is placed in RAM, they install perfectly fine and work even on reboots. I'm trying to mimic that exact same process but I struggle with the /sbin/makepkg part as it creates the .tgz or .txz files for us which can then be managed with pkgtools. I'd like to do that too, is to create the .txz or .tgz files after I compile, but so far I'm struggling with that even after 3 hours of Google searching.
 
Old 02-01-2012, 08:07 AM   #4
audriusk
Member
 
Registered: Mar 2011
Location: Klaipėda, Lithuania
Distribution: Slackware
Posts: 248

Rep: Reputation: 107Reputation: 107
Scripts from SlackBuilds.org untar and compile packages in /tmp by default (unless you override it). Since you have your /tmp mounted as tmpfs, the whole package building process is already happening in RAM and nothing is written to your SSD. When SlackBuild finishes, you can installpkg or upgradepkg your freshly built package.txz (which also resides in /tmp) and move it to some permanent place (e.g. your home directory) for later use.
 
Old 02-01-2012, 10:13 AM   #5
Richard Cranium
Senior Member
 
Registered: Apr 2009
Location: Carrollton, Texas
Distribution: Slackware64 14.1
Posts: 1,581

Rep: Reputation: 468Reputation: 468Reputation: 468Reputation: 468Reputation: 468
Quote:
Originally Posted by Konphine View Post
I know how to install a package. However, what I'm trying to do is compile programs in RAM and then install them permanently whereas if I did everything in RAM the program installs in the RAM and would be deleted on a reboot.

On the other hand, if I use the *.SlackBuild files, even in /tmp which is placed in RAM, they install perfectly fine and work even on reboots. I'm trying to mimic that exact same process but I struggle with the /sbin/makepkg part as it creates the .tgz or .txz files for us which can then be managed with pkgtools. I'd like to do that too, is to create the .txz or .tgz files after I compile, but so far I'm struggling with that even after 3 hours of Google searching.
Well, the SlackBuild scripts also move all the results of compiling/installing your soon-to-be package to a single directory tree so that makepkg can actually work. Depending upon the source that you are building, that can be rather difficult to get exactly correct.

Have you looked at src2pkg?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Why size of swap space is 2x of RAM??? Why not 1.5x of RAM or 2.5x of RAM??? Saurav Ghosh Linux - Newbie 7 11-01-2011 04:49 AM
What could cause segfaults while compiling, if the ram seems to be fine? Cultist Linux - General 6 07-23-2011 02:18 AM
Can compiling severely damage your RAM? piggysmile Linux - Hardware 4 06-14-2005 02:23 PM
installing to ram casimir DamnSmallLinux 6 02-03-2004 08:52 PM
Installing Ram jeempc Linux - Hardware 2 07-14-2003 10:32 PM


All times are GMT -5. The time now is 03:11 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration