GmSSL icon indicating copy to clipboard operation
GmSSL copied to clipboard

下载新的版本,编译报错---mac下

Open sslvpn007 opened this issue 9 years ago • 4 comments

crypto/saf/saf_ec.c:477:23: error: expected ';' after return statement return SAR_IndataErr); ^ ; crypto/saf/saf_ec.c:479:31: error: use of undeclared identifier 'uiCertificate'; did you mean 'pucCertificate'? if (uiCertificateLen <= 0 || uiCertificate > INT_MAX) { ^~~~~~~~~~~~~ pucCertificate crypto/saf/saf_ec.c:461:17: note: 'pucCertificate' declared here unsigned char *pucCertificate, ^ crypto/saf/saf_ec.c:479:45: warning: ordered comparison between pointer and integer ('unsigned char *' and 'int') if (uiCertificateLen <= 0 || uiCertificate > INT_MAX) { ~~~~~~~~~~~~~ ^ ~~~~~~~ crypto/saf/saf_ec.c:550:23: error: expected ';' after return statement return SAR_IndataErr); ^ ; crypto/saf/saf_ec.c:552:31: error: use of undeclared identifier 'uiCertificate'; did you mean 'pucCertificate'? if (uiCertificateLen <= 0 || uiCertificate > INT_MAX) { ^~~~~~~~~~~~~ pucCertificate crypto/saf/saf_ec.c:461:17: note: 'pucCertificate' declared here unsigned char *pucCertificate, ^ fatal error: too many errors emitted, stopping now [-ferror-limit=] 5 warnings and 20 errors generated. make[1]: *** [crypto/saf/saf_ec.o] Error 1 make: *** [all] Error 2 bash-3.2$

sslvpn007 avatar Feb 20 '17 02:02 sslvpn007

在linux下 也编译出错:

[root@MAASG GmSSL-master]# ./config --prefix=/usr/local Operating system: i686-whatever-linux2 perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LANGUAGE = (unset), LC_ALL = (unset), LANG = "zh_CN:GB18030" are supported and installed on your system. perl: warning: Falling back to the standard locale ("C"). perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LANGUAGE = (unset), LC_ALL = (unset), LANG = "zh_CN:GB18030" are supported and installed on your system. perl: warning: Falling back to the standard locale ("C"). Perl v5.10.0 required--this is only v5.8.5, stopped at ./Configure line 12. perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LANGUAGE = (unset), LC_ALL = (unset), LANG = "zh_CN:GB18030" are supported and installed on your system. perl: warning: Falling back to the standard locale ("C"). Perl v5.10.0 required--this is only v5.8.5, stopped at ./Configure line 12. This system (linux-x86) is not supported. See file INSTALL for details.

sslvpn007 avatar Feb 20 '17 05:02 sslvpn007

./config no-saf no-sdf no-skf no-sof no-zuc

guanzhi avatar Feb 20 '17 12:02 guanzhi

@guanzhi 在windows下面编译最新的代码也出错: 环境:64位win10 version: 1607,msys2更新到最新,gcc version: 6.3.0, 编译命令: ./config no-saf no-sdf no-skf no-sof no-zuc make 错误: ///////////////////////////////////////////////////////////////////////////////////////////////////// D:/Development/msys2/mingw32/i686-w64-mingw32/include/minwindef.h:24:29: error: conflicting types for 'ULONG' typedef unsigned __LONG32 ULONG; ^~~~~ In file included from include/openssl/gmapi.h:63:0, from crypto/gmapi/gmapi_skf_ec.c:52: include/openssl/skf.h:93:18: note: previous declaration of 'ULONG' was here typedef UINT32 ULONG; ^~~~~ In file included from D:/Development/msys2/mingw32/i686-w64-mingw32/include/windef.h:8:0, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/windows.h:69, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/winsock2.h:23, from ./e_os.h:190, from crypto/gmapi/../ec/ec_lcl.h:33, from crypto/gmapi/gmapi_skf_ec.c:54: D:/Development/msys2/mingw32/i686-w64-mingw32/include/minwindef.h:131:15: error: conflicting types for 'BOOL' typedef int BOOL; ^~~~ In file included from include/openssl/gmapi.h:64:0, from crypto/gmapi/gmapi_skf_ec.c:52: include/openssl/sof.h:56:14: note: previous declaration of 'BOOL' was here typedef long BOOL; ^~~~ In file included from D:/Development/msys2/mingw32/i686-w64-mingw32/include/windef.h:8:0, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/windows.h:69, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/winsock2.h:23, from ./e_os.h:190, from crypto/gmapi/../ec/ec_lcl.h:33, from crypto/gmapi/gmapi_skf_ec.c:54: D:/Development/msys2/mingw32/i686-w64-mingw32/include/minwindef.h:141:29: error: conflicting types for 'DWORD' typedef unsigned __LONG32 DWORD; ^~~~~ In file included from include/openssl/gmapi.h:63:0, from crypto/gmapi/gmapi_skf_ec.c:52: include/openssl/skf.h:96:18: note: previous declaration of 'DWORD' was here typedef UINT32 DWORD; ^~~~~ In file included from D:/Development/msys2/mingw32/i686-w64-mingw32/include/minwindef.h:163:0, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/windef.h:8, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/windows.h:69, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/winsock2.h:23, from ./e_os.h:190, from crypto/gmapi/../ec/ec_lcl.h:33, from crypto/gmapi/gmapi_skf_ec.c:54: D:/Development/msys2/mingw32/i686-w64-mingw32/include/winnt.h:278:16: error: conflicting types for 'CHAR' typedef char CHAR; ^~~~ In file included from include/openssl/gmapi.h:63:0, from crypto/gmapi/gmapi_skf_ec.c:52: include/openssl/skf.h:89:17: note: previous declaration of 'CHAR' was here typedef UINT8 CHAR; ^~~~ In file included from D:/Development/msys2/mingw32/i686-w64-mingw32/include/minwindef.h:163:0, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/windef.h:8, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/windows.h:69, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/winsock2.h:23, from ./e_os.h:190, from crypto/gmapi/../ec/ec_lcl.h:33, from crypto/gmapi/gmapi_skf_ec.c:54: D:/Development/msys2/mingw32/i686-w64-mingw32/include/winnt.h:280:20: error: conflicting types for 'LONG' typedef __LONG32 LONG; ^~~~ In file included from include/openssl/gmapi.h:63:0, from crypto/gmapi/gmapi_skf_ec.c:52: include/openssl/skf.h:92:17: note: previous declaration of 'LONG' was here typedef INT32 LONG; ^~~~ In file included from D:/Development/msys2/mingw32/i686-w64-mingw32/include/minwindef.h:163:0, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/windef.h:8, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/windows.h:69, from D:/Development/msys2/mingw32/i686-w64-mingw32/include/winsock2.h:23, from ./e_os.h:190, from crypto/gmapi/../ec/ec_lcl.h:33, from crypto/gmapi/gmapi_skf_ec.c:54: D:/Development/msys2/mingw32/i686-w64-mingw32/include/winnt.h:329:24: error: conflicting types for 'LPSTR' typedef CHAR *NPSTR,*LPSTR,*PSTR; ^~~~~ In file included from include/openssl/gmapi.h:63:0, from crypto/gmapi/gmapi_skf_ec.c:52: include/openssl/skf.h:98:18: note: previous declaration of 'LPSTR' was here typedef CHAR * LPSTR; ^~~~~ make[1]: *** [Makefile:4012: crypto/gmapi/gmapi_skf_ec.o] Error 1 make[1]: Leaving directory '/d/tobia/ClionProjects/GmSSL' make: *** [Makefile:128:all] 错误 2 /////////////////////////////////////////////////////////////////////////////////////////////////

tobiaswang avatar Feb 21 '17 07:02 tobiaswang

Marked as stale issue. Will be closed later if no activity for a while.

github-actions[bot] avatar Oct 11 '20 01:10 github-actions[bot]