LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices



Reply
 
Search this Thread
Old 12-19-2011, 06:50 PM   #1
dezavu
LQ Newbie
 
Registered: Jun 2011
Posts: 28

Rep: Reputation: Disabled
Create RPM from tarball.


Hi,

I have a tarball of powerbroker software but don't have SPEC file & need to create RPM form it.
It will be very helpful if someone help me for this.


Thanks & Regards.
Vijay
 
Old 12-19-2011, 09:48 PM   #2
jailbait
Guru
 
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Debian Wheezy, Debian Jessie
Posts: 7,590

Rep: Reputation: 188Reputation: 188
Is your tarball source code or executable code? If it is source code you can unpack the tarball and then compile it into a RPM package using checkinstall. You can get an explanation of how checkinstall works here:

http://asic-linux.com.mx/~izto/checkinstall/

-------------------
Steve Stites

Last edited by jailbait; 12-19-2011 at 09:49 PM.
 
Old 12-23-2011, 05:11 AM   #3
dezavu
LQ Newbie
 
Registered: Jun 2011
Posts: 28

Original Poster
Rep: Reputation: Disabled
Hi,
In our case the provided "tarball" doesn't have the source code. We have created the following SPEC file.
Quote:
[root@bourne ~]# cat /usr/src/redhat/SPECS/pb.spec
# Author Vijay Rane
Name: COF_Powerbroker
Version: 6.2.0
Release: 09%{?dist}
Summary: Powerbroker
Source: /usr/src/redhat/SOURCES/us_lin64_prod_client.tar.gz
License: Commercial
Group: System Environment/Base
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}

%description
This package is of Powerbroker-6.2.0 as per Company standard.

%prep
echo Building %{name}-%{version}-%{release}
%setup -q

%build

%install
sh install.sh

%files
%defattr(-,root,root,-)
%{_bindir}/%{name}
%{_libdir}/%{name}
%{_mandir}/%{name}
%{_htmldir}/%{name}


%clean
rm -rf $RPM_BUILD_ROOT

%changelog
*Wed Dec 21 2011 Vijay Rane <Vijay.Rane@xyz.com> 6.2
-Initial SPEC File
But using this SPEC file we are getting the following error:

Quote:
+ /usr/lib/rpm/brp-compress
/usr/lib/rpm/brp-compress: line 8: cd: /var/tmp/COF_Powerbroker-6.2.0-09: No such file or directory
+ /usr/lib/rpm/brp-strip
find: /var/tmp/COF_Powerbroker-6.2.0-09: No such file or directory
+ /usr/lib/rpm/brp-strip-static-archive
find: /var/tmp/COF_Powerbroker-6.2.0-09: No such file or directory
+ /usr/lib/rpm/brp-strip-comment-note
find: /var/tmp/COF_Powerbroker-6.2.0-09: No such file or directory
Processing files: COF_Powerbroker-6.2.0-09
error: File not found: /var/tmp/COF_Powerbroker-6.2.0-09/usr/bin/COF_Powerbroker
error: File not found: /var/tmp/COF_Powerbroker-6.2.0-09/usr/lib64/COF_Powerbroker
error: File not found: /var/tmp/COF_Powerbroker-6.2.0-09/usr/share/man/COF_Powerbroker
error: File must begin with "/": %{_htmldir}/COF_Powerbroker
Checking for unpackaged file(s): /usr/lib/rpm/check-files /var/tmp/COF_Powerbroker-6.2.0-09


RPM build errors:
File not found: /var/tmp/COF_Powerbroker-6.2.0-09/usr/bin/COF_Powerbroker
File not found: /var/tmp/COF_Powerbroker-6.2.0-09/usr/lib64/COF_Powerbroker
File not found: /var/tmp/COF_Powerbroker-6.2.0-09/usr/share/man/COF_Powerbroker
File must begin with "/": %{_htmldir}/COF_Powerbroker
The provided "tarball" has the following content;

dr-xr-xr-x 2 root root 4096 Sep 27 2010 bin
dr-xr-xr-x 3 root root 4096 Sep 27 2010 examples
dr-xr-xr-x 2 root root 4096 Sep 27 2010 html
dr-xr-xr-x 2 root root 4096 Sep 27 2010 install
-rwx------ 1 root root 93 Dec 22 09:41 install.sh
dr-xr-xr-x 2 root root 4096 Sep 27 2010 lib
dr-xr-xr-x 4 root root 4096 Sep 27 2010 man
-r--r--r-- 1 root root 11061 Sep 27 2010 MANIFEST
-rw-r----- 1 root root 1026 Dec 14 13:06 pb.key
-rw-r----- 1 root root 3657 Dec 14 13:10 pb.settings
dr-xr-xr-x 3 root root 4096 Sep 27 2010 thirdparty


Could you please help me, where I am getting wrong?

Thanks & Regards,
Vijay
 
  


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 tarball is better than rpm maxy7710 Linux - Newbie 8 04-29-2008 10:12 AM
can download tarball, but not RPM ylts Linux - Networking 11 04-15-2005 02:58 AM
I need RPM to tarball conversion mhelliwell Linux - General 3 03-18-2005 11:11 AM
how to create error log for tarball everythingand2 Linux - Newbie 1 11-22-2003 04:38 PM
create kernel RPM from tarball? randomx Linux - General 2 07-17-2003 12:01 AM


All times are GMT -5. The time now is 02:08 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