git/list[1] front-page[2] threads[3] people[4] search[5] about
 

daemon.c broken on OpenBSD

From
Randal L. Schwartz <merlyn@stonehenge.com>
Date
Oct 24, 2005, 04:06 UTC
Message-ID
<867jc336f4.fsf@blue.stonehenge.com>
Wow.
    gcc -o daemon.o -c -g -O2 -Wall -I/usr/local/include -L/usr/local/lib -Dstrcasestr=gitstrcasestr -DNO_STRCASESTR=1 -DSHA1_HEADER='<openssl/sha.h>' daemon.c
    In file included from /usr/include/sys/poll.h:54,
                     from daemon.c:7:
    /usr/include/ctype.h:67: error: syntax error before ']' token
    /usr/include/ctype.h:68: error: syntax error before ']' token
    /usr/include/ctype.h:70: error: syntax error before ']' token
    /usr/include/ctype.h:75: error: syntax error before ']' token
    /usr/include/ctype.h:78: error: syntax error before '(' token
    /usr/include/ctype.h:79: error: syntax error before '(' token
    /usr/include/ctype.h:93: error: syntax error before "c"
    In file included from /usr/include/sys/poll.h:54,
                     from daemon.c:7:
    /usr/include/ctype.h:91:1: unterminated #if
    /usr/include/ctype.h:40:1: unterminated #ifndef
    In file included from daemon.c:7:
    /usr/include/sys/poll.h:53:1: unterminated #ifndef
    /usr/include/sys/poll.h:28:1: unterminated #ifndef
    gmake: *** [daemon.o] Error 1

Apparently something in the early lines of daemon.c (before line 7) is defining something that breaks the core /usr/include/ctype.h.

Lines 66 to 68 of ctype.h look like:
    #if defined(__GNUC__) || defined(_ANSI_LIBRARY) || defined(lint)
    int	isalnum(int);
    int	isalpha(int);

If that rings a bell, help me out here. I'm guessing "isalnum" is getting defined (wrongly). Yeah, looks like in cache.h. Why is this getting defined?

-- 
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!
Next: Junio C Hamano
Message 1 of 16 in “daemon.c broken on OpenBSD”
  1. Randal L. SchwartzOct 24, 2005
  2. Junio C HamanoOct 24, 2005
  3. Matthias UrlichsOct 24, 2005
  4. Randal L. SchwartzOct 25, 2005
  5. Randal L. SchwartzOct 25, 2005
  6. Randal L. SchwartzOct 25, 2005
  7. Linus TorvaldsOct 24, 2005
  8. Randal L. SchwartzOct 24, 2005
  9. Linus TorvaldsOct 24, 2005
  10. H. Peter AnvinOct 24, 2005
  11. Linus TorvaldsOct 24, 2005
  12. H. Peter AnvinOct 24, 2005
  13. Linus TorvaldsOct 24, 2005
  14. H. Peter AnvinOct 24, 2005
  15. Morten WelinderOct 24, 2005
  16. Junio C HamanoOct 24, 2005

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.