buggrep - Bugs: bug #18245, grep does not build on systems...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #18245: grep does not build on systems lacking S_ISSOCK

Submitted by:  Matthew Woehlke <woehlkmp>
Submitted on:  Thu 09 Nov 2006 10:14:51 PM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: NoneStatus: None
Privacy: PublicAssigned to: None
Open/Closed: Closed

Fri 04 Dec 2009 07:25:57 PM UTC, comment #5:

Fixed by gnulibification.

Paolo Bonzini <bonzini>
Sun 13 Jan 2008 06:18:39 AM UTC, comment #4:

Same problem here, using mingw. Grep sources seem to assume that !DJGPP implies the system has S_ISSOCK.

Yevgen Muntyan <muntyan>
Fri 10 Nov 2006 04:02:50 PM UTC, comment #3:

I was thinking more along the lines of doing it in preprocessor (i.e. "assumption" :-) - only for _TANDEM, of course), but I can live with doing it 'by hand'. Although for the sake of full disclosure, given that I usually find out I need it after-the-fact, and ./configure runs tend to take hours, I'm probably going to stick to dropping it in headers as needed.

What about HAVE_STRDUP; any thoughts? That seems like an assumption that often goes wrong; I think grep is the third package I've had to take that out of config.h.

Matthew Woehlke <woehlkmp>
Fri 10 Nov 2006 12:57:31 AM UTC, comment #2:

As a general rule GNU applications do not attempt to set feature-test macros like _XOPEN_SOURCE_EXTENDED and _XOPEN_SOURCE. We tried doing that a while ago, but it was a maintenance nightmare. If you need that sort of thing for an unusual platform, you can set it in CPPFLAGS when you call 'configure'. But please don't expect 'configure' to automatically deduce it for you.

Paul Eggert <eggert>
Project Member
Thu 09 Nov 2006 10:21:41 PM UTC, comment #1:

Oops, problem is that _XOPEN_SOURCE_EXTENDED=1 must be defined for sys/stat.h to pick up S_ISSOCK and _S_IFSOCK.

Matthew Woehlke <woehlkmp>
Thu 09 Nov 2006 10:14:51 PM UTC, original submission:

Building grep on Tandem NSK/OSS fails, as S_ISSOCK is not defined.

Solution:
#ifndef S_ISSOCK
# define S_ISSOCK(mode) (((mode) & S_IFMT) == S_IFSOCK)
#endif

(As an aside, config.h incorrectly defines HAVE_STRDUP, which OSS does not.)

Matthew Woehlke <woehlkmp>

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by bonzini (Posted a comment)
  • -unavailable- added by muntyan (Posted a comment)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follows 1 latest change.

    Date Changed By Updated Field Previous Value => Replaced By
    Fri 04 Dec 2009 07:25:57 PM UTCbonziniOpen/ClosedOpen=>Closed

    Back to the top


    Powered by Savane 3.1-cleanup1