嵌入式开发者社区

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

作者: smallknife_hb    时间: 2015-1-12 14:22
标题: 交叉编译问题,急
我对syslink进行交叉编译到arm,但是出现如下错误:
% k1 [6 k$ ?6 g% B/ g/home/tl/Projects/Xdl-build-arm/../../qt/Qt4.7/include/QtCore/qtconcurrentrunbase.h:65: error: two or more data types in declaration of 'parameter'
$ d/ U) u' B$ E3 N' K: T8 y: n" L/ R. X  |
这个头文件内容如下:+ a4 H% ], T% |9 i4 q7 J5 g$ g
#ifndef QTCONCURRENT_RUNBASE_H* m/ _  p# \6 p* i# M
#define QTCONCURRENT_RUNBASE_H
* x  F- y' ^3 f8 y# e; B, P  U: U3 L! A+ v# w
#include <QtCore/qglobal.h>5 t. P: Z/ k) C# o, |. Q

/ h/ Z- M) |( ^/ I# `, Q#ifndef QT_NO_CONCURRENT
  ]1 [4 w9 g( M1 t+ r9 }6 X  B+ _8 v+ L( _/ _
#include <QtCore/qfuture.h>% M5 s3 ]3 X9 E$ A( M! t3 i
#include <QtCore/qrunnable.h>
( I7 J5 A8 w5 E0 A' g! {4 v#include <QtCore/qthreadpool.h>
0 ^: Z/ Q$ o9 f6 t
- \2 u; m0 b/ Q" w: s# r3 @# wQT_BEGIN_HEADER
8 E8 G; J+ g- e8 g; eQT_BEGIN_NAMESPACE
/ H- s/ l7 A# ~: q2 d4 S3 R/ R' {$ L: W
QT_MODULE(Core)
$ ]$ Q  b+ u2 a. M$ j8 u  l1 u9 t; W" D- h$ V
#ifndef qdoc; H9 W% E7 @; f

% N/ ]* a' q2 l& I% E0 J$ R& K/ h: enamespace QtConcurrent {
# v+ [4 @( F: r) I1 M
0 a; l# e8 N, Y' Q& Itemplate <typename T>% y, {+ b" k3 r' ]; h
struct SelectSpecialization; b2 Z" t& b/ a' G' G% |
{" D( j1 }$ v9 v) U
    template <class Normal, class Void>% k3 W$ f1 |* F: b2 c) o3 B! J# J: u
    struct Type { typedef Normal type; };+ d5 {9 Q9 L# X+ J" |
};
3 g  h4 x9 |, Z, G! N1 h7 E" C, s9 E: U$ q& j
template <>
3 v' B( z2 f* T4 ?: h3 G( T3 Vstruct SelectSpecialization<void>1 o2 ?3 {* F8 ]2 y) \9 w# P
{
5 H9 {+ y2 h" [    template <class Normal, class Void>! Y: `  `- ^6 k4 r3 x3 Q
    struct Type { typedef Void type; };
. R& j: P# V) U0 A. U, Z% D};
/ z& i; }, {% z5 D$ c2 v
: \5 O; M4 A8 f, Gtemplate <typename T>' R! L; b# a) X/ |7 }/ e
class RunFunctionTaskBase : public QFutureInterface<T> , public QRunnable
) T* |7 O+ d& a1 l; z+ g6 G{! {7 ~: t0 t" K) I- c3 o
public:
/ u. x, T9 C; P7 X! z0 u) V! {    QFuture<T> start()
/ P- m6 D; k& h- s    {. B# F* _; k1 c/ }1 ]2 U1 }+ b
        this->setRunnable(this);5 b& X# Y6 [, T1 n8 C* e( e
        this->reportStarted();
* O7 }$ b7 c1 O2 u( P        QFuture<T> future = this->future();# R: G6 J5 C/ l! z# P0 U* s& Q
        QThreadPool::globalInstance()->start(this, /*m_priority*/ 0);3 k0 P) n& ]$ c: X0 s' e
        return future;  F% a: }' p$ ~9 Q. r. D
    }- ]: B% D& S5 s5 G* }: s
; Q& f$ n' Y: S5 N
    void run() {}: e) V3 H) v3 J( T, C
    virtual void runFunctor() = 0;
# g+ V! ?% A- I- O9 p" b5 O* }};. g9 R, l3 v0 D
0 x$ O0 F9 r5 q7 f! x- V5 c7 e) h
template <typename T>
- ~! R, M1 U6 b) g5 A* u0 jclass RunFunctionTask : public RunFunctionTaskBase<T>3 |% \/ s& ?5 K, m1 _
{
# i7 n4 b1 L  P# lpublic:* R' T6 Z- m9 o8 M( A) f6 J# I
    void run()0 t- j5 Z) Y5 V: M
    {
3 c7 v2 c! k! b' e: z/ Q1 t        if (this->isCanceled()) {
: s8 {( M9 s' Z. \, a6 R) ?            this->reportFinished();
1 Z8 h$ s. j( m4 t. p! W; W            return;$ w1 d, f; Z. M8 F0 \5 L
        }
4 E2 q% o4 t! Q5 K7 _        this->runFunctor();5 |' Z; l! Z* K) x% G/ R* D
        this->reportResult(result);
) U9 D4 k6 H8 [% w2 e& P3 y0 s        this->reportFinished();
: j1 M! D6 \2 A: l- ^& w    }
  Y+ r/ [/ {$ Z$ x2 |    T result;
4 c8 J- n  M2 _};: V$ Z8 ~) {9 A
+ ~- @) J6 g3 K& C# p
template <># T! B/ y: W- K& f
class RunFunctionTask<void> : public RunFunctionTaskBase<void>
* P/ H: F( j; w8 l6 \! u5 s2 ?3 c{
( g& j9 d1 v. O( L, ~: opublic:
$ s; B8 m# E4 {+ G( K( w0 F, f    void run()
8 y' ?, Z8 y1 v0 P    {
3 c9 w" a1 r2 ~        if (this->isCanceled()) {( V0 d5 B. J! R- X  E% A
            this->reportFinished();; H# L( E/ X- z( |% f, p
            return;" O7 ~# D8 y( k* t2 R9 V' g
        }
& q. |. C: k1 b& A5 V5 O        this->runFunctor();
( I3 f( n+ A1 p# b% J, I        this->reportFinished();
0 j: [2 s& v5 c8 e. g1 O! C7 b    }! V' [# n# b" j+ z( h- a7 M$ B
};( T1 t) y' \$ g
, ^! T3 L+ x# V, u1 q$ R
} //namespace QtConcurrent
; n2 x0 V: j$ V+ O6 r- E1 V
2 L8 v8 f( w  U#endif //qdoc
# A! w6 s3 d: v  O' d( {5 _( u- \4 j' h1 W" S+ r8 D
QT_END_NAMESPACE
( {5 l+ f3 v' W4 A# KQT_END_HEADER2 d; l* G9 i9 ^; M4 x9 v
. ^7 R/ @, q! E
#endif // QT_NO_CONCURRENT
8 |9 k; |2 L- T1 x, h$ A( x6 r+ w# l3 p, m1 J7 I
#endif
+ Z/ A6 h% m7 Q0 O" {* `8 G
" h" h: d$ }6 L# Q3 W
作者: 2532609929    时间: 2015-1-12 22:22
是做创龙哪个文档的实验呢?没看出来!可以将编译命令、步骤写出来吗?) b- x& N. D! o7 i8 H





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