[ZBX-22313] ./configure not working with -std=c99 Created: 2023 Feb 07  Updated: 2024 Apr 10  Resolved: 2023 Feb 23

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Documentation (D)
Affects Version/s: 6.4.0beta6
Fix Version/s: 7.0 (plan)

Type: Documentation task Priority: Trivial
Reporter: Jurijs Klopovskis Assignee: Marina Generalova
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File image-2023-02-20-21-21-20-353.png     PNG File image-2023-02-20-21-22-12-978.png    
Issue Links:
Sub-task
Team: Team A
Sprint: Sprint 97 (Feb 2023)
Story Points: 0.25

 Description   

Set -std=c99

export CFLAGS=-std=c99

Running ./confiugure results in

./configure --enable-agent
...
checking for library containing backtrace_symbols... none required
checking for library containing jail_getname... no
checking for main in -lm... yes
checking for main in -lkvm... no
checking for DNS lookup functions... yes
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... no
checking for an ANSI C-conforming const... yes
checking for pid_t... yes
checking for socklen_t... yes
checking for actual socklen_t parameter type in socket functions... socklen_t
checking for integer field name in union sigval of struct siginfo_t... configure: error: Unable to find integer field name in union sigval of struct siginfo_t


 Comments   
Comment by Vladislavs Sokurenko [ 2023 Feb 16 ]

-std=c99 is not supported, following should do the trick if cannot be compiled with -std=c89

export CFLAGS="-std=gnu99"

 

Comment by King [ 2023 Feb 20 ]

Hi,I encountered the same problem, after I executed make install, the system reported an error

This is my deployment environment。

 

Please help me to see how can I solve this problem, thanks

Comment by Vladislavs Sokurenko [ 2023 Feb 20 ]

Please try with export CFLAGS="-std=gnu99"

Comment by King [ 2023 Feb 20 ]

1. Execute compilation
./configure --prefix=/usr/local/zabbix --enable-server --enable-agent --with-mysql=/usr/bin/mysql_config --enable-ipv6 --with-net-snmp --with -libcurl --with-libxml2
2. make install export CFLAGS="-std=gnu99"
Is this correct? Thanks

Comment by Vladislavs Sokurenko [ 2023 Feb 20 ]

Please try:
CFLAGS="-std=gnu99" ./configure --prefix=/usr/local/zabbix --enable-server --enable-agent --with-mysql=/usr/bin/mysql_config --enable-ipv6 --with-net-snmp --with -libcurl --with-libxml2

Or just this as first step:
export CFLAGS="-std=gnu99"

Comment by King [ 2023 Feb 20 ]

This solved my problem very well, Thank you so much。

Comment by Marina Generalova [ 2023 Feb 21 ]

Documentation updated:

Installation from sources in 6.0, 6.2, 6.4.

Generated at Tue Apr 01 04:04:32 EEST 2025 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.