wok rev 13256

qemacs-tiny: -Werror=unused-but-set-variable fix
author Pascal Bellard <pascal.bellard@slitaz.org>
date Fri Aug 17 09:13:42 2012 +0200 (2012-08-17)
parents f82b9cdc36cd
children 585734d0d3e1
files qemacs-tiny/receipt
line diff
     1.1 --- a/qemacs-tiny/receipt	Thu Aug 16 21:48:35 2012 +0200
     1.2 +++ b/qemacs-tiny/receipt	Fri Aug 17 09:13:42 2012 +0200
     1.3 @@ -1,12 +1,13 @@
     1.4  # SliTaz package receipt.
     1.5  
     1.6  PACKAGE="qemacs-tiny"
     1.7 +SOURCE="qemacs"
     1.8  VERSION="0.3.2"
     1.9  CATEGORY="development"
    1.10  SHORT_DESC="Tiny emacs clone."
    1.11  MAINTAINER="pascal.bellard@slitaz.org"
    1.12 -TARBALL="$PACKAGE-$VERSION.tar.gz"
    1.13 -WEB_SITE="http://bellard.org/$PACKAGE/"
    1.14 +TARBALL="$SOURCE-$VERSION.tar.gz"
    1.15 +WEB_SITE="http://bellard.org/$SOURCE/"
    1.16  WGET_URL="${WEB_SITE}$TARBALL"
    1.17  TAGS="editor"
    1.18  
    1.19 @@ -17,6 +18,18 @@
    1.20  compile_rules()
    1.21  {
    1.22  	cd $src
    1.23 +
    1.24 +	# quick fix for variable 'XXX' set but not used [-Werror=unused-but-set-variable]
    1.25 +	sed -i	-e 's/int count,/int count=count,/' \
    1.26 +		-e 's/ line_count,/ line_count=line_count,/' \
    1.27 +		-e 's/int len;/int len=len;/' \
    1.28 +		-e 's/EditState \*e;/EditState *e=e;/' \
    1.29 +		-e 's/int err,/int err=err,/' qe.c
    1.30 +	sed -i 's/size_start,/size_start=size_start,/' buffer.c
    1.31 +	sed -i 's/stack_ptr = 0;/&; stack[0] = stack[0];/' clang.c
    1.32 +	sed -i 's/len, offset1/len=len, offset1/' latex-mode.c
    1.33 +	sed -i 's/len1, len2/len1=len1, len2=len2/' dired.c
    1.34 +	
    1.35  	sed -i 's/\(define SAVED_DATA_SIZE \).*/\1 __builtin_offsetof(EditState,end_of_saved_data)/' qe.h
    1.36  	./configure --prefix=/usr --enable-tiny && make qe
    1.37  }