Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 108978 - mdbtools : gnome dependance should be optional
Summary: mdbtools : gnome dependance should be optional
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: No maintainer - Look at https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers if you want to take care of it
URL:
Whiteboard:
Keywords:
: 118180 (view as bug list)
Depends on:
Blocks:
 
Reported: 2005-10-12 01:58 UTC by Frédéric COIFFIER
Modified: 2007-01-02 06:23 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
mdbtools-0.6_pre1.ebuild (mdbtools-0.6_pre1.ebuild,1.20 KB, text/plain)
2005-10-12 01:58 UTC, Frédéric COIFFIER
Details
mdbtools-0.6_pre1.ebuild.diff (mdbtools-0.6_pre1.ebuild.diff,599 bytes, patch)
2005-10-18 12:34 UTC, Cory Visi (RETIRED)
Details | Diff
mdbtools-0.6_pre1-gcc34.patch (mdbtools-0.6_pre1-gcc34.patch,1.53 KB, patch)
2005-10-18 12:40 UTC, Cory Visi (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Frédéric COIFFIER 2005-10-12 01:58:14 UTC
In the mdbtools-0.5.ebuild, there is the following dependance : 
        X? ( >=x11-libs/gtk+-2 
                >=gnome-base/libglade-2 
                >=gnome-base/libgnomeui-2 ) 
 
I think this dependeance should be replaced by this one : 
 
        gnome? ( >=x11-libs/gtk+-2 
                >=gnome-base/libglade-2 
                >=gnome-base/libgnomeui-2 ) 
 
Secondly, the version of mdbtools could be upgraded to the last 0.6_pre1 which 
is really usable. 

Reproducible: Always
Steps to Reproduce:
1.
2.
3.
Comment 1 Frédéric COIFFIER 2005-10-12 01:58:57 UTC
Created attachment 70445 [details]
mdbtools-0.6_pre1.ebuild
Comment 2 Cory Visi (RETIRED) gentoo-dev 2005-10-18 11:21:42 UTC
I looked into this dependency at length, and I agree with Fr
Comment 3 Cory Visi (RETIRED) gentoo-dev 2005-10-18 11:21:42 UTC
I looked into this dependency at length, and I agree with Frédéric about the USE
flags.  No question, X should be replaced with gnome in DEPEND.

mdbtools is primarily a library and a set of command line tools to manipulate
mdb files (MS Access).  It also comes with an "optional" GUI database browser
tool.  The tool not only depends on X and gtk, but it requires libglade and
gnomeui as well, which are clearly part of gnome-base.  The optional browser
tool is called "gmdb" or "gmdb2" and the configure script silently omits it from
the build if the libglade and gnomeui libraries are not found.  If you do have
libglade and gnomeui installed, it will build the gmdb binary regardless of
configure flags specified (in fact there is no configure flag to turn this
add-on on or off.)

This has been a problem in other packages and many times maintainers have
insisted on patching the autoconf files to add a configure option to hardware
the add-on component to the status of the USE flag.  In this case, I think the
relationship between the "gnome" USE flag and the gmbd tool is fairly loose. 
When people turn on "gnome" they expect to get extra user interface apps with
packages, and that is the way this ebuild has operated so far.  Therefore I do
not think we need to patch the autoconf files.  I'm interested to hear what
other people think too.

I will attach patches eventually, but first some related comments.
Comment 4 Cory Visi (RETIRED) gentoo-dev 2005-10-18 12:29:42 UTC
On a side note, I experienced a compile error with 0.5 that I cannot seem to
reproduce now.  It went away when I upgraded to 0.6pre1.  I wanted to add this
as encouragement to upgrade the version, but I won't open another bug.
Comment 5 Cory Visi (RETIRED) gentoo-dev 2005-10-18 12:34:05 UTC
Created attachment 70965 [details, diff]
mdbtools-0.6_pre1.ebuild.diff

To apply this patch:
cp mdbtools-0.5.ebuild mdbtools-0.6_pre1.ebuild
patch -p0 mdbtools-0.6_pre1.ebuild.diff

Changes:
- Upgrade version to 0.6pre1
- Change X use flag to gnome
- Removed gtk dependency because gnomeui and libglade depend on gtk already
- Made the compatibility symlink dependent on the gnome use flag
- Keyworded unstable on my two test archs
Comment 6 Cory Visi (RETIRED) gentoo-dev 2005-10-18 12:40:37 UTC
Created attachment 70966 [details, diff]
mdbtools-0.6_pre1-gcc34.patch

Changes:
- Updated patch to apply cleanly to 0.6pre1.

Basically, aside from the code shifting around a bit, I removed the C99/gcc 3.4
fix for the CASE statement, because it's now fixed elegantly in the code with a
proper default { break; } clause.
Comment 7 Igor Korot 2005-10-30 20:47:48 UTC
I would suggest to ad a USE flag, such as "gui" in order to build or not to 
build the gmdb (or gmdb2) - GUI part of the project. Some people don't mind 
working from the command line, and some hates it. ;-)
Comment 8 Carsten Lohrke (RETIRED) gentoo-dev 2005-11-14 15:18:53 UTC
*** Bug 112552 has been marked as a duplicate of this bug. ***
Comment 9 Mathias Kegelmann 2006-01-07 07:35:59 UTC
*** Bug 118180 has been marked as a duplicate of this bug. ***
Comment 10 Cory Visi (RETIRED) gentoo-dev 2006-05-24 16:40:46 UTC
I committed the new version to CVS.  Please test!
Comment 11 Gergan Penkov 2006-05-27 07:36:55 UTC
It fails to compile with gcc-4, the problem is :
 i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../include -I../../include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -march=athlon-xp -O2 -pipe -DSQL -DUNIXODBC -MT backend.lo -MD -MP -MF .deps/backend.Tpo -c backend.c  -fPIC -DPIC -o .libs/backend.o
backend.c:31: error: static declaration of 'mdb_backends' follows non-static declaration
../../include/mdbtools.h:150: error: previous declaration of 'mdb_backends' was here
make[2]: *** [backend.lo] Error 1
make[2]: Leaving directory `/var/tmp/portage/mdbtools-0.6_pre1/work/mdbtools-0.6pre1/src/libmdb'

which seems to be corrected in cvs long time ago (removing the static qualifier), this 0.6_pre1 version is 2 years old, please consider adding ebuild fo some more recent cvs-snapshot (probably even reusing the debian snapshot).
Comment 12 Cory Visi (RETIRED) gentoo-dev 2006-05-30 14:36:56 UTC
Any particular snapshot dates you recommend that are more recent than Debian's patch?
Comment 13 Gergan Penkov 2006-05-30 15:02:30 UTC
well I thought of mdbtools_0.5.99.0.6pre1.0.20051109.orig.tar.gz although I haven't tested it, but reading the comments in the debian diff and looking at the cvs it seems that gcc4 problem was fixed upstream.
On the other hand halcy0n has already commited a gcc4 patch (upstream change is http://mdbtools.cvs.sourceforge.net/mdbtools/mdbtools/src/libmdb/backend.c?r1=1.23&r2=1.24 in the backend.c not in the includes), but the compilation dies on another place now:
/bin/sh ../../libtool --mode=link i686-pc-linux-gnu-gcc  -march=athlon-xp -O2 -pipe -DSQL -DUNIXODBC  -Wl,-O1 -Wl,--as-needed -o unittest  unittest.o libmdbodbc.la ../libmdb/libmdb.la ../sql/libmdbsql.la -lfl -lglib-2.0   -L/usr/lib -lodbcinst
i686-pc-linux-gnu-gcc -march=athlon-xp -O2 -pipe -DSQL -DUNIXODBC -Wl,-O1 -Wl,--as-needed -o .libs/unittest unittest.o  ./.libs/libmdbodbc -L/usr/lib ../libmdb/.libs/libmdb -lm ../sql/.libs/libmdbsql -lfl -lglib-2.0 -lodbcinst
./.libs/libmdbodbc: undefined reference to `ceil'
./.libs/libmdbodbc: undefined reference to `log10'
collect2: ld returned 1 exit status
make[2]: *** [unittest] Error 1
but this could be simply because of the --as-needed, so nothing bad :)
Comment 14 Frédéric COIFFIER 2006-05-31 14:23:40 UTC
In my case, the mdbtools-0.6_pre1.ebuild which is currently in portage compiles fine with gcc-4.1.1 (without odbc and gnome).
Comment 15 Igor Korot 2006-05-31 21:33:25 UTC
Did you compiled it with the GUI?
Comment 16 Frédéric COIFFIER 2006-06-12 04:38:46 UTC
(In reply to comment #14)
> Did you compiled it with the GUI?
> 

No : I haven't tried with the 'gnome' USE flags (Gnome isn't installed on my PC)
Comment 17 Charlie Shepherd (RETIRED) gentoo-dev 2007-01-02 06:23:08 UTC
Afaict, this bug is fixed.