LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 02-27-2006, 02:39 PM   #1
Hungry ghost
Senior Member
 
Registered: Dec 2004
Posts: 1,222

Rep: Reputation: 667Reputation: 667Reputation: 667Reputation: 667Reputation: 667Reputation: 667
Need help building my own rpm


Hi all. I recently downloaded gyachi which is an improved version of gyach-enhanced. I compiled it without problems after installing the required libraries and installed it. Now I'm playing with the idea of making a rpm file with the source, but I have some problems: I made a rudimentary .spec file following some howto's I've seen on internet, but after I run 'rpmbuild -ba gyachi-20060208.spec' from inside the SPECS directory I can see it's extracting the package, running the configure shell script and running 'make', but after that, it just builds a .src.rpm package, not the binary package which is what I'm really looking for.

Here's how my .spec file looks:

Code:
Summary: A yahoo! client
Name: gyachi
Version: 20060208b
Release: 0
Group: Applications/Internet
License: GPL
Source0: %{name}-%{version}.tar.gz

%description
GyachI is an improved version of GyachE, a feature-rich client for the yahoo instant messaging protocol.

%prep
%setup -q

%build
%configure
make

%makeinstall
Any help on building the binary package is greatly appreciated.
As a side note, I have no experience in programming.

Thanks in advance.
 
Old 02-27-2006, 04:36 PM   #2
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian stable
Posts: 5,908

Rep: Reputation: 356Reputation: 356Reputation: 356Reputation: 356
The -ba switch to rpmpuild is *supposed* to build both .src.rpm and .rpm. It's possible that your rpmbuild has a bug. Try rpmbuild -bb (to build only a binary .rpm).

For all you could ever want to know about rpm, go to the Red Hat website. Somewhere under Documentation, you will find THE book on rpm - Maximum RPM. You can read it on-line, or download it. Chapter 13 deals with writing .spec files.
 
Old 02-27-2006, 05:48 PM   #3
Hungry ghost
Senior Member
 
Registered: Dec 2004
Posts: 1,222

Original Poster
Rep: Reputation: 667Reputation: 667Reputation: 667Reputation: 667Reputation: 667Reputation: 667
No go, when I run 'rpmbuild -bb gyachi-20060208.spec' it seems to run the configure script but not 'make', since I get the following results:

Code:
(...)configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands
+ make
Making all in client
make[1]: Entering directory `/home/vicente/rpmbuild/BUILD/gyachi-20060208/client'
make  all-am
make[2]: Entering directory `/home/vicente/rpmbuild/BUILD/gyachi-20060208/client'
make[2]: Leaving directory `/home/vicente/rpmbuild/BUILD/gyachi-20060208/client'
make[1]: Leaving directory `/home/vicente/rpmbuild/BUILD/gyachi-20060208/client'
Making all in webcam
make[1]: Entering directory `/home/vicente/rpmbuild/BUILD/gyachi-20060208/webcam'
make  all-am
make[2]: Entering directory `/home/vicente/rpmbuild/BUILD/gyachi-20060208/webcam'
make[2]: Leaving directory `/home/vicente/rpmbuild/BUILD/gyachi-20060208/webcam'
make[1]: Leaving directory `/home/vicente/rpmbuild/BUILD/gyachi-20060208/webcam'
make[1]: Entering directory `/home/vicente/rpmbuild/BUILD/gyachi-20060208'
make[1]: Nothing to be done for `all-am'.
make[1]: Leaving directory `/home/vicente/rpmbuild/BUILD/gyachi-20060208'
+ exit 0
Checking for unpackaged file(s): /usr/lib/rpm/check-files %{buildroot}
[vicente@dyn-1043 SPECS]$
This is really weird since I can compile it cleanly manually and with 'rpmbuild -ba'.
Well, I'll get the Maximum RPM book and study it hard to see if I find my way around this issue

Thanks for your help.
 
Old 02-27-2006, 07:35 PM   #4
MasterC
LQ Guru
 
Registered: Mar 2002
Location: Salt Lake City, UT - USA
Distribution: Gentoo ; LFS ; Kubuntu ; CentOS ; Raspbian
Posts: 12,613

Rep: Reputation: 69
Not to stray too far, but...

I use checkinstall. It creates an RPM for me, I don't use SPEC or SRC.RPM instead I use the real source, compile it my way, and then instead of running make install, I run checkinstall and it creates an RPM for me.

Cool
 
Old 02-27-2006, 09:30 PM   #5
Hungry ghost
Senior Member
 
Registered: Dec 2004
Posts: 1,222

Original Poster
Rep: Reputation: 667Reputation: 667Reputation: 667Reputation: 667Reputation: 667Reputation: 667
Cool! I had no knowledge of this program, but now I've seen something weird: I created the .rpm file with checkinstall, then opened it with file-roller, I can see a directory to be extracted in '/' containing two subdirectories: 'usr' (containing 'local/share/gyachi') and -here comes the weird part- a 'selinux' directory, which contains a 'context' file (a binary file). To explain myself further I'll make a graphic explanation on the contents of the package:

______selinux/context
/----______usr/local/share/gyachi

So, my question is, why a messaging app should write something in the /selinux directory during the installation? It sounds like some sort of virus to me (or some trojan perhaps?). After I noticed this, I issued the command 'ls -la /selinux', and this is what I got:

Code:
[vicente@dyn-1043 ~]$ ls -la /selinux
total 8
drwxr-xr-x   1 root root    0 feb 27 03:30 .
drwxr-xr-x  23 root root 4096 feb 27 07:30 ..
-rw-rw-rw-   1 root root    0 feb 27 03:30 access
dr-xr-xr-x   1 root root    0 feb 27 03:30 avc
dr-xr-xr-x   1 root root    0 feb 27 03:30 booleans
-rw-r--r--   1 root root    0 feb 27 03:30 checkreqprot
--w-------   1 root root    0 feb 27 03:30 commit_pending_bools
-rw-rw-rw-   1 root root    0 feb 27 03:30 context
-rw-rw-rw-   1 root root    0 feb 27 03:30 create
--w-------   1 root root    0 feb 27 03:30 disable
-rw-r--r--   1 root root    0 feb 27 03:30 enforce
-rw-------   1 root root    0 feb 27 03:30 load
-rw-rw-rw-   1 root root    0 feb 27 03:30 member
-r--r--r--   1 root root    0 feb 27 03:30 mls
crw-rw-rw-   1 root root 1, 3 feb 27 03:30 null
-r--r--r--   1 root root    0 feb 27 03:30 policyvers
-rw-rw-rw-   1 root root    0 feb 27 03:30 relabel
-rw-rw-rw-   1 root root    0 feb 27 03:30 user
[vicente@dyn-1043 ~]$
As you can see, all the contents of the selinux directory seem to have been created today (I reinstalled gyachi today from the source).
As a side note, I downloaded the program from http://gyachi.sourceforge.net/

So what do you think?? And what should I do now??

Edit: Should I open a new topic in the Security forum??

Last edited by Hungry ghost; 02-27-2006 at 09:36 PM.
 
  


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
Building RPM via src.Rpm ivanatora Linux - Newbie 2 02-20-2006 04:29 PM
regarding building RPM hinetvenkat Linux - Networking 2 08-29-2005 08:42 AM
need help building rpm Hockeyfan Linux - Software 3 11-20-2004 05:15 AM
building rpm nearfar Linux - Newbie 1 12-29-2003 09:21 PM
building rpm saleem Programming 1 11-12-2001 05:42 AM

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

All times are GMT -5. The time now is 05:00 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
Open Source Consulting | Domain Registration