在 Linux Red Hat 机器上编译 pro c 程序时出错。错误代码 - PCC-S-02014

问题描述 投票:0回答:1

我正在尝试在 Red Hat 版本 8 机器上编译 proc c 程序。 GCC版本是8.5.0,我的Oracle客户端版本是19.0。当我编译程序时,出现以下错误。请帮忙。我尝试添加解析但没有成功。

编译程序时,出现以下错误。

System default option values taken from: /u01/app/oracle/product/19.0.0/client_1/precomp/admin/pcscfg.cfg

Syntax error at line 166, column 45, file /usr/include/sys/cdefs.h:
Error at line 166, column 45 in file /usr/include/sys/cdefs.h
#define __glibc_fortify(f, __l, __s, __osz, ...) \
............................................1
PCC-S-02014, Encountered the symbol "..." when expecting one of the following:

   an identifier, define, elif, else, endif, error, if, ifdef,
   ifndef, include, include_next, line, pragma, undef, exec,
   sql, begin, end, var, type, oracle,
   an immediate preprocessor command, a C token, create,
   function, package, procedure, trigger, or, replace,

Syntax error at line 168, column 9, file /usr/include/sys/cdefs.h:
Error at line 168, column 9 in file /usr/include/sys/cdefs.h
   ? __ ## f ## _alias (__VA_ARGS__)                                          \
........1

PCC-S-02201, Encountered the symbol "__uint8_t" when expecting one of the follow
ing:

   auto, char, const, double, enum, float, int, long,
   ulong_varchar, OCIBFileLocator OCIBlobLocator,
   OCIClobLocator, OCIDateTime, OCIExtProcContext, OCIInterval,
   OCIRowid, OCIDate, OCINumber, OCIRaw, OCIString, register,

   short, signed, sql_context, sql_cursor, static, struct,
   union, unsigned, utext, uvarchar, varchar, void, volatile,
   a typedef name,
The symbol "enum," was substituted for "__uint8_t" to continue.

Syntax error at line 53, column 9, file /usr/include/bits/types.h:
Error at line 53, column 9 in file /usr/include/bits/types.h
typedef __int16_t __int_least16_t;
........1

   char, const, double, enum, float, int, long, ulong_varchar,
   OCIBFileLocator OCIBlobLocator, OCIClobLocator, OCIDateTime,
   OCIExtProcContext, OCIInterval, OCIRowid, OCIDate, OCINumber,
   OCIRaw, OCIString, short, signed, sql_context, sql_cursor,
   struct, union, unsigned, utext, uvarchar, varchar, void,
   volatile, a typedef name,

Error at line 0, column 0 in file /home/Functions.pc
PCC-F-02102, Fatal error while doing C preprocessing
There are compilation errors step1!!
gcc rhel oracleclient
1个回答
0
投票

看起来 glibc 中

__builtin_dynamic_object_size
的向后移植错过了这个提交:

commit 2337e04e21ba6040926ec871e403533f77043c40
Author: Siddhesh Poyarekar <[email protected]>
Date:   Thu Feb 2 07:49:02 2023 -0500

    cdefs: Limit definition of fortification macros
    
    Define the __glibc_fortify and other macros only when __FORTIFY_LEVEL >
    0.  This has the effect of not defining these macros on older C90
    compilers that do not have support for variable length argument lists.
    
    Also trim off the trailing backslashes from the definition of
    __glibc_fortify and __glibc_fortify_n macros.
    
    Signed-off-by: Siddhesh Poyarekar <[email protected]>
    Reviewed-by: Florian Weimer <[email protected]>

我将此报告为:

您也可以向红帽客户支持报告此问题,特别是如果您需要带有修复程序的测试版本。

© www.soinside.com 2019 - 2024. All rights reserved.