Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/swift/17.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python cryptopp错误:应为'='''''';asm&x27;或'__属性';在'之前;{';代币_Python_Gcc_Crypto++ - Fatal编程技术网

Python cryptopp错误:应为'='''''';asm&x27;或'__属性';在'之前;{';代币

Python cryptopp错误:应为'='''''';asm&x27;或'__属性';在'之前;{';代币,python,gcc,crypto++,Python,Gcc,Crypto++,我添加了一个需要安装cryptopp的安全模块,该模块用C编写,包含以下内容: #include <Python.h> #include <common/credentials.h> #include "proto/security.pb.h" #include <string.h> GCC根据文件名后缀决定文件的编写语言。可以将文件重命名为*.cc或*.cpp,也可以将-xC++传递给g++.但我调用的是g++,而不是GCC。我在*.c文件上使用的也是g+

我添加了一个需要安装cryptopp的安全模块,该模块用C编写,包含以下内容:

#include <Python.h>
#include <common/credentials.h>
#include "proto/security.pb.h"
#include <string.h>

GCC根据文件名后缀决定文件的编写语言。可以将文件重命名为*.cc或*.cpp,也可以将
-xC++
传递给g++.

但我调用的是g++,而不是GCC。我在*.c文件上使用的也是g++。回答得好。您甚至列出了
-x
。如果有兴趣,这里是
-x
上的GCC文档:。
g++ -o /home/build/workarea/1.0.0/build_fileclient/baseutils/src/cc/unixusergrouphelper.os -c -g -Wall -isystem/usr/local/protobuf-2.5.0//include -O2 -pthread -fPIC -fPIC -I/home/build/workarea/1.0.0/build_fileclient -I. -I/usr/include -I/usr/local/protobuf-2.5.0/include -I/home/build/workarea/1.0.0/build_fileclient/fs -Ifs -I/home/build/workarea/1.0.0/build_fileclient/fs/common/gperftools/src -Ifs/common/gperftools/src -I/home/build/workarea/1.0.0/build_fileclient/fs/server -Ifs/server -I/home/build/workarea/1.0.0/build_fileclient/fs/client -Ifs/client -I/usr/local/java/include -I/usr/local/java/include/linux -I/usr/include/python2.6 -I/home/build/workarea/1.0.0/build_fileclient/fs/client/fileclient/java/fs-jni/target/native/javah -Ifs/client/fileclient/java/fs-jni/target/native/javah -I/home/build/workarea/1.0.0/build_version -I/home/build/workarea/github/dl/hadoop-common/hadoop-hdfs-project/hadoop-hdfs -I/home/build/workarea/github/dl/hadoop-common/hadoop-hdfs-project/hadoop-hdfs/target/native baseutils/src/cc/unixusergrouphelper.cc
In file included from /usr/include/cryptopp/osrng.h:6:0,
                 from fs/common/credentials.h:6,
                 from baseutils/src/cc/securitymodule.c:2:
/usr/include/cryptopp/config.h:97:1: error: unknown type name 'namespace'
/usr/include/cryptopp/config.h:97:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token
In file included from /usr/include/cryptopp/cryptlib.h:83:0,
                 from /usr/include/cryptopp/randpool.h:4,
                 from /usr/include/cryptopp/osrng.h:10,
                 from fs/common/credentials.h:6,
                 from baseutils/src/cc/securitymodule.c:2:
/usr/include/cryptopp/stdcpp.h:14:18: fatal error: memory: No such file or directory
compilation terminated.
In file included from /usr/include/cryptopp/osrng.h:6:0,
                 from fs/common/credentials.h:6,
                 from baseutils/src/cc/securitymodule.c:2:
/usr/include/cryptopp/config.h:97:1: error: unknown type name 'namespace'
/usr/include/cryptopp/config.h:97:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token
In file included from /usr/include/cryptopp/cryptlib.h:83:0,
                 from /usr/include/cryptopp/randpool.h:4,
                 from /usr/include/cryptopp/osrng.h:10,
                 from fs/common/credentials.h:6,
                 from baseutils/src/cc/securitymodule.c:2:
/usr/include/cryptopp/stdcpp.h:14:18: fatal error: memory: No such file or directory
compilation terminated.