Integrate adding files with the file manager
[anjuta-git-plugin.git] / global-tags / tm_global_tags.c
blobb35673e7ce9b2aea4a324d723b5cc3a5f3863cdd
1 #include "stdlib.h"
2 #include "tm_tagmanager.h"
4 static char *pre_process = "gcc -E -dD -p";
5 int main(int argc, char **argv)
7 if (argc > 2)
9 /* Create global taglist */
10 int status;
11 char *command;
12 command = g_strdup_printf("%s %s", pre_process,
13 NVL(getenv("CFLAGS"), ""));
14 //printf(">%s<\n", command);
15 status = tm_workspace_create_global_tags(command,
16 (const char **) (argv + 2),
17 argc - 2, argv[1]);
18 g_free(command);
19 if (!status)
20 return 1;
22 else
24 fprintf(stderr, "Usage: %s <Tag File> <File list>\n", argv[0]);
25 return 1;
27 return 0;