compilation - apt-pkg编译问题

标签 compilation include compiler-errors apt

我正在尝试编译使用apt-pkg的第三方代码。错误是

/usr/include/apt-pkg/depcache.h:188: error: ‘regex_t’ was not declared in this scope

我已验证regex.h存在于/usr/include/regex.h

我正在使用ubuntu 10.4 64位编译代码。

有什么问题吗?

最佳答案

在使用regex_t之前,需要在regex_h中包含regex.h,或者在包含depcache.h之前将其包含在任何包含depcache.h的代码中。

也许有一个#ifdef为您的环境设置不正确,并阻止了regex.h的包含。

关于compilation - apt-pkg编译问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7924444/

相关文章:

linux - 将驱动程序编译为内核的一部分,而不是模块

include - Jekyll 包含和 YAML frontmatter

include - 尝试将 ViewModel 传递到具有抽象变量类型的包含布局中的数据绑定(bind)错误

visual-studio-2008 - 在MS VS 2008中构建项目时出错

C++ 错误 C2227 : left of '->looseHealth' must point to class/struct/union/generic type

c++ - 通过 Windows 命令行,我们如何编译 Netbeans C/C++ 应用程序?

ios - "Running 2 of 3 custom shell scripts"Xcode 8.2

java - 从 Java 内部编译外部 .java 文件

c++ - 在 pragma pack 中包含 std map 会导致崩溃

android-studio - libgdx android studio - 无法解析方法drawMultiLine和符号HAlignment