~wibblymat/ubuntu/oneiric/sagan/ftbfs-jam

« back to all changes in this revision

Viewing changes to src/sagan-usage.c

  • Committer: Bazaar Package Importer
  • Author(s): Pierre Chifflier
  • Date: 2011-03-17 15:18:58 UTC
  • Revision ID: james.westby@ubuntu.com-20110317151858-iqvfx0hsxlamxp6b
Tags: upstream-0.1.9~svn129
ImportĀ upstreamĀ versionĀ 0.1.9~svn129

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
** Copyright (C) 2009-2011 Softwink, Inc. 
 
3
** Copyright (C) 2009-2011 Champ Clark III <champ@softwink.com>
 
4
**
 
5
** This program is free software; you can redistribute it and/or modify
 
6
** it under the terms of the GNU General Public License Version 2 as
 
7
** published by the Free Software Foundation.  You may not use, modify or
 
8
** distribute this program under any other version of the GNU General
 
9
** Public License.
 
10
**
 
11
** This program is distributed in the hope that it will be useful,
 
12
** but WITHOUT ANY WARRANTY; without even the implied warranty of
 
13
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
14
** GNU General Public License for more details.
 
15
**
 
16
** You should have received a copy of the GNU General Public License
 
17
** along with this program; if not, write to the Free Software
 
18
** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 
19
*/
 
20
 
 
21
/* sagan-usage
 
22
 *
 
23
 * Gives the user basic operation of the sagan binary.  Also displays 
 
24
 * information of compile time options
 
25
 *
 
26
 */
 
27
 
 
28
#ifdef HAVE_CONFIG_H
 
29
#include "config.h"             /* From autoconf */
 
30
#endif
 
31
 
 
32
#include <stdio.h>
 
33
 
 
34
#include "sagan.h"
 
35
#include "version.h"
 
36
 
 
37
 
 
38
void sagan_usage(void)
 
39
{
 
40
fprintf(stderr, "\n--[Sagan version %s | Help/usage screen]--------------------------------\n\n", VERSION);
 
41
fprintf(stderr, "-h, --help\t\tHelp (this screen).\n");
 
42
fprintf(stderr, "-d, --debug [type]\tTypes: syslog,load");
 
43
 
 
44
#if defined(HAVE_LIBMYSQLCLIENT_R) || defined(HAVE_LIBPQ)
 
45
fprintf(stderr, ", sql");
 
46
#endif
 
47
 
 
48
#ifdef HAVE_LIBESMTP
 
49
fprintf(stderr, ", smtp");
 
50
#endif
 
51
 
 
52
#ifdef HAVE_LIBLOGNORM
 
53
fprintf(stderr, ", normalize");
 
54
#endif
 
55
 
 
56
#ifdef HAVE_LIBPCAP
 
57
fprintf(stderr, ", plog");
 
58
#endif
 
59
 
 
60
fprintf(stderr, ".\n");
 
61
 
 
62
fprintf(stderr, "-D, --daemon\t\tMake process a daemon (fork to the background).\n");
 
63
fprintf(stderr, "-U, --user\t\tRun as user (defaults to 'sagan').\n");
 
64
fprintf(stderr, "-c, --chroot\t\tChroot to username 'sagan's home.\n");
 
65
fprintf(stderr, "-f, --config\t\tSagan configuration file to load.\n");
 
66
fprintf(stderr, "-p, --program\t\tRun Sagan in syslog-ng's 'program' mode.\n\n");
 
67
 
 
68
#ifdef HAVE_LIBPQ
 
69
fprintf(stderr, "* PostgreSQL support is included\n");
 
70
#endif
 
71
 
 
72
#ifdef HAVE_LIBMYSQLCLIENT_R
 
73
fprintf(stderr, "* MySQL support is included\n");
 
74
#endif
 
75
 
 
76
#ifdef HAVE_LIBESMTP
 
77
fprintf(stderr, "* libesmtp (SMTP) support is included\n");
 
78
#endif
 
79
 
 
80
#ifdef HAVE_LIBPRELUDE
 
81
fprintf(stderr, "* Prelude (libprelude) support is included\n");
 
82
#endif
 
83
 
 
84
#ifdef HAVE_LIBLOGNORM
 
85
fprintf(stderr, "* liblognorm (log normalization) support is included\n");
 
86
#endif
 
87
 
 
88
#ifdef HAVE_LIBPCAP
 
89
fprintf(stderr, "* PLOG (syslog sniffer) support is included\n");
 
90
#endif
 
91
 
 
92
}