- milestone: --> Compilation Issues
Hi,
I'm sure there's probably something wrong with my setup
but I'd appreciate your help anyway. I followed the
instructions in README.BUILD. I installed the dependent
libs by running apt-get install on tmake, flex, bison,
libqt-dev & libqt-mt-dev. The qt version installed was
3.2.3.1-22. I also set the QTDIR env variable. Then, I
ran tmake to build the Makefile and it seemed to work
as there were no error messages and I got a Makefile.
When I run make, I get the output that I pasted at the
bottom of the message. The compile cmd that blows up is
g++ -c -pipe -Wall -W -O2 -D_REENTRANT
-DQT_THREAD_SUPPORT -DNO_DEBUG -I. -I/usr/include/qt -o
optionsDialog.o optionsDialog.cpp.
The first error is on the line that declares the class
XxOptionsDialog in the file optionsDialog.h
I checked to make sure that /usr/include/qt had the qt
header files. I've also attached the generated
Makefile. Here's the output. Thanks.
colinux:/home/scott/xxdiff-3.0.4/src# make
g++ -c -pipe -Wall -W -O2 -D_REENTRANT
-DQT_THREAD_SUPPORT -DNO_DEBUG -I. -I/usr/include/qt -o
optionsDialog.o optionsDialog.cpp
In file included from optionsDialog.cpp:27:
optionsDialog.h:57: error: syntax error before `{' token
optionsDialog.h:59: error: non-member function `const
char* className()' cannot
have `const' method qualifier
optionsDialog.h:59: error: syntax error before `protected'
optionsDialog.h:63: error: syntax error before `;' token
optionsDialog.h:73: error: destructors must be member
functions
optionsDialog.h:73: error: virtual outside class
declaration
optionsDialog.h:76: error: virtual outside class
declaration
optionsDialog.h:122: error: syntax error before `public'
optionsDialog.h:174: error: syntax error before `private'
optionsDialog.h:183: error: non-member function `void
setFileDiffOptions(XxCommandSwitch, bool)' cannot
have `const' method
qualifier
optionsDialog.h:187: error: non-member function `void
setFileDiffQuality(XxQuality)' cannot have `const'
method qualifier
optionsDialog.h:196: error: non-member function `QString
getFontDisplayText(const QFont&)' cannot have
`const' method qualifier
optionsDialog.h:206: error: syntax error before `}' token
In file included from optionsDialog.cpp:31:
app.h:455: error: syntax error before `*' token
optionsDialog.cpp:198: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In constructor
`XxOptionsDialog::XxOptionsDialog(XxApp*,
QWidget*)':
optionsDialog.cpp:199: error: class `XxOptionsDialog'
does not have any field
named `BaseClass'
optionsDialog.cpp:200: error: class `XxOptionsDialog'
does not have any field
named `_app'
optionsDialog.cpp:235: error: `_buttonApply' undeclared
(first use this
function)
optionsDialog.cpp:235: error: (Each undeclared
identifier is reported only once
for each function it appears in.)
optionsDialog.cpp:235: error: `connect' undeclared
(first use this function)
optionsDialog.cpp:236: error: `_buttonOk' undeclared
(first use this function)
optionsDialog.cpp:241: error:
`_checkboxIgnoreTrailingBlanks' undeclared (first
use this function)
optionsDialog.cpp:243: error:
`_checkboxIgnoreWhitespace' undeclared (first use
this function)
optionsDialog.cpp:245: error: `_checkboxIgnoreCase'
undeclared (first use this
function)
optionsDialog.cpp:247: error:
`_checkboxIgnoreBlankLines' undeclared (first use
this function)
optionsDialog.cpp:250: error:
`_radiobuttonQualityNormal' undeclared (first use
this function)
optionsDialog.cpp:252: error:
`_radiobuttonQualityFastest' undeclared (first
use this function)
optionsDialog.cpp:254: error:
`_radiobuttonQualityHighest' undeclared (first
use this function)
optionsDialog.cpp:266: error: `_editFontApp' undeclared
(first use this
function)
optionsDialog.cpp:268: error: `_editFontText'
undeclared (first use this
function)
optionsDialog.cpp:279: error: `_listboxColors'
undeclared (first use this
function)
optionsDialog.cpp:285: error: `_buttonEditFore'
undeclared (first use this
function)
optionsDialog.cpp:287: error: `_buttonEditBack'
undeclared (first use this
function)
optionsDialog.cpp: At global scope:
optionsDialog.cpp:297: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In destructor
`XxOptionsDialog::~XxOptionsDialog()':
optionsDialog.cpp:300: error: `disconnect' undeclared
(first use this function)
optionsDialog.cpp: At global scope:
optionsDialog.cpp:306: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:314: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::show()':
optionsDialog.cpp:328: error: `_labelFontApp'
undeclared (first use this
function)
optionsDialog.cpp:329: error: `_labelFontText'
undeclared (first use this
function)
optionsDialog.cpp:331: error: `synchronize' undeclared
(first use this
function)
optionsDialog.cpp:332: error: `BaseClass' undeclared
(first use this function)
optionsDialog.cpp:332: error: syntax error before `::'
token
optionsDialog.cpp: At global scope:
optionsDialog.cpp:338: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::synchronize()':
optionsDialog.cpp:346: error: `_lineeditCommandFiles2'
undeclared (first use
this function)
optionsDialog.cpp:382: error: `_lineeditCommandFiles3'
undeclared (first use
this function)
optionsDialog.cpp:389: error: `_lineeditCommandDirs'
undeclared (first use this
function)
optionsDialog.cpp:393: error:
`_lineeditCommandDirsRecursive' undeclared (first
use this function)
optionsDialog.cpp:399: error: `_checkboxRecursive'
undeclared (first use this
function)
optionsDialog.cpp:406: error: `_comboHordiffType'
undeclared (first use this
function)
optionsDialog.cpp:407: error: `_spinboxHordiffContext'
undeclared (first use
this function)
optionsDialog.cpp:409: error:
`_checkboxIgnoreHorizontalWhitespace' undeclared
(first use this function)
optionsDialog.cpp:412: error:
`_checkboxHideCarriageReturns' undeclared (first
use this function)
optionsDialog.cpp:416: error: `_spinboxTabWidth'
undeclared (first use this
function)
optionsDialog.cpp:418: error:
`_checkboxDrawVerticalLine' undeclared (first use
this function)
optionsDialog.cpp:422: error: `_comboIgnoreFile'
undeclared (first use this
function)
optionsDialog.cpp:425: error:
`_checkboxIgnoreFileChanges' undeclared (first
use this function)
optionsDialog.cpp:429: error:
`_checkboxFormatClipboardText' undeclared (first
use this function)
optionsDialog.cpp:433: error:
`_lineeditClipboardFormat' undeclared (first use
this function)
optionsDialog.cpp:439: error: `_labelFontAppName'
undeclared (first use this
function)
optionsDialog.cpp:443: error: `_labelFontTextName'
undeclared (first use this
function)
optionsDialog.cpp:463: error: `_labelEditFore'
undeclared (first use this
function)
optionsDialog.cpp:464: error: `_labelEditBack'
undeclared (first use this
function)
optionsDialog.cpp: At global scope:
optionsDialog.cpp:474: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::selectDiffOptions()':
optionsDialog.cpp:475: error: `_tabWidget' undeclared
(first use this function)
optionsDialog.cpp:475: error: `getDiffPageIndex'
undeclared (first use this
function)
optionsDialog.cpp: At global scope:
optionsDialog.cpp:481: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:488: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::onApply()':
optionsDialog.cpp:491: error: `disconnect' undeclared
(first use this function)
optionsDialog.cpp:565: error: `_spinboxVlinePos'
undeclared (first use this
function)
optionsDialog.cpp:629: error: `connect' undeclared
(first use this function)
optionsDialog.cpp: At global scope:
optionsDialog.cpp:635: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::onClose()':
optionsDialog.cpp:636: error: `hide' undeclared (first
use this function)
optionsDialog.cpp: At global scope:
optionsDialog.cpp:642: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:650: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:658: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:666: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:677: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::setFileDiffOptions(XxCommandSwitch,
bool) const':
optionsDialog.cpp:686: error: incomplete type
'XxOptionsDialog' cannot be used
to name a scope
optionsDialog.cpp:689: error: incomplete type
'XxOptionsDialog' cannot be used
to name a scope
optionsDialog.cpp: At global scope:
optionsDialog.cpp:698: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:707: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:716: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:727: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:747: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::listboxColors(const QString&)':
optionsDialog.cpp:769: error: `_labelDescription'
undeclared (first use this
function)
optionsDialog.cpp: At global scope:
optionsDialog.cpp:775: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::editFontApp()':
optionsDialog.cpp:786: error: no matching function for
call to `QFontDialog::
getFont(bool*, const QFont&, XxOptionsDialog* const,
const char[12])'
/usr/include/qt/qfontdialog.h:71: error: candidates
are: static QFont
QFontDialog::getFont(bool*, const QFont&, QWidget*,
const char*)
/usr/include/qt/qfontdialog.h:73: error:
static QFont
QFontDialog::getFont(bool*, QWidget*, const char*)
/usr/include/qt/qfontdialog.h:124: error:
static QFont
QFontDialog::getFont(bool*, const QFont*, QWidget*,
const char*)
optionsDialog.cpp: At global scope:
optionsDialog.cpp:803: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::editFontText()':
optionsDialog.cpp:814: error: no matching function for
call to `QFontDialog::
getFont(bool*, const QFont&, XxOptionsDialog* const,
const char[12])'
/usr/include/qt/qfontdialog.h:71: error: candidates
are: static QFont
QFontDialog::getFont(bool*, const QFont&, QWidget*,
const char*)
/usr/include/qt/qfontdialog.h:73: error:
static QFont
QFontDialog::getFont(bool*, QWidget*, const char*)
/usr/include/qt/qfontdialog.h:124: error:
static QFont
QFontDialog::getFont(bool*, const QFont*, QWidget*,
const char*)
optionsDialog.cpp: At global scope:
optionsDialog.cpp:831: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::editColorFore()':
optionsDialog.cpp:846: error: no matching function for
call to `QColorDialog::
getColor(QColor&, XxOptionsDialog* const)'
/usr/include/qt/qcolordialog.h:54: error: candidates
are: static QColor
QColorDialog::getColor(QColor, QWidget*, const char*)
optionsDialog.cpp: At global scope:
optionsDialog.cpp:861: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::editColorBack()':
optionsDialog.cpp:876: error: no matching function for
call to `QColorDialog::
getColor(QColor&, XxOptionsDialog* const)'
/usr/include/qt/qcolordialog.h:54: error: candidates
are: static QColor
QColorDialog::getColor(QColor, QWidget*, const char*)
optionsDialog.cpp: At global scope:
optionsDialog.cpp:894: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:904: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:920: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:937: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `int
XxOptionsDialog::isInCommand(const
QString&, const QString&, const QString&, const
QString&)':
optionsDialog.cpp:942: error: incomplete type
'XxOptionsDialog' cannot be used
to name a scope
optionsDialog.cpp:943: error: incomplete type
'XxOptionsDialog' cannot be used
to name a scope
optionsDialog.cpp:944: error: incomplete type
'XxOptionsDialog' cannot be used
to name a scope
optionsDialog.cpp: At global scope:
optionsDialog.cpp:980: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp: In member function `void
XxOptionsDialog::setOneOfInCommand(QString&, const
QString&, const QString&,
const QString&)':
optionsDialog.cpp:986: error: incomplete type
'XxOptionsDialog' cannot be used
to name a scope
optionsDialog.cpp:989: error: incomplete type
'XxOptionsDialog' cannot be used
to name a scope
optionsDialog.cpp:993: error: incomplete type
'XxOptionsDialog' cannot be used
to name a scope
optionsDialog.cpp: At global scope:
optionsDialog.cpp:1003: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.cpp:1018: error: invalid use of undefined
type `class
XxOptionsDialog'
optionsDialog.h:57: error: forward declaration of
`class XxOptionsDialog'
optionsDialog.h:59: warning: `QMetaObject*
staticMetaObject()' declared
`static' but never defined
optionsDialog.h:59: warning: `QString tr(const char*)'
declared `static' but
never defined
optionsDialog.h:59: warning: `QString tr(const char*,
const char*)' declared
`static' but never defined
optionsDialog.h:91: warning: `bool isInCommand(const
QString&, const QString&)'
declared `static' but never defined
optionsDialog.h:96: warning: `void
addToCommand(QString&, const QString&)'
declared `static' but never defined
optionsDialog.h:100: warning: `void
removeFromCommand(QString&, const QString&)
' declared `static' but never defined
optionsDialog.h:111: warning: `int isInCommand(const
QString&, const QString&,
const QString&, const QString&)' declared `static'
but never defined
optionsDialog.h:119: warning: `void
setOneOfInCommand(QString&, const QString&,
const QString&, const QString&)' declared `static'
but never defined
make: *** [optionsDialog.o] Error 1