[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Building RPM 4.00



Hi,

I have managed to build rpm 4.0 an interesting 8 hour tour.
I share my experience and observations her in the hope that
1) you can enlighten me what I have done wrong
2) if I failed to comply to 1 maybe it is helpfull to make
   installing rpm 4.0.x an effort less installation

Conclusion (for those who don't want the read the whole email).
The upgrade to 4.0 wasn't simple for me.

1) Catch 22 situation in order to install rpm4.0 you need rpm4.0
   Maybe it is possible to make a basic rpm4.0.rpm version
   created with rpm version 3.0
2) Big problem installing from tar (with hindsight) was the
   assumptions made by installing db packages.
	a) it need to be shared (gives you different versions of the
	   libs) Therefor in INSTALL the --enable-shared should be
	   include
	b) the different include file versions are assumed to
	   be in db$MAJOR_VERSION/db.h which isn't installed default so
	   that's something needs to be done by hand.
3) The (default) locations for de package database seems to be
   different. 


My system was an original redhat 5.2 system which has been
upgraded by rpm's and hand installs. the kernel I'm running is
2.2.17. This may also be a cause for confusion in this process.

First its a bit of a catch 22 situation if you download an
binairy version you get:
only packages with major numbers <= 3 are supported by this
version of RPM
error: /tmp/rpm-4.0-4.i386.rpm cannot be installed


So maybe if an rpm is needed one created by 3.x version is
necessay.

I than proceded  with rpm-4.0.tar.gz (from www.rpm.org).

The same problem as installing the binairy rpm-4.0.x is probably
true for the db-3.1.14*.rpm which is there to. I haven't downloaded
it but instead went to sleepycat.com and downloaded

db-3.1.17 (ofcourse I could see that 3.1.14 was used in rpm-4.0
so maybe this lead to problems anyway)

The only targets db-3.1.17 has are:
	PROGS=   db_archive db_checkpoint db_deadlock \
		db_dump db_load db_printlog db_recover db_stat db_upgrade
		db_verify

	libdb=      libdb.a	

The configure scripts tries to check in libdb, libdb-3.1, libdb-3.0
for db_create and dbopen

db_create
	Offcourse if will succeed for libdb with db_create. I failed
	to understand how libdb-3.1 and libdb-3.0 would get there and
	wonderd if they were necessary (I know in the development
	environment it was). Oooh, I just found out those are the shared
	libraries. Then INSTALL should contain the line 
	../dist/configure -enable_shared (got me wrong there)

dbopen
	dbopen seems to be only there if you #include <db_185.h>
	which does:
	#define dbopen  __db185_open
	DB *__db185_open __P((const char *, int, int, DBTYPE, const
	void *));
	Linking fails which means that db1.c will not be included.
	And db1.c refers to #include <db1/db.h> 
	And db2.c refers to #include <db2/db.h> 
	And db3.c refers to #include <db3/db.h> 
	which isn't created by installing db unless you do and make
	a link like ln -s /usr/include/db3/db.h /usr/include/db.h
	fall back to the old db libraries but the headers are out of
	sync if you do normal installion. And the synchronosation
	between the headerfile and library might be wrong there to.

Then in the end you have got the problem with db1basename()
but that has already been answered on deja by Jeff Johnson 
his suggestion is simple to move db1basename() to a file which
get included.

The only problem I'm faced with now is that I'm not able to
convert my old rpm database to the new one because 
a) they look in different places (easily solvable)
b) they look for differen things package.rpm versus Package.rpm
Any suggestions for those?

Thanks for reading so far.

René





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] []