| * along with this program; if not, see: <http://www.gnu.org/licenses/>. | * along with this program; if not, see: <http://www.gnu.org/licenses/>. | ||||
| */ | */ | ||||
| #include "config.h" | |||||
| #include <errno.h> | #include <errno.h> | ||||
| #include <stdbool.h> | #include <stdbool.h> | ||||
| #include <stdio.h> | #include <stdio.h> | ||||
| #include <stdlib.h> | #include <stdlib.h> | ||||
| #include <string.h> | #include <string.h> | ||||
| #include <ctype.h> | #include <ctype.h> | ||||
| #ifndef NEED_GETOPT | |||||
| #ifdef HAVE_GETOPT_H | |||||
| #include <getopt.h> | #include <getopt.h> | ||||
| #endif | #endif | ||||
| #include <time.h> | #include <time.h> | ||||
| printf("eSpeak text-to-speech: %s Data at: %s\n", version, path_data); | printf("eSpeak text-to-speech: %s Data at: %s\n", version, path_data); | ||||
| } | } | ||||
| #ifdef NEED_GETOPT | |||||
| #ifndef HAVE_GETOPT_H | |||||
| struct option { | struct option { | ||||
| char *name; | char *name; | ||||
| int has_arg; | int has_arg; | ||||
| devicename[0] = 0; | devicename[0] = 0; | ||||
| option_punctlist[0] = 0; | option_punctlist[0] = 0; | ||||
| #ifdef NEED_GETOPT | |||||
| #ifndef HAVE_GETOPT_H | |||||
| optind = 1; | optind = 1; | ||||
| opt_string = ""; | opt_string = ""; | ||||
| while (optind < argc) { | while (optind < argc) { |
| #endif | #endif | ||||
| #ifdef __QNX__ | #ifdef __QNX__ | ||||
| #define NEED_GETOPT | |||||
| #define NO_VARIADIC_MACROS | #define NO_VARIADIC_MACROS | ||||
| #endif | #endif | ||||
| #define PLATFORM_WINDOWS | #define PLATFORM_WINDOWS | ||||
| #define PATHSEP '\\' | #define PATHSEP '\\' | ||||
| #define NEED_GETOPT | |||||
| #define NO_VARIADIC_MACROS | #define NO_VARIADIC_MACROS | ||||
| #else | #else |
| #endif | #endif | ||||
| #endif | #endif | ||||
| #ifndef NEED_GETOPT | |||||
| #ifdef HAVE_GETOPT_H | |||||
| #include <getopt.h> | #include <getopt.h> | ||||
| #endif | #endif | ||||
| #include <time.h> | #include <time.h> | ||||
| return finished; | return finished; | ||||
| } | } | ||||
| #ifdef NEED_GETOPT | |||||
| #ifndef HAVE_GETOPT_H | |||||
| struct option { | struct option { | ||||
| char *name; | char *name; | ||||
| int has_arg; | int has_arg; | ||||
| option_multibyte = espeakCHARS_AUTO; | option_multibyte = espeakCHARS_AUTO; | ||||
| f_trans = stdout; | f_trans = stdout; | ||||
| #ifdef NEED_GETOPT | |||||
| #ifndef HAVE_GETOPT_H | |||||
| optind = 1; | optind = 1; | ||||
| opt_string = ""; | opt_string = ""; | ||||
| while (optind < argc) { | while (optind < argc) { |