The How-To Geek Forums Have Migrated to Discourse

How-To Geek Forums / Linux

how to make rpm from .tar.gz files

(3 posts)
  • Started 8 years ago by deadend
  • Latest reply from jake
  • Topic Viewed 10381 times


Recommended: Clean Your Mac the Easy Way with CleanMyMac 3

If you want to clean up your Mac the easy way, CleanMyMac is a great tool to get the job done easily, and it will even keep your computer clean automatically.

Unlike the competition, it also includes great tools like a Clean Uninstaller, to get rid of applications and clean up the junk that they leave behind. All with the click of a button.

Download CleanMyMac 3 for Free Today

Posted yesterday 
Posts: 1

hello everyone....

can anyone tells me how can i make a rpms for my redhat linux. today i download one software, but this is in .tar.gz form. i don't how to make rpm form .tar.gz file....

can anyone teach me .....

thanks in advance

Posted 8 years ago
Posts: 40

It doesn't work like that. RPMs are precompiled programs for your architecture. .tar.gz is source code that you personally need to compile. run the following commands in the commandline (in the folder where your tarball (technical term for .tar.gz files) is):

(you may want to run this as root)

tar -xvzf <your tar file>
cd <directory created by tar extraction>
make install

that should install it, assuming you aren't missing any dependencies. It'll tell you when you ./configure.

Posted 8 years ago
Posts: 11

There is also a possibility that that file is a Slackware package, though those are more commonly .tgz rather than .tar.gz. It depends where you got it from. If it *is* a Slackware file, you can use the Alien program and run the following command to make an rpm: (or sudo if you don't have fakeroot)

fakeroot alien -r name.tar.gz

However, keep in mind that you rarely need to do this as you can find tons of sites filled with RPMs out there, such as RPM Find.

Posted 8 years ago

Topic Closed

This topic has been closed to new replies.