Results 1 to 3 of 3

Thread: Qtopia core 4.2.2 cross compile make error

  1. #1
    Join Date
    Apr 2007
    Posts
    1
    Qt products
    Platforms
    Unix/X11

    Question Qtopia core 4.2.2 cross compile make error

    hi all

    I have an arm toolchain installed -eabi version 4 ( if that helps) . I tried compiling qtopia core 4.2.2 with the configure statement:

    ./configure -embedded arm -xplatform qws/linux-arm-g++ -continue -debug

    The make gave the following error:

    In file included from kernel/qabstractitemmodel.cpp:24:
    kernel/qabstractitemmodel.h:139:72: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.h:143:48: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.h:296:85: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.h:316:89: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.h:339:54: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.h:342:43: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.cpp:437:52: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.cpp:508:68: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.cpp:552:68: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.cpp:581:68: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.cpp:625:68: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.cpp:1675:57: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.cpp:1715:59: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.cpp:1906:78: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.cpp:2334:86: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.cpp:2462:85: error: macro "index" passed 3 arguments, but takes just 2
    kernel/qabstractitemmodel.cpp:2594:36: error: macro "index" requires 2 arguments, but only 1 given
    kernel/qabstractitemmodel.h:138: error: 'index' declared as a 'virtual' field
    kernel/qabstractitemmodel.h:138: error: expected ';' before 'const'
    kernel/qabstractitemmodel.h: In member function 'QModelIndex QAbstractItemModel::sibling(int, int, const QModelIndex&) const':
    kernel/qabstractitemmodel.h:143: error: 'index' was not declared in this scope
    kernel/qabstractitemmodel.h: At global scope:
    kernel/qabstractitemmodel.h:142: warning: unused parameter 'row'
    kernel/qabstractitemmodel.h:142: warning: unused parameter 'column'
    kernel/qabstractitemmodel.h:142: warning: unused parameter 'idx'
    kernel/qabstractitemmodel.h:296: error: expected ';' before 'const'
    kernel/qabstractitemmodel.h:316: error: expected ';' before 'const'
    kernel/qabstractitemmodel.h: In member function 'QModelIndex QModelIndex::sibling(int, int) const':
    kernel/qabstractitemmodel.h:339: error: 'const class QAbstractItemModel' has no member named 'index'
    kernel/qabstractitemmodel.h: At global scope:
    kernel/qabstractitemmodel.h:338: warning: unused parameter 'arow'
    kernel/qabstractitemmodel.h:338: warning: unused parameter 'acolumn'
    kernel/qabstractitemmodel.h: In member function 'QModelIndex QModelIndex::child(int, int) const':
    kernel/qabstractitemmodel.h:342: error: 'const class QAbstractItemModel' has no member named 'index'
    kernel/qabstractitemmodel.h: At global scope:
    kernel/qabstractitemmodel.h:341: warning: unused parameter 'arow'
    kernel/qabstractitemmodel.h:341: warning: unused parameter 'acolumn'
    kernel/qabstractitemmodel.cpp:437: error: expected ';' before 'const'
    kernel/qabstractitemmodel.cpp:438: error: expected `;' before 'QModelIndex'
    kernel/qabstractitemmodel.cpp: In member function 'void QAbstractItemModelPrivate::rowsInserted(const QModelIndex&, int, int)':
    kernel/qabstractitemmodel.cpp:508: error: 'class QAbstractItemModel' has no member named 'index'
    kernel/qabstractitemmodel.cpp:503: warning: unused variable 'count'
    kernel/qabstractitemmodel.cpp: At global scope:
    kernel/qabstractitemmodel.cpp:500: warning: unused parameter 'parent'
    kernel/qabstractitemmodel.cpp: In member function 'void QAbstractItemModelPrivate::rowsRemoved(const QModelIndex&, int, int)':
    kernel/qabstractitemmodel.cpp:552: error: 'class QAbstractItemModel' has no member named 'index'
    kernel/qabstractitemmodel.cpp:547: warning: unused variable 'count'
    kernel/qabstractitemmodel.cpp: At global scope:
    kernel/qabstractitemmodel.cpp:541: warning: unused parameter 'parent'
    kernel/qabstractitemmodel.cpp: In member function 'void QAbstractItemModelPrivate::columnsInserted(const QModelIndex&, int, int)':
    kernel/qabstractitemmodel.cpp:581: error: 'class QAbstractItemModel' has no member named 'index'
    kernel/qabstractitemmodel.cpp:576: warning: unused variable 'count'
    kernel/qabstractitemmodel.cpp: At global scope:
    kernel/qabstractitemmodel.cpp:573: warning: unused parameter 'parent'
    kernel/qabstractitemmodel.cpp: In member function 'void QAbstractItemModelPrivate::columnsRemoved(const QModelIndex&, int, int)':
    kernel/qabstractitemmodel.cpp:625: error: 'class QAbstractItemModel' has no member named 'index'
    kernel/qabstractitemmodel.cpp:620: warning: unused variable 'count'
    kernel/qabstractitemmodel.cpp: At global scope:
    kernel/qabstractitemmodel.cpp:614: warning: unused parameter 'parent'
    kernel/qabstractitemmodel.cpp: In member function 'virtual QModelIndexList QAbstractItemModel::match(const QModelIndex&, int, const QVariant&, int, Qt::MatchFlags) const':
    kernel/qabstractitemmodel.cpp:1675: error: 'index' was not declared in this scope
    kernel/qabstractitemmodel.cpp: In member function 'bool QAbstractItemModel::decodeData(int, int, const QModelIndex&, QDataStream&)':
    kernel/qabstractitemmodel.cpp:1906: error: 'index' was not declared in this scope
    kernel/qabstractitemmodel.cpp: At global scope:
    kernel/qabstractitemmodel.cpp:2334: error: expected initializer before 'const'
    kernel/qabstractitemmodel.cpp:2462: error: expected initializer before 'const'
    kernel/qabstractitemmodel.cpp: In member function 'virtual bool QAbstractTableModel::dropMimeData(const QMimeData*, Qt:ropAction, int, int, const QModelIndex&)':
    kernel/qabstractitemmodel.cpp:2544: error: invalid conversion from 'int' to 'const char*'
    kernel/qabstractitemmodel.cpp:2544: error: initializing argument 1 of 'char* strchr(const char*, int)'
    kernel/qabstractitemmodel.cpp:2544: error: no matching function for call to 'QAbstractTableModel::setItemData(char*, const QMap<int, QVariant>&)'
    kernel/qabstractitemmodel.cpp:1347: note: candidates are: virtual bool QAbstractItemModel::setItemData(const QModelIndex&, const QMap<int, QVariant>&)
    kernel/qabstractitemmodel.cpp: In member function 'virtual bool QAbstractListModel::dropMimeData(const QMimeData*, Qt:ropAction, int, int, const QModelIndex&)':
    kernel/qabstractitemmodel.cpp:2594: error: 'index' was not declared in this scope
    gmake[2]: *** [.obj/debug-shared-emb-arm/qabstractitemmodel.o] Error 1
    gmake[2]: Leaving directory `/home/newuser/Project/qtopia-core-opensource-src-4.2.1/src/corelib'
    gmake[1]: *** [sub-corelib-make_default] Error 2
    gmake[1]: Leaving directory `/home/newuser/Project/qtopia-core-opensource-src-4.2.1/src'
    gmake: *** [sub-src-make_default-ordered] Error 2

    I am new to qtopia. Will someone please help me?

  2. #2

    Default Re: Qtopia core 4.2.2 cross compile make error

    Hi, I have exact the same problem with Qtopia Core 4.2.3, i try with following config :
    ./configure -embedded mips -xplatform qws/linux-mips-g+

    i build a toolchain with buildroot.

    What do we wrong ?? Have no more idea

  3. #3

    Default Re: Qtopia core 4.2.2 cross compile make error

    I have the same problem. I used toolchain with gcc-3.4.6 built from buildroot.

    I guess configuration of buildroot cause the problem. All index( ) in headers become index after pre-processor.

    I know it is not a good idea, but I add:

    #ifdef index
    #undef index
    #endif

    on every wrong place of header and source files.

    For example:
    vi src/corelib/kernel/qabstractitemmodel.h:
    ___138#ifdef index
    ___139#undef index
    ___140#endif
    ___141 virtual QModelIndex index(int row, int column,

    It works, but not good.
    Where can i find a good toolchain for compile these?

Similar Threads

  1. Installation on Fedora Core 4
    By jcr in forum Installation and Deployment
    Replies: 3
    Last Post: 29th January 2009, 01:34
  2. qt 4.2.2 install on aix
    By try to remember in forum Installation and Deployment
    Replies: 2
    Last Post: 28th March 2007, 12:19
  3. Qt-x11-commercial-src-4.2.0-snapshot-20060824 error
    By DevObject in forum Installation and Deployment
    Replies: 4
    Last Post: 24th August 2006, 23:31
  4. use qpsql
    By raphaelf in forum Installation and Deployment
    Replies: 34
    Last Post: 22nd August 2006, 12:52
  5. Am I the only one with "make" error ?
    By probine in forum Installation and Deployment
    Replies: 1
    Last Post: 13th February 2006, 12:54

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.