/* osmo-cc-router main * * (C) 2020 by Andreas Eversberg * All Rights Reserved * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #include #include #include #include #include #include #include #include #include "../libdebug/debug.h" #include "../liboptions/options.h" #include "../libg711/g711.h" #include "call.h" #include "audio.h" #include "display.h" int show_help = 0; int num_kanal = 1; static osmo_cc_endpoint_t *cc_ep1 = NULL, *cc_ep2 = NULL; static char *routing_script = "~/.osmocom/router/routing.sh"; static char *routing_shell = "bash"; #define MAX_CC_ARGS 1024 static int cc_argc1 = 0, cc_argc2 = 0; static const char *cc_argv1[MAX_CC_ARGS], *cc_argv2[MAX_CC_ARGS]; static void print_usage(const char *app) { printf("Usage: %s []\n", app); } static void print_help() { /* - - */ printf(" -h --help\n"); printf(" This help\n"); printf(" --config [~/]\n"); printf(" Give a config file to use. If it starts with '~/', path is at home dir.\n"); printf(" Each line in config file is one option, '-' or '--' must not be given!\n"); debug_print_help(); printf(" -r --routing-script