Warren Young a écrit :
> Actually, I think you've got it, even if you don't know it. rebake
> really isn't for direct use on systems where we use autoconf, since
> regenerating Makefile.in isn't sufficient. On those systems, you should
> use bootstrap instead, since that runs through all the autoconf stuff in
> addition to the Bakefile stuff.
I know i missed something really simple ;)
>
> I tried adding your changes, and it seems to work here, even with
> Bakefile 0.2.0. Here are some lines from the end of the library link step:
>
> g++ -shared -fPIC -o libmysqlpp.so.2.2.1 mysqlpp_coldata.o
> mysqlpp_connection.o mysqlpp_datetime.o mysqlpp_field_names.o
> mysqlpp_fields.o mysqlpp_field_types.o mysqlpp_manip.o mysqlpp_myset.o
> mysqlpp_mysql++.o mysqlpp_qparms.o mysqlpp_query.o mysqlpp_result.o
> mysqlpp_row.o mysqlpp_sql_string.o mysqlpp_string_util.o
> mysqlpp_transaction.o mysqlpp_type_info.o mysqlpp_vallist.o
> -Wl,-soname,libmysqlpp.so.2 -lmysqlclient -lz
> (cd .; rm -f libmysqlpp.so libmysqlpp.so.2; ln -s libmysqlpp.so.2.2.1
> libmysqlpp.so.2; ln -s libmysqlpp.so.2 libmysqlpp.so)
Great !
>
> We'll also need some changes to the RPM spec file. Patches thoughtfully
> considered.
>
You only have to change
%files
%{_libdir}/libmysqlpp.so.*
...
%files devel
%{_libdir}/libmysqlpp.so
Works very well.
- Install mysql++ and mysql++-devel
- Build the "examples" : OK
- Run the "examples" : OK
- Remove mysql++-devel
- Run the "examples" : OK
Here is my full specfile (use for the Fedora Extras submission, and
probably for EPEL soon, EPEL = Extras for Enterprise Linux =
Redhat/CentOS) :
http://remi.collet.free.fr/rpms/extras/mysql++.spec
Note that the soname patch require "bakefile-0.2.0" which is not
available in the repository, that's why i put conditional "rebake".
I don't really want to push bakefile to Extras (as i don't know much
about it and it need a lot of work), and if someone do it, it will push
the latest 0.2.2 (do think to upgrade to this version for mysql++ ?).
Regards.