Package: praat
Severity: minor
Tags: patch
User: pkg-llvm-t...@lists.alioth.debian.org
Usertags: clang-ftbfs

Hello,

Using the rebuild infrastructure, your package fails to build with clang
(instead of gcc).

Detected this kind of error:
http://clang.debian.net/status.php?version=3.6.0&key=MISSING_PROTOTYPE

Full build log is available here:
http://clang.debian.net/logs/2015-03-25/praat_5.4.0-1_unstable_clang.log

I have attached a patch to fix this error.


Regards,
--Arthur Marble


-- System Information:
Debian Release: sid (unstable)
Architecture: amd64 (x86_64)
Kernel: Linux 4.2.0-1-amd64
Locale: LANG=en_US.UTF-8, LC_CTYPE="en_US.UTF-8"
Shell: /bin/sh linked to /bin/dash
Compiler: Debian clang version 3.6.2-3 (based on LLVM 3.6.2)
--- a/external/espeak/compiledict.cpp
+++ b/external/espeak/compiledict.cpp
@@ -138,6 +138,13 @@
 	int group3_ix;
 } RGROUP;
 
+// Function prototypes
+const char *LookupMnemName(MNEM_TAB *table, const int value);
+char *print_dictionary_flags(unsigned int *flags);
+char *DecodeRule(const char *group_chars, int group_length, char *rule, int control);
+int isHexDigit(int c);
+int  string_sorter(char **a, char **b);
+
 
 int isspace2(unsigned int c)
 {//=========================
--- a/external/espeak/dictionary.cpp
+++ b/external/espeak/dictionary.cpp
@@ -40,6 +40,10 @@
 extern char *print_dictionary_flags(unsigned int *flags);
 extern char *DecodeRule(const char *group_chars, int group_length, char *rule, int control);
 
+// Function prototypes
+int HashDictionary(const char *string);
+int IsVowel(Translator *tr, int letter);
+
 // accented characters which indicate (in some languages) the start of a separate syllable
 //static const unsigned short diereses_list[7] = {L'ä',L'ë',L'ï',L'ö',L'ü',L'ÿ',0};
 static const unsigned short diereses_list[7] = {0xe4,0xeb,0xef,0xf6,0xfc,0xff,0};
--- a/external/espeak/klatt.cpp
+++ b/external/espeak/klatt.cpp
@@ -71,6 +71,11 @@
 static klatt_frame_t  kt_frame;
 static klatt_global_t kt_globals;
 
+// Function prototypes
+int Wavegen_Klatt(int resume);
+void SetSynth_Klatt(int length, int modn, frame_t *fr1, frame_t *fr2, voice_t *v, int control);
+
+
 /*
 function RESONATOR
 
--- a/external/espeak/numbers.cpp
+++ b/external/espeak/numbers.cpp
@@ -389,6 +389,10 @@
 LIGATURE('t','s',M_CURL),
 };
 
+// Function prototypes
+bool CheckThousandsGroup(char *word, int group_len);
+
+
 static int LookupLetter2(Translator *tr, unsigned int letter, char *ph_buf)
 {//========================================================================
 	int len;
--- a/external/espeak/readclause.cpp
+++ b/external/espeak/readclause.cpp
@@ -1381,6 +1381,9 @@
 }  // end of attr_prosody_value
 
 
+// Function prototypes
+int AddNameData(const char *name, int wide);
+
 int AddNameData(const char *name, int wide)
 {//========================================
 // Add the name to the namedata and return its position
--- a/external/espeak/speak_lib.cpp
+++ b/external/espeak/speak_lib.cpp
@@ -742,7 +742,7 @@
 	uri_callback = UriCallback;
 }
 
-
+ESPEAK_API void espeak_SetPhonemeCallback(int (* PhonemeCallback)(const char*));
 ESPEAK_API void espeak_SetPhonemeCallback(int (* PhonemeCallback)(const char*))
 {//===========================================================================
 	phoneme_callback = PhonemeCallback;
--- a/external/espeak/synthdata.cpp
+++ b/external/espeak/synthdata.cpp
@@ -177,6 +177,7 @@
 }  //  end of LoadPhData
 
 
+void FreePhData(void);
 void FreePhData(void)
 {//==================
 #ifndef DATA_FROM_SOURCECODE_FILES
--- a/external/espeak/synthesize.cpp
+++ b/external/espeak/synthesize.cpp
@@ -613,6 +613,7 @@
 }
 
 
+int FormantTransition2(frameref_t *seq, int &n_frames, unsigned int data1, unsigned int data2, PHONEME_TAB *other_ph, int which);
 int FormantTransition2(frameref_t *seq, int &n_frames, unsigned int data1, unsigned int data2, PHONEME_TAB *other_ph, int which)
 {//==============================================================================================================================
 	int ix;
--- a/external/espeak/tr_languages.cpp
+++ b/external/espeak/tr_languages.cpp
@@ -319,6 +319,7 @@
 }  // end of SetCyrillicLetters
 
 
+void SetIndicLetters(Translator *tr);
 void SetIndicLetters(Translator *tr)
 {//=================================
 	// Set letter types for Indic scripts, Devanagari, Tamill, etc
@@ -345,6 +346,7 @@
 }
 
 
+void SetupTranslator(Translator *tr, const short *lengths, const unsigned char *amps);
 void SetupTranslator(Translator *tr, const short *lengths, const unsigned char *amps)
 {//==================================================================================
 	if(lengths != NULL)
--- a/external/espeak/translate.cpp
+++ b/external/espeak/translate.cpp
@@ -437,6 +437,7 @@
 	return(0);
 }
 
+int IsSpace(unsigned int c);
 int IsSpace(unsigned int c)
 {//========================
 	if(c == 0)
@@ -607,6 +608,7 @@
 }
 
 
+int IsAllUpper(const char *word);
 int IsAllUpper(const char *word)
 {//=============================
 	int c;
@@ -715,6 +717,7 @@
 
 extern char *phondata_ptr;
 
+int ChangeEquivalentPhonemes(Translator *tr, int lang2, char *phonemes);
 int ChangeEquivalentPhonemes(Translator *tr, int lang2, char *phonemes)
 {//====================================================================
 // tr:  the original language
@@ -1609,6 +1612,7 @@
 }
 
 
+void Word_EmbeddedCmd();
 void Word_EmbeddedCmd()
 {//====================
 // Process embedded commands for emphasis, sayas, and break
--- a/LPC/Tube.cpp
+++ b/LPC/Tube.cpp
@@ -88,6 +88,7 @@
 	}
 }
 
+void Tube_init (Tube me, double tmin, double tmax, long nt, double dt, double t1, long maxnSegments, double defaultLength);
 void Tube_init (Tube me, double tmin, double tmax, long nt, double dt, double t1, long maxnSegments, double defaultLength) {
 	my maxnSegments = maxnSegments;
 	Sampled_init (me, tmin, tmax, nt, dt, t1);
--- a/dwtools/CC.cpp
+++ b/dwtools/CC.cpp
@@ -205,6 +205,7 @@
 	return index > cf -> numberOfCoefficients ? NUMundefined : cf -> c[index];
 }
 
+double CC_getValueAtTime (I, double t, long index);
 double CC_getValueAtTime (I, double t, long index) {
 	iam (CC);
 	long iframe = Sampled_xToNearestIndex (me, t);
@@ -230,6 +231,7 @@
 	return cf -> c0;
 }
 
+double CC_getC0ValueAtTime (I, double t);
 double CC_getC0ValueAtTime (I, double t) {
 	iam (CC);
 	long iframe = Sampled_xToNearestIndex (me, t);
--- a/dwtools/DataModeler.cpp
+++ b/dwtools/DataModeler.cpp
@@ -1300,6 +1300,8 @@
 }
 
 void FormantModeler_speckle_inside (FormantModeler me, Graphics g, double xmin, double xmax, double fmax,
+	long fromTrack, long toTrack, int estimated, long numberOfParameters, int errorBars, double barWidth_mm, double horizontalOffset_mm);
+void FormantModeler_speckle_inside (FormantModeler me, Graphics g, double xmin, double xmax, double fmax,
 	long fromTrack, long toTrack, int estimated, long numberOfParameters, int errorBars, double barWidth_mm, double horizontalOffset_mm) {
 	for (long iformant = fromTrack; iformant <= toTrack; iformant++) {
 		DataModeler ffi =  (DataModeler) my trackmodelers -> item[iformant];
@@ -1376,6 +1378,7 @@
 	
 }
 
+long FormantModeler_getMaximumNumberOfParameters (FormantModeler me);
 long FormantModeler_getMaximumNumberOfParameters (FormantModeler me) {
 	long maxnum = 1;
 	for (long i = 1; i <= my trackmodelers -> size; i++) {
@@ -1703,6 +1706,7 @@
 	}
 }
 
+void FormantModeler_getVariancesBetweenTrackAndEstimatedTrack (FormantModeler me, long iformant, long estimatedFormant, double var[]);
 void FormantModeler_getVariancesBetweenTrackAndEstimatedTrack (FormantModeler me, long iformant, long estimatedFormant, double var[]) {
 	long numberOfDataPoints = FormantModeler_getNumberOfDataPoints (me);
 	long numberOfFormants = my trackmodelers -> size;
@@ -2139,6 +2143,7 @@
 	}
 }
 
+void FormantModeler_Formant_correctFormantsProbablyIndexedFalsely (FormantModeler me, Formant thee);
 void FormantModeler_Formant_correctFormantsProbablyIndexedFalsely (FormantModeler me, Formant thee) {
 	try {
 		(void) thee;
@@ -2149,6 +2154,7 @@
 }
 
 // If e.g. first formant is obviously "missing" then assign F1 as 
+void FormantModeler_correctFormantsProbablyIndexedFalsely (FormantModeler me);
 void FormantModeler_correctFormantsProbablyIndexedFalsely (FormantModeler me) {
 	(void) me;
 	/* if shift down F1 ("correct" F1 missed)
--- a/dwtools/HMM.cpp
+++ b/dwtools/HMM.cpp
@@ -142,6 +142,7 @@
 
 Thing_implement (HMMObservation, Daata, 0);
 
+void HMMObservation_init (HMMObservation me, const char32 *label, long numberOfComponents, long dimension, long storage);
 void HMMObservation_init (HMMObservation me, const char32 *label, long numberOfComponents, long dimension, long storage) {
 	my label = Melder_dup (label);
 	my gm = GaussianMixture_create (numberOfComponents, dimension, storage);
@@ -201,6 +202,7 @@
 
 Thing_implement (HMMState, Daata, 0);
 
+void HMMState_init (HMMState me, const char32 *label);
 void HMMState_init (HMMState me, const char32 *label) {
 	my label = Melder_dup (label);
 }
--- a/dwtools/Minimizers.cpp
+++ b/dwtools/Minimizers.cpp
@@ -158,6 +158,7 @@
 	Minimizer_reset (me, popt.peek());
 }
 
+void Minimizer_setAfterEachIteration (Minimizer me, void (*after) (Minimizer me, Any aclosure), Any aclosure);
 void Minimizer_setAfterEachIteration (Minimizer me, void (*after) (Minimizer me, Any aclosure), Any aclosure) {
 	my after = after;
 	my aclosure = aclosure;
--- a/external/espeak/voices.cpp
+++ b/external/espeak/voices.cpp
@@ -1765,6 +1765,7 @@
 }  //  end of SetVoiceByProperties
 
 
+void FreeVoiceList();
 void FreeVoiceList()
 {//=================
 	for(int ix=0; ix<n_voices_list; ix++)
--- a/external/espeak/wavegen.cpp
+++ b/external/espeak/wavegen.cpp
@@ -798,6 +798,7 @@
 }  // end of WavegenInit
 
 
+int GetAmplitude(void);
 int GetAmplitude(void)
 {//===================
 	int amp;
@@ -863,6 +864,7 @@
 
 
 
+int PeaksToHarmspect(wavegen_peaks_t *peaks, int pitch, int *htab, int control);
 int PeaksToHarmspect(wavegen_peaks_t *peaks, int pitch, int *htab, int control)
 {//============================================================================
 // Calculate the amplitude of each  harmonics from the formants
@@ -1175,6 +1177,7 @@
 
 
 
+int Wavegen();
 int Wavegen()
 {//==========
 	unsigned short waveph;
@@ -1666,6 +1669,7 @@
 }
 
 
+void SetPitch2(voice_t *voice, int pitch1, int pitch2, int *pitch_base, int *pitch_range);
 void SetPitch2(voice_t *voice, int pitch1, int pitch2, int *pitch_base, int *pitch_range)
 {//======================================================================================
 	int x;
@@ -1697,6 +1701,7 @@
 }
 
 
+void SetPitch(int length, unsigned char *env, int pitch1, int pitch2);
 void SetPitch(int length, unsigned char *env, int pitch1, int pitch2)
 {//==================================================================
 // length in samples
@@ -1734,6 +1739,7 @@
 
 
 
+void SetSynth(int length, int modn, frame_t *fr1, frame_t *fr2, voice_t *v);
 void SetSynth(int length, int modn, frame_t *fr1, frame_t *fr2, voice_t *v)
 {//========================================================================
 	int ix;
@@ -1869,6 +1875,7 @@
 
 
 
+int WavegenFill2(int fill_zeros);
 int WavegenFill2(int fill_zeros)
 {//============================
 // Pick up next wavegen commands from the queue
--- a/sys/melder_audio.cpp
+++ b/sys/melder_audio.cpp
@@ -598,6 +598,7 @@
 }
 
 #ifdef HAVE_PULSEAUDIO
+void pulseAudio_initialize ();
 void pulseAudio_initialize () {
 	struct MelderPlay *me = & thePlay;
 	if (! my pulseAudio.pulseAudioInitialized) {
@@ -644,6 +645,7 @@
 	my pulseAudio.pulseAudioInitialized = false;
 }
 
+void pulseAudio_server_info_cb (pa_context *context, const pa_server_info *info, void *userdata);
 void pulseAudio_server_info_cb (pa_context *context, const pa_server_info *info, void *userdata) {
 	struct MelderPlay *me = (struct MelderPlay *) userdata;
 	if (! info) {
@@ -678,6 +680,7 @@
 	pa_threaded_mainloop_signal (my pulseAudio.mainloop, 0);
 }
 
+void pulseAudio_serverReport ();
 void pulseAudio_serverReport () {
 	// TODO: initiaize context
 	struct MelderPlay *me = & thePlay;
@@ -766,6 +769,7 @@
 	(void) p;
 }
 // asynchronous version
+void stream_write_cb2 (pa_stream *stream, size_t length, void *userdata);
 void stream_write_cb2 (pa_stream *stream, size_t length, void *userdata) {
 	struct MelderPlay *me = (struct MelderPlay *) userdata;
 	if (stream == my pulseAudio.stream) {
@@ -882,6 +886,7 @@
 	}
 }
 
+void stream_state_cb (pa_stream *stream, void *userdata);
 void stream_state_cb (pa_stream *stream, void *userdata) {
 	struct MelderPlay *me = (struct MelderPlay *) userdata;
 

Reply via email to