wok rev 18789

Add opencv (again)
author Pascal Bellard <pascal.bellard@slitaz.org>
date Tue Jan 05 11:03:10 2016 +0100 (2016-01-05)
parents a4c10aa3ed2d
children 3d18330745fd
files opencv-dev/receipt opencv/receipt syslinux/stuff/iso2exe/iso2exe.c
line diff
     1.1 --- a/opencv-dev/receipt	Tue Jan 05 10:11:51 2016 +0100
     1.2 +++ b/opencv-dev/receipt	Tue Jan 05 11:03:10 2016 +0100
     1.3 @@ -9,7 +9,7 @@
     1.4  WEB_SITE="http://opencv.org/"
     1.5  WANTED="opencv"
     1.6  
     1.7 -DEPENDS="opencv"
     1.8 +DEPENDS="opencv pkg-config"
     1.9  
    1.10  # Rules to gen a SliTaz package suitable for Tazpkg.
    1.11  genpkg_rules()
     2.1 --- a/opencv/receipt	Tue Jan 05 10:11:51 2016 +0100
     2.2 +++ b/opencv/receipt	Tue Jan 05 11:03:10 2016 +0100
     2.3 @@ -10,9 +10,8 @@
     2.4  WEB_SITE="http://opencv.org/"
     2.5  WGET_URL="https://github.com/Itseez/opencv/archive/$VERSION.tar.gz"
     2.6  
     2.7 -DEPENDS="gtk+ ffmpeg jpeg tiff libpng gdal"
     2.8 -BUILD_DEPENDS="wget cmake gtk+-dev ffmpeg-dev jpeg-dev tiff-dev libpng-dev \
     2.9 -gdal-dev"
    2.10 +DEPENDS="gtk+ ffmpeg jpeg tiff libpng"
    2.11 +BUILD_DEPENDS="wget cmake gtk+-dev ffmpeg-dev jpeg-dev tiff-dev libpng-dev"
    2.12  
    2.13  # Rules to configure and make the package.
    2.14  compile_rules()
     3.1 --- a/syslinux/stuff/iso2exe/iso2exe.c	Tue Jan 05 10:11:51 2016 +0100
     3.2 +++ b/syslinux/stuff/iso2exe/iso2exe.c	Tue Jan 05 11:03:10 2016 +0100
     3.3 @@ -311,7 +311,7 @@
     3.4  		}
     3.5  		lseek(fd, 0UL, SEEK_SET);
     3.6  		for (i = 0; i < 32; i++, n = BUFFERSZ) {
     3.7 -			write(fd, buffer + n, 1024);
     3.8 +			write(fd, buffer + n, BUFFERSZ);
     3.9  		}
    3.10  		i = getcustomsector();
    3.11  		lseek(fd, i * 2048UL, SEEK_SET);
    3.12 @@ -393,11 +393,14 @@
    3.13  		clear_config(pos);
    3.14  		lseek(fd, pos, SEEK_SET);
    3.15  		write(fd, "#!boot 00000000000000000000000000000000\n", 40);
    3.16 +		n = pos + 40;
    3.17  		md5_begin();
    3.18  		if (append) {
    3.19 +			i = strlen(append);
    3.20  			writenhash("append=", 7);
    3.21 -			writenhash(append, strlen(append));
    3.22 +			writenhash(append, i);
    3.23  			writenhash("\n", 1);
    3.24 +			n += i + 8;
    3.25  		}
    3.26  		if (initrd) {
    3.27  			char number[16], *p;
    3.28 @@ -420,6 +423,7 @@
    3.29  				writenhash("initrd:", 7);
    3.30  				i = number - p + sizeof(number);
    3.31  				writenhash(p, i);
    3.32 +				n += i + 7;
    3.33  				lseek(data, 0UL, SEEK_SET);
    3.34  				do {
    3.35  					i = read(data, buffer, BUFFERSZ);
    3.36 @@ -428,11 +432,22 @@
    3.37  					if (i > end)
    3.38  						i = end;
    3.39  					writenhash(buffer, i);
    3.40 +					n += i;
    3.41  					end -= i;
    3.42  				} while (end != 0);
    3.43  			}
    3.44  			close(data);
    3.45  		}
    3.46 +		while (n & 0x000FFFFFUL) {
    3.47 +			unsigned long i = 0x100000UL - (n & 0x000FFFFFUL);
    3.48 +			if (i > BUFFERSZ)
    3.49 +				i = BUFFERSZ;
    3.50 +			i = write(fd, buffer + BUFFERSZ, i);
    3.51 +			if (i <= 0)
    3.52 +				break;
    3.53 +			n += i;
    3.54 +		}
    3.55 +		ftruncate(fd, n);
    3.56  		md5_end();
    3.57  		{
    3.58  			static char h[] = "0123456789abcdef";