Ubuntu10.10安裝arm版本的Qt遇到error: thread-local storage not supported for this target
用arm編譯的時候卻碰到如下錯誤:
thread/qthread_unix.cpp:117: error: thread-local storage not supported for this target
make[1]: *** [.obj/release-shared-emb-arm/qthread_unix.o] 錯誤 1
make[1]:正在離開目錄 `/home/soft/qtenv/arm/src/corelib'
make: *** [sub-corelib-make_default-ordered] 錯誤 2
#
去看了下/src/corelib/thread目錄下
-rwxr--r-- 1 fsp fsp 20122 2012-03-14 22:01 qthread_unix.cpp*
-rw-r--r-- 1 fsp fsp 18695 2012-03-14 22:01 qthread_win.cpp
-rw-r--r-- 1 fsp fsp 2684 2012-03-14 22:01 qwaitcondition.h
-rw-r--r-- 1 fsp fsp 6163 2012-03-14 22:01 qwaitcondition.qdoc
-rw-r--r-- 1 fsp fsp 5730 2012-03-14 22:01 qwaitcondition_symbian.cpp
-rw-r--r-- 1 fsp fsp 6094 2012-03-14 22:01 qwaitcondition_unix.cpp
-rw-r--r-- 1 fsp fsp 6418 2012-03-14 22:01 qwaitcondition_win.cpp
-rw-r--r-- 1 fsp fsp 1259 2012-03-14 22:01 thread.pri
# vi qthread_unix.cpp
打開文件, 發現HAVE_TLS宏打開了才會導致錯誤,
關掉該宏後再編譯, 果然通過了。
於是就打了如下補丁:
110 #define HAVE_TLS
111 #endif
112 #if defined(Q_CC_XLC) || defined (Q_CC_SUN)
113 #define HAVE_TLS
114 #endif
115
116 #ifdef HAVE_TLS
117# static __thread QThreadData *currentThreadData = 0;
118 #endif
Ubuntu 14.04 64位安裝Android Studio 和 Genymotion
Ubuntu安裝eclipse,並創建桌面快捷方式,ubuntueclipse
(轉載)Ubuntu keylin 14.04 如何開啟root用戶登錄,keylin14.04
學習中的錯誤——ubuntu 14.04 LTS 啟動eclipse報錯,14.04eclipse
Ubuntu14.04更新軟件導致登錄死循環,不過可以進入tty模式,ubuntu14.04tty
ubuntu16.04更新內核--使用4.6以上的內核會讓用A卡的Dell電腦更快--及卸載多余內核,ubuntu16.044.6