嵌入式开发者社区

标题: 交叉编译问题,急 [打印本页]

作者: smallknife_hb    时间: 2015-1-12 14:22
标题: 交叉编译问题,急
我对syslink进行交叉编译到arm,但是出现如下错误:6 d6 F1 w! _) ~- s& v6 M, s0 x: W
/home/tl/Projects/Xdl-build-arm/../../qt/Qt4.7/include/QtCore/qtconcurrentrunbase.h:65: error: two or more data types in declaration of 'parameter'% |5 O  c0 [" Q

& w# W4 L& }0 r5 D: P8 H9 X$ l0 Y这个头文件内容如下:  v. ~8 \: C2 k7 s5 @
#ifndef QTCONCURRENT_RUNBASE_H: |; X# {9 e* j  k( W* l# J
#define QTCONCURRENT_RUNBASE_H  O4 B# ~* \" k+ c
5 h. J  ~4 L% R3 l
#include <QtCore/qglobal.h>
9 U- G. X; g* X7 l  x2 D0 l5 |
! v9 C3 Q/ T7 `  [% v$ a9 w* O#ifndef QT_NO_CONCURRENT
, D2 d+ |4 A. o9 P
- Y. A& y# S: ?4 k5 ~#include <QtCore/qfuture.h>
- ^+ B' ^" W- o! K( y#include <QtCore/qrunnable.h>
" ^0 u; C1 {. S#include <QtCore/qthreadpool.h>" D+ Z0 A5 Z3 M6 W; b0 u

8 W- X% T8 K! v& i( AQT_BEGIN_HEADER
" `. @' s6 \$ w/ n7 l" TQT_BEGIN_NAMESPACE
  q5 G7 @+ @7 a% j5 V3 ~, A$ b& h  i9 x7 t
QT_MODULE(Core)  ]% j- E; O, P) R# [
* G) J5 j. n2 P" _% w1 m  o
#ifndef qdoc: P& C5 U! V( n/ l

* C3 _' Z8 R/ ]( Snamespace QtConcurrent {% E" ^/ U$ Q+ k0 F8 ^

! j# m, Z0 l& ^% P  p8 {& x5 P1 q9 E" v: @template <typename T>
) [* z1 E% ]: Q; e7 dstruct SelectSpecialization
$ |$ n# R# Z+ i{
/ N- i9 @, |$ ]5 S4 D    template <class Normal, class Void>" A+ ^9 Q( o$ d) K3 j
    struct Type { typedef Normal type; };
) ?& S7 ^4 E) h7 Q  O% w7 g};
+ J3 U4 l) R, m* \9 z# F$ m, M1 o' ^/ G3 ^+ C9 o" @: {' f
template <>
7 j" Z: k8 P) r% astruct SelectSpecialization<void>. i4 A# h# X2 J1 f1 `( P( f2 E& T  l
{  Y8 E$ K8 |( @6 i) }+ H
    template <class Normal, class Void>; u% X# Y* H/ A8 z8 Y
    struct Type { typedef Void type; };
! l6 I; m2 w5 H8 i: \* f) ]};0 {7 t" O. P2 g& J6 J! m( R+ H0 ?
! M" i6 u, ^, b* r9 ~/ x
template <typename T>
8 X) C' V' L- L% u2 Vclass RunFunctionTaskBase : public QFutureInterface<T> , public QRunnable
" e6 @: r6 k* ]7 |! _( f( ~{
5 t$ ]* J& z+ b% v, ~9 Opublic:5 P6 f5 R; P$ |. e
    QFuture<T> start()' Q% R( Y9 k3 _
    {# a8 B* {  s1 g; L
        this->setRunnable(this);
7 o. Q' d  e7 ~6 Y: r4 y! ^! U        this->reportStarted();
! n  g6 d+ H1 F6 l  u, t        QFuture<T> future = this->future();- P' p' z6 x; y( `" I0 ?1 @
        QThreadPool::globalInstance()->start(this, /*m_priority*/ 0);( J$ C4 M4 c( h; _/ I
        return future;  Q( o( r" V6 h
    }% c5 I  E* l( B; }0 t
) ?' ?' U. r6 q* ]% V; E, l8 @
    void run() {}* _1 E0 u8 u, D& p5 k8 N
    virtual void runFunctor() = 0;
) F% w' z& n2 C, W# j3 f};/ B4 f" x$ R, D; L

; m. o2 U8 Q+ D$ z$ |" Rtemplate <typename T>$ ~' R& |+ p& C' `/ y; ^# B- \) C
class RunFunctionTask : public RunFunctionTaskBase<T>
: e9 N% C; d0 F8 Z0 ~{
8 h: l5 v  d# G1 y) Opublic:3 n' ^5 V# p7 e9 u! u- d5 F5 y
    void run()
, G+ B9 [2 q! h4 H    {
! I1 v' `2 f8 \8 i8 m  B        if (this->isCanceled()) {
/ w8 ^! B; |1 Z; S% ~1 G            this->reportFinished();& R% J' N6 p4 f, E9 F
            return;4 Z+ P& o" X) O) I: {  [" ~( E
        }
  X- {+ ]( q# ~        this->runFunctor();3 \' q5 ?/ V5 K6 q4 X! C; @
        this->reportResult(result);
: t: U8 f2 M% R; W        this->reportFinished();1 t& D  @3 V( d3 C* E
    }
, l+ K7 ^: C+ ~$ S6 s  r& C    T result;
$ e$ S6 P$ E9 K& J; c" _};7 v6 z0 X, D& }2 ]9 I8 ]

1 U6 z& ^2 G" E9 z; g& Itemplate <>. W5 A9 j3 _; q2 z1 m0 f) }
class RunFunctionTask<void> : public RunFunctionTaskBase<void>+ N  s# L2 t! I0 T$ \
{
* w. I1 s3 k1 w3 d7 Q: }+ t# Upublic:2 j4 I' U+ q, _# b. W* a( R$ v% ^
    void run()
* Q# a/ C' h% n% O' p/ j( L+ [    {
& w3 M$ \+ e. p' ]        if (this->isCanceled()) {
5 ]/ s+ p9 i6 `6 `1 [/ U            this->reportFinished();
* t" I. F: V5 S# {5 D            return;: ^, Q) K0 t6 [+ m5 |- C2 b4 i6 S0 d
        }( d) L' p/ F+ I& W; k$ g
        this->runFunctor();
. w5 Q$ R1 k0 T, g2 Y, C+ V        this->reportFinished();* j. h* W$ |  F
    }2 Y: p3 _. y( Y( p8 N- m" S
};$ `1 \& c$ A& n  c5 w* V" ^6 b
2 g+ h# {0 c! ~! S
} //namespace QtConcurrent
$ V  S# c% a4 o9 m9 @+ A" k& x8 a$ B8 S1 A1 t' [
#endif //qdoc
3 k/ K/ C% F4 ]) B5 _. o
8 P/ I4 H+ t& j: R! ]! }; _, X5 q9 hQT_END_NAMESPACE7 W3 O" X; e6 p* {* m* j' i+ A
QT_END_HEADER
9 C1 u! K9 l: ~. i
- B2 D* D, H/ R: T# h! Q#endif // QT_NO_CONCURRENT
3 y6 I7 y& y6 M. ^0 R3 K3 K, D/ d6 a4 O0 g+ e
#endif
; Q/ r- t' w% m  y( R8 v: D4 x
8 o; {% c% X# Z+ q/ v5 n
作者: 2532609929    时间: 2015-1-12 22:22
是做创龙哪个文档的实验呢?没看出来!可以将编译命令、步骤写出来吗?3 R4 o$ ~0 s& l1 N; Z7 X2 D





欢迎光临 嵌入式开发者社区 (https://www.51ele.net/) Powered by Discuz! X3.4