[clam-devel] Network compilation problem
David García Garzón
david.garcia at upf.edu
Thu Apr 29 14:34:53 PDT 2010
A Dijous 29 Abril 2010 23:04:15, SAn va escriure:
> On Tue, Apr 27, 2010 at 06:09, David García Garzón <david.garcia at upf.edu>
wrote:
> > A Divendres 23 Abril 2010 20:11:00, SAn va escriure:
> >> On Fri, Apr 23, 2010 at 09:47, David García Garzón
> >>
> >> <david.garcia at barcelonamedia.org> wrote:
> >> > Adding that to SHCXXFLAGS has sense, adding to CPPPATH would be
even
> >> > nicer, although, as you say, maybe there is a better way based on
> >> > pkg-config, and/or patching qt4.py to work well without this.
> >> >
> >> > But QT4_MOC as defined in the patch has no sense at all. This option
> >> > is used as moc command (tipical value is '/usr/bin/moc'). I cannot
> >> > find an explanation for it working but that the statement has no
> >> > effect in the place it is patched (so build will work without the
> >> > statement) or that moc generated files were generated in previous
> >> > executions, (so the patch wouldn't work with a clean build).
> >>
> >> $ QTDIR=/usr/lib/qt scons install prefix=$pkgdir/usr clam_prefix=/usr
> >> qt_plugins_install_path=/usr/lib/qt/plugins/designer release=0
> >> verbose=1
> >> [...]
> >> moc -I/home/san/clam/clean/pkg/usr/include -I/usr/local/include
> >> -I/usr/include/libxml++-2.6 -I/usr/lib/libxml++-2.6/include
> >> -I/usr/include/libxml2 -I/usr/include/glibmm-2.4
> >> -I/usr/lib/glibmm-2.4/include -I/usr/include/sigc++-2.0
> >> -I/usr/lib/sigc++-2.0/include -I/usr/include/glib-2.0
> >> -I/usr/lib/glib-2.0/include -I/usr/include/alsa -I/usr/include/QtCore
> >> -I/usr/include/QtGui -I/usr/include/QtOpenGL -I/usr/include/QtXml
> >> -I/usr/include/QtSvg -I/usr/include/QtUiTools
> >> -I/usr/include/QtDesigner -I/usr/include/QtWebKit
> >> -I/usr/include/QtNetwork -o
> >> src/clamWidgetsPlugin/generated/moc_KeySpacePlugin.cxx
> >> src/clamWidgetsPlugin/KeySpacePlugin.hxx
> >> [...]
> >> XTERM_SHELL, /bin/bash
> >> PATH,
> >> /bin:/usr/bin:/sbin:/usr/sbin:/opt/kde/bin:/usr/bin/perlbin/site:/usr/bi
> >> n/ perlbin/vendor:/usr/bin/perlbin/core:/opt/qt/bin TERM, xterm
> >> QT_XFT, true
> >> PKG_CONFIG_PATH, /usr/lib/pkgconfig:/opt/qt/lib/pkgconfig
> >> _, /usr/bin/scons
> >> PWD, /home/san/clam/Ms/src/NetworkEditor-1.4.0
> >> QTDIR, /usr/lib/qt
> >> Building src/clamWidgetsPlugin/generated/moc_KeySpacePlugin.cxx with
> >> action: $QT4_MOC $QT4_MOCFROMHFLAGS $QT4_MOCINCFLAGS -o
$TARGET
> >
> > $SOURCE
> >
> >> ['moc', '-I/home/san/clam/clean/pkg/usr/include',
> >> '-I/usr/local/include', '-I/usr/include/libxml++-2.6',
> >> '-I/usr/lib/libxml++-2.6/include', '-I/usr/include/libxml2',
> >> '-I/usr/include/glibmm-2.4', '-I/usr/lib/glibmm-2.4/include',
> >> '-I/usr/include/sigc++-2.0', '-I/usr/lib/sigc++-2.0/include',
> >> '-I/usr/include/glib-2.0', '-I/usr/lib/glib-2.0/include',
> >> '-I/usr/include/alsa', '-I/usr/include/QtCore',
> >> '-I/usr/include/QtGui', '-I/usr/include/QtOpenGL',
> >> '-I/usr/include/QtXml', '-I/usr/include/QtSvg',
> >> '-I/usr/include/QtUiTools', '-I/usr/include/QtDesigner',
> >> '-I/usr/include/QtWebKit', '-I/usr/include/QtNetwork', '-o',
> >> '"src/clamWidgetsPlugin/generated/moc_KeySpacePlugin.cxx"',
> >> '"src/clamWidgetsPlugin/KeySpacePlugin.hxx"']
> >> src/clamWidgetsPlugin/KeySpacePlugin.hxx:33: Error: Undefined interface
> >> scons: *** [src/clamWidgetsPlugin/generated/moc_KeySpacePlugin.cxx]
> >> Error 1 scons: building terminated because of errors.
> >>
> >> (i have patched scons *only* to print more stuff, and SConstruct to
> >> use -O0, wishing to down the build time)
> >>
> >> So, i changed
> >> env.Append(QT4_MOC=["-I/usr/include"])
> >> for
> >> env.Append(QT4_MOCFROMHFLAGS=["-I/usr/include"])
> >> its okey now?
> >
> > Does the CPPPATH work?
> >
> > env.AppendUnique(CPPPATH=['/usr/include'])
> >
> > If not try to append it before or after the EnableQtModules call. It
> > should not, but it could be a difference.
>
> It worked only with env.AppendUnique(CPPPATH=['/usr/include']) before
> EnableQt4Modules !!
So then we are close to make the patch worthless. The problem is that the
expansion of CPPPATH into MOC4_*FLAGS is done in EnableQt4Modules and it
should be lazier. I'll try to fix it but the workaround is clear, i guess.
--
David García Garzón
(Work) david dot garcia at upf anotherdot edu
http://www.iua.upf.edu/~dgarcia
More information about the clam-devel
mailing list