mirror of
https://github.com/RPCS3/soundtouch.git
synced 2024-11-08 12:02:28 +01:00
Small updates to dynamic-link libary build script & pascal example
Signed-off-by: Olli <oparviai'at'iki.fi>
This commit is contained in:
parent
17925302ae
commit
774257ab5f
12
README.html
12
README.html
@ -131,10 +131,12 @@
|
||||
</table>
|
||||
|
||||
<b>Compiling portable Shared Library / DLL version</b>
|
||||
<p> The GNU autotools compilation does not automatically create a shared-library version of
|
||||
SoundTouch (.so or .dll) that features position-independent code and C-language
|
||||
api that are more suitable for cross-language development than C++ libraries.</p>
|
||||
<p> Use script "make-gnu-dll-sh" to build a portable dynamic library version if such is desired.</p>
|
||||
<p> The GNU autotools compilation automatically builds an additional dynamic-link version
|
||||
of SoundTouch library that features position-independent code and "C"-style API that is
|
||||
more suitable for calling the SoundTouch routines from other programming languages.</p>
|
||||
<p>This dynamic-link library is built under source/SoundTouchDLL directory, whose
|
||||
subdirectories also comtain simple example apps that use the dynamic-link library.
|
||||
</p>
|
||||
|
||||
<h4><b>2.2.2 Compiling with cmake</b></h4>
|
||||
<p>'cmake' build scripts are provided as an alternative to the autotools toolchain.</p>
|
||||
@ -622,7 +624,7 @@
|
||||
window. This ensures that with zero tempo change the output will be same as input.
|
||||
</li>
|
||||
<li>Bugfix: Fix a bug in TDstrectch with too small initial skipFract value that occurred
|
||||
with certain processing parameter settings: Replace assert with assignment that
|
||||
with certain processing parameter settings: Replace assert with assignment that
|
||||
corrects the situation.
|
||||
</li>
|
||||
<li>Remove OpenMP "_init_threading" workaround from Android build as it's not needed with concurrent
|
||||
|
@ -440,8 +440,11 @@ var
|
||||
|
||||
procedure InitDLL;
|
||||
begin
|
||||
// for Windows: use 'SoundTouch.dll` as filename
|
||||
{$ifdef mswindows} // Windows
|
||||
SoundTouchLibHandle := LoadLibrary('.\SoundTouchDll.dll');
|
||||
{$else} // Unix
|
||||
SoundTouchLibHandle := LoadLibrary('./libSoundTouchDll.so');
|
||||
{$endif}
|
||||
if SoundTouchLibHandle <> 0 then
|
||||
try
|
||||
Pointer(SoundTouchCreateInstance) := GetProcAddress(SoundTouchLibHandle, 'soundtouch_createInstance');
|
||||
|
@ -17,9 +17,6 @@
|
||||
|
||||
include $(top_srcdir)/config/am_include.mk
|
||||
|
||||
#AUTOMAKE_OPTIONS = subdir-objects
|
||||
|
||||
|
||||
noinst_HEADERS=../SoundTouch/AAFilter.h ../SoundTouch/cpu_detect.h ../SoundTouch/cpu_detect_x86.cpp ../SoundTouch/FIRFilter.h \
|
||||
../SoundTouch/RateTransposer.h ../SoundTouch/TDStretch.h ../SoundTouch/PeakFinder.h ../SoundTouch/InterpolateCubic.h \
|
||||
../SoundTouch/InterpolateLinear.h ../SoundTouch/InterpolateShannon.h
|
||||
@ -34,13 +31,9 @@ libSoundTouchDll_la_SOURCES=../SoundTouch/AAFilter.cpp ../SoundTouch/FIRFilter.c
|
||||
../SoundTouch/BPMDetect.cpp ../SoundTouch/PeakFinder.cpp ../SoundTouch/InterpolateLinear.cpp \
|
||||
../SoundTouch/InterpolateCubic.cpp ../SoundTouch/InterpolateShannon.cpp SoundTouchDLL.cpp
|
||||
|
||||
# Compiler flags
|
||||
|
||||
# Modify the default 0.0.0 to LIB_SONAME.0.0
|
||||
#libSoundTouchDll_la_LDFLAGS=-version-info @LIB_SONAME@
|
||||
LDFLAGS=-version-info @LIB_SONAME@
|
||||
|
||||
|
||||
if X86
|
||||
CXXFLAGS1=-mstackrealign -msse
|
||||
endif
|
||||
@ -49,9 +42,4 @@ if X86_64
|
||||
CXXFLAGS2=-fPIC
|
||||
endif
|
||||
|
||||
#libSoundTouchDll_CXXFLAGS=$(AM_CXXFLAGS) $(CXXFLAGS1) $(CXXFLAGS2) -shared -DDLL_EXPORTS -fvisibility=hidden
|
||||
CXXFLAGS=$(AM_CXXFLAGS) $(CXXFLAGS1) $(CXXFLAGS2) -shared -DDLL_EXPORTS -fvisibility=hidden
|
||||
|
||||
# TODO:
|
||||
# - saatu kääntymään
|
||||
# - tee testi, toimiiko dll?
|
||||
|
@ -1,6 +1,9 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# This script compiles SoundTouch dynamic-link library for GNU environment
|
||||
# This script is deprecated. Don't use this, the makefile can now compile
|
||||
# the dynamic-link library 'libSoundTouchDLL.so' automatically.
|
||||
#
|
||||
# This script compiles SoundTouch dynamic-link library for GNU environment
|
||||
# with wrapper functions that are easier to import to Java / Mono / etc
|
||||
#
|
||||
|
||||
@ -11,11 +14,15 @@ if [[ $arch == *"86"* ]]; then
|
||||
# Intel x86/x64 architecture
|
||||
flags="$flags -mstackrealign -msse"
|
||||
|
||||
if [[ $arch == *"_64" ]]; then
|
||||
if [[ $arch == *"_64" ]]; then
|
||||
flags="$flags -fPIC"
|
||||
fi
|
||||
fi
|
||||
|
||||
echo "*************************************************************************"
|
||||
echo "NOTE: Rather use the makefile that can now build the dynamic-link library"
|
||||
echo "*************************************************************************"
|
||||
echo ""
|
||||
echo "Building SoundTouchDLL for $arch with flags:$flags"
|
||||
|
||||
g++ -O3 -ffast-math -shared $flags -DDLL_EXPORTS -fvisibility=hidden -I../../include \
|
||||
|
Loading…
Reference in New Issue
Block a user