Updated Swedish translation
[anjuta.git] / plugins / am-project / ac-scanner.h
blob379c6acd968e58754be2458dc8388bdb8a017be2
1 /* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */
2 /*
3 * ac-scanner.h
4 * Copyright (C) Sébastien Granjoux 2009 <seb.sfo@free.fr>
6 * main.c is free software: you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License as published by the
8 * Free Software Foundation, either version 3 of the License, or
9 * (at your option) any later version.
11 * main.c is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
14 * See the GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License along
17 * with this program. If not, see <http://www.gnu.org/licenses/>.
20 #ifndef _AC_SCANNER_H_
21 #define _AC_SCANNER_H_
23 #include "am-project.h"
25 #include <glib.h>
26 #include <gio/gio.h>
28 G_BEGIN_DECLS
30 /* Token location is found directly from token value. We don't maintain a
31 * independent position. */
32 #define YYLTYPE AnjutaToken*
33 #define YYSTYPE AnjutaToken*
35 typedef struct _AmpAcScanner AmpAcScanner;
37 AmpAcScanner *amp_ac_scanner_new (AmpProject *project);
38 void amp_ac_scanner_free (AmpAcScanner *scanner);
40 gboolean amp_ac_scanner_parse (AmpAcScanner *scanner, AnjutaTokenFile *file, GError **error);
41 AnjutaToken* amp_ac_scanner_parse_token (AmpAcScanner *scanner, AnjutaToken *root, AnjutaToken *content, gint start, GFile *filename, GError **error);
43 void amp_ac_scanner_load_module (AmpAcScanner *scanner, AnjutaToken *module);
44 void amp_ac_scanner_load_config (AmpAcScanner *scanner, AnjutaToken *list);
45 void amp_ac_scanner_load_properties (AmpAcScanner *scanner, AnjutaToken *macro, AnjutaToken *args);
46 void amp_ac_scanner_include (AmpAcScanner *scanner, AnjutaToken *list);
47 void amp_ac_scanner_update_variable (AmpAcScanner *scanner, AnjutaToken *variable);
48 void amp_ac_scanner_subst_variable (AmpAcScanner *scanner, AnjutaToken *list);
50 void amp_ac_yyerror (YYLTYPE *loc, AmpAcScanner *scanner, char const *s);
52 enum
54 /* Order is important as the backend will try to follow it */
55 AC_TOKEN_FIRST_ORDERED_MACRO = ANJUTA_TOKEN_USER,
56 /* requirements & informations */
57 AC_TOKEN_AC_PREREQ,
58 AC_TOKEN_AC_INIT,
59 AC_TOKEN_AC_CONFIG_HEADERS,
60 AC_TOKEN_AC_CONFIG_SRCDIR,
61 AC_TOKEN_AC_CONFIG_MACRO_DIR,
62 AC_TOKEN_AM_INIT_AUTOMAKE,
64 /* Options */
65 AC_TOKEN_AM_MAINTAINER_MODE,
66 AC_TOKEN_AC_ARG_ENABLE,
68 /* Check for programs */
69 AC_TOKEN_AC_PROG_CC,
70 AC_TOKEN_AC_PROG_CPP,
71 AC_TOKEN_AC_PROG_CXX,
72 AC_TOKEN_AC_PROG_LEX,
73 AC_TOKEN_AC_PROG_YACC,
74 AC_TOKEN_AC_PROG_RANLIB,
75 AC_TOKEN_IT_PROG_INTLTOOL,
76 AC_TOKEN_LT_PREREQ,
77 AC_TOKEN_LT_INIT,
78 AC_TOKEN_AM_PROG_LIBTOOL,
79 AC_TOKEN_AC_PROG_LIBTOOL,
80 AC_TOKEN_PKG_PROG_PKG_CONFIG,
81 AC_TOKEN_AC_CHECK_PROG,
82 AC_TOKEN_AM_GLIB_GNU_GETTEXT,
84 /* Check for libraries */
85 AC_TOKEN_PKG_CHECK_MODULES,
86 AC_TOKEN_AC_CHECK_LIB,
88 /* Check for headers */
89 AC_TOKEN_AC_HEADER_STDC,
90 AC_TOKEN_AC_CHECK_HEADERS,
91 AC_TOKEN_AC_EGREP_HEADER,
93 /* Check for types & structures */
94 AC_TOKEN_AC_C_CONST,
95 AC_TOKEN_AC_OBJEXT,
96 AC_TOKEN_AC_EXEEXT,
97 AC_TOKEN_AC_TYPE_SIZE_T,
98 AC_TOKEN_AC_TYPE_OFF_T,
100 /* Check for functions */
101 AC_TOKEN_AC_CHECK_FUNCS,
103 /* Output files */
104 AC_TOKEN_AC_CONFIG_FILES,
105 AC_TOKEN_OBSOLETE_AC_OUTPUT,
106 AC_TOKEN_AC_OUTPUT,
107 AC_TOKEN_LAST_ORDERED_MACRO,
109 AC_TOKEN_AC_SUBST,
111 AC_TOKEN_SPACE_LIST,
112 AC_TOKEN_OPEN_STRING,
113 AC_TOKEN_CLOSE_STRING
116 enum
118 AC_SPACE_LIST_STATE = 1
121 G_END_DECLS
123 #endif