diff options
Diffstat (limited to 'pjmedia/include')
-rw-r--r-- | pjmedia/include/pjmedia-codec/config.h | 7 | ||||
-rw-r--r-- | pjmedia/include/pjmedia-codec/config_auto.h.in | 59 | ||||
-rw-r--r-- | pjmedia/include/pjmedia/config.h | 10 | ||||
-rw-r--r-- | pjmedia/include/pjmedia/config_auto.h.in | 42 |
4 files changed, 115 insertions, 3 deletions
diff --git a/pjmedia/include/pjmedia-codec/config.h b/pjmedia/include/pjmedia-codec/config.h index 85bd7785..4f2f82d3 100644 --- a/pjmedia/include/pjmedia-codec/config.h +++ b/pjmedia/include/pjmedia-codec/config.h @@ -21,6 +21,12 @@ #include <pjmedia/types.h> +/* + * Include config_auto.h if autoconf is used (PJ_AUTOCONF is set) + */ +#if defined(PJ_AUTOCONF) +# include <pjmedia-codec/config_auto.h> +#endif /** * Unless specified otherwise, L16 codec is included by default. @@ -56,3 +62,4 @@ #endif /* __PJMEDIA_CODEC_CONFIG_H__ */ + diff --git a/pjmedia/include/pjmedia-codec/config_auto.h.in b/pjmedia/include/pjmedia-codec/config_auto.h.in new file mode 100644 index 00000000..528390cd --- /dev/null +++ b/pjmedia/include/pjmedia-codec/config_auto.h.in @@ -0,0 +1,59 @@ +/* $Id$ */ +/* + * Copyright (C) 2003-2006 Benny Prijono <benny@prijono.org> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ +#ifndef __PJMEDIA_CODEC_CONFIG_AUTO_H_ +#define __PJMEDIA_CODEC_CONFIG_AUTO_H_ + +/** + * @file config_auto.h + * @brief PJMEDIA-CODEC configuration as set by autoconf script + */ + +/* + * Note: + * The configuration in config_site.h overrides any other settings, + * including the setting as detected by autoconf. + */ + +/* L16 codec */ +#ifndef PJMEDIA_HAS_L16_CODEC +#undef PJMEDIA_HAS_L16_CODEC +#endif + + +/* GSM codec */ +#ifndef PJMEDIA_HAS_GSM_CODEC +#undef PJMEDIA_HAS_GSM_CODEC +#endif + + +/* Speex codec */ +#ifndef PJMEDIA_HAS_SPEEX_CODEC +#undef PJMEDIA_HAS_SPEEX_CODEC +#endif + + +/* iLBC codec */ +#ifndef PJMEDIA_HAS_ILBC_CODEC +#undef PJMEDIA_HAS_ILBC_CODEC +#endif + + +#endif /* __PJMEDIA_CODEC_CONFIG_AUTO_H_ */ + + diff --git a/pjmedia/include/pjmedia/config.h b/pjmedia/include/pjmedia/config.h index fcd2b20a..11bd8df8 100644 --- a/pjmedia/include/pjmedia/config.h +++ b/pjmedia/include/pjmedia/config.h @@ -38,6 +38,13 @@ */ /* + * Include config_auto.h if autoconf is used (PJ_AUTOCONF is set) + */ +#if defined(PJ_AUTOCONF) +# include <pjmedia/config_auto.h> +#endif + +/* * Types of sound stream backends. */ @@ -91,9 +98,6 @@ /** * Unless specified otherwise, G711 codec is included by default. - * Note that there are parts of G711 codec (such as linear2ulaw) that are - * needed by other PJMEDIA components (e.g. silence detector, conference). - * Thus disabling G711 is generally not a good idea. */ #ifndef PJMEDIA_HAS_G711_CODEC # define PJMEDIA_HAS_G711_CODEC 1 diff --git a/pjmedia/include/pjmedia/config_auto.h.in b/pjmedia/include/pjmedia/config_auto.h.in new file mode 100644 index 00000000..1d792522 --- /dev/null +++ b/pjmedia/include/pjmedia/config_auto.h.in @@ -0,0 +1,42 @@ +/* $Id$ */ +/* + * Copyright (C) 2003-2006 Benny Prijono <benny@prijono.org> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ +#ifndef __PJMEDIA_CONFIG_AUTO_H_ +#define __PJMEDIA_CONFIG_AUTO_H_ + +/** + * @file config_auto.h + * @brief PJMEDIA configuration as set by autoconf script + */ + +/* + * Note: + * The configuration in config_site.h overrides any other settings, + * including the setting as detected by autoconf. + */ + +/* G711 codec */ +#ifndef PJMEDIA_HAS_G711_CODEC +#undef PJMEDIA_HAS_G711_CODEC +#endif + + +#endif /* __PJMEDIA_CONFIG_AUTO_H_ */ + + + |