From 4923f3f80ecd77e8f3c549a7fca31c4fd83c9c4d Mon Sep 17 00:00:00 2001 From: Jean-Marc Valin Date: Wed, 26 Oct 2011 21:36:57 -0400 Subject: [PATCH] Moves the main headers from src/ to include/ --- Makefile.am | 12 ++++++------ Makefile.draft | 3 ++- celt/tests/Makefile.am | 2 +- celt_headers.txt | 4 ++-- doc/Doxyfile.in | 8 ++++---- doc/Makefile.am | 8 ++++---- doc/build_draft.sh | 3 ++- {src => include}/opus.h | 0 {celt => include}/opus_custom.h | 0 {celt => include}/opus_defines.h | 0 {src => include}/opus_multistream.h | 0 {celt => include}/opus_types.h | 0 opus_headers.txt | 4 ++-- tests/test_opus_api.c | 2 +- tests/test_opus_decode.c | 2 +- tests/test_opus_encode.c | 2 +- 16 files changed, 26 insertions(+), 24 deletions(-) rename {src => include}/opus.h (100%) rename {celt => include}/opus_custom.h (100%) rename {celt => include}/opus_defines.h (100%) rename {src => include}/opus_multistream.h (100%) rename {celt => include}/opus_types.h (100%) diff --git a/Makefile.am b/Makefile.am index 2309232f..056d4477 100644 --- a/Makefile.am +++ b/Makefile.am @@ -4,7 +4,7 @@ lib_LTLIBRARIES = libopus.la SUBDIRS = . celt/tests doc -INCLUDES = -I$(top_srcdir)/celt -I$(top_srcdir)/silk -I$(top_srcdir)/silk/float -I$(top_srcdir)/silk/fixed +INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/celt -I$(top_srcdir)/silk -I$(top_srcdir)/silk/float -I$(top_srcdir)/silk/fixed include celt_sources.mk include silk_sources.mk @@ -22,7 +22,7 @@ include opus_headers.txt libopus_la_SOURCES = $(CELT_SOURCES) $(SILK_SOURCES) $(OPUS_SOURCES) -pkginclude_HEADERS = src/opus.h src/opus_multistream.h celt/opus_types.h celt/opus_defines.h +pkginclude_HEADERS = include/opus.h include/opus_multistream.h include/opus_types.h include/opus_defines.h noinst_HEADERS = $(OPUS_HEAD) $(SILK_HEAD) $(CELT_HEAD) @@ -41,17 +41,17 @@ repacketizer_demo_LDADD = libopus.la -lm opus_compare_SOURCES = src/opus_compare.c opus_compare_LDADD = -lm -test_opus_api_SOURCES = tests/test_opus_api.c +test_opus_api_SOURCES = tests/test_opus_api.c tests/test_opus_common.h test_opus_api_LDADD = libopus.la -lm -test_opus_encode_SOURCES = tests/test_opus_encode.c +test_opus_encode_SOURCES = tests/test_opus_encode.c tests/test_opus_common.h test_opus_encode_LDADD = libopus.la -lm -test_opus_decode_SOURCES = tests/test_opus_decode.c +test_opus_decode_SOURCES = tests/test_opus_decode.c tests/test_opus_common.h test_opus_decode_LDADD = libopus.la -lm if CUSTOM_MODES -pkginclude_HEADERS += celt/opus_custom.h +pkginclude_HEADERS += include/opus_custom.h noinst_PROGRAMS += opus_custom_demo opus_custom_demo_SOURCES = celt/opus_custom_demo.c opus_custom_demo_LDADD = libopus.la -lm diff --git a/Makefile.draft b/Makefile.draft index afd026e1..4fb6d0e9 100644 --- a/Makefile.draft +++ b/Makefile.draft @@ -53,7 +53,8 @@ ifdef FIXED_POINT CFLAGS += -DFIXED_POINT=1 -DDISABLE_FLOAT_API endif -CINCLUDES += silk/ \ +CINCLUDES += include/ \ + silk/ \ silk/float/ \ silk/fixed/ \ celt/ \ diff --git a/celt/tests/Makefile.am b/celt/tests/Makefile.am index 9c4d899a..0dfdfd9f 100644 --- a/celt/tests/Makefile.am +++ b/celt/tests/Makefile.am @@ -1,4 +1,4 @@ -INCLUDES = -I$(top_srcdir)/celt +INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/celt METASOURCES = AUTO TESTS = type-test ectest cwrs32-test dft-test laplace-test mdct-test mathops-test rotation-test diff --git a/celt_headers.txt b/celt_headers.txt index dd9d335f..492e87a6 100644 --- a/celt_headers.txt +++ b/celt_headers.txt @@ -2,8 +2,8 @@ CELT_HEAD = \ celt/arch.h \ celt/bands.h \ celt/celt.h \ -celt/opus_types.h \ -celt/opus_defines.h \ +include/opus_types.h \ +include/opus_defines.h \ celt/cwrs.h \ celt/ecintrin.h \ celt/entcode.h \ diff --git a/doc/Doxyfile.in b/doc/Doxyfile.in index ff808524..5bf1f879 100644 --- a/doc/Doxyfile.in +++ b/doc/Doxyfile.in @@ -610,10 +610,10 @@ WARN_LOGFILE = # directories like "/usr/src/myproject". Separate the files or directories # with spaces. -INPUT = @top_srcdir@/src/opus.h \ - @top_srcdir@/celt/opus_types.h \ - @top_srcdir@/celt/opus_defines.h \ - @top_srcdir@/src/opus_multistream.h +INPUT = @top_srcdir@/include/opus.h \ + @top_srcdir@/include/opus_types.h \ + @top_srcdir@/include/opus_defines.h \ + @top_srcdir@/include/opus_multistream.h # This tag can be used to specify the character encoding of the source files # that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is diff --git a/doc/Makefile.am b/doc/Makefile.am index bd7eba3f..b36b064c 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -1,9 +1,9 @@ ## Process this file with automake to produce Makefile.in -DOCINPUTS = $(top_srcdir)/src/opus.h \ - $(top_srcdir)/src/opus_multistream.h \ - $(top_srcdir)/celt/opus_defines.h \ - $(top_srcdir)/celt/opus_types.h +DOCINPUTS = $(top_srcdir)/include/opus.h \ + $(top_srcdir)/include/opus_multistream.h \ + $(top_srcdir)/include/opus_defines.h \ + $(top_srcdir)/include/opus_types.h doc_DATA = doxygen-build.stamp diff --git a/doc/build_draft.sh b/doc/build_draft.sh index 703399bd..1c12847e 100755 --- a/doc/build_draft.sh +++ b/doc/build_draft.sh @@ -16,6 +16,7 @@ mkdir "${destdir}/silk" mkdir "${destdir}/silk/float" mkdir "${destdir}/silk/fixed" mkdir "${destdir}/celt" +mkdir "${destdir}/include" for f in `cat "${toplevel}"/opus_sources.mk "${toplevel}"/celt_sources.mk \ "${toplevel}"/silk_sources.mk "${toplevel}"/opus_headers.txt \ "${toplevel}"/celt_headers.txt "${toplevel}"/silk_headers.txt \ @@ -25,7 +26,7 @@ done cp -a "${toplevel}"/src/opus_demo.c "${destdir}"/src/ cp -a "${toplevel}"/src/opus_compare.c "${destdir}"/src/ cp -a "${toplevel}"/celt/opus_custom_demo.c "${destdir}"/celt/ -cp -a "${toplevel}"/celt/opus_custom.h "${destdir}"/celt/ +cp -a "${toplevel}"/include/opus_custom.h "${destdir}"/celt/ cp -a "${toplevel}"/Makefile.draft "${destdir}"/Makefile cp -a "${toplevel}"/opus_sources.mk "${destdir}"/ cp -a "${toplevel}"/celt_sources.mk "${destdir}"/ diff --git a/src/opus.h b/include/opus.h similarity index 100% rename from src/opus.h rename to include/opus.h diff --git a/celt/opus_custom.h b/include/opus_custom.h similarity index 100% rename from celt/opus_custom.h rename to include/opus_custom.h diff --git a/celt/opus_defines.h b/include/opus_defines.h similarity index 100% rename from celt/opus_defines.h rename to include/opus_defines.h diff --git a/src/opus_multistream.h b/include/opus_multistream.h similarity index 100% rename from src/opus_multistream.h rename to include/opus_multistream.h diff --git a/celt/opus_types.h b/include/opus_types.h similarity index 100% rename from celt/opus_types.h rename to include/opus_types.h diff --git a/opus_headers.txt b/opus_headers.txt index 4fc5b659..f160710c 100644 --- a/opus_headers.txt +++ b/opus_headers.txt @@ -1,4 +1,4 @@ OPUS_HEAD = \ -src/opus.h \ -src/opus_multistream.h \ +include/opus.h \ +include/opus_multistream.h \ src/opus_private.h diff --git a/tests/test_opus_api.c b/tests/test_opus_api.c index 60ae2960..e4afd584 100644 --- a/tests/test_opus_api.c +++ b/tests/test_opus_api.c @@ -49,7 +49,7 @@ #include #include #include -#include "../src/opus.h" +#include "../include/opus.h" #include "test_opus_common.h" #ifdef VALGRIND diff --git a/tests/test_opus_decode.c b/tests/test_opus_decode.c index ac521a22..605e4f99 100644 --- a/tests/test_opus_decode.c +++ b/tests/test_opus_decode.c @@ -37,7 +37,7 @@ #include #include #include -#include "../src/opus.h" +#include "../include/opus.h" #include "test_opus_common.h" #define MAX_PACKET (1500) diff --git a/tests/test_opus_encode.c b/tests/test_opus_encode.c index 4ec536fe..7bdb89da 100644 --- a/tests/test_opus_encode.c +++ b/tests/test_opus_encode.c @@ -37,7 +37,7 @@ #include #include #include -#include "../src/opus.h" +#include "../include/opus.h" #include "../src/opus_private.h" #include "test_opus_common.h"