Browse Source

make all headers (almost) self-contained by using include guards and #include statements within headers

master
Juho Hiltunen 7 years ago
parent
commit
738492100a

+ 1
- 0
src/libespeak-ng/compiledict.c View File

@@ -22,6 +22,7 @@

#include <ctype.h>
#include <errno.h>
#include <stdbool.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>

+ 2
- 0
src/libespeak-ng/error.h View File

@@ -18,6 +18,8 @@
#ifndef ESPEAK_NG_ERROR_API
#define ESPEAK_NG_ERROR_API

#include <espeak-ng/espeak_ng.h>

#ifdef __cplusplus
extern "C"
{

+ 4
- 2
src/libespeak-ng/espeak_command.h View File

@@ -16,8 +16,10 @@
* along with this program; if not, see: <http://www.gnu.org/licenses/>.
*/

#ifndef ESPEAK_COMMAND_H
#define ESPEAK_COMMAND_H
#ifndef ESPEAK_NG_COMMAND_H
#define ESPEAK_NG_COMMAND_H

#include <espeak-ng/espeak_ng.h>

#ifdef __cplusplus
extern "C"

+ 5
- 3
src/libespeak-ng/event.h View File

@@ -16,9 +16,6 @@
* along with this program; if not, see: <http://www.gnu.org/licenses/>.
*/

#ifndef EVENT_H
#define EVENT_H

/*
Manage events (sentence, word, mark, end,...), is responsible of calling the external
callback as soon as the relevant audio sample is played.
@@ -39,6 +36,11 @@

*/

#ifndef ESPEAK_NG_EVENT_H
#define ESPEAK_NG_EVENT_H

#include <espeak-ng/espeak_ng.h>

#ifdef __cplusplus
extern "C"
{

+ 6
- 3
src/libespeak-ng/fifo.h View File

@@ -16,12 +16,15 @@
* along with this program; if not, see: <http://www.gnu.org/licenses/>.
*/

#ifndef FIFO_H
#define FIFO_H

// Helps to add espeak commands in a first-in first-out queue
// and run them asynchronously.

#ifndef ESPEAK_NG_FIFO_H
#define ESPEAK_NG_FIFO_H

#include <espeak-ng/espeak_ng.h>
#include "espeak_command.h"

#ifdef __cplusplus
extern "C"
{

+ 1
- 0
src/libespeak-ng/ieee80.h View File

@@ -42,6 +42,7 @@
* conversions, and accommodated conversions involving +/- infinity,
* NaN's, and denormalized numbers.
*/

#ifndef IEEE_H
#define IEEE_H


+ 8
- 0
src/libespeak-ng/klatt.h View File

@@ -21,6 +21,12 @@
* along with this program; if not, see: <http://www.gnu.org/licenses/>.
*/

#ifndef ESPEAK_NG_KLATT_H
#define ESPEAK_NG_KLATT_H

#include "speech.h"
#include "synthesize.h"

#ifdef __cplusplus
extern "C"
{
@@ -179,3 +185,5 @@ int Wavegen_Klatt2(int length, int resume, frame_t *fr1, frame_t *fr2);
#ifdef __cplusplus
}
#endif

#endif

+ 7
- 0
src/libespeak-ng/phoneme.h View File

@@ -17,6 +17,11 @@
* along with this program; if not, see: <http://www.gnu.org/licenses/>.
*/

#ifndef ESPEAK_NG_PHONEME_H
#define ESPEAK_NG_PHONEME_H

#include <espeak-ng/espeak_ng.h>

#ifdef __cplusplus
extern "C"
{
@@ -291,3 +296,5 @@ extern int phoneme_tab_number;
#ifdef __cplusplus
}
#endif

#endif

+ 5
- 0
src/libespeak-ng/sintab.h View File

@@ -17,6 +17,9 @@
* along with this program; if not, see: <http://www.gnu.org/licenses/>.
*/

#ifndef ESPEAK_NG_SINTAB_H
#define ESPEAK_NG_SINTAB_H

#ifdef __cplusplus
extern "C"
{
@@ -284,3 +287,5 @@ short int sin_tab[2048] = {
#ifdef __cplusplus
}
#endif

#endif

+ 9
- 0
src/libespeak-ng/spect.h View File

@@ -17,6 +17,13 @@
* along with this program; if not, see: <http://www.gnu.org/licenses/>.
*/

#ifndef ESPEAK_NG_SPECT_H
#define ESPEAK_NG_SPECT_H

#include <espeak-ng/espeak_ng.h>
#include "synthesize.h"
#include "speech.h"

#ifdef __cplusplus
extern "C"
{
@@ -133,3 +140,5 @@ espeak_ng_STATUS LoadSpectSeq(SpectSeq *spect, const char *filename);
#ifdef __cplusplus
}
#endif

#endif

+ 4
- 2
src/libespeak-ng/speech.h View File

@@ -17,8 +17,10 @@
* along with this program; if not, see: <http://www.gnu.org/licenses/>.
*/

#ifndef SPEECH_H
#define SPEECH_H
#ifndef ESPEAK_NG_SPEECH_H
#define ESPEAK_NG_SPEECH_H

#include <espeak-ng/espeak_ng.h>

#ifdef __cplusplus
extern "C"

+ 5
- 0
src/libespeak-ng/ssml.h View File

@@ -21,6 +21,11 @@
#ifndef ESPEAK_NG_SSML_API
#define ESPEAK_NG_SSML_API

#include <stdbool.h>
#include <wchar.h>

#include <espeak-ng/speak_lib.h>

#ifdef __cplusplus
extern "C"
{

+ 12
- 1
src/libespeak-ng/synthesize.h View File

@@ -17,13 +17,22 @@
* along with this program; if not, see: <http://www.gnu.org/licenses/>.
*/

#include <stdbool.h>
#ifndef ESPEAK_NG_SYNTHESIZE_H
#define ESPEAK_NG_SYNTHESIZE_H

#include "speech.h"

#ifdef __cplusplus
extern "C"
{
#endif

#include <stdint.h>
#include <stdbool.h>
#include <espeak-ng/espeak_ng.h>
#include "phoneme.h"
#include "voice.h"

#define espeakINITIALIZE_PHONEME_IPA 0x0002 // move this to speak_lib.h, after eSpeak version 1.46.02

#define N_PHONEME_LIST 1000 // enough for source[N_TR_SOURCE] full of text, else it will truncate
@@ -559,3 +568,5 @@ void InitBreath(void);
#ifdef __cplusplus
}
#endif

#endif

+ 12
- 0
src/libespeak-ng/translate.h View File

@@ -17,6 +17,16 @@
* along with this program; if not, see: <http://www.gnu.org/licenses/>.
*/

#ifndef ESPEAK_NG_TRANSLATE_H
#define ESPEAK_NG_TRANSLATE_H

#include <stdbool.h>

#include <espeak-ng/espeak_ng.h>
#include <espeak-ng/encoding.h>

#include "synthesize.h"

#ifdef __cplusplus
extern "C"
{
@@ -784,3 +794,5 @@ extern FILE *f_trans; // for logging
#ifdef __cplusplus
}
#endif

#endif

+ 9
- 0
src/libespeak-ng/voice.h View File

@@ -17,6 +17,13 @@
* along with this program; if not, see: <http://www.gnu.org/licenses/>.
*/

#ifndef ESPEAK_NG_VOICE_H
#define ESPEAK_NG_VOICE_H

#include <espeak-ng/espeak_ng.h>

#include "speech.h"

#ifdef __cplusplus
extern "C"
{
@@ -93,3 +100,5 @@ void FreeVoiceList(void);
#ifdef __cplusplus
}
#endif

#endif

+ 1
- 1
src/libespeak-ng/wavegen.c View File

@@ -32,10 +32,10 @@
#include <espeak-ng/espeak_ng.h>
#include <espeak-ng/speak_lib.h>

#include "synthesize.h"
#include "speech.h"
#include "phoneme.h"
#include "voice.h"
#include "synthesize.h"

#ifdef INCLUDE_KLATT
#include "klatt.h"

Loading…
Cancel
Save