diff --git a/srcpkgs/libgsm/patches/gsm-1.0.12-64bit.patch b/srcpkgs/libgsm/patches/gsm-1.0.12-64bit.patch index 07bd43d56cf..85cfeac6eae 100644 --- a/srcpkgs/libgsm/patches/gsm-1.0.12-64bit.patch +++ b/srcpkgs/libgsm/patches/gsm-1.0.12-64bit.patch @@ -1,15 +1,20 @@ ---- a/inc/private.h 2006-04-26 22:17:01.000000000 +0300 -+++ b/inc/private.h 2007-08-19 12:23:02.000000000 +0300 -@@ -10,10 +10,10 @@ - #define PRIVATE_H +--- a/inc/private.h ++++ b/inc/private.h +@@ -12,12 +12,12 @@ + #ifdef __cplusplus + extern "C" { + #endif ++#include ++typedef int16_t word; /* 16 bit signed int */ ++typedef int32_t longword; /* 32 bit signed int */ - typedef short word; /* 16 bit signed int */ +-typedef short word; /* 16 bit signed int */ -typedef long longword; /* 32 bit signed int */ -+typedef int longword; /* 32 bit signed int */ - - typedef unsigned short uword; /* unsigned word */ +- +-typedef unsigned short uword; /* unsigned word */ -typedef unsigned long ulongword; /* unsigned longword */ -+typedef unsigned int ulongword; /* unsigned longword */ ++typedef uint16_t uword; /* unsigned word */ ++typedef uint32_t ulongword; /* unsigned longword */ struct gsm_state { diff --git a/srcpkgs/libgsm/patches/gsm-1.0.12-memcpy.patch b/srcpkgs/libgsm/patches/gsm-1.0.12-memcpy.patch index a08d2c82df6..3e43546dc7e 100644 --- a/srcpkgs/libgsm/patches/gsm-1.0.12-memcpy.patch +++ b/srcpkgs/libgsm/patches/gsm-1.0.12-memcpy.patch @@ -1,10 +1,10 @@ ---- a/src/code.c 2006-04-26 22:16:50.000000000 +0300 -+++ b/src/code.c 2007-08-19 12:18:01.000000000 +0300 +--- a/src/code.c ++++ b/src/code.c @@ -8,6 +8,7 @@ #include "config.h" +#include - #ifdef HAS_STDLIB_H - #include + #ifdef HAS_STRING_H + #include diff --git a/srcpkgs/libgsm/patches/gsm-1.0.13-shared.patch b/srcpkgs/libgsm/patches/gsm-1.0.13-shared.patch index 34fb998a906..be681ad9b31 100644 --- a/srcpkgs/libgsm/patches/gsm-1.0.13-shared.patch +++ b/srcpkgs/libgsm/patches/gsm-1.0.13-shared.patch @@ -1,6 +1,19 @@ ---- a/Makefile 2006-04-26 22:14:26.000000000 +0300 -+++ b/Makefile 2009-09-08 14:50:02.000000000 +0300 -@@ -96,7 +96,7 @@ +--- a/Makefile ++++ b/Makefile +@@ -44,10 +44,11 @@ WAV49 = -DWAV49 + # CCFLAGS = -c -O + + CC = gcc -ansi -pedantic +-CCFLAGS = -c -O2 -DNeedFunctionPrototypes=1 -Wall -Wno-comment ++CCFLAGS = -O2 -DNeedFunctionPrototypes=1 -Wall -Wno-comment + + LD = $(CC) + ++VERSION = 1.0.13 + # LD = gcc + # LDFLAGS = + +@@ -96,7 +97,7 @@ TOAST_INSTALL_MAN = $(TOAST_INSTALL_ROOT # Other tools SHELL = /bin/sh @@ -9,7 +22,15 @@ BASENAME = basename AR = ar ARFLAGS = cr -@@ -140,6 +140,7 @@ +@@ -133,13 +134,14 @@ CFLAGS = $(CCFLAGS) $(SASR) $(DEBUG) $(M + $(WAV49) $(CCINC) -I$(INC) + ######### It's $(CC) $(CFLAGS) + +-LFLAGS = $(LDFLAGS) $(LDINC) ++LFLAGS = $(CFLAGS) $(LDFLAGS) $(LDINC) + ######### It's $(LD) $(LFLAGS) + + # Targets LIBGSM = $(LIB)/libgsm.a @@ -17,7 +38,7 @@ TOAST = $(BIN)/toast UNTOAST = $(BIN)/untoast -@@ -203,24 +204,43 @@ +@@ -203,24 +205,43 @@ SOURCES = $(GSM_SOURCES) \ # Object files @@ -79,7 +100,7 @@ TOAST_OBJECTS = $(SRC)/toast.o \ $(SRC)/toast_lin.o \ -@@ -228,7 +248,7 @@ +@@ -228,7 +249,7 @@ TOAST_OBJECTS = $(SRC)/toast.o \ $(SRC)/toast_alaw.o \ $(SRC)/toast_audio.o @@ -88,8 +109,12 @@ # Manuals -@@ -277,9 +297,12 @@ - $(CC) $(CFLAGS) $? +@@ -274,12 +295,15 @@ TOAST_INSTALL_TARGETS = \ + # Default rules + + .c.o: +- $(CC) $(CFLAGS) $? ++ $(CC) -c $(CFLAGS) $? @-mv `$(BASENAME) $@` $@ > /dev/null 2>&1 +%.lo: %.c @@ -102,15 +127,15 @@ @-echo $(ROOT): Done. tst: $(TST)/lin2cod $(TST)/cod2lin $(TOAST) $(TST)/test-result -@@ -299,24 +322,29 @@ +@@ -299,24 +323,29 @@ install: toastinstall gsminstall # The basic API: libgsm -$(LIBGSM): $(LIB) $(GSM_OBJECTS) +$(LIBGSMSO): $(LIB) $(SHARED_GSM_OBJECTS) -+ $(LD) $(LFLAGS) -o $@.1.0.13 -shared -Xlinker -soname -Xlinker libgsm.so.1 $(SHARED_GSM_OBJECTS) -lc -+ ln -fs libgsm.so.1.0.13 lib/libgsm.so.1 -+ ln -fs libgsm.so.1.0.13 lib/libgsm.so ++ $(LD) $(LFLAGS) -o $@.$(VERSION) -shared -Xlinker -soname -Xlinker libgsm.so.1 $(SHARED_GSM_OBJECTS) -lc ++ ln -fs libgsm.so.$(VERSION) lib/libgsm.so.1 ++ ln -fs libgsm.so.$(VERSION) lib/libgsm.so + +$(LIBGSM): $(LIB) $(STATIC_GSM_OBJECTS) -rm $(RMFLAGS) $(LIBGSM) @@ -137,12 +162,26 @@ # The local bin and lib directories -@@ -426,7 +454,9 @@ +@@ -357,11 +386,11 @@ $(TOAST_INSTALL_BIN)/toast: $(TOAST) + + $(TOAST_INSTALL_BIN)/untoast: $(TOAST_INSTALL_BIN)/toast + -rm $(RMFLAGS) $@ +- $(LN) $? $@ ++ $(LN) -r $? $@ + + $(TOAST_INSTALL_BIN)/tcat: $(TOAST_INSTALL_BIN)/toast + -rm $(RMFLAGS) $@ +- $(LN) $? $@ ++ $(LN) -r $? $@ + + $(TOAST_INSTALL_MAN)/toast.1: $(MAN)/toast.1 + -rm $(RMFLAGS) $@ +@@ -426,7 +455,9 @@ semi-clean: clean: semi-clean -rm $(RMFLAGS) $(LIBGSM) $(ADDTST)/add \ - $(TOAST) $(TCAT) $(UNTOAST) \ -+ $(LIBGSMSO) $(LIB)/libgsm.so.1.0.13 \ ++ $(LIBGSMSO) $(LIB)/libgsm.so.$(VERSION) \ + $(LIB)libgsm.so.1 \ + $(TOAST) $(TCAT) $(UNTOAST) \ $(ROOT)/gsm-1.0.tar.gz diff --git a/srcpkgs/libgsm/template b/srcpkgs/libgsm/template index b2ce9f8be19..a59933e56fe 100644 --- a/srcpkgs/libgsm/template +++ b/srcpkgs/libgsm/template @@ -1,7 +1,7 @@ # Template file for 'libgsm' pkgname=libgsm version=1.0.22 -revision=1 +revision=2 wrksrc="gsm-${version%.*}-pl${version##*.}" short_desc="GSM 06.10 lossy speech compression" maintainer="Orphaned " @@ -11,7 +11,7 @@ distfiles="http://www.quut.com/gsm/gsm-${version}.tar.gz" checksum=f0072e91f6bb85a878b2f6dbf4a0b7c850c4deb8049d554c65340b3bf69df0ac do_build() { - make CC=$CC LD=$CC AR=$AR CCFLAGS="$CFLAGS -c -DNeedFunctionPrototypes=1" + make CC=$CC LD=$CC AR=$AR CCFLAGS="$CFLAGS" } do_install() {