ref: 012443916146c670f7f9a521c89a45d8b7ab0c7a
parent: a06902b53f50964e680b284c7647e90175baac05
author: cbagwell <cbagwell>
date: Sat Mar 18 22:08:31 EST 2006
Adding support for compiling with Open Watcom compiler.
--- a/Changelog
+++ b/Changelog
@@ -33,6 +33,9 @@
on RMS values.
o Prevent infinite loop in pitch effect from uninitialize variable.
Frank Heckenbach
+ o Prevent crashes when printing error mesages (1447239)
+ o Added makefile and support files to compile using Open Watcom
+ compiler. (1417798) Marty
sox-12.17.9
-----------
--- /dev/null
+++ b/watcom/makefile
@@ -1,0 +1,60 @@
+# Makefile for Open Watcom make utility and compiler.
+# Doesn't include the GSM library, or other format libraries
+# Also need to create the stconfig.h file (from stconfig.h.in or ../win32/
+# stconfig.h), and ststdint.h which can simply include <stdint.h>.
+
+#GSM_SUPPORT = 1
+#VORBIS = 1
+
+!ifdef __LOADDLL__
+! loaddll wcc386 wccd386.dll
+! loaddll wlink wlink.dll
+! loaddll wlib wlibd.dll
+!endif
+
+CC = wcc386
+CFLAGS = -zq -wx -6r -fp6 -fpi87 -oikl+nrt
+
+FOBJ = 8svx.obj adpcm.obj aiff.obj alsa.obj au.obj auto.obj avr.obj cdr.obj &
+cvsd.obj dat.obj g711.obj g721.obj g723_16.obj g723_24.obj g723_40.obj &
+g72x.obj gsm.obj hcom.obj ima_rw.obj maud.obj mp3.obj nulfile.obj oss.obj &
+prc.obj raw.obj sf.obj smp.obj sndrtool.obj sphere.obj sunaudio.obj &
+tx16w.obj voc.obj vorbis.obj vox.obj wav.obj wve.obj
+
+EOBJ = avg.obj band.obj bandpass.obj breject.obj btrworth.obj chorus.obj &
+compand.obj copy.obj dcshift.obj deemphas.obj earwax.obj echo.obj echos.obj &
+fade.obj FFT.obj filter.obj flanger.obj highp.obj highpass.obj lowp.obj &
+lowpass.obj mask.obj mcompand.obj noiseprof.obj noisered.obj phaser.obj &
+pitch.obj pan.obj polyphas.obj rate.obj repeat.obj resample.obj reverb.obj &
+reverse.obj silence.obj speed.obj stat.obj stretch.obj swap.obj synth.obj &
+trim.obj vibro.obj vol.obj
+
+LIBOBJS = $(FOBJ) $(EOBJ) handlers.obj misc.obj stio.obj getopt.obj util.obj
+#VORBISLIB = -logg -lvorbis -lvorbisfile -lvorbisenc
+
+all: .SYMBOLIC sox.exe soxmix.exe
+
+LINK_CMD = wlink SYS NT F $[@ L st.lib N $@
+sox.exe: sox.obj st.lib
+ $(LINK_CMD)
+soxmix.exe: soxmix.obj st.lib
+ $(LINK_CMD)
+
+sox.obj: sox.c
+ $(CC) $[@ -bc -bt=NT $(CFLAGS) -fo=$@
+soxmix.obj: sox.c
+ $(CC) $[@ -bc -bt=NT -dSOXMIX $(CFLAGS) -fo=$@
+
+st.lib: $(LIBOBJS)
+ %create st.lbc
+ FOR %o IN ($(LIBOBJS)) DO @%append st.lbc +%o
+ wlib -n -b -c $@ @st.lbc
+
+C_CMD = $(CC) $[@ -bt=NT $(CFLAGS) -fo=$@
+.c.obj:
+ $(C_CMD)
+
+clean: .PROCEDURE
+ del *.obj
+ del *.err
+ del st.lib
--- /dev/null
+++ b/watcom/stconfig.h
@@ -1,0 +1,174 @@
+/* stconfig.h.in. Generated from configure.in by autoheader. */
+
+/* Define if you want to use internal GSM library */
+#undef ENABLE_GSM
+
+/* Define if you want to use fast ALAW conversions */
+#define FAST_ALAW_CONVERSION 1
+
+/* Define if you want to use fast ULAW conversions */
+#define FAST_ULAW_CONVERSION 1
+
+/* Define if you have ALSA installed */
+#undef HAVE_ALSA
+
+/* Define if you have ALSA 0.4 installed */
+#undef HAVE_ALSA4
+
+/* Define if you have ALSA 0.5 installed */
+#undef HAVE_ALSA5
+
+/* Define if you have ALSA 0.9 installed */
+#undef HAVE_ALSA9
+
+/* Define to 1 if you have the <byteswap.h> header file. */
+#undef HAVE_BYTESWAP_H
+
+/* Define to 1 if you have the <errno.h> header file. */
+#define HAVE_ERRNO_H 1
+
+/* Define to 1 if you have the <fcntl.h> header file. */
+#define HAVE_FCNTL_H 1
+
+/* Define to 1 if you have the `getopt' function. */
+//#define HAVE_GETOPT 1
+/* My Open Watcom 1.4 rc2 has getopt via <unistd.h> but there are issues
+after "-" and invalid options. */
+
+/* Define to 1 if you have the <getopt.h> header file. */
+#undef HAVE_GETOPT_H
+
+/* Define to 1 if you have the <inttypes.h> header file. */
+#define HAVE_INTTYPES_H 1
+
+/* Define if you have LAME (LAME Ain't an MP3 Encoder) library installed */
+#undef HAVE_LAME
+
+/* Define to 1 if you have the `m' library (-lm). */
+#undef HAVE_LIBM
+
+/* Define if you have MAD (MP3 Audio Decoder) Library installed */
+#undef HAVE_LIBMAD
+
+/* Define if you have Ogg Vorbis Library installed */
+//#define HAVE_LIBVORBIS
+
+/* Define to 1 if you have the <limits.h> header file. */
+#define HAVE_LIMITS_H 1
+
+/* Define to 1 if you have the <linux/asound.h> header file. */
+#undef HAVE_LINUX_ASOUND_H
+
+/* Define to 1 if you have the <machine/soundcard.h> header file. */
+#undef HAVE_MACHINE_SOUNDCARD_H
+
+/* Define to 1 if you have the <malloc.h> header file. */
+#define HAVE_MALLOC_H 1
+
+/* Define to 1 if you have the `memmove' function. */
+#define HAVE_MEMMOVE 1
+
+/* Define to 1 if you have the <memory.h> header file. */
+#define HAVE_MEMORY_H 1
+
+/* Define if you have OSS installed */
+#undef HAVE_OSS
+
+/* Define to 1 if you have the `rand' function. */
+#define HAVE_RAND 1
+
+/* Define to 1 if you have the <sound/asound.h> header file. */
+#undef HAVE_SOUND_ASOUND_H
+
+/* Define to 1 if you have the <stdint.h> header file. */
+#define HAVE_STDINT_H 1
+
+/* Define to 1 if you have the <stdlib.h> header file. */
+#define HAVE_STDLIB_H 1
+
+/* Define to 1 if you have the `strcasecmp' function. */
+#define HAVE_STRCASECMP 1
+
+/* Define to 1 if you have the `strdup' function. */
+#define HAVE_STRDUP 1
+
+/* Define to 1 if you have the `strerror' function. */
+#define HAVE_STRERROR 1
+
+/* Define to 1 if you have the <strings.h> header file. */
+#define HAVE_STRINGS_H 1
+
+/* Define to 1 if you have the <string.h> header file. */
+#define HAVE_STRING_H 1
+
+/* Define if you have Sun /dev/audio installed */
+#undef HAVE_SUNAUDIO
+
+/* Define to 1 if you have the <sun/audioio.h> header file. */
+#undef HAVE_SUN_AUDIOIO_H
+
+/* Define to 1 if you have the <sys/audioio.h> header file. */
+#undef HAVE_SYS_AUDIOIO_H
+
+/* Define to 1 if you have the <sys/soundcard.h> header file. */
+#undef HAVE_SYS_SOUNDCARD_H
+
+/* Define to 1 if you have the <sys/stat.h> header file. */
+#define HAVE_SYS_STAT_H 1
+
+/* Define to 1 if you have the <sys/types.h> header file. */
+#define HAVE_SYS_TYPES_H 1
+
+/* Define to 1 if you have the <unistd.h> header file. */
+//#define HAVE_UNISTD_H 1
+/* Stop getopt being defined, see above. */
+
+/* Define to the address where bug reports for this package should be sent. */
+#undef PACKAGE_BUGREPORT
+
+/* Define to the full name of this package. */
+#undef PACKAGE_NAME
+
+/* Define to the full name and version of this package. */
+#undef PACKAGE_STRING
+
+/* Define to the one symbol short name of this package. */
+#undef PACKAGE_TARNAME
+
+/* Define to the version of this package. */
+#undef PACKAGE_VERSION
+
+/* The number of bytes in type char */
+#define SIZEOF_CHAR (sizeof (char))
+
+/* The number of bytes in type int */
+#define SIZEOF_INT (sizeof (int))
+
+/* The number of bytes in type long */
+#define SIZEOF_LONG (sizeof (long))
+
+/* The number of bytes in type short */
+#define SIZEOF_SHORT (sizeof (short))
+
+/* The number of bytes in type void* */
+#define SIZEOF_VOIDP (sizeof (void *))
+
+/* Define to 1 if you have the ANSI C header files. */
+#define STDC_HEADERS 1
+
+/* Define if you want to use old rate routines */
+#undef USE_OLD_RATE
+
+/* Define to 1 if your processor stores words with the most significant byte
+ first (like Motorola and SPARC, unlike Intel and VAX). */
+#undef WORDS_BIGENDIAN
+
+/* Define to empty if `const' does not conform to ANSI C. */
+#undef const
+
+/* Define as `__inline' if that's what the C compiler calls it, or to nothing
+ if it is not supported. */
+#undef inline
+
+/* Define to `unsigned' if <sys/types.h> does not define. */
+#undef size_t
--- /dev/null
+++ b/watcom/ststdint.h
@@ -1,0 +1,1 @@
+#include <stdint.h>