diff options
author | Jean-Marc Valin <jean-marc.valin@octasic.com> | 2008-12-23 17:31:39 +0300 |
---|---|---|
committer | Jean-Marc Valin <jean-marc.valin@octasic.com> | 2008-12-23 17:31:39 +0300 |
commit | 4d108fc37a37e9f851340ada51ff301cf2b5a315 (patch) | |
tree | e2092c9ae09f229d7183f0e1e9be405e6ec93078 /tests | |
parent | 61832f162fea8d5a3d52524533429182b1127f2b (diff) |
Unit tests now #include the relevant source files to prevent symbol visibility
problems when building shared libraries only.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/Makefile.am | 3 | ||||
-rw-r--r-- | tests/cwrs32-test.c | 8 | ||||
-rw-r--r-- | tests/dft-test.c | 3 | ||||
-rw-r--r-- | tests/ectest.c | 6 | ||||
-rw-r--r-- | tests/laplace-test.c | 8 | ||||
-rw-r--r-- | tests/mdct-test.c | 3 | ||||
-rw-r--r-- | tests/real-fft-test.c | 3 |
7 files changed, 31 insertions, 3 deletions
diff --git a/tests/Makefile.am b/tests/Makefile.am index 36ced45..5655845 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -14,6 +14,3 @@ laplace_test_SOURCES = laplace-test.c mdct_test_SOURCES = mdct-test.c #rotation_test_SOURCES = rotation-test.c mathops_test_SOURCES = mathops-test.c - -AM_LDFLAGS = -static -LDADD = $(top_builddir)/libcelt/libcelt.la diff --git a/tests/cwrs32-test.c b/tests/cwrs32-test.c index b6ef23d..22f40ea 100644 --- a/tests/cwrs32-test.c +++ b/tests/cwrs32-test.c @@ -5,6 +5,14 @@ #include <stdio.h> #include "cwrs.h" #include <string.h> + +#include "../libcelt/cwrs.c" +#include "../libcelt/rangeenc.c" +#include "../libcelt/rangedec.c" +#include "../libcelt/entenc.c" +#include "../libcelt/entdec.c" +#include "../libcelt/entcode.c" + #define NMAX (10) #define MMAX (9) diff --git a/tests/dft-test.c b/tests/dft-test.c index 4e9c0ab..348746c 100644 --- a/tests/dft-test.c +++ b/tests/dft-test.c @@ -5,6 +5,9 @@ #include <stdio.h> #include "kiss_fft.h" +#include "../libcelt/kiss_fft.c" + + #ifndef M_PI #define M_PI 3.141592653 #endif diff --git a/tests/ectest.c b/tests/ectest.c index 49d39a1..3972518 100644 --- a/tests/ectest.c +++ b/tests/ectest.c @@ -9,6 +9,12 @@ #include "entenc.h" #include "entdec.h" +#include "../libcelt/rangeenc.c" +#include "../libcelt/rangedec.c" +#include "../libcelt/entenc.c" +#include "../libcelt/entdec.c" +#include "../libcelt/entcode.c" + #ifndef M_LOG2E # define M_LOG2E 1.4426950408889634074 #endif diff --git a/tests/laplace-test.c b/tests/laplace-test.c index de10b82..b797c1a 100644 --- a/tests/laplace-test.c +++ b/tests/laplace-test.c @@ -7,6 +7,14 @@ #include "laplace.h" #include "stack_alloc.h" +#include "../libcelt/rangeenc.c" +#include "../libcelt/rangedec.c" +#include "../libcelt/entenc.c" +#include "../libcelt/entdec.c" +#include "../libcelt/entcode.c" +#include "../libcelt/laplace.c" + + int main(void) { int i; diff --git a/tests/mdct-test.c b/tests/mdct-test.c index cd6acae..6a9393d 100644 --- a/tests/mdct-test.c +++ b/tests/mdct-test.c @@ -6,6 +6,9 @@ #include "mdct.h" #include "stack_alloc.h" +#include "../libcelt/kiss_fft.c" +#include "../libcelt/mdct.c" + #ifndef M_PI #define M_PI 3.141592653 #endif diff --git a/tests/real-fft-test.c b/tests/real-fft-test.c index aa9c395..9f49795 100644 --- a/tests/real-fft-test.c +++ b/tests/real-fft-test.c @@ -7,6 +7,9 @@ #include <stdio.h> #include <string.h> +#include "../libcelt/kiss_fft.c" +#include "../libcelt/kiss_fftr.c" + int ret=0; static |