build script: add fluidsynth target

This commit is contained in:
alexey.lysiuk 2020-12-12 12:53:02 +02:00
parent 593741ed2a
commit d89e22218f
3 changed files with 31 additions and 0 deletions

1
.gitignore vendored
View file

@ -9,6 +9,7 @@
/deps/bzip2/bin/
/deps/bzip2/man/
/deps/flac/bin/
/deps/fluidsynth/bin/
/deps/glib/bin/gdbus*
/deps/glib/bin/gio*
/deps/glib/bin/glib-compile*

View file

@ -709,6 +709,25 @@ class FlacTarget(ConfigureMakeStaticDependencyTarget):
return os.path.exists(builder.source_path + 'FLAC/flac.pc.in')
class FluidSynthTarget(CMakeStaticDependencyTarget):
def __init__(self, name='fluidsynth'):
super().__init__(name)
opts = self.options
opts['LIB_SUFFIX'] = None
opts['enable-framework'] = 'NO'
opts['enable-readline'] = 'NO'
opts['enable-sdl2'] = 'NO'
def prepare_source(self, builder: 'Builder'):
builder.download_source(
'https://github.com/FluidSynth/fluidsynth/archive/v2.1.5.tar.gz',
'b539b7c65a650b56f01cd60a4e83c6125c217c5a63c0c214ef6274894a677d00')
def detect(self, builder: 'Builder') -> bool:
return os.path.exists(builder.source_path + 'fluidsynth.pc.in')
class GettextTarget(ConfigureMakeStaticDependencyTarget):
def __init__(self, name='gettext'):
super().__init__(name)
@ -1344,6 +1363,7 @@ class Builder(object):
Bzip2Target(),
FfiTarget(),
FlacTarget(),
FluidSynthTarget(),
GlibTarget(),
IconvTarget(),
InstPatchTarget(),

View file

@ -0,0 +1,10 @@
prefix=
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${prefix}/include
Name: FluidSynth
Description: Software SoundFont synth
Version: 2.1.5
Libs: -L${libdir} -lfluidsynth
Cflags: -I${includedir}