嵌入式开发者社区

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

作者: smallknife_hb    时间: 2015-1-12 14:22
标题: 交叉编译问题,急
我对syslink进行交叉编译到arm,但是出现如下错误:) i8 Z% U- M' ]5 a, E
/home/tl/Projects/Xdl-build-arm/../../qt/Qt4.7/include/QtCore/qtconcurrentrunbase.h:65: error: two or more data types in declaration of 'parameter'- i) R5 X) q& V: u$ l1 K; G
' a" u& ]7 y3 U
这个头文件内容如下:
7 u* b4 l4 c6 m. y: T# f#ifndef QTCONCURRENT_RUNBASE_H
) ~# P7 _4 k1 S; m( M#define QTCONCURRENT_RUNBASE_H. N0 s' D  w1 W; x- R( V
7 k9 B0 H2 Z4 S
#include <QtCore/qglobal.h>$ F/ H9 T; b2 ^0 Z
% d! m& H+ o+ `( L
#ifndef QT_NO_CONCURRENT+ }5 c, b0 N& u
6 V- l8 s' a  H* l2 Z4 h
#include <QtCore/qfuture.h>
8 m" V  G$ r6 u/ i/ M0 `. b7 X% ?+ Z#include <QtCore/qrunnable.h>, l* a- j, v' ?, ]$ q, y5 s
#include <QtCore/qthreadpool.h>
! f! e6 |  g. t
( V* u, w) g2 K) n9 e' d1 `: tQT_BEGIN_HEADER
, e/ Z3 J; x1 rQT_BEGIN_NAMESPACE. y* ?' z8 w# j
7 ]: f/ r7 ?5 E* P. f9 J
QT_MODULE(Core)
' w$ i3 |8 Z  K& u$ a0 s/ T6 P3 D6 Q/ l9 X: H+ r/ y5 Z
#ifndef qdoc
# y) h# G1 \% w5 L' }; n( g; }" C- J6 [4 b2 z9 C& [% T7 L7 G
namespace QtConcurrent {  G, t  a! h' l( I
, \0 L. k* b( I
template <typename T>
% w  d  T5 D, `struct SelectSpecialization" P1 W7 x8 x% s
{" Z0 q8 a1 B! j% w  u* d4 L0 ?" x- F
    template <class Normal, class Void>
: T  W- h7 C/ ?7 E    struct Type { typedef Normal type; };! |" O4 b% t" K. ]# Z0 x8 S
};
: W7 L) f- ]( H. M
) Q% r( \7 d5 E+ K' k  htemplate <>$ @* v6 r. |5 W/ b; y1 H) s8 G- T* S
struct SelectSpecialization<void>( J& F+ ^% t, a+ _
{
% s& l; M. j; F+ a! o/ ]    template <class Normal, class Void>1 s+ f6 V2 Q1 I: o$ Q5 Y  {
    struct Type { typedef Void type; };
1 Q1 P. A3 M0 ~3 j1 D1 J: a};5 h- L7 G: `0 \3 k

* ^8 ^# K4 O5 u+ G. jtemplate <typename T>
  _% ^( ]# X7 n! rclass RunFunctionTaskBase : public QFutureInterface<T> , public QRunnable7 c: K9 h$ S2 z+ d& R4 [* V  [' F" ^
{% p$ m9 X3 J0 V3 P& C& z. j
public:
- i3 A: b) G# |% e    QFuture<T> start()$ c, }' a5 a- Q( ?6 n
    {+ j0 ~5 I( ?; ]: ?' O1 S3 G
        this->setRunnable(this);7 X! G% _2 D, b. \8 Q4 _3 T
        this->reportStarted();
* L. ?& w! P/ K5 j) J        QFuture<T> future = this->future();& o5 X+ A, r4 q, C  \7 y$ x
        QThreadPool::globalInstance()->start(this, /*m_priority*/ 0);/ _. r6 o7 N) @9 Q4 x# M
        return future;
) v2 q, I# ?% B- e3 c; U3 B    }
5 ?6 J8 z' ?' q4 V$ E
9 d! k5 ~& C9 Q8 h& ?0 b3 s0 w    void run() {}6 A6 t/ y3 b) G' C# Y
    virtual void runFunctor() = 0;4 R# {& ^- \: a, ]9 L
};
5 r% g5 q7 [* q) ^  I7 D% _; C. ?, A
: e, x* ?+ z4 c& g7 q" C9 Utemplate <typename T>
$ ~3 O& v* G) v7 ^( r: y! d2 Pclass RunFunctionTask : public RunFunctionTaskBase<T>
* D0 n( g2 ?5 h) l# R- L{" x" Q/ @( U0 [) ~% N( V
public:9 Y3 D" D, A8 C8 x; F0 }: L- w9 |: M
    void run()& q3 F  p, E) M; G
    {5 W/ R) H6 Q, |7 X( E; S/ U
        if (this->isCanceled()) {
9 @+ c+ ]* B1 y            this->reportFinished();- R& m- n2 l9 ~  k+ j$ u
            return;
: `" \1 D. A: e$ @% s  P        }
! v- s  u2 Y! w* q        this->runFunctor();
' j& [" a% ^; _# b( f/ m        this->reportResult(result);
4 \8 j4 G6 d6 g! B# A7 ~        this->reportFinished();
- Z5 t. j* T% Q  p' _/ r2 |    }
5 V. H* ]; E8 [8 Q+ R( q    T result;9 m3 f: p1 B. t9 q' D  M- W
};, K) ~' F: q6 x# S  t. w9 n% P

! ^- y2 }- m: o5 P: i: |& Ntemplate <>
+ Y' f) p1 W7 G8 W* B4 m$ u0 fclass RunFunctionTask<void> : public RunFunctionTaskBase<void>
1 S# {+ W" @$ Z8 R" b{- l: ?% z/ ]* R5 R) ]% W+ |! E$ G
public:
, `5 o4 n* {7 T    void run()6 W$ S0 R8 V1 l5 D/ Z; `4 D
    {  F9 Z( x6 u' _2 b+ Y/ c* ~. Q
        if (this->isCanceled()) {: ?, ]2 _' J9 C
            this->reportFinished();! u/ S: N; N. U
            return;
  J' A( N% x+ T2 o2 ^        }
3 I6 B2 g+ i& z; V. X        this->runFunctor();) {. |$ S  k' U6 V$ C3 q  E
        this->reportFinished();
* J. ^1 Z* ]  o% s, G    }
. Q$ @. ]: k3 T5 ]; w};' X# d! v7 Y% U& y+ ]7 h

3 _7 J% X# ~0 m1 F. d% e+ [; P+ i} //namespace QtConcurrent
6 t$ X8 V' S$ E9 G$ ^7 ]  y9 M9 _9 D" |' J
#endif //qdoc% L4 Q/ z! W* b0 P
: C9 L  \0 T& N7 j) [
QT_END_NAMESPACE
5 n) ]( |* B/ J- gQT_END_HEADER6 A5 X  O0 `4 S

# |# n# M5 b, K. R3 A#endif // QT_NO_CONCURRENT
) T  ^  P" g( K8 J: ~: G2 Q8 m- ?
#endif
* T# x$ Y# {) |
2 I9 x8 B* k( M# U% [. {  H: s
作者: 2532609929    时间: 2015-1-12 22:22
是做创龙哪个文档的实验呢?没看出来!可以将编译命令、步骤写出来吗?  H& x% ^# S* Z7 N$ o& A





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