unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* [brian.schack@usa.net: Need to define 'unix' to compile under OS X?]
@ 2006-11-30  3:21 Richard Stallman
  2006-11-30 14:12 ` YAMAMOTO Mitsuharu
  0 siblings, 1 reply; 2+ messages in thread
From: Richard Stallman @ 2006-11-30  3:21 UTC (permalink / raw)


Someone interested in the Mac might want to do something about this.

------- Start of forwarded message -------
To: bug-gnu-emacs@gnu.org
From: Brian Schack <brian.schack@usa.net>
Date: Wed, 29 Nov 2006 23:18:16 +0800
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Z-USANET-MsgId: XID159kkCPsX0431X36
Subject: Need to define 'unix' to compile under OS X?
X-Spam-Status: No, score=0.1 required=5.0 tests=FORGED_RCVD_HELO 
	autolearn=failed version=3.0.4

I'm running GNU Emacs 22.0.90.1 (i386-apple-darwin8.8.1, X toolkit),
and I noticed a problem while running Gnus.  

Specifically, in nnmaildir-request-accept-article it makes a call to
the unix-sync function.  However, unix-sync is reported as undefined.

It seems the problem lies in fileio.c, where unix-sync is defined.
The definition of unix-sync is bracketed by #ifdef unix.  My guess is
that the symbol 'unix' is not defined when I compile under OS X.  To
test this, I reran configure as follows:

% ./configure ./configure --with-x CPPFLAGS=-Dunix

and things worked okay.

- -- 
Brian Schack		mailto: brian.schack@usa.net
19 X?ch?ng Street 2F	phone:  2381 4727
Taipei 100		fax:    2381 2145
TAIWAN			



_______________________________________________
bug-gnu-emacs mailing list
bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs
------- End of forwarded message -------

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [brian.schack@usa.net: Need to define 'unix' to compile under OS X?]
  2006-11-30  3:21 [brian.schack@usa.net: Need to define 'unix' to compile under OS X?] Richard Stallman
@ 2006-11-30 14:12 ` YAMAMOTO Mitsuharu
  0 siblings, 0 replies; 2+ messages in thread
From: YAMAMOTO Mitsuharu @ 2006-11-30 14:12 UTC (permalink / raw)
  Cc: emacs-devel

>>>>> On Wed, 29 Nov 2006 22:21:05 -0500, Richard Stallman <rms@gnu.org> said:

> Someone interested in the Mac might want to do something about this.

How about introducing HAVE_SYNC?

				     YAMAMOTO Mitsuharu
				mituharu@math.s.chiba-u.ac.jp
Index: configure.in
===================================================================
RCS file: /cvsroot/emacs/emacs/configure.in,v
retrieving revision 1.419
diff -c -r1.419 configure.in
*** configure.in	26 Nov 2006 22:16:17 -0000	1.419
--- configure.in	30 Nov 2006 14:01:26 -0000
***************
*** 2489,2495 ****
  utimes setrlimit setpgid getcwd getwd shutdown getaddrinfo \
  __fpending mblen mbrlen mbsinit strsignal setitimer ualarm index rindex \
  sendto recvfrom getsockopt setsockopt getsockname getpeername \
! gai_strerror mkstemp getline getdelim mremap memmove fsync bzero \
  memset memcmp difftime memcpy mempcpy mblen mbrlen posix_memalign)
  
  AC_CHECK_HEADERS(sys/un.h)
--- 2489,2495 ----
  utimes setrlimit setpgid getcwd getwd shutdown getaddrinfo \
  __fpending mblen mbrlen mbsinit strsignal setitimer ualarm index rindex \
  sendto recvfrom getsockopt setsockopt getsockname getpeername \
! gai_strerror mkstemp getline getdelim mremap memmove fsync sync bzero \
  memset memcmp difftime memcpy mempcpy mblen mbrlen posix_memalign)
  
  AC_CHECK_HEADERS(sys/un.h)
Index: src/fileio.c
===================================================================
RCS file: /cvsroot/emacs/emacs/src/fileio.c,v
retrieving revision 1.575
diff -c -r1.575 fileio.c
*** src/fileio.c	21 Nov 2006 01:34:30 -0000	1.575
--- src/fileio.c	30 Nov 2006 14:02:32 -0000
***************
*** 3541,3551 ****
    return Qt;
  }
  \f
! #ifdef __NetBSD__
! #define unix 42
! #endif
! 
! #ifdef unix
  DEFUN ("unix-sync", Funix_sync, Sunix_sync, 0, 0, "",
         doc: /* Tell Unix to finish all pending disk updates.  */)
       ()
--- 3541,3547 ----
    return Qt;
  }
  \f
! #ifdef HAVE_SYNC
  DEFUN ("unix-sync", Funix_sync, Sunix_sync, 0, 0, "",
         doc: /* Tell Unix to finish all pending disk updates.  */)
       ()
***************
*** 3554,3560 ****
    return Qnil;
  }
  
! #endif /* unix */
  
  DEFUN ("file-newer-than-file-p", Ffile_newer_than_file_p, Sfile_newer_than_file_p, 2, 2, 0,
         doc: /* Return t if file FILE1 is newer than file FILE2.
--- 3550,3556 ----
    return Qnil;
  }
  
! #endif /* HAVE_SYNC */
  
  DEFUN ("file-newer-than-file-p", Ffile_newer_than_file_p, Sfile_newer_than_file_p, 2, 2, 0,
         doc: /* Return t if file FILE1 is newer than file FILE2.
***************
*** 6793,6799 ****
    defsubr (&Sread_file_name);
    defsubr (&Snext_read_file_uses_dialog_p);
  
! #ifdef unix
    defsubr (&Sunix_sync);
  #endif
  }
--- 6789,6795 ----
    defsubr (&Sread_file_name);
    defsubr (&Snext_read_file_uses_dialog_p);
  
! #ifdef HAVE_SYNC
    defsubr (&Sunix_sync);
  #endif
  }

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2006-11-30 14:12 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-11-30  3:21 [brian.schack@usa.net: Need to define 'unix' to compile under OS X?] Richard Stallman
2006-11-30 14:12 ` YAMAMOTO Mitsuharu

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).