dbTalk Databases Forums  

Packaging improvement - Devhelp integration.

mailing.database.mysql-plusplus mailing.database.mysql-plusplus


Discuss Packaging improvement - Devhelp integration. in the mailing.database.mysql-plusplus forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Remi Collet
 
Posts: n/a

Default Packaging improvement - Devhelp integration. - 03-01-2008 , 04:07 AM






--------------070404090004040301070109
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Hi,

I've made some new packaging improvements to have 'minimal' devhelp
integration for MySQL++ manuals.

Info : Devhelp is the API document browser for GNOME 2.
(it use gecko for HTML rendering).

A screenshot :
http://rpms.famillecollet.com/files/devhelp.png

mysql++.devhelp file and spec.patch attached.

It just a "first" work.

I think having a tree (left panel) with classes or members will be great
but this require docbook/xsl/xsltproc skills that i miss...

Feedbacks about this is welcome

Remi


Spec changes (extracts from the diff)

=== For Sources
+Source1: mysql++.devhelp

=== For Requires & Description
%package manuals
+Requires: devhelp

%description manuals
+User Manual and Reference Manual are provided both in PDF and in
+HTML format. You can use devhelp to browse it.
+

=== For %install
+# DevHelp stuff
+%{__mkdir_p} %{buildroot}%{_datadir}/devhelp/books/%{name}
+%{__install} -m644 %{SOURCE1}
%{buildroot}%{_datadir}/devhelp/books/%{name}/%{name}.devhelp
+%{__cp} -r doc/html/userman
%{buildroot}%{_datadir}/devhelp/books/%{name}/userman
+%{__cp} -r doc/html/refman
%{buildroot}%{_datadir}/devhelp/books/%{name}/refman
+

=== For %files
%files manuals
%defattr(-,root,root,-)
-%doc doc/pdf doc/html doc/README-manuals-RPM.txt
+%doc doc/pdf/* doc/README-manuals-RPM.txt
+%{_datadir}/devhelp/books/%{name}

--------------070404090004040301070109
Content-Type: text/xml;
name="mysql++.devhelp"
Content-Transfer-Encoding: 8bit
Content-Disposition: inline;
filename="mysql++.devhelp"

<?xml version="1.0"?>
<book xmlns:fo="http://www.w3.org/1999/XSL/Format"
title="MySQL++: C++ wrapper for MySQL’s C API"
name="mysql++"
link="userman/index.html">
<chapters>
<sub name="User Manual" link="userman/index.html"/>
<sub name="Reference Manual" link="refman/index.html"/>
</chapters>
</book>


--------------070404090004040301070109
Content-Type: text/x-patch;
name="spec.patch"
Content-Transfer-Encoding: 8bit
Content-Disposition: inline;
filename="spec.patch"

--- mysql++.spec 2008-02-28 21:34:56.000000000 +0100
+++ /home/extras/SPECS/extras/mysql++.spec 2008-03-01 10:42:54.000000000 +0100
@@ -1,23 +1,26 @@
Summary: C++ wrapper for the MySQL C API
Name: mysql++
Version: 3.0.0
-Release: 0.1.rc5%{?dist}
+Release: 1%{?dist}
License: LGPLv2
Group: Development/Libraries
URL: http://tangentsoft.net/mysql++/
-#Source0: http://tangentsoft.net/mysql++/releases/mysql++-%{version}.tar.gz
-Source0: http://tangentsoft.net/mysql++/test/...0.0-rc5.tar.gz
-
-Patch0: mysql++3rc5-gcc43.patch
+Source0: http://tangentsoft.net/mysql++/releases/mysql++-%{version}.tar.gz
+Source1: mysql++.devhelp

BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
BuildRequires: mysql-devel

%description
-MySQL++ makes working with MySQL server queries as easy as working
-with STL containers. This package contains only the libraries needed to
-run MySQL++-based programs. If you are building your own MySQL++-based
-programs, you also need to install the -devel package.
+MySQL++ is a C++ wrapper for MySQL’s C API.
+
+It is built around STL principles, to make dealing with the database as easy
+as dealing with an STL container. MySQL++ relieves the programmer of dealing
+with cumbersome C data structures, generation of repetitive SQL statements,
+and manual creation of C++ data structures to mirror the database schema.
+
+If you are building your own MySQL++-based programs, you also need
+to install the -devel package.

%package devel
Summary: MySQL++ developer files (headers, examples, etc.)
@@ -26,23 +29,28 @@
Requires: mysql-devel

%description devel
-These are the files needed to compile MySQL++ based programs, plus
-some sample code to get you started. If you aren't building your own
-programs, you probably don't need to install this package.
+These are the files needed to compile MySQL++ based programs,
+plus some sample code to get you started.You probably need to
+install the -manuals package.
+
+If you aren't building your own programs, you probably don't need
+to install this package.

%package manuals
Summary: MySQL++ user and reference manuals
Group: Development/Libraries
+Requires: devhelp

%description manuals
This is the MySQL++ documentation. It's a separate RPM just because
it's so large, and it doesn't change with every release.

+User Manual and Reference Manual are provided both in PDF and in
+HTML format. You can use devhelp to browse it.
+
%prep
%setup -q

-%patch0 -p0 -b .gcc43
-
%build
%configure --with-mysql-lib=%{_libdir}/mysql \
--enable-thread-check \
@@ -73,6 +81,12 @@
-e '/^all:/s/test_[a-z,_]* //g' \
Makefile.simple > doc/examples/Makefile

+# DevHelp stuff
+%{__mkdir_p} %{buildroot}%{_datadir}/devhelp/books/%{name}
+%{__install} -m644 %{SOURCE1} %{buildroot}%{_datadir}/devhelp/books/%{name}/%{name}.devhelp
+%{__cp} -r doc/html/userman %{buildroot}%{_datadir}/devhelp/books/%{name}/userman
+%{__cp} -r doc/html/refman %{buildroot}%{_datadir}/devhelp/books/%{name}/refman
+
%clean
rm -rf %{buildroot} doc/examples

@@ -93,9 +107,14 @@

%files manuals
%defattr(-,root,root,-)
-%doc doc/pdf doc/html doc/README-manuals-RPM.txt
+%doc doc/pdf/* doc/README-manuals-RPM.txt
+%{_datadir}/devhelp/books/%{name}

%changelog
+* Sat Mar 1 2008 Remi Collet <rpms (AT) FamilleCollet (DOT) com> 3.0.0-1
+- update to 3.0.0 Finale
+- use devhelp to browse manuals
+
* Wed Feb 20 2008 Remi Collet <rpms (AT) FamilleCollet (DOT) com> 3.0.0-0.1.rc5
- update to 3.0.0 rc5



--------------070404090004040301070109
Content-Type: text/plain; charset=us-ascii


--
MySQL++ Mailing List
For list archives: http://lists.mysql.com/plusplus
To unsubscribe: http://lists.mysql.com/plusplus?unsu...ie.nctu.edu.tw
--------------070404090004040301070109--

Reply With Quote
  #2  
Old   
Warren Young
 
Posts: n/a

Default Re: Packaging improvement - Devhelp integration. - 03-03-2008 , 09:06 PM






Remi Collet wrote:
Quote:
It just a "first" work.
I can't really help you much with this because, while I do primarily use
MySQL++ on Linux, it's always via ssh. I rarely see a GNOME screen,
much less work in one.

Because I'm not likely to help you iterate this into an acceptable
shape, I'd rather see this in a more complete form before accepting it.

Quote:
I think having a tree (left panel) with classes or members will be great
but this require docbook/xsl/xsltproc skills that i miss...
I can answer the DocBook questions or direct you to good sources, if you
can formulate them. If you don't even know what questions to ask, well,
see above.

Quote:
=== For %install
+# DevHelp stuff
+%{__mkdir_p} %{buildroot}%{_datadir}/devhelp/books/%{name}
+%{__install} -m644 %{SOURCE1}
%{buildroot}%{_datadir}/devhelp/books/%{name}/%{name}.devhelp
+%{__cp} -r doc/html/userman
%{buildroot}%{_datadir}/devhelp/books/%{name}/userman
+%{__cp} -r doc/html/refman
%{buildroot}%{_datadir}/devhelp/books/%{name}/refman
+

=== For %files
%files manuals
%defattr(-,root,root,-)
-%doc doc/pdf doc/html doc/README-manuals-RPM.txt
+%doc doc/pdf/* doc/README-manuals-RPM.txt
+%{_datadir}/devhelp/books/%{name}
I'd rather the HTML be available at its current location in addition to
the devhelp path. You can do this with a symlink. It doesn't greatly
matter to me whether the HTML actually lives under the regular doc dir
or under the devhelp dir, but given a choice, I'd keep it where it is
now and make the devhelp location the symlink.

--
MySQL++ Mailing List
For list archives: http://lists.mysql.com/plusplus
To unsubscribe: http://lists.mysql.com/plusplus?unsu...ie.nctu.edu.tw



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.