mirror of
https://github.com/linux-speakup/espeakup.git
synced 2026-08-09 09:19:09 +02:00
parent
30ef2145e7
commit
0c09fe5449
14 changed files with 96 additions and 48 deletions
4
.gitignore
vendored
4
.gitignore
vendored
|
|
@ -1,3 +1 @@
|
||||||
espeakup
|
build*
|
||||||
src/*.d
|
|
||||||
src/*.o
|
|
||||||
|
|
|
||||||
37
Makefile
37
Makefile
|
|
@ -1,37 +0,0 @@
|
||||||
PREFIX = /usr/local
|
|
||||||
BINDIR = ${PREFIX}/bin
|
|
||||||
MANDIR = ${PREFIX}/share/man
|
|
||||||
SRC_DIR = src
|
|
||||||
DEPFLAGS = -MMD
|
|
||||||
WARNFLAGS = -Wall -Wpedantic \
|
|
||||||
-Wextra
|
|
||||||
|
|
||||||
CFLAGS += ${DEPFLAGS} ${WARNFLAGS}
|
|
||||||
|
|
||||||
LDLIBS = -lespeak-ng -lpthread -lasound -lm
|
|
||||||
|
|
||||||
INSTALL = install
|
|
||||||
BINMODE = 0755
|
|
||||||
MANMODE = 0644
|
|
||||||
|
|
||||||
SRC = $(wildcard $(SRC_DIR)/*.c)
|
|
||||||
OBJECTS := $(patsubst %.c,%.o,$(wildcard $(SRC_DIR)/*.c))
|
|
||||||
|
|
||||||
all: espeakup
|
|
||||||
|
|
||||||
install: espeakup
|
|
||||||
${INSTALL} -d ${DESTDIR}${BINDIR}
|
|
||||||
${INSTALL} -m ${BINMODE} $< ${DESTDIR}${BINDIR}
|
|
||||||
${INSTALL} -d ${DESTDIR}${MANDIR}/man8
|
|
||||||
${INSTALL} -m ${MANMODE} doc/espeakup.8 ${DESTDIR}${MANDIR}/man8
|
|
||||||
|
|
||||||
espeakup: ${OBJECTS}
|
|
||||||
cc $(LDLIBS) -o ./espeakup $(OBJECTS)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
${RM} $(SRC_DIR)/*.d $(SRC_DIR)/*.o
|
|
||||||
|
|
||||||
distclean: clean
|
|
||||||
${RM} espeakup
|
|
||||||
|
|
||||||
-include ${SRCS:.c=.d}
|
|
||||||
12
README.md
12
README.md
|
|
@ -18,9 +18,15 @@ is beyond the scope of this document.
|
||||||
|
|
||||||
The preferred way to install espeakup is using your distribution's
|
The preferred way to install espeakup is using your distribution's
|
||||||
packaging system, but if your distribution does not have a package for
|
packaging system, but if your distribution does not have a package for
|
||||||
espeakup yet, espeakup just uses a Makefile, so you should be able to
|
espeakup yet, espeakup just uses meson, so you should be able to
|
||||||
change to the source directory, then type make, then as root, make
|
change to the source directory, then type:
|
||||||
install.
|
|
||||||
|
```bash
|
||||||
|
meson . ./build
|
||||||
|
cd ./build
|
||||||
|
ninja
|
||||||
|
sudo ninja install
|
||||||
|
```
|
||||||
|
|
||||||
## Starting Up
|
## Starting Up
|
||||||
|
|
||||||
|
|
|
||||||
1
doc/meson.build
Normal file
1
doc/meson.build
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
install_man('espeakup.8')
|
||||||
21
meson.build
Normal file
21
meson.build
Normal file
|
|
@ -0,0 +1,21 @@
|
||||||
|
project('espeakup', 'c',
|
||||||
|
default_options : ['buildtype=debugoptimized', 'c_std=gnu11', 'warning_level=3'],
|
||||||
|
license : 'GPL-3.0-or-later',
|
||||||
|
version : '0.81',
|
||||||
|
meson_version : '>=0.47.0')
|
||||||
|
|
||||||
|
cc = meson.get_compiler('c')
|
||||||
|
thread_dep = dependency('threads')
|
||||||
|
espeak_dep = dependency('espeak-ng')
|
||||||
|
alsa_dep = dependency('alsa')
|
||||||
|
math_dep = cc.find_library('m', required : false)
|
||||||
|
|
||||||
|
subdir('doc')
|
||||||
|
subdir('services')
|
||||||
|
subdir('src')
|
||||||
|
|
||||||
|
executable('espeakup',
|
||||||
|
espeakup_version,
|
||||||
|
espeakup_sources,
|
||||||
|
dependencies : [thread_dep, espeak_dep, alsa_dep, math_dep],
|
||||||
|
install : true)
|
||||||
2
meson_options.txt
Normal file
2
meson_options.txt
Normal file
|
|
@ -0,0 +1,2 @@
|
||||||
|
option('systemd', type : 'feature', value : 'auto',
|
||||||
|
description :'enable systemd support')
|
||||||
4
services/meson.build
Normal file
4
services/meson.build
Normal file
|
|
@ -0,0 +1,4 @@
|
||||||
|
systemd = dependency('systemd', required: get_option('systemd'))
|
||||||
|
if systemd.found()
|
||||||
|
subdir('systemd')
|
||||||
|
endif
|
||||||
|
|
@ -1 +0,0 @@
|
||||||
default_voice=
|
|
||||||
|
|
@ -6,10 +6,10 @@ After=systemd-udev-settle.service sound.target
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Type=forking
|
Type=forking
|
||||||
EnvironmentFile=/etc/conf.d/espeakup
|
|
||||||
PIDFile=/run/espeakup.pid
|
PIDFile=/run/espeakup.pid
|
||||||
ExecStartPre=+/sbin/modprobe speakup_soft
|
Environment="default_voice="
|
||||||
ExecStart=/usr/bin/espeakup --default-voice=${default_voice}
|
ExecStartPre=+modprobe speakup_soft
|
||||||
|
ExecStart=@bindir@/espeakup --default-voice=${default_voice}
|
||||||
ExecReload=kill -HUP $MAINPID
|
ExecReload=kill -HUP $MAINPID
|
||||||
Restart=always
|
Restart=always
|
||||||
|
|
||||||
17
services/systemd/meson.build
Normal file
17
services/systemd/meson.build
Normal file
|
|
@ -0,0 +1,17 @@
|
||||||
|
unitdir = systemd.get_pkgconfig_variable('systemdsystemunitdir')
|
||||||
|
prefixdir = get_option('prefix')
|
||||||
|
bindir = join_paths(prefixdir, get_option('bindir'))
|
||||||
|
|
||||||
|
unit_conf = configuration_data()
|
||||||
|
|
||||||
|
unit_conf.set('bindir', bindir)
|
||||||
|
|
||||||
|
service_file = configure_file(
|
||||||
|
input : 'espeakup.service.in',
|
||||||
|
output : 'espeakup.service',
|
||||||
|
configuration : unit_conf
|
||||||
|
)
|
||||||
|
|
||||||
|
install_data(service_file,
|
||||||
|
install_dir : unitdir
|
||||||
|
)
|
||||||
|
|
@ -23,6 +23,7 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
#include "espeakup.h"
|
#include "espeakup.h"
|
||||||
|
#include "version.h"
|
||||||
|
|
||||||
/* pid path */
|
/* pid path */
|
||||||
extern char *pidPath;
|
extern char *pidPath;
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,6 @@
|
||||||
|
|
||||||
#include "queue.h"
|
#include "queue.h"
|
||||||
|
|
||||||
#define PACKAGE_VERSION "0.81"
|
|
||||||
#define PACKAGE_BUGREPORT "https://github.com/linux-speakup/espeakup/issues"
|
#define PACKAGE_BUGREPORT "https://github.com/linux-speakup/espeakup/issues"
|
||||||
|
|
||||||
enum espeakup_mode_t {
|
enum espeakup_mode_t {
|
||||||
|
|
|
||||||
12
src/meson.build
Normal file
12
src/meson.build
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
espeakup_version = vcs_tag(input : 'version.h.in', output : 'version.h')
|
||||||
|
|
||||||
|
|
||||||
|
espeakup_sources = files([
|
||||||
|
'cli.c',
|
||||||
|
'espeak.c',
|
||||||
|
'espeakup.c',
|
||||||
|
'queue.c',
|
||||||
|
'signal.c',
|
||||||
|
'softsynth.c',
|
||||||
|
'stringhandling.c'
|
||||||
|
])
|
||||||
25
src/version.h.in
Normal file
25
src/version.h.in
Normal file
|
|
@ -0,0 +1,25 @@
|
||||||
|
/*
|
||||||
|
* espeakup - interface which allows speakup to use espeak
|
||||||
|
*
|
||||||
|
* Copyright (C) 2008 William Hubbs
|
||||||
|
*
|
||||||
|
* 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 <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef __VERSION_H
|
||||||
|
#define __VERSION_H
|
||||||
|
|
||||||
|
#define PACKAGE_VERSION "@VCS_TAG@"
|
||||||
|
|
||||||
|
#endif
|
||||||
Loading…
Add table
Add a link
Reference in a new issue