rpmbuild -ta syslog-ng aborts when can't find some file it is looking for, or, 'what's a .sysconfig'?

Hey folks,

Using ES3.

Since redhat, in it's infinite wisdom, only supports legacy syslog, I'm trying to roll-my-own syslog-ng.
Was doing alright until:

cd rpm/SOURCES
rpmbuild -ta syslog-ng-1.6.5.tar.gz


make[1]: Leaving directory `/home/blow/rpm/BUILD/syslog-ng-1.6.5'
+ install -m644 /home/blow/rpm/SOURCES/syslog-ng.conf
install: cannot stat `/home/blow/rpm/SOURCES/syslog-ng.conf': No such
file or directory error: Bad exit status from
/home/blow/rpm/tmp/rpm-tmp.38571 (%install)

## ok, cp over /etc/syslog-ng.conf from old machine, or could use

scp netmon:/etc/syslog-ng/syslog-ng.conf ~/rpm/SOURCES
rpmbuild -ta syslog-ng-1.6.5.tar.gz


make[1]: Leaving directory `/home/blow/rpm/BUILD/syslog-ng-1.6.5'
+ install -m644 /home/blow/rpm/SOURCES/syslog-ng.conf
/home/blow/rpm/tmp/syslog-ng-buildroot/etc/syslog-ng/syslog-ng.conf +
install -m755 /home/blow/rpm/SOURCES/syslog-ng.init
install: cannot stat `/home/blow/rpm/SOURCES/syslog-ng.init': No such
file or directory error: Bad exit status from
/home/blow/rpm/tmp/rpm-tmp.83428 (%install)


ok, untar the tar and mv contrib/init.d.Redhat to

rpmbuild -ta syslog-ng-1.6.5.tar.gz


+ install -m644 /home/blow/rpm/SOURCES/syslog-ng.conf
/home/blow/rpm/tmp/syslog-ng-buildroot/etc/syslog-ng/syslog-ng.conf +
install -m755 /home/blow/rpm/SOURCES/syslog-ng.init
/home/blow/rpm/tmp/syslog-ng-buildroot/etc/rc.d/init.d/syslog-ng +
install -m700 /home/blow/rpm/SOURCES/mysql-syslog.pipe
install: cannot stat `/home/blow/rpm/SOURCES/mysql-syslog.pipe': No
such file or directory error: Bad exit status from
/home/blow/rpm/tmp/rpm-tmp.30612 (%install)


touch ~/rpm/SOURCES/mysql-syslog.pipe
<and also ~/rpm/SOURCES/mysql-syslog.buffer>
rpmbuild -ta syslog-ng-1.6.5.tar.gz

+ install -m700 /home/blow/rpm/SOURCES/syslog-ng.sysconfig
/home/blow/rpm/tmp/syslog-ng-buildroot/etc/sysconfig/syslog-ng install:
cannot stat `/home/blow/rpm/SOURCES/syslog-ng.sysconfig': No such file
or directory error: Bad exit status from
/home/blow/rpm/tmp/rpm-tmp.78368 (%install)

OK, wtf do I do now?  what's a syslog-ng.sysconfig?  no reference anywhere.
Googling gives three obscure entries from years ago that have to do
with patches (presumably long since incorporated).  Where's the RTFM that
talks about .sysconfig?

Pardon my frustration, and thanks in advance.

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

It looks to me like the specfile for an ordinary build is basically broken. But you can work around that, like:

cp libol-0.3.14.tar.gz /usr/src/redhat/SOURCES
cp syslog-ng-1.6.5.tar.gz /usr/src/redhat/SOURCES
cd /usr/src/redhat
rpmbuild -ta SOURCES/libol-0.3.14.tar.gz
rpm -i RPMS/i386/libol-0.3.14-1.i386.rpm RPMS/i386/libol-devel-0.3.14-1.i386.rpm
rpmbuild -ta SOURCES/syslog-ng-1.6.5.tar.gz

The last build will fail so you do:

cp BUILD/syslog-ng-1.6.5/contrib/init.d.RedHat-7.3 SOURCES/syslog-ng.init
cp BUILD/syslog-ng-1.6.5/contrib/syslog-ng.conf.RedHat SOURCES/syslog-ng.conf
cat >SOURCES/syslog-ng.sysconfig <<EOF
touch SOURCES/mysql-syslog.pipe
touch SOURCES/mysql-syslog.buffer

and finally:

rpmbuild -ta SOURCES/syslog-ng-1.6.5.tar.gz

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial

   How about
# rpm -ta syslog-ng-1.6.5.tar.gz
and then
# rpm -ivh /usr/src/redhat/RPMS/i386/syslog-ng-1.6.5*.rpm

amlpAuthor Commented:

Ok, that's kinda what I was leaning towards, just making a file named syslog-ng.sysconfig with nothing in it, just like I did with the mysql-pipe and mysql-buffer (which I happen to know are just placeholders (sockets?).

Poking around, it looks like the packagename.sysconfig is the file that goes in redhat's /etc/sysconfig.   It looks like these files hold the commandline options for any deamons the 'package' starts.  Since there aren't any for syslog-ng, keeping it empty should be ok.  I guess.

But to fix the package, should it be done some kinda way in syslog-ng.spec?  or included in the .tar.gz?  Side gripe:  why isn't this explicitly documented somewhere /side gripe.

It looks to me like the spec file is just included for those that want to make an SRPM for a particular distro. The way it is written it presumes that the necessary files are present in the SOURCES dir and they do get included in the SRPM that gets built. Once the SRPM is built future rebuilds can use that rather than the source tarball,
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.