我正在尝试编译 ACE lib,但编译时出错。
我的 Linux 系统是 Slackware 14.2 64 位
lib是ACE 6.1.4版(我需要编译的版本)
在发布此之前,我已经按照从ACE web构建 ACE 的所有步骤进行操作。
如何编译这个库?
这是错误:
In file included from /home/cyneo/Downloads/ACE_wrappers/ace/OS_NS_Thread.h:32,
from /home/cyneo/Downloads/ACE_wrappers/ace/Guard_T.h:26,
from /home/cyneo/Downloads/ACE_wrappers/ace/Free_List.cpp:7,
from /home/cyneo/Downloads/ACE_wrappers/ace/Free_List.h:142,
from /home/cyneo/Downloads/ACE_wrappers/ace/Malloc_T.h:26,
from /home/cyneo/Downloads/ACE_wrappers/ace/Local_Name_Space.h:20,
from Local_Name_Space.cpp:3:
/home/cyneo/Downloads/ACE_wrappers/ace/os_include/os_sched.h:47:6: error: conflicting declaration ‘typedef struct cpu_set_t cpu_set_t’
} cpu_set_t;
^~~~~~~~~
In file included from /usr/include/sched.h:44,
from /usr/include/pthread.h:23,
from /home/cyneo/Downloads/ACE_wrappers/ace/os_include/os_pthread.h:51,
from /home/cyneo/Downloads/ACE_wrappers/ace/OS_NS_Thread.h:31,
from /home/cyneo/Downloads/ACE_wrappers/ace/Guard_T.h:26,
from /home/cyneo/Downloads/ACE_wrappers/ace/Free_List.cpp:7,
from /home/cyneo/Downloads/ACE_wrappers/ace/Free_List.h:142,
from /home/cyneo/Downloads/ACE_wrappers/ace/Malloc_T.h:26,
from /home/cyneo/Downloads/ACE_wrappers/ace/Local_Name_Space.h:20,
from Local_Name_Space.cpp:3:
/usr/include/bits/cpu-set.h:42:3: nota: previous declaration as ‘typedef struct cpu_set_t cpu_set_t’
} cpu_set_t;
In file included from /home/cyneo/Downloads/ACE_wrappers/ace/TSS_T.h:261,
from /home/cyneo/Downloads/ACE_wrappers/ace/Singleton.h:24,
from /home/cyneo/Downloads/ACE_wrappers/ace/Service_Gestalt.h:30,
from /home/cyneo/Downloads/ACE_wrappers/ace/Service_Object.h:27,
from /home/cyneo/Downloads/ACE_wrappers/ace/Naming_Context.h:25,
from /home/cyneo/Downloads/ACE_wrappers/ace/Local_Name_Space_T.h:25,
from /home/cyneo/Downloads/ACE_wrappers/ace/Local_Name_Space.h:128,
from Local_Name_Space.cpp:3:
/home/cyneo/Downloads/ACE_wrappers/ace/TSS_T.cpp: En la función miembro ‘void ACE_TSS_Guard<ACE_LOCK>::init_key()’:
/home/cyneo/Downloads/ACE_wrappers/ace/TSS_T.cpp:357:39: error: no matching function for call to ‘ACE_Thread::keycreate(ACE_thread_key_t*, void (*)(void*), void*)’
(void *) this);
^
make[1]: *** [/home/cyneo/Downloads/ACE_wrappers/include/makeinclude/rules.local.GNU:189: .shobj/Local_Name_Space.o] Error 1
我找到了这个,但我无法为我工作:
https://bugs.gentoo.org/638606
https://638606.bugs.gentoo.org/attachment.cgi?id=532828
编辑:
我也尝试编译 ACE 6.5.0,但出现此错误:
during GIMPLE pass: wrestrict
En la función miembro ‘virtual int ACE_Configuration_Heap::open_section(const ACE_Configuration_Section_Key&, const ACE_TCHAR*, int, ACE_Configuration_Section_Key&)’:
en pp_format, en pretty-print.c:1378
ACE_Configuration_Heap::open_section (const ACE_Configuration_Section_Key& base,