LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
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 05-07-2018, 08:43 AM   #1
cold.eye
LQ Newbie
 
Registered: May 2018
Posts: 2

Rep: Reputation: Disabled
Building RPM from from tar.gz with install script.


Dear All

I would like to ask you for some hint\advise.
I have a tar.gz package which contains install script and some binary.
Code:
[server1 ~ ]# tar -tvf package.tar.gz
drwxr-xr-x root/root         0 2018-05-07 15:05 package/
-rw-r--r-- root/root        14 2018-05-07 15:07 package/exec
-rw-r--r-- root/root         5 2018-05-07 15:07 package/install
install script moves exec binary to /bin directory and config some stuff for it.

Now i need to build it in RPM. I can create RPM with install and exec files. After installing RPM files are placed in /var/tmp/package/ directory. In post script I can run /var/tmp/package/install.
I do not need /var/tmp/package/install file and /var/tmp/package/ directory so i can remove them in post script.
I know that final /bin/exec file is not recognized as part of any RPM however i cannot skip install script and just copy exec file directly to /bin directory.

And now the question: How to deal with following warning during RPM uninstallation:
Quote:
warning: file /var/tmp/package/exec: remove failed: No such file or directory
warning: file /var/tmp/package/install: remove failed: No such file or directory
I thought about creating empty files before uninstallation however i do not think that's a good idea.
How would you solve this issue?
Is there any better way to build rpm and keep install script?

Regards
 
Old 05-07-2018, 07:33 PM   #2
AwesomeMachine
LQ Guru
 
Registered: Jan 2005
Location: USA and Italy
Distribution: Debian testing/sid; OpenSuSE; Fedora; Mint
Posts: 5,524

Rep: Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015
Hi cold.eye,

Welcome!

Let me get this straight. You are trying to make a rpm file. https://access.redhat.com/sites/defa...ding_howto.pdf
 
Old 05-08-2018, 03:04 AM   #3
cold.eye
LQ Newbie
 
Registered: May 2018
Posts: 2

Original Poster
Rep: Reputation: Disabled
Hi

Thanks for answer. I know this document. I also read about building RPMs on following sites:
https://access.redhat.com/documentat...ng_guide/index
https://fedoraproject.org/wiki/How_t...25prep_section
https://docs-old.fedoraproject.org/e...ide/index.html
https://access.redhat.com/sites/defa...e_10082013.pdf
.. and some other sites.
But my situation i a little bit more tricky and i couldn't find any help on those site.

Kind regards.
 
Old 05-08-2018, 08:25 AM   #4
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
Quote:
Originally Posted by cold.eye View Post
How to deal with following warning during RPM uninstallation:
Code:
warning: file /var/tmp/package/exec: remove failed: No such file or directory
warning: file /var/tmp/package/install: remove failed: No such file or directory
Non-fatal, warning. Ignore it.

Props on the DOCs
 
  


Reply



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
How to build an rpm which runs a automatic script from the tar which installs everything. johnjones Linux - Newbie 1 05-18-2016 11:49 AM
Require help for building rpm from .src.rpm during uncompressing tar.xz file Santoshkb Linux - General 4 09-16-2013 02:15 AM
RPM and tar install frankjg Linux - General 6 07-29-2007 01:25 PM
How do i install a program (rpm or tar.gz) scripts Linux - Newbie 15 12-26-2004 04:25 AM
Building RPM files from TAR files parle Linux - Software 3 05-05-2002 11:02 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:02 PM.

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
Open Source Consulting | Domain Registration