summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-support/links
diff options
context:
space:
mode:
authorMartin Jansa <Martin.Jansa@gmail.com>2012-12-22 18:08:20 +0100
committerMartin Jansa <Martin.Jansa@gmail.com>2012-12-23 09:32:57 +0100
commit6097b49f1fe7183f7b34fa2e4c5a8fbfd805ed26 (patch)
treee87d88043acb8222d180e5503ab94fe95cbb690d /meta-oe/recipes-support/links
parentf7b703f4af4bbadb48e26ea93e54a91f00cb1a57 (diff)
downloadmeta-openembedded-6097b49f1fe7183f7b34fa2e4c5a8fbfd805ed26.tar.gz
links: upgrade to 2.7 to fix build with libpng-1.5
* cookies api changed between 2.1pre30 and 2.7 * LIC_FILES_CHKSUM changed because of formal change 296c296 < This program is free software; you can redistribute it and/or modify --- > on, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 > USAThis program is free software; you can redistribute it and/or > modify Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Diffstat (limited to 'meta-oe/recipes-support/links')
-rw-r--r--meta-oe/recipes-support/links/files/cookies-save-0.96.patch106
-rw-r--r--meta-oe/recipes-support/links/files/links-2.1pre17-fix-segfault-on-loading-cookies.patch20
-rw-r--r--meta-oe/recipes-support/links/links-x11_2.7.bb (renamed from meta-oe/recipes-support/links/links-x11_2.0+2.1pre30.bb)7
-rw-r--r--meta-oe/recipes-support/links/links.inc12
-rw-r--r--meta-oe/recipes-support/links/links_2.7.bb (renamed from meta-oe/recipes-support/links/links_2.0+2.1pre30.bb)4
5 files changed, 9 insertions, 140 deletions
diff --git a/meta-oe/recipes-support/links/files/cookies-save-0.96.patch b/meta-oe/recipes-support/links/files/cookies-save-0.96.patch
deleted file mode 100644
index a1e35c01c..000000000
--- a/meta-oe/recipes-support/links/files/cookies-save-0.96.patch
+++ /dev/null
@@ -1,106 +0,0 @@
1diff -ru links-0.96/cookies.c links-0.96+cookies-save/cookies.c
2--- links-0.96/cookies.c Mon Sep 3 07:19:37 2001
3+++ links-0.96+cookies-save/cookies.c Mon Sep 3 07:18:42 2001
4@@ -276,15 +276,99 @@
5
6 void init_cookies(void)
7 {
8- /* !!! FIXME: read cookies */
9+ unsigned char in_buffer[MAX_STR_LEN];
10+ unsigned char *cookfile, *p, *q;
11+ FILE *fp;
12+
13+ /* must be called after init_home */
14+ if (! links_home) return;
15+
16+ cookfile = stracpy(links_home);
17+ if (! cookfile) return;
18+ add_to_strn(&cookfile, "cookies");
19+
20+ fp = fopen(cookfile, "r");
21+ mem_free(cookfile);
22+ if (fp == NULL) return;
23+
24+ while (fgets(in_buffer, MAX_STR_LEN, fp)) {
25+ struct cookie *cookie;
26+
27+ if (!(cookie = mem_alloc(sizeof(struct cookie)))) return;
28+ memset(cookie, 0, sizeof(struct cookie));
29+
30+ q = in_buffer; p = strchr(in_buffer, ' ');
31+ if (p == NULL) goto inv;
32+ *p++ = '\0';
33+ cookie->name = stracpy(q);
34+
35+ q = p; p = strchr(p, ' ');
36+ if (p == NULL) goto inv;
37+ *p++ = '\0';
38+ cookie->value = stracpy(q);
39+
40+ q = p; p = strchr(p, ' ');
41+ if (p == NULL) goto inv;
42+ *p++ = '\0';
43+ cookie->server = stracpy(q);
44+
45+ q = p; p = strchr(p, ' ');
46+ if (p == NULL) goto inv;
47+ *p++ = '\0';
48+ cookie->path = stracpy(q);
49+
50+ q = p; p = strchr(p, ' ');
51+ if (p == NULL) goto inv;
52+ *p++ = '\0';
53+ cookie->domain = stracpy(q);
54+
55+ q = p; p = strchr(p, ' ');
56+ if (p == NULL) goto inv;
57+ *p++ = '\0';
58+ cookie->expires = atoi(q);
59+
60+ cookie->secure = atoi(p);
61+
62+ cookie->id = cookie_id++;
63+
64+ accept_cookie(cookie);
65+
66+ continue;
67+
68+inv:
69+ free_cookie(cookie);
70+ free(cookie);
71+ }
72+ fclose(fp);
73 }
74
75 void cleanup_cookies(void)
76 {
77 struct cookie *c;
78+ unsigned char *cookfile;
79+ FILE *fp;
80+
81 free_list(c_domains);
82- /* !!! FIXME: save cookies */
83- foreach (c, cookies) free_cookie(c);
84+
85+ cookfile = stracpy(links_home);
86+ if (! cookfile) return;
87+ add_to_strn(&cookfile, "cookies");
88+
89+ fp = fopen(cookfile, "w");
90+ mem_free(cookfile);
91+ if (fp == NULL) return;
92+
93+ foreach (c, cookies) {
94+ if (c->expires && ! cookie_expired(c))
95+ fprintf(fp, "%s %s %s %s %s %d %d\n", c->name, c->value,
96+ c->server?c->server:(unsigned char *)"", c->path?c->path:(unsigned char *)"",
97+ c->domain?c->domain:(unsigned char *)"", c->expires, c->secure);
98+
99+ free_cookie(c);
100+ }
101+
102+ fclose(fp);
103+
104 free_list(cookies);
105 }
106
diff --git a/meta-oe/recipes-support/links/files/links-2.1pre17-fix-segfault-on-loading-cookies.patch b/meta-oe/recipes-support/links/files/links-2.1pre17-fix-segfault-on-loading-cookies.patch
deleted file mode 100644
index 0d3b407e2..000000000
--- a/meta-oe/recipes-support/links/files/links-2.1pre17-fix-segfault-on-loading-cookies.patch
+++ /dev/null
@@ -1,20 +0,0 @@
1--- links-2.1pre17/cookies.c.pix 2005-05-15 23:05:10.000000000 +0800
2+++ links-2.1pre17/cookies.c 2005-05-15 23:17:21.000000000 +0800
3@@ -41,7 +41,7 @@
4
5 void free_cookie(struct cookie *c)
6 {
7- mem_free(c->name);
8+ if (c->value) mem_free(c->name);
9 if (c->value) mem_free(c->value);
10 if (c->server) mem_free(c->server);
11 if (c->path) mem_free(c->path);
12@@ -355,7 +355,7 @@
13
14 inv:
15 free_cookie(cookie);
16- free(cookie);
17+ mem_free(cookie);
18 }
19 fclose(fp);
20 }
diff --git a/meta-oe/recipes-support/links/links-x11_2.0+2.1pre30.bb b/meta-oe/recipes-support/links/links-x11_2.7.bb
index b71da9f88..601742f9f 100644
--- a/meta-oe/recipes-support/links/links-x11_2.0+2.1pre30.bb
+++ b/meta-oe/recipes-support/links/links-x11_2.7.bb
@@ -6,6 +6,8 @@ RCONFLICTS_${PN} = "links"
6SRC_URI += " file://links2.desktop \ 6SRC_URI += " file://links2.desktop \
7 http://www.xora.org.uk/oe/links2.png;name=icon" 7 http://www.xora.org.uk/oe/links2.png;name=icon"
8 8
9S = "${WORKDIR}/links-${PV}"
10
9EXTRA_OECONF = "--enable-javascript --with-libfl --enable-graphics \ 11EXTRA_OECONF = "--enable-javascript --with-libfl --enable-graphics \
10 --with-ssl=${STAGING_LIBDIR}/.. --with-libjpeg \ 12 --with-ssl=${STAGING_LIBDIR}/.. --with-libjpeg \
11 --without-libtiff --without-svgalib --without-fb \ 13 --without-libtiff --without-svgalib --without-fb \
@@ -19,8 +21,7 @@ do_install_append() {
19 install -m 0644 ${WORKDIR}/links2.png ${D}/${datadir}/pixmaps 21 install -m 0644 ${WORKDIR}/links2.png ${D}/${datadir}/pixmaps
20} 22}
21 23
22 24SRC_URI[md5sum] = "d06aa6e14b2172d73188871a5357185a"
23SRC_URI[md5sum] = "f0f107cc824b71e43f0c6ab620209daf" 25SRC_URI[sha256sum] = "0c182b1cbcdfd5cdcd2f75a6032d1a4b660d07c1225c1e07757cec81d3302130"
24SRC_URI[sha256sum] = "f32314d851e86ec463967ddce78d051e3953b529878cbaeecf882c625ad29c75"
25SRC_URI[icon.md5sum] = "477e8787927c634614bac01b44355a33" 26SRC_URI[icon.md5sum] = "477e8787927c634614bac01b44355a33"
26SRC_URI[icon.sha256sum] = "eddcd8b8c8698aa621d1a453943892d77b72ed492e0d14e0dbac5c6a57e52f47" 27SRC_URI[icon.sha256sum] = "eddcd8b8c8698aa621d1a453943892d77b72ed492e0d14e0dbac5c6a57e52f47"
diff --git a/meta-oe/recipes-support/links/links.inc b/meta-oe/recipes-support/links/links.inc
index abd10f2ac..e77e2c454 100644
--- a/meta-oe/recipes-support/links/links.inc
+++ b/meta-oe/recipes-support/links/links.inc
@@ -3,17 +3,11 @@ browser, similar to Lynx."
3HOMEPAGE = "http://links.twibright.com/" 3HOMEPAGE = "http://links.twibright.com/"
4SECTION = "console/network" 4SECTION = "console/network"
5LICENSE = "GPLv2" 5LICENSE = "GPLv2"
6LIC_FILES_CHKSUM = "file://COPYING;md5=b0c80473f97008e42e29a9f80fcc55ff" 6LIC_FILES_CHKSUM = "file://COPYING;md5=65e735be2e05d5943803344148f57603"
7DEPENDS = "jpeg libpng flex openssl zlib" 7DEPENDS = "jpeg libpng flex openssl zlib"
8 8
9LPV = "${@d.getVar("PV",1).split("+")[1]}" 9SRC_URI = "http://links.twibright.com/download/links-${PV}.tar.bz2 \
10
11SRC_URI = "http://links.twibright.com/download/links-${LPV}.tar.bz2 \
12 file://ac-prog-cxx.patch \ 10 file://ac-prog-cxx.patch \
13 file://cookies-save-0.96.patch \ 11"
14 file://links-2.1pre17-fix-segfault-on-loading-cookies.patch"
15 12
16inherit autotools 13inherit autotools
17
18S = "${WORKDIR}/links-${LPV}"
19
diff --git a/meta-oe/recipes-support/links/links_2.0+2.1pre30.bb b/meta-oe/recipes-support/links/links_2.7.bb
index 24961737d..24c198557 100644
--- a/meta-oe/recipes-support/links/links_2.0+2.1pre30.bb
+++ b/meta-oe/recipes-support/links/links_2.7.bb
@@ -9,5 +9,5 @@ EXTRA_OECONF = "--enable-javascript --with-libfl --enable-graphics \
9 --without-directfb --without-pmshell --without-atheos \ 9 --without-directfb --without-pmshell --without-atheos \
10 --without-x --without-sdl" 10 --without-x --without-sdl"
11 11
12SRC_URI[md5sum] = "f0f107cc824b71e43f0c6ab620209daf" 12SRC_URI[md5sum] = "d06aa6e14b2172d73188871a5357185a"
13SRC_URI[sha256sum] = "f32314d851e86ec463967ddce78d051e3953b529878cbaeecf882c625ad29c75" 13SRC_URI[sha256sum] = "0c182b1cbcdfd5cdcd2f75a6032d1a4b660d07c1225c1e07757cec81d3302130"