diff --git a/.gitmodules b/.gitmodules index efe6b96d..7c21d026 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,6 +1,3 @@ [submodule "m4"] path = m4 url = ../icecast-m4.git -[submodule "src/common"] - path = src/common - url = ../icecast-common.git diff --git a/autogen.sh b/autogen.sh index 31f08af5..9e77802a 100755 --- a/autogen.sh +++ b/autogen.sh @@ -5,13 +5,10 @@ set -e srcdir=$(dirname "$0") test -n "$srcdir" && cd "$srcdir" -if ! { # Test for any file in the m4 submodule - test -e "$srcdir/m4/ax_check_compile_flag.m4" && -# Test for any file in the common submodule - test -e "$srcdir/src/common/log/log.c"; }; +if ! test -e "$srcdir/m4/ax_check_compile_flag.m4" then - echo "ERROR: Submodules missing! Ensure you git cloned with '--recursive' or run:" + echo "ERROR: Submodule missing! Ensure you git cloned with '--recursive' or run:" echo " git submodule update --init" exit 1 fi diff --git a/configure.ac b/configure.ac index 29953bb8..62ff8db2 100644 --- a/configure.ac +++ b/configure.ac @@ -8,6 +8,8 @@ AC_CONFIG_AUX_DIR([build-aux]) AC_PROG_CC +LT_INIT + AX_CHECK_COMPILE_FLAG([-std=c99], [ AX_APPEND_FLAG([-std=c99]) ], [ @@ -44,9 +46,6 @@ m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) AM_MAINTAINER_MODE([enable]) -LT_INIT - - dnl Sanitizer flags AC_ARG_WITH([sanitizer], @@ -100,8 +99,6 @@ AC_CHECK_HEADERS([sys/timeb.h]) AC_CHECK_HEADERS([sys/socket.h]) AC_CHECK_HEADERS([pwd.h grp.h]) -XIPH_NET - dnl Check for functions AC_FUNC_FORK AC_FUNC_CHOWN @@ -109,24 +106,17 @@ AC_FUNC_CHOWN AC_CHECK_FUNCS([setuid]) AC_CHECK_FUNCS([chroot]) AC_CHECK_FUNCS([strcasestr]) -AC_CHECK_FUNCS([gethostname]) AC_CHECK_FUNCS([uname]) AC_CHECK_FUNCS([setenv]) AC_CHECK_FUNCS([setresuid]) AC_CHECK_FUNCS([setresgid]) AC_CHECK_FUNCS([localtime_r]) -AC_CHECK_FUNCS([gettimeofday]) -AC_CHECK_FUNCS([ftime]) dnl Do not check for poll on Darwin, it is broken in some versions AS_IF([test "${SYS}" != "darwin"], [ AC_CHECK_FUNCS([poll]) ]) -AC_SEARCH_LIBS([nanosleep], [rt posix4], [ - AC_DEFINE([HAVE_NANOSLEEP], [1], [Define if you have nanosleep]) -]) - dnl Checks for types and typedefs AC_TYPE_OFF_T AC_TYPE_PID_T @@ -136,6 +126,16 @@ AC_TYPE_UID_T dnl Checks for required libraries +dnl +dnl permafrost +dnl +PKG_CHECK_MODULES([PERMAFROST], [permafrost], [], [ + AC_MSG_ERROR([${PERMAFROST_PKG_ERRORS}. permafrost is required.]) +]) + +CFLAGS="${CFLAGS} ${PERMAFROST_CFLAGS}" +LIBS="${LIBS} ${PERMAFROST_LIBS}" + dnl dnl libxml2 dnl @@ -274,24 +274,12 @@ AS_IF([test "$with_default_config" != "no"], [ ]) -dnl Make substitutions -AC_SUBST(XIPH_LIBS) -AC_SUBST(XIPH_CPPFLAGS) -AC_SUBST(XIPH_CFLAGS) -AC_SUBST(XIPH_LDFLAGS) - AC_CONFIG_HEADERS([config.h]) AC_CONFIG_FILES([ Makefile conf/Makefile src/Makefile - src/common/avl/Makefile - src/common/httpp/Makefile - src/common/thread/Makefile - src/common/log/Makefile - src/common/net/Makefile - src/common/timing/Makefile doc/Makefile web/Makefile admin/Makefile diff --git a/src/Makefile.am b/src/Makefile.am index a02637dd..7b98fa62 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,7 +1,5 @@ ## Process this with automake to create Makefile.in -SUBDIRS = common/avl common/net common/thread common/httpp common/log common/timing - bin_PROGRAMS = icecast noinst_HEADERS = \ @@ -132,15 +130,4 @@ EXTRA_icecast_SOURCES = \ format_theora.c \ format_speex.c -icecast_DEPENDENCIES = \ - common/net/libicenet.la \ - common/thread/libicethread.la \ - common/httpp/libicehttpp.la \ - common/log/libicelog.la \ - common/avl/libiceavl.la \ - common/timing/libicetiming.la - -icecast_LDADD = $(icecast_DEPENDENCIES) -icecast_CPPFLAGS = $(AM_CPPFLAGS) -I$(srcdir)/common - include $(srcdir)/tests/Makefile.am diff --git a/src/acl.h b/src/acl.h index 7be9d20a..ac9535db 100644 --- a/src/acl.h +++ b/src/acl.h @@ -16,7 +16,7 @@ #include #include #include -#include "common/httpp/httpp.h" +#include #include "icecasttypes.h" #include "cfgfile.h" diff --git a/src/auth.c b/src/auth.c index 9e1007a7..74e329f6 100644 --- a/src/auth.c +++ b/src/auth.c @@ -24,13 +24,14 @@ #include #include +#include + #include "auth.h" #include "source.h" #include "client.h" #include "errors.h" #include "cfgfile.h" #include "stats.h" -#include "common/httpp/httpp.h" #include "fserve.h" #include "admin.h" #include "acl.h" diff --git a/src/auth.h b/src/auth.h index 91c4715c..f34ce5ed 100644 --- a/src/auth.h +++ b/src/auth.h @@ -22,8 +22,8 @@ #include #include -#include "common/thread/thread.h" -#include "common/httpp/httpp.h" +#include +#include #include "icecasttypes.h" #include "cfgfile.h" diff --git a/src/auth_htpasswd.c b/src/auth_htpasswd.c index 48bf347e..7b35d61c 100644 --- a/src/auth_htpasswd.c +++ b/src/auth_htpasswd.c @@ -26,11 +26,12 @@ #include #include +#include + #include "auth.h" #include "source.h" #include "client.h" #include "cfgfile.h" -#include "common/httpp/httpp.h" #include "md5.h" #include "logging.h" diff --git a/src/auth_url.c b/src/auth_url.c index b83c8db6..9988f512 100644 --- a/src/auth_url.c +++ b/src/auth_url.c @@ -74,7 +74,8 @@ #include "client.h" #include "cfgfile.h" #include "connection.h" -#include "common/httpp/httpp.h" + +#include #include "logging.h" #define CATMODULE "auth_url" diff --git a/src/cfgfile.c b/src/cfgfile.c index 1ec825d0..39ee209f 100644 --- a/src/cfgfile.c +++ b/src/cfgfile.c @@ -26,7 +26,7 @@ #include #include -#include "common/thread/thread.h" +#include #include "cfgfile.h" #include "global.h" diff --git a/src/cfgfile.h b/src/cfgfile.h index f2bcb104..d4f9f7a9 100644 --- a/src/cfgfile.h +++ b/src/cfgfile.h @@ -23,8 +23,9 @@ #define MAX_YP_DIRECTORIES 25 #include -#include "common/thread/thread.h" -#include "common/avl/avl.h" +#include +#include + #include "icecasttypes.h" #include "compat.h" diff --git a/src/client.c b/src/client.c index ea3b0216..d0787ed9 100644 --- a/src/client.c +++ b/src/client.c @@ -26,9 +26,9 @@ #include -#include "common/thread/thread.h" -#include "common/avl/avl.h" -#include "common/httpp/httpp.h" +#include +#include +#include #include "global.h" #include "refobject.h" diff --git a/src/client.h b/src/client.h index 89996809..67d4df5e 100644 --- a/src/client.h +++ b/src/client.h @@ -19,8 +19,8 @@ #ifndef __CLIENT_H__ #define __CLIENT_H__ -#include "common/httpp/httpp.h" -#include "common/httpp/encoding.h" +#include +#include #include "icecasttypes.h" #include "errors.h" diff --git a/src/common b/src/common deleted file mode 160000 index ad5fc100..00000000 --- a/src/common +++ /dev/null @@ -1 +0,0 @@ -Subproject commit ad5fc1006122f42abd34ade3f42bf2779297140d diff --git a/src/connection.c b/src/connection.c index e3640f22..084a2f4d 100644 --- a/src/connection.c +++ b/src/connection.c @@ -33,10 +33,10 @@ #include #endif -#include "common/thread/thread.h" -#include "common/avl/avl.h" -#include "common/net/sock.h" -#include "common/httpp/httpp.h" +#include +#include +#include +#include #include "compat.h" #include "connection.h" diff --git a/src/connection.h b/src/connection.h index 3261d1ee..22051433 100644 --- a/src/connection.h +++ b/src/connection.h @@ -21,8 +21,9 @@ #include "icecasttypes.h" #include "compat.h" -#include "common/thread/thread.h" -#include "common/net/sock.h" + +#include +#include typedef unsigned long connection_id_t; diff --git a/src/event.h b/src/event.h index 3ef2b497..dc01add2 100644 --- a/src/event.h +++ b/src/event.h @@ -13,7 +13,7 @@ #include #include -#include "common/thread/thread.h" +#include #include "icecasttypes.h" diff --git a/src/fastevent.c b/src/fastevent.c index 5ab90b64..174d4d5e 100644 --- a/src/fastevent.c +++ b/src/fastevent.c @@ -17,7 +17,7 @@ #include #include -#include "common/thread/thread.h" +#include #include "fastevent.h" diff --git a/src/format.h b/src/format.h index 5ddae298..83cc7937 100644 --- a/src/format.h +++ b/src/format.h @@ -25,7 +25,8 @@ #include "client.h" #include "refbuf.h" #include "cfgfile.h" -#include "common/httpp/httpp.h" + +#include typedef enum _format_type_tag { diff --git a/src/format_mp3.c b/src/format_mp3.c index 1d476dad..eedf5130 100644 --- a/src/format_mp3.c +++ b/src/format_mp3.c @@ -36,7 +36,8 @@ #include "stats.h" #include "format.h" -#include "common/httpp/httpp.h" + +#include #include "logging.h" diff --git a/src/fserve.c b/src/fserve.c index 4d8e5a35..032661e4 100644 --- a/src/fserve.c +++ b/src/fserve.c @@ -42,10 +42,10 @@ #endif #endif -#include "common/thread/thread.h" -#include "common/avl/avl.h" -#include "common/httpp/httpp.h" -#include "common/net/sock.h" +#include +#include +#include +#include #include "fserve.h" #include "compat.h" diff --git a/src/global.c b/src/global.c index 2a2fec6f..6ca44857 100644 --- a/src/global.c +++ b/src/global.c @@ -18,8 +18,8 @@ #include -#include "common/thread/thread.h" -#include "common/avl/avl.h" +#include +#include #include "global.h" #include "refobject.h" diff --git a/src/global.h b/src/global.h index 1415d1e9..c15c78ae 100644 --- a/src/global.h +++ b/src/global.h @@ -21,8 +21,8 @@ #define ICECAST_VERSION_STRING "Icecast " PACKAGE_VERSION -#include "common/thread/thread.h" -#include "common/avl/avl.h" +#include +#include #include "icecasttypes.h" typedef struct ice_global_tag diff --git a/src/listensocket.c b/src/listensocket.c index 2fef714a..a0cdac1b 100644 --- a/src/listensocket.c +++ b/src/listensocket.c @@ -22,8 +22,8 @@ #include -#include "common/net/sock.h" -#include "common/thread/thread.h" +#include +#include #include "listensocket.h" #include "global.h" diff --git a/src/logging.c b/src/logging.c index 145dbfcc..c5ea479f 100644 --- a/src/logging.c +++ b/src/logging.c @@ -19,8 +19,8 @@ #include #include -#include "common/thread/thread.h" -#include "common/httpp/httpp.h" +#include +#include #include "logging.h" #include "connection.h" diff --git a/src/logging.h b/src/logging.h index 9ffde1f7..ab83a60b 100644 --- a/src/logging.h +++ b/src/logging.h @@ -14,7 +14,7 @@ #ifndef __LOGGING_H__ #define __LOGGING_H__ -#include "common/log/log.h" +#include #include "icecasttypes.h" diff --git a/src/main.c b/src/main.c index b2e6ecb1..4ba41697 100644 --- a/src/main.c +++ b/src/main.c @@ -44,10 +44,10 @@ #include #endif -#include "common/thread/thread.h" -#include "common/net/sock.h" -#include "common/net/resolver.h" -#include "common/httpp/httpp.h" +#include +#include +#include +#include #if HAVE_SYS_TYPES_H #include diff --git a/src/matchfile.c b/src/matchfile.c index a3b71af3..3896474b 100644 --- a/src/matchfile.c +++ b/src/matchfile.c @@ -19,7 +19,7 @@ #include #include -#include "common/avl/avl.h" +#include #include "matchfile.h" #include "logging.h" diff --git a/src/module.c b/src/module.c index 52287f42..4c2e7760 100644 --- a/src/module.c +++ b/src/module.c @@ -13,8 +13,8 @@ #include #include -#include "common/thread/thread.h" -#include "common/avl/avl.h" +#include +#include #include "refobject.h" #include "module.h" diff --git a/src/refobject.c b/src/refobject.c index 7b8eb464..14da9172 100644 --- a/src/refobject.c +++ b/src/refobject.c @@ -13,7 +13,7 @@ #include #include -#include "common/thread/thread.h" +#include #include "refobject.h" diff --git a/src/refobject.h b/src/refobject.h index 2e7ec504..d252a2cc 100644 --- a/src/refobject.h +++ b/src/refobject.h @@ -17,9 +17,10 @@ #include #endif + #include -#include "common/thread/thread.h" +#include #include "icecasttypes.h" #include "compat.h" diff --git a/src/reportxml.c b/src/reportxml.c index afed1966..c0da9eb5 100644 --- a/src/reportxml.c +++ b/src/reportxml.c @@ -16,8 +16,8 @@ #include -#include "common/thread/thread.h" -#include "common/avl/avl.h" +#include +#include #include "reportxml.h" #include "refobject.h" diff --git a/src/sighandler.c b/src/sighandler.c index 6057e445..7083c46f 100644 --- a/src/sighandler.c +++ b/src/sighandler.c @@ -17,9 +17,9 @@ #include -#include "common/thread/thread.h" -#include "common/avl/avl.h" -#include "common/httpp/httpp.h" +#include +#include +#include #include "global.h" #include "connection.h" diff --git a/src/slave.c b/src/slave.c index 145871fb..23fe5586 100644 --- a/src/slave.c +++ b/src/slave.c @@ -38,10 +38,11 @@ #include "compat.h" #include -#include "common/thread/thread.h" -#include "common/avl/avl.h" -#include "common/net/sock.h" -#include "common/httpp/httpp.h" + +#include +#include +#include +#include #include "slave.h" #include "cfgfile.h" diff --git a/src/slave.h b/src/slave.h index 3814f94a..6b55e6be 100644 --- a/src/slave.h +++ b/src/slave.h @@ -14,7 +14,7 @@ #ifndef __SLAVE_H__ #define __SLAVE_H__ -#include "common/thread/thread.h" +#include #include "icecasttypes.h" #include "cfgfile.h" diff --git a/src/source.c b/src/source.c index d944cf40..e01b669e 100644 --- a/src/source.c +++ b/src/source.c @@ -39,9 +39,9 @@ #define snprintf _snprintf #endif -#include "common/thread/thread.h" -#include "common/avl/avl.h" -#include "common/httpp/httpp.h" +#include +#include +#include #include "source.h" #include "compat.h" diff --git a/src/source.h b/src/source.h index adb5f835..faedce4a 100644 --- a/src/source.h +++ b/src/source.h @@ -16,8 +16,8 @@ #include -#include "common/thread/thread.h" -#include "common/httpp/httpp.h" +#include +#include #include "icecasttypes.h" #include "yp.h" diff --git a/src/stats.c b/src/stats.c index b8a4fb5a..35b75945 100644 --- a/src/stats.c +++ b/src/stats.c @@ -25,10 +25,10 @@ #include #include -#include "common/thread/thread.h" -#include "common/avl/avl.h" -#include "common/httpp/httpp.h" -#include "common/net/sock.h" +#include +#include +#include +#include #include "stats.h" #include "connection.h" diff --git a/src/tests/Makefile.am b/src/tests/Makefile.am index bfa9497b..c539e626 100644 --- a/src/tests/Makefile.am +++ b/src/tests/Makefile.am @@ -30,15 +30,11 @@ check_PROGRAMS += ctest_resourcematch.test ctest_refobject_test_SOURCES = %reldir%/ctest_refobject.c ctest_refobject_test_LDADD = libice_ctest.la \ - common/thread/libicethread.la \ - common/avl/libiceavl.la \ icecast-refobject.o check_PROGRAMS += ctest_refobject.test ctest_buffer_test_SOURCES = %reldir%/ctest_buffer.c ctest_buffer_test_LDADD = libice_ctest.la \ - common/thread/libicethread.la \ - common/avl/libiceavl.la \ icecast-refobject.o \ icecast-buffer.o check_PROGRAMS += ctest_buffer.test diff --git a/src/tls.h b/src/tls.h index 35266cb5..f4e4da3a 100644 --- a/src/tls.h +++ b/src/tls.h @@ -9,7 +9,7 @@ #ifndef __TLS_H__ #define __TLS_H__ -#include "common/net/sock.h" +#include /* Do we have TLS Support? */ #if defined(HAVE_OPENSSL) diff --git a/src/util.c b/src/util.c index 85368319..fe433ff6 100644 --- a/src/util.c +++ b/src/util.c @@ -39,8 +39,8 @@ #include #endif -#include "common/net/sock.h" -#include "common/thread/thread.h" +#include +#include #include "util.h" #include "compat.h" diff --git a/src/util.h b/src/util.h index 65ea074f..1ea3aebc 100644 --- a/src/util.h +++ b/src/util.h @@ -17,7 +17,7 @@ /* for FILE* */ #include -#include "common/net/sock.h" +#include #include "icecasttypes.h" #define UNKNOWN_CONTENT 0 diff --git a/src/xslt.c b/src/xslt.c index 1d33fede..792a353b 100644 --- a/src/xslt.c +++ b/src/xslt.c @@ -41,10 +41,10 @@ #define snprintf _snprintf #endif -#include "common/thread/thread.h" -#include "common/avl/avl.h" -#include "common/httpp/httpp.h" -#include "common/net/sock.h" +#include +#include +#include +#include #include "xslt.h" #include "refbuf.h" diff --git a/src/yp.c b/src/yp.c index b736de87..39a7392a 100644 --- a/src/yp.c +++ b/src/yp.c @@ -20,7 +20,7 @@ #include #include -#include "common/thread/thread.h" +#include #include "yp.h" #include "global.h"