1867d7bc83fcd634866e820a33e1251019646693
[apps/madmutt.git] / lib-lib / macros.h
1 /*
2  *  This program is free software; you can redistribute it and/or modify
3  *  it under the terms of the GNU General Public License as published by
4  *  the Free Software Foundation; either version 2 of the License, or (at
5  *  your option) any later version.
6  *
7  *  This program is distributed in the hope that it will be useful, but
8  *  WITHOUT ANY WARRANTY; without even the implied warranty of
9  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
10  *  General Public License for more details.
11  *
12  *  You should have received a copy of the GNU General Public License
13  *  along with this program; if not, write to the Free Software
14  *  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
15  *  MA 02110-1301, USA.
16  *
17  *  Copyright © 2006 Pierre Habouzit
18  */
19
20 #ifndef MUTT_LIB_LIB_MACROS_H
21 #define MUTT_LIB_LIB_MACROS_H
22
23 /*
24  * config.h must be included by source file!
25  */
26
27 #ifdef _
28 #  undef _
29 #endif
30
31 #ifdef ENABLE_NLS
32 #  include <libintl.h>
33 #define _(a)       (gettext(a))
34 #  ifdef gettext_noop
35 #    define N_(a)  gettext_noop(a)
36 #  else
37 #    define N_(a)  (a)
38 #  endif
39 #else
40 #  define _(a)     (a)
41 #  define N_(a)    (a)
42 #endif
43
44
45 #define TRUE 1
46 #define FALSE 0
47
48 #undef MAX
49 #undef MIN
50 #define MAX(a,b) ((a) < (b) ? (b) : (a))
51 #define MIN(a,b) ((a) < (b) ? (a) : (b))
52
53 #endif /* MUTT_LIB_LIB_MACROS_H */