Skip to content

Commit

Permalink
bellbird codebase
Browse files Browse the repository at this point in the history
  • Loading branch information
LongBoolean committed Feb 19, 2016
1 parent dc978cd commit c77c1ad
Show file tree
Hide file tree
Showing 449 changed files with 53,449 additions and 667,566 deletions.
17 changes: 17 additions & 0 deletions .gitignore
@@ -0,0 +1,17 @@
*~
aclocal.m4
autom4te.cache
config.log
config.status
configure.ac
depcomp
.deps
install-sh
ltmain.sh
Makefile.in
missing
*.o
m4/
config.guess
config.sub
configure
8 changes: 0 additions & 8 deletions .time-stamp

This file was deleted.

53 changes: 29 additions & 24 deletions ACKNOWLEDGEMENTS
@@ -1,3 +1,27 @@
Bellbird contains code from a number of projects. The largest
component of code orginated from:

Flite for Android's version of:
Flite: a small run-time speech synthesis engine
version 1.5.6-current

Bellbird also contains code from:
-flite 2.0 (Dec 2014)
-hts_engine 1.08 (Dec 2013)
-flite+hts 1.04 (Dec 2012)

We would like to acknowledge the work of the projects on which bellbird's
source was based without which bellbird would not be possible. In numerous
cases changes in bellbird are slight compared to the original projects which
performed the "heavy lifting". The largest acknowledgement goes to Prof. Alan
W. Black, the key author of flite.

The direct contributors to bellbird have included:
Peter Drysdale
Sergio Oller


We also include acknowledgements from flite which are relevant to Bellbird:

The initial development of flite was primarily done by awb while
travelling, perhaps the name is doubly appropriate as a substantial
Expand All @@ -6,8 +30,7 @@ time awb was funded by the Language Technonologies Institute at
Carnegie Mellon University.

Kevin A. Lenzo was involved in the design, conversion techniques and
representions for the voice distributed with flite (as well as being
the actual kal voice itself).
representions for the voice distributed with flite.

Other contributions are:

Expand Down Expand Up @@ -35,39 +58,21 @@ Marcela Charfuelan (DFKI)
but we understood the technqiues from Marcela's Open Mary Java code and
implemented them in our optimized version of MLSA.
David Huggins-Daines (dhd@cepstral.com)
much of the clunits code, porting to multiple platforms, substantial
code tidy up and configure/autoconf guidance.
porting to multiple platforms, substantial code tidy up.
Cepstral, LLC (http://cepstral.com)
For supporting DHD to spend time (in 2001) on flite and passing
back the important early fixes and enhancements including SAPI
support (funded by Portuguese FCT to produce an open source
synthesis solution).
back the important early fixes and enhancements.
Willie Walker <william.walker@sun.com> and the rest of the Sun Speech Group
lots of low level bugs (and fixes).
Portuguese Foundation for Science and Technology (FCT) Praxis XXI program
The SAPI interface provided by Cepstral, LLC was partially funded by
the above program.
Craig Reese: IDA/Supercomputing Research Center
Joe Campbell: Department of Defense
who wrote the ulaw conversion routines in src/speech/cst_wave_utils.c
Mario Lang:
causing the support of shared libraries to happen
Eric House (fixin@peak.org)
who provided examples of how to do 68K Call Backs for system functions
Greg Parker gparker@sealiesoftware.com
peal, the binding glue and shared library foo for getting the arm
version doing something reasonable under PalmOS
Lukas Loehrer <loehrerl@gmx.net> Feb 2006
alsa support (default if available)
Udhyakumar N
For making the mixed excitation code work, and show its value
Brian Langner
redid the Visual Studio support
Alok Parlikar
Android support, and cg voice dumping (and loading), indic support
cg voice loading
Gopala Anumanchipalli
spamf0 support, unitran integration
Richard Sproat and Kyoung-young Kim (UIUC)
Unitran: unicode to sampa grapheme mapping tables
Sun Microsystems
g72x code
spamf0 support
185 changes: 185 additions & 0 deletions CMakeLists.txt
@@ -0,0 +1,185 @@
# The projects name is bellbird.
PROJECT(BELLBIRD C)

if( NOT VERSION )
SET( VERSION "0.1.7-unstable")
endif( NOT VERSION )

cmake_minimum_required( VERSION 2.6.0 )
if( COMMAND cmake_policy )
cmake_policy( SET CMP0003 NEW )
cmake_policy( SET CMP0005 NEW )
endif( COMMAND cmake_policy)
SET( CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/CMakeScripts )

# Check for 32bit linux systems which require _FILE_OFFSET_BITS
# set to be able to read and write files >2Gb
INCLUDE(CheckFileOffsetBits)
CHECK_FILE_OFFSET_BITS()
if( _FILE_OFFSET_BITS )
ADD_DEFINITIONS (-D_FILE_OFFSET_BITS=64)
endif( _FILE_OFFSET_BITS)

option( ENABLE_ALSA "Build with ALSA support" ON )
option( ENABLE_O2 "Build with -O2 optimization" ON )
option( ENABLE_WALL "Build with -Wall warnings" ON )
option( ENABLE_CLANG "Build using clang compiler" OFF)
option( ENABLE_ANDROID "Build for Android" OFF)

if( ENABLE_ALSA )
ADD_DEFINITIONS (-DCST_AUDIO_ALSA)
else( ENABLE_ALSA )
ADD_DEFINITIONS (-DCST_AUDIO_NONE)
endif( ENABLE_ALSA )

if( ENABLE_O2 )
SET( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O2")
endif( ENABLE_O2 )

if( ENABLE_WALL )
SET( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra")
endif( ENABLE_WALL )

if( ENABLE_CLANG )
SET(CMAKE_C_COMPILER "/usr/bin/clang")
endif( ENABLE_CLANG )

if( ENABLE_ANDROID )
SET( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -march=armv7-a -mfloat-abi=softfp -mfpu=vfpv3-d16")
endif( ENABLE_ANDROID )

# Look for dependencies
if( ENABLE_ALSA )
FIND_PACKAGE ( ALSA REQUIRED )
SET( ALSA_LIBRARY asound )
endif( ENABLE_ALSA )

INCLUDE_DIRECTORIES( include )

SET(SRC_LIBBELLBIRD
src/audio/au_alsa.c
src/audio/au_none.c
src/audio/bell_audio.c
src/audio/bell_au_buff.c
src/cg/cst_cg.c
src/cg/cst_cg_load_voice.c
src/cg/cst_cg_map.c
src/cg/cst_mlpg.c
src/cg/cst_mlsa.c
src/cg/cst_spamf0.c
src/commonsynth/HTS_misc.c
src/commonsynth/bell_driver.c
src/hrg/cst_ffeature.c
src/hrg/cst_item.c
src/hrg/cst_relation.c
src/hrg/cst_utterance.c
src/hts/HTS_engine.c
src/hts/HTS_gstream.c
src/hts/HTS_label.c
src/hts/HTS_model.c
src/hts/HTS_pstream.c
src/hts/HTS_sstream.c
src/hts/HTS_vocoder.c
src/lexicon/cst_lexicon.c
src/lexicon/cst_lts.c
src/regex/cst_regex.c
src/regex/regexp.c
src/speech/cst_track.c
src/speech/cst_wave.c
src/speech/cst_wave_io.c
src/stats/cst_cart.c
src/synth/cst_ffeatures.c
src/synth/cst_phoneset.c
src/synth/cst_ssml.c
src/synth/cst_synth.c
src/synth/cst_utt_utils.c
src/synth/cst_voice
src/synth/flite.c
src/utils/bell_file.c
src/utils/cst_alloc.c
src/utils/cst_endian.c
src/utils/cst_error.c
src/utils/cst_features.c
src/utils/cst_string.c
src/utils/cst_tokenstream.c
src/utils/cst_val.c
src/utils/cst_val_const.c
src/utils/cst_val_user.c
)

SET(SRC_LIBBELLBIRD_USENGLISH
lang/usenglish/us_int_accent_cart.c
lang/usenglish/us_int_tone_cart.c
lang/usenglish/us_phoneset.c
lang/usenglish/us_ffeatures.c
lang/usenglish/us_ffeatures_hts.c
lang/usenglish/us_phrasing_cart.c
lang/usenglish/us_gpos.c
lang/usenglish/us_text.c
lang/usenglish/us_expand.c
lang/usenglish/us_nums_cart.c
lang/usenglish/us_aswd.c
lang/usenglish/usenglish.c
lang/usenglish/us_pos_cart.c
)

SET(SRC_LIBBELLBIRD_CMULEX
lang/cmulex/cmu_lts_rules.c
lang/cmulex/cmu_lts_model.c
lang/cmulex/cmu_lex.c
lang/cmulex/cmu_lex_entries.c
lang/cmulex/cmu_lex_data.c
lang/cmulex/cmu_postlex.c
)

ADD_LIBRARY(
libbellbird
${SRC_LIBBELLBIRD}
)

if ( ENABLE_ALSA )
TARGET_LINK_LIBRARIES (
libbellbird
${ALSA_LIBRARY}
)
else ( ENABLE_ALSA )
TARGET_LINK_LIBRARIES (
libbellbird
)
endif ( ENABLE_ALSA )

ADD_LIBRARY(
libbellbird_usenglish
${SRC_LIBBELLBIRD_USENGLISH}
)

ADD_LIBRARY(
libbellbird_cmulex
${SRC_LIBBELLBIRD_CMULEX}
)

ADD_EXECUTABLE ( bellbird main/bellbird.c )

SET_PROPERTY(
TARGET bellbird
APPEND PROPERTY COMPILE_DEFINITIONS PACKAGE_STRING=\"${VERSION}\"
)

TARGET_LINK_LIBRARIES (
bellbird
libbellbird_cmulex
libbellbird_usenglish
libbellbird
m
)

ADD_EXECUTABLE ( compile_regexes main/compile_regexes.c )

TARGET_LINK_LIBRARIES (
compile_regexes
libbellbird_cmulex
libbellbird_usenglish
libbellbird
m
)

14 changes: 14 additions & 0 deletions CMakeScripts/CheckFileOffsetBits.c
@@ -0,0 +1,14 @@
#include <sys/types.h>

#define KB ((off_t)1024)
#define MB ((off_t)1024 * KB)
#define GB ((off_t)1024 * MB)
#define TB ((off_t)1024 * GB)
int t2[(((64 * GB -1) % 671088649) == 268434537)
&& (((TB - (64 * GB -1) + 255) % 1792151290) == 305159546)? 1: -1];

int main()
{
;
return 0;
}
43 changes: 43 additions & 0 deletions CMakeScripts/CheckFileOffsetBits.cmake
@@ -0,0 +1,43 @@
# This file has been modified for Bellbird.
# See COPYING for more copyright details.
# The unmodified source code copyright notices
# are included below.
# - Check if _FILE_OFFSET_BITS macro needed for large files
# CHECK_FILE_OFFSET_BITS ()
#
# The following variables may be set before calling this macro to
# modify the way the check is run:
#
# CMAKE_REQUIRED_FLAGS = string of compile command line flags
# CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar)
# CMAKE_REQUIRED_INCLUDES = list of include directories
# Copyright (c) 2009, Michihiro NAKAJIMA
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING file.

GET_FILENAME_COMPONENT(_selfdir_CheckFileOffsetBits
"${CMAKE_CURRENT_LIST_FILE}" PATH)

MACRO (CHECK_FILE_OFFSET_BITS)
MESSAGE(STATUS "Checking _FILE_OFFSET_BITS for large files")
TRY_COMPILE(__WITHOUT_FILE_OFFSET_BITS_64
${CMAKE_CURRENT_BINARY_DIR}
${_selfdir_CheckFileOffsetBits}/CheckFileOffsetBits.c
COMPILE_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS})
IF(NOT __WITHOUT_FILE_OFFSET_BITS_64)
TRY_COMPILE(__WITH_FILE_OFFSET_BITS_64
${CMAKE_CURRENT_BINARY_DIR}
${_selfdir_CheckFileOffsetBits}/CheckFileOffsetBits.c
COMPILE_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS} -D_FILE_OFFSET_BITS=64)
ENDIF(NOT __WITHOUT_FILE_OFFSET_BITS_64)

IF(NOT __WITHOUT_FILE_OFFSET_BITS_64 AND __WITH_FILE_OFFSET_BITS_64)
SET(_FILE_OFFSET_BITS 64 CACHE INTERNAL "_FILE_OFFSET_BITS macro needed for large files")
MESSAGE(STATUS "Checking _FILE_OFFSET_BITS for large files - needed")
ELSE(NOT __WITHOUT_FILE_OFFSET_BITS_64 AND __WITH_FILE_OFFSET_BITS_64)
SET(_FILE_OFFSET_BITS "" CACHE INTERNAL "_FILE_OFFSET_BITS macro needed for large files")
MESSAGE(STATUS "Checking _FILE_OFFSET_BITS for large files - not needed")
ENDIF(NOT __WITHOUT_FILE_OFFSET_BITS_64 AND __WITH_FILE_OFFSET_BITS_64)

ENDMACRO (CHECK_FILE_OFFSET_BITS)

0 comments on commit c77c1ad

Please sign in to comment.