Summary: | ASTERISK-01039: compile errors on openbsd (from dev list) | ||
Reporter: | mxhess (mxhess) | Labels: | |
Date Opened: | 2004-02-16 19:12:23.000-0600 | Date Closed: | 2011-06-07 14:10:38 |
Priority: | Minor | Regression? | No |
Status: | Closed/Complete | Components: | Core/Configuration |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ( 0) aesopt.h.diff ( 1) frame.h.diff ( 2) Makefile.codecs.gsm.diff ( 3) Makefile.codecs.lpc10.diff | |
Description: | I noticed a few compile errors when trying to compile asterisk on openbsd 3.4 (1.0 cvs tag). sys/endian.h shouldn't be called directly and instead sys/types.h should be in the include.. below is the output of cvs diff -u. I also had to comment out the -march= inclusion when it's blank as the compiler seemed to hate that. But with these changes asterisk compiled and ran so I figured I'd send it in and see what everyone thought. ****** ADDITIONAL INFORMATION ****** cvs server: Diffing . Index: aesopt.h =================================================================== RCS file: /usr/cvsroot/asterisk/aesopt.h,v retrieving revision 1.2 diff -u -r1.2 aesopt.h --- aesopt.h 7 Jan 2004 20:45:50 -0000 1.2 +++ aesopt.h 16 Feb 2004 17:18:03 -0000 @@ -148,8 +148,10 @@ /* PLATFORM SPECIFIC INCLUDES */ -#if defined( __FreeBSD__ ) || defined( __OpenBSD__ ) +#if defined( __FreeBSD__ ) # include <sys/endian.h> +#elif defined( __OpenBSD__ ) +# include <sys/types.h> #elif defined( BSD ) && ( BSD >= 199103 ) # include <machine/endian.h> #elif defined( __GNUC__ ) || defined( __GNU_LIBRARY__ ) cvs server: Diffing agi cvs server: Diffing apps cvs server: Diffing astman cvs server: Diffing cdr cvs server: Diffing channels cvs server: Diffing channels/h323 cvs server: Diffing codecs cvs server: Diffing codecs/gsm Index: codecs/gsm/Makefile =================================================================== RCS file: /usr/cvsroot/asterisk/codecs/gsm/Makefile,v retrieving revision 1.12 diff -u -r1.12 Makefile --- codecs/gsm/Makefile 15 Jan 2004 21:31:26 -0000 1.12 +++ codecs/gsm/Makefile 16 Feb 2004 17:18:08 -0000 @@ -40,7 +40,7 @@ ifneq (${OSARCH},Darwin) ifneq (${PROC},x86_64) ifneq ($(shell uname -m),ppc) -OPTIMIZE+=-march=$(PROC) +#OPTIMIZE+=-march=$(PROC) endif endif endif cvs server: Diffing codecs/gsm/inc cvs server: Diffing codecs/gsm/src cvs server: Diffing codecs/ilbc cvs server: Diffing codecs/lpc10 Index: codecs/lpc10/Makefile =================================================================== RCS file: /usr/cvsroot/asterisk/codecs/lpc10/Makefile,v retrieving revision 1.9 diff -u -r1.9 Makefile --- codecs/lpc10/Makefile 8 Jan 2004 16:52:11 -0000 1.9 +++ codecs/lpc10/Makefile 16 Feb 2004 17:18:09 -0000 @@ -29,7 +29,7 @@ ifneq ($(OSARCH),Darwin) ifneq ($(PROC),ppc) ifneq ($(PROC),x86_64) - CFLAGS+= -march=$(PROC) +# CFLAGS+= -march=$(PROC) endif endif endif cvs server: Diffing configs cvs server: Diffing contrib cvs server: Diffing contrib/init.d cvs server: Diffing contrib/scripts cvs server: Diffing contrib/thirdparty cvs server: Diffing db1-ast cvs server: Diffing db1-ast/btree cvs server: Diffing db1-ast/db cvs server: Diffing db1-ast/hash cvs server: Diffing db1-ast/include cvs server: Diffing db1-ast/mpool cvs server: Diffing db1-ast/recno cvs server: Diffing doc cvs server: Diffing editline cvs server: Diffing editline/TEST cvs server: Diffing editline/np cvs server: Diffing editline/readline cvs server: Diffing formats cvs server: Diffing images cvs server: Diffing include cvs server: Diffing include/asterisk Index: include/asterisk/frame.h =================================================================== RCS file: /usr/cvsroot/asterisk/include/asterisk/frame.h,v retrieving revision 1.27 diff -u -r1.27 frame.h --- include/asterisk/frame.h 4 Nov 2003 02:40:09 -0000 1.27 +++ include/asterisk/frame.h 16 Feb 2004 17:18:11 -0000 @@ -26,8 +26,10 @@ #ifndef __BYTE_ORDER #ifdef __linux__ #include <endian.h> -#elif defined(__OpenBSD__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__APPLE__) +#elif defined(__FreeBSD__) || defined(__NetBSD__) || defined(__APPLE__) #include <machine/endian.h> +#elif defined(__OpenBSD__) +#include <sys/types.h> #define __BYTE_ORDER BYTE_ORDER #define __LITTLE_ENDIAN LITTLE_ENDIAN #define __BIG_ENDIAN BIG_ENDIAN cvs server: Diffing keys cvs server: Diffing pbx cvs server: Diffing redhat cvs server: Diffing res cvs server: Diffing sounds cvs server: Diffing sounds/digits cvs server: Diffing stdtime | ||
Comments: | By: Brian West (bkw918) 2004-02-17 00:11:15.000-0600 Please attach the diff By: mxhess (mxhess) 2004-02-17 03:20:09.000-0600 context diffs attached.. one for each file changed. I question the compatability of the makefile changes I made.. I don't think they would be appropiate for all systems.. it just worked on my openbsd i386 3.4 system so I went with it. But the aesopt.h and frame.h changes should only beneficially affect openbsd and no other platform. By: Tilghman Lesher (tilghman) 2004-03-19 16:18:13.000-0600 See bugs ASTERISK-996 and ASTERISK-1196. Closing this one as a dupe. |