我一直在閱讀和研究這幾天,現在我需要一些外部幫助!在AIX上使用pthread進行靜態鏈接
(與本網站似乎是一個不錯的地方,所以我想我會 在這裏發佈我的問題,看看它是如何去)
我們的小公司還沒有建立我們對AIX 應用了好幾年,並且我已經分配了這個任務(好的 我喜歡挑戰)。
我遇到的問題很容易描述,而且我可以看到 其他人也在遇到它,儘管我無法找到 找到答案。
如果我鏈接的應用「非靜態的」,意思是我不使用在構建命令「-static」 ,應用程序運行發展 機器上很好,但不是我們的,我們使用其他AIX機器上爲 測試。
[兩臺機器上的快速註釋;
開發:
~$ uname -a
AIX aix3 2 5 000BA50D4C00
測試:
~$ uname -a
AIX aix4 1 5 002459A64C00
]
,如果我用 「-static」,應用 「斷」 在運行時 在開發機器上鍊接當拋出異常時:
terminate called after throwing an instance of 'MyAppError'
Segmentation fault (core dumped)
AND(如果這還不夠),應用程序仍然沒有在測試機上沒有 運行:
exec(): 0509-036 Cannot load program ./myapp because of the following errors:
0509-130 Symbol resolution failed for myapp because:
0509-136 Symbol _sigqueue (number 65) is not exported from
dependent module /unix.
0509-136 Symbol ra_attachrset (number 95) is not exported from
dependent module /unix.
0509-136 Symbol __rs_pickmcm (number 99) is not exported from
dependent module /unix.
0509-136 Symbol _timer_create (number 122) is not exported from
dependent module /unix.
0509-136 Symbol _timer_delete (number 123) is not exported from
dependent module /unix.
0509-136 Symbol _timer_getoverrun (number 124) is not exported from
dependent module /unix.
0509-136 Symbol _timer_gettime (number 125) is not exported from
dependent module /unix.
0509-136 Symbol _timer_settime (number 126) is not exported from
dependent module /unix.
0509-136 Symbol count_event_waiters (number 159) is not exported from
dependent module /unix.
0509-192 Examine .loader section symbols with the
'dump -Tv' command.
我要在這裏指出,我們正在與聯「-pthead」, 和我讀過幾篇文章,說當使用pthread的時候,它是不正確的鏈接 。
我的大腦受傷了。
我非常感謝這方面的任何意見。