perf tools: Convert parse-options.c internal functions to static
authorJosh Poimboeuf <jpoimboe@redhat.com>
Mon, 14 Dec 2015 04:18:12 +0000 (22:18 -0600)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 14 Dec 2015 15:33:01 +0000 (12:33 -0300)
Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/c027b5f47ec1055077f5650edb1c7ad37c191e6c.1449965119.git.jpoimboe@redhat.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/parse-options.c
tools/perf/util/parse-options.h

index de3290b47db1a0d28c8ece603b1fcc35a19926c4..14b2bee81e755213c8f7a02d23dfa47401dadfcb 100644 (file)
@@ -360,8 +360,8 @@ static void check_typos(const char *arg, const struct option *options)
        }
 }
 
-void parse_options_start(struct parse_opt_ctx_t *ctx,
-                        int argc, const char **argv, int flags)
+static void parse_options_start(struct parse_opt_ctx_t *ctx,
+                               int argc, const char **argv, int flags)
 {
        memset(ctx, 0, sizeof(*ctx));
        ctx->argc = argc - 1;
@@ -378,9 +378,9 @@ static int usage_with_options_internal(const char * const *,
                                       const struct option *, int,
                                       struct parse_opt_ctx_t *);
 
-int parse_options_step(struct parse_opt_ctx_t *ctx,
-                      const struct option *options,
-                      const char * const usagestr[])
+static int parse_options_step(struct parse_opt_ctx_t *ctx,
+                             const struct option *options,
+                             const char * const usagestr[])
 {
        int internal_help = !(ctx->flags & PARSE_OPT_NO_INTERNAL_HELP);
        int excl_short_opt = 1;
@@ -489,7 +489,7 @@ exclusive:
        return PARSE_OPT_HELP;
 }
 
-int parse_options_end(struct parse_opt_ctx_t *ctx)
+static int parse_options_end(struct parse_opt_ctx_t *ctx)
 {
        memmove(ctx->out + ctx->cpidx, ctx->argv, ctx->argc * sizeof(*ctx->out));
        ctx->out[ctx->cpidx + ctx->argc] = NULL;
@@ -717,9 +717,9 @@ static bool option__in_argv(const struct option *opt, const struct parse_opt_ctx
        return false;
 }
 
-int usage_with_options_internal(const char * const *usagestr,
-                               const struct option *opts, int full,
-                               struct parse_opt_ctx_t *ctx)
+static int usage_with_options_internal(const char * const *usagestr,
+                                      const struct option *opts, int full,
+                                      struct parse_opt_ctx_t *ctx)
 {
        struct option *ordered;
 
index a8e407bc251e418df2e04623bec08c9de9f5a6cb..dd1236d4990343349d3e025c86390e2c52799748 100644 (file)
@@ -195,15 +195,6 @@ extern int parse_options_usage(const char * const *usagestr,
                               const char *optstr,
                               bool short_opt);
 
-extern void parse_options_start(struct parse_opt_ctx_t *ctx,
-                               int argc, const char **argv, int flags);
-
-extern int parse_options_step(struct parse_opt_ctx_t *ctx,
-                             const struct option *options,
-                             const char * const usagestr[]);
-
-extern int parse_options_end(struct parse_opt_ctx_t *ctx);
-
 
 /*----- some often used options -----*/
 extern int parse_opt_abbrev_cb(const struct option *, const char *, int);
This page took 0.031446 seconds and 5 git commands to generate.