Code cleanup for cygw32
[bpt/emacs.git] / src / cygw32.h
CommitLineData
f701ab72 1/* Header for Cygwin support routines.
245dc6da 2 Copyright (C) 2011-2012 Free Software Foundation, Inc.
f701ab72
DC
3
4This file is part of GNU Emacs.
5
6GNU Emacs is free software: you can redistribute it and/or modify
7it under the terms of the GNU General Public License as published by
8the Free Software Foundation, either version 3 of the License, or
9(at your option) any later version.
10
11GNU Emacs is distributed in the hope that it will be useful,
12but WITHOUT ANY WARRANTY; without even the implied warranty of
13MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14GNU General Public License for more details.
15
16You should have received a copy of the GNU General Public License
17along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
18
19#ifndef CYGW32_H
20#define CYGW32_H
21#include <config.h>
22#include <windef.h>
23#include <sys/cygwin.h>
24#include <wchar.h>
25
26#include <signal.h>
27#include <stdio.h>
28#include <limits.h>
29#include <errno.h>
30#include <math.h>
31#include <setjmp.h>
32
33#include "lisp.h"
34#include "coding.h"
35
36/* *** Character conversion *** */
37
38/* Access the wide-character string stored in a Lisp string object. */
39#define WCSDATA(x) ((wchar_t *) SDATA (x))
40
bb84afd5
EZ
41/* Convert the multi-byte string in STR to UTF-16LE encoded unibyte
42 string, and store it in *BUF. BUF may safely point to STR on entry. */
f701ab72
DC
43extern wchar_t *to_unicode (Lisp_Object str, Lisp_Object *buf);
44
bb84afd5
EZ
45/* Convert STR, a UTF-16LE encoded string embedded in a unibyte string
46 object, to a multi-byte Emacs string, and return it. */
f701ab72
DC
47extern Lisp_Object from_unicode (Lisp_Object str);
48
f701ab72
DC
49/* *** Misc *** */
50extern void syms_of_cygw32 (void);
51extern char * w32_strerror (int error_no);
52
53#endif /* CYGW32_H */