public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andreas Jaeger <aj@suse.de>
To: Daniel Phillips <phillips@innominate.de>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Compile dnotify example w/o glibc 2.2 headers
Date: 24 Jan 2001 11:12:57 +0100	[thread overview]
Message-ID: <hoy9w1xnpy.fsf@gee.suse.de> (raw)
In-Reply-To: <01012410434304.16618@gimli>
In-Reply-To: <01012410434304.16618@gimli> (Daniel Phillips's message of "Wed, 24 Jan 2001 10:27:54 +0100")

Daniel Phillips <phillips@innominate.de> writes:

> <plug>dnotify is cool, check it out</plug>
> 
> If you want to compile the example in Documentation/dnotify.txt and
> you don't have glibc 2.2 headers installed you have 3 choices:
> 
>   1) Upgrade to glibc 2.2
>   2) Hunt for the missing symbols in the 2.4 source tree
>   3) Apply this patch
> 
> Option (1) is recommended of course, but if you're lazy (like me)
> then...
> 
> --- 2.4.0/Documentation/dnotify.txt~	Mon Jan 22 16:04:32 2001
> +++ 2.4.0/Documentation/dnotify.txt	Mon Jan 22 16:04:25 2001
> @@ -63,6 +63,17 @@
>  	#include <stdio.h>
>  	#include <unistd.h>
>  	
> +	#ifndef F_NOTIFY 	/* pre-glibc 2.2? */

If you're checking for glibc 2.2 or newer, better use:
#if __GLIBC__ == 2 && __GLIBC_MINOR__ >= 2

Andreas
> +	#define F_NOTIFY	1026
> +	#define DN_ACCESS	0x00000001	/* File accessed */
> +	#define DN_MODIFY	0x00000002	/* File modified */
> +	#define DN_CREATE	0x00000004	/* File created */
> +	#define DN_DELETE	0x00000008	/* File removed */
> +	#define DN_RENAME	0x00000010	/* File renamed */
> +	#define DN_ATTRIB	0x00000020	/* File changed attibutes */
> +	#define DN_MULTISHOT	0x80000000	/* Don't remove notifier */
> +	#endif
> +
>  	static volatile int event_fd;
>  	
>  	static void handler(int sig, siginfo_t *si, void *data)

-- 
 Andreas Jaeger
  SuSE Labs aj@suse.de
   private aj@arthur.inka.de
    http://www.suse.de/~aj
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

      reply	other threads:[~2001-01-24 10:13 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-01-24  9:27 [PATCH] Compile dnotify example w/o glibc 2.2 headers Daniel Phillips
2001-01-24 10:12 ` Andreas Jaeger [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=hoy9w1xnpy.fsf@gee.suse.de \
    --to=aj@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=phillips@innominate.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox