Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
75 commits
Select commit Hold shift + click to select a range
da1e23c
initial changes for android (remove glib dep)
loki666 Oct 27, 2017
d2c9b82
update fluid_sys.c
loki666 Oct 27, 2017
9365219
Merge branch 'master' into android
loki666 Oct 28, 2017
db11828
Merge branch 'master' into android
loki666 Nov 5, 2017
d18eb62
Merge branch 'master' into android
loki666 Nov 7, 2017
f8950ac
Merge branch 'master' into android
loki666 Nov 8, 2017
1f497c6
Merge https://github.com/FluidSynth/fluidsynth
loki666 Nov 13, 2017
0fdab26
fix indentation
loki666 Nov 13, 2017
838a979
fix new_fluid_timer
loki666 Nov 13, 2017
3628530
Merge https://github.com/FluidSynth/fluidsynth
loki666 Nov 13, 2017
74e64e0
Merge https://github.com/FluidSynth/fluidsynth
loki666 Nov 15, 2017
c0de66d
Merge https://github.com/FluidSynth/fluidsynth
loki666 Nov 23, 2017
a5e4b1f
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Nov 27, 2017
603b4df
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Dec 5, 2017
9ecf082
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Dec 15, 2017
b03a403
fix merge
loki666 Dec 15, 2017
0656a18
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Dec 19, 2017
172b644
merge upstream
loki666 Jan 4, 2018
c964bb2
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Jan 8, 2018
9bf7207
switch to cmake
loki666 Jan 18, 2018
6df25fe
oops
loki666 Jan 18, 2018
2f80817
use floats on 32bits arch
loki666 Jan 19, 2018
1eb3433
use ANDROID_ABI cmake variable
loki666 Jan 19, 2018
ee44990
Merge https://github.com/FluidSynth/fluidsynth
loki666 Jan 27, 2018
11ac51c
Merge remote-tracking branch 'upstream/master'
loki666 Feb 23, 2018
58894b7
build fluid_sfont.c
loki666 Feb 23, 2018
847aa11
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Mar 7, 2018
b1ab2b7
fix build
loki666 Mar 7, 2018
59380ad
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Mar 26, 2018
3010e3e
Merge https://github.com/FluidSynth/fluidsynth
loki666 Apr 3, 2018
f076375
Merge https://github.com/FluidSynth/fluidsynth
loki666 Apr 8, 2018
1d30430
add files to android CMakeLists.txt
loki666 Apr 8, 2018
0a066c1
fix fluid_sys.h
loki666 Apr 8, 2018
da03bae
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Apr 17, 2018
0f871e7
register audio settings
loki666 Apr 20, 2018
862b9fe
Merge https://github.com/FluidSynth/fluidsynth
loki666 Apr 21, 2018
4af3958
Merge https://github.com/FluidSynth/fluidsynth
loki666 Apr 21, 2018
a31f7e4
Merge https://github.com/FluidSynth/fluidsynth
loki666 Apr 26, 2018
ead0676
Merge remote-tracking branch 'FluidSynth/master'
loki666 May 5, 2018
9849423
Merge remote-tracking branch 'FluidSynth/master'
loki666 May 5, 2018
b7b5d4c
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 May 25, 2018
d4b4dd0
fix FLUID_ASSERT
loki666 May 25, 2018
30a2898
Merge https://github.com/FluidSynth/fluidsynth
loki666 Jun 3, 2018
497baa8
Merge https://github.com/FluidSynth/fluidsynth
loki666 Jun 4, 2018
e341258
android: move android/CMakeLists.txt in /CMakeLists.txt
loki666 Jun 11, 2018
43c3a0b
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Jun 28, 2018
e22bf92
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Jul 2, 2018
9812648
remove ramsfont
loki666 Jul 2, 2018
807dac5
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Jul 31, 2018
ed24806
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Sep 20, 2018
655dfcc
Merge https://github.com/FluidSynth/fluidsynth
loki666 Oct 25, 2018
3b28317
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Nov 9, 2018
e491056
Update fluidsynth_priv.h
loki666 Nov 14, 2018
95df4b0
Update CMakeLists.txt
loki666 Nov 14, 2018
619bd9e
Update CMakeLists.txt
loki666 Nov 15, 2018
05b1509
Merge https://github.com/FluidSynth/fluidsynth
loki666 Nov 18, 2018
64cdbdf
use upstream fluid_adriver.c and fluid_mdriver.c
loki666 Nov 18, 2018
57bc090
Merge branch 'master' of https://github.com/FluidSynth/fluidsynth
loki666 Feb 5, 2019
3b6cdf8
Merge remote-tracking branch 'upstream/master'
loki666 Feb 26, 2019
b2b1907
fix merge
loki666 Feb 26, 2019
e3740cc
update version
loki666 Feb 26, 2019
8435cd4
fix gentables build
loki666 Feb 26, 2019
0bb67a6
fix merge
loki666 Feb 26, 2019
487875f
fix merge
loki666 Feb 26, 2019
63cfb11
fix fluid_sys.h
loki666 Feb 26, 2019
96c3886
fix fluid_sys.h
loki666 Feb 26, 2019
00a2db3
Fix build
Sep 25, 2019
aecb715
Merge remote-tracking branch 'vendor/2.0.x' into fixes
Sep 25, 2019
ee32185
C++ compilation fixes
romanbsd Sep 25, 2019
132ad2a
Merge pull request #4 from romanbsd/fixes
loki666 Sep 26, 2019
26669aa
Update fluid_sys.h
loki666 Oct 23, 2019
e18b707
Merge remote-tracking branch 'vendor/master'
romanbsd Jan 5, 2020
fde1c25
bump version strings to 2.1.0
loki666 Jan 9, 2020
679c63c
fix for Android NDK
loki666 Jan 9, 2020
cdeac3e
add math floats functions defines
loki666 Feb 14, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
103 changes: 103 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,107 @@

# CMake based build system. Pedro Lopez-Cabanillas <plcl@users.sf.net>

if ( ANDROID )
enable_language(C)
cmake_minimum_required(VERSION 3.4.1)

set(fluidsynth_sources
src/midi/fluid_midi.c
src/midi/fluid_midi_router.c
src/midi/fluid_seq.c
src/midi/fluid_seqbind.c
src/rvoice/fluid_adsr_env.c
src/rvoice/fluid_chorus.c
src/rvoice/fluid_iir_filter.c
src/rvoice/fluid_lfo.c
src/rvoice/fluid_rev.c
src/rvoice/fluid_rvoice.c
src/rvoice/fluid_rvoice_dsp.c
src/rvoice/fluid_rvoice_event.c
src/rvoice/fluid_rvoice_mixer.c
src/sfloader/fluid_defsfont.c
src/sfloader/fluid_sfont.c
src/sfloader/fluid_sffile.c
src/sfloader/fluid_samplecache.c
src/synth/fluid_chan.c
src/synth/fluid_event.c
src/synth/fluid_gen.c
src/synth/fluid_mod.c
src/synth/fluid_synth.c
src/synth/fluid_tuning.c
src/synth/fluid_voice.c
src/synth/fluid_synth_monopoly.c
src/utils/fluid_conv.c
src/utils/fluid_hash.c
src/utils/fluid_list.c
src/utils/fluid_ringbuffer.c
src/utils/fluid_settings.c
src/bindings/fluid_filerenderer.c
src/utils/fluid_sys.c
android/src/bindings/fluid_cmd.c
src/drivers/fluid_adriver.c
src/drivers/fluid_mdriver.c
)

set ( public_main_HEADER
${CMAKE_BINARY_DIR}/include/fluidsynth.h
)

configure_file ( include/fluidsynth.cmake
${public_main_HEADER} )

add_library(fluidsynth SHARED ${fluidsynth_sources})

if(ANDROID_ABI STREQUAL "armeabi-v7a")
target_compile_options(fluidsynth PRIVATE -DWITH_FLOAT)
endif()
if(ANDROID_ABI STREQUAL "x86")
target_compile_options(fluidsynth PRIVATE -DWITH_FLOAT)
endif()

# Specify directories which the compiler should look for headers
target_include_directories(fluidsynth PRIVATE
android android/include
include
src
src/synth
src/midi
src/rvoice
src/sfloader
src/utils
src/bindings
src/drivers
${CMAKE_BINARY_DIR}/include
${CMAKE_BINARY_DIR}
)

target_include_directories(fluidsynth INTERFACE
android android/include
include
${CMAKE_BINARY_DIR}/include
)

target_compile_options(fluidsynth PRIVATE -std=gnu11
PRIVATE -Wall
PRIVATE -DHAVE_CONFIG_H
PRIVATE -Wno-unused-variable
PRIVATE -Wno-error=format
PRIVATE "$<$<CONFIG:DEBUG>:-Werror>") # Only include -Werror when building debug config

# ******* Auto Generated Lookup Tables ******

include(ExternalProject)
ExternalProject_Add(gentables
DOWNLOAD_COMMAND ""
SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/src/gentables
BINARY_DIR ${CMAKE_CURRENT_BINARY_DIR}/src/gentables
INSTALL_COMMAND ${CMAKE_CURRENT_BINARY_DIR}/src/gentables/make_tables.exe "${CMAKE_BINARY_DIR}/"
CMAKE_GENERATOR "Unix Makefiles"
)
add_dependencies(fluidsynth gentables)

else ( ANDROID )

cmake_minimum_required ( VERSION 3.1.0 ) # because of CMAKE_C_STANDARD
project ( FluidSynth C )
set ( CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake_admin )
Expand Down Expand Up @@ -808,3 +909,5 @@ set ( CPACK_PACKAGE_NAME ${PACKAGE} )
set ( CPACK_STRIP_FILES ON )

include ( CPack )

endif ( ANDROID )
228 changes: 228 additions & 0 deletions android/config.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,228 @@
#ifndef CONFIG_H
#define CONFIG_H

/* Define to enable ALSA driver */
/* #undef ALSA_SUPPORT */

/* Define to activate sound output to files */
/* #undef AUFILE_SUPPORT */

/* whether or not we are supporting CoreAudio */
/* #undef COREAUDIO_SUPPORT */

/* whether or not we are supporting CoreMIDI */
/* #undef COREMIDI_SUPPORT */

/* whether or not we are supporting DART */
/* #undef DART_SUPPORT */

/* Define if building for Mac OS X Darwin */
/* #undef DARWIN */

/* Define if D-Bus support is enabled */
/* #undef DBUS_SUPPORT */

/* Define to enable FPE checks */
/* #undef FPE_CHECK */

/* Define to 1 if you have the <arpa/inet.h> header file. */
/*#undef HAVE_ARPA_INET_H */

/* Define to 1 if you have the <dlfcn.h> header file. */
#define HAVE_DLFCN_H 1

/* Define to 1 if you have the <errno.h> header file. */
#define HAVE_ERRNO_H 1

/* Define to 1 if you have the <fcntl.h> header file. */
#define HAVE_FCNTL_H 1

/* Define to 1 if you have the <inttypes.h> header file. */
#define HAVE_INTTYPES_H 1

/* whether or not we are supporting ladcca */
/* #undef HAVE_LADCCA */

/* whether or not we are supporting lash */
/* #undef HAVE_LASH */

/* Define to 1 if you have the `dl' library (-ldl). */
/* #undef HAVE_LIBDL */

/* Define to 1 if you have the `MidiShare' library (-lMidiShare). */
/* #undef HAVE_LIBMIDISHARE */

/* Define to 1 if you have the `pthread' library (-lpthread). */
#define HAVE_LIBPTHREAD TRUE

/* Define to 1 if you have the <limits.h> header file. */
#define HAVE_LIMITS_H 1

/* Define to 1 if you have the <machine/soundcard.h> header file. */
/* #undef HAVE_MACHINE_SOUNDCARD_H */

/* Define to 1 if you have the <math.h> header file. */
#define HAVE_MATH_H 1

/* Define to 1 if you have the <memory.h> header file. */
#define HAVE_MEMORY_H 1

/* Define to 1 if you have the <MidiShare.h> header file. */
/* #undef HAVE_MIDISHARE_H */

/* Define to 1 if you have the <netinet/in.h> header file. */
#define HAVE_NETINET_IN_H 1

/* Define to 1 if you have the <netinet/tcp.h> header file. */
#define HAVE_NETINET_TCP_H 1

/* Define to 1 if you have the <pthread.h> header file. */
#define HAVE_PTHREAD_H 1

/* Define to 1 if you have the <signal.h> header file. */
#define HAVE_SIGNAL_H 1

/* Define to 1 if you have the <stdarg.h> header file. */
#define HAVE_STDARG_H 1

/* Define to 1 if you have the <stdint.h> header file. */
#define HAVE_STDINT_H 1

/* Define to 1 if you have the <stdio.h> header file. */
#define HAVE_STDIO_H 1

/* Define to 1 if you have the <stdlib.h> header file. */
#define HAVE_STDLIB_H 1

/* Define to 1 if you have the <strings.h> header file. */
#define HAVE_STRINGS_H 1

/* Define to 1 if you have the <string.h> header file. */
#define HAVE_STRING_H 1

/* Define to 1 if you have the <sys/ioctl.h> header file. */
#define HAVE_SYS_IOCTL_H 1

/* Define to 1 if you have the <sys/mman.h> header file. */
/* #undef HAVE_SYS_MMAN_H */

/* Define to 1 if you have the <sys/socket.h> header file. */
#define HAVE_SYS_SOCKET_H 1

/* Define to 1 if you have the <netinet/in.h> header file. */
#define HAVE_NETINET_IN_H 1

/* Define to 1 if you have the <netinet/tcp.h> header file. */
#define HAVE_NETINET_TCP_H 1

/* Define to 1 if you have the <arpa/inet.h> header file. */
#define HAVE_ARPA_INET_H 1

/* Define to 1 if you have the <sys/soundcard.h> header file. */
/* #undef HAVE_SYS_SOUNDCARD_H */

/* Define to 1 if you have the <sys/stat.h> header file. */
#define HAVE_SYS_STAT_H 1

/* Define to 1 if you have the <sys/time.h> header file. */
#define HAVE_SYS_TIME_H 1

/* Define to 1 if you have the <sys/types.h> header file. */
#define HAVE_SYS_TYPES_H 1

/* Define to 1 if you have the <unistd.h> header file. */
#define HAVE_UNISTD_H 1

/* Define to 1 if you have the <windows.h> header file. */
/* #undef HAVE_WINDOWS_H */

/* Define to 1 if you have the <getopt.h> header file. */
#define HAVE_GETOPT_H 1

/* Define to enable JACK driver */
/* #undef JACK_SUPPORT */

/* Include the LADSPA Fx unit */
/* #undef LADSPA */

/* libsndfile has ogg vorbis support */
/* #undef LIBSNDFILE_HASVORBIS */

/* Define to enable libsndfile support */
/* #undef LIBSNDFILE_SUPPORT */

/* Define to enable MidiShare driver */
/* #undef MIDISHARE_SUPPORT */

/* Define if using the MinGW32 environment */
/* #undef MINGW32 */

/* Define to 1 if your C compiler doesn't accept -c and -o together. */
/* #undef NO_MINUS_C_MINUS_O */

/* Define to enable OSS driver */
/* #undef OSS_SUPPORT */

/* Name of package */
#define PACKAGE "fluidsynth"

/* Define to the address where bug reports for this package should be sent. */
/* #undef PACKAGE_BUGREPORT */

/* Define to the full name of this package. */
/* #undef PACKAGE_NAME */

/* Define to the full name and version of this package. */
/* #undef PACKAGE_STRING */

/* Define to the one symbol short name of this package. */
/* #undef PACKAGE_TARNAME */

/* Define to the version of this package. */
/* #undef PACKAGE_VERSION */

/* Define to enable PortAudio driver */
/* #undef PORTAUDIO_SUPPORT */

/* Define to enable PulseAudio driver */
/* #undef PULSE_SUPPORT */

/* Define to 1 if you have the ANSI C header files. */
#define STDC_HEADERS 1

/* Define to enable SIGFPE assertions */
/* #undef TRAP_ON_FPE */

/* Version number of package */
#define VERSION "2.1.0"

/* Define to do all DSP in single floating point precision */
/* #undef WITH_FLOAT */

#define HAVE_SINF 1
#define HAVE_COSF 1
#define HAVE_FABSF 1
#define HAVE_POWF 1
#define HAVE_SQRTF 1
#define HAVE_LOGF 1

/* Define to profile the DSP code */
/* #undef WITH_PROFILING */

/* Define to use the readline library for line editing */
/* #undef WITH_READLINE */

/* Define if the compiler supports VLA */
#define SUPPORTS_VLA

/* Define to 1 if your processor stores words with the most significant byte
first (like Motorola and SPARC, unlike Intel and VAX). */
/* #undef WORDS_BIGENDIAN */

/* Define to `__inline__' or `__inline' if that's what the C compiler
calls it, or to nothing if 'inline' is not supported under any name. */
#ifndef __cplusplus
/* #undef inline */
#endif

#endif /* CONFIG_H */
47 changes: 47 additions & 0 deletions android/include/fluidsynth/version.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
/* FluidSynth - A Software Synthesizer
*
* Copyright (C) 2003 Peter Hanappe and others.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public License
* as published by the Free Software Foundation; either version 2 of
* the License, or (at your option) any later version.
*
* This library 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
* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public
* License along with this library; if not, write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA
*/

#ifndef _FLUIDSYNTH_VERSION_H
#define _FLUIDSYNTH_VERSION_H


#ifdef __cplusplus
extern "C" {
#endif

/**
* @file version.h
* @brief Library version functions and defines
*/

#define FLUIDSYNTH_VERSION "2.1.0" /**< String constant of libfluidsynth version. */
#define FLUIDSYNTH_VERSION_MAJOR 2 /**< libfluidsynth major version integer constant. */
#define FLUIDSYNTH_VERSION_MINOR 1 /**< libfluidsynth minor version integer constant. */
#define FLUIDSYNTH_VERSION_MICRO 0 /**< libfluidsynth micro version integer constant. */

FLUIDSYNTH_API void fluid_version(int *major, int *minor, int *micro);
FLUIDSYNTH_API char* fluid_version_str(void);


#ifdef __cplusplus
}
#endif

#endif /* _FLUIDSYNTH_VERSION_H */
Loading