Skip to contentSkip to conversation

lynx: new package

PATCH Superseded Mario Lang 3 participants 3 messages Dec 10, 2017 – Dec 12, 2017

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Mario Lang

author
#0 lore raw

PATCH 1/1 lynx: new package

---
 DEVELOPERS             |  3 +++
 package/Config.in      |  1 +
 package/lynx/Config.in |  7 +++++++
 package/lynx/lynx.hash |  3 +++
 package/lynx/lynx.mk   | 31 +++++++++++++++++++++++++++++++
 5 files changed, 45 insertions(+)
 create mode 100644 package/lynx/Config.in
 create mode 100644 package/lynx/lynx.hash
 create mode 100644 package/lynx/lynx.mk
DEVELOPERS +3 -0
index 77e3344fa4..63809f1afb 100644
@@ -1040,6 +1040,9 @@ F:	package/polkit/
 F:	package/sg3_utils/
 F:	package/udisks/
 
+N:	Mario Lang <[email protected]>
+F:	package/lynx/
+
 N:	Mario Rugiero <[email protected]>
 F:	package/ratpoison/
 
package/Config.in +1 -0
index cb2141b8f3..c3ebbfc8c4 100644
@@ -1699,6 +1699,7 @@ menu "Networking applications"
 	source "package/linuxptp/Config.in"
 	source "package/lldpd/Config.in"
 	source "package/lrzsz/Config.in"
+	source "package/lynx/Config.in"
 	source "package/macchanger/Config.in"
 	source "package/memcached/Config.in"
 	source "package/mii-diag/Config.in"
package/lynx/Config.in new file +7 -0
new file mode 100644
index 0000000000..2ccdad6f0b
@@ -0,0 +1,7 @@
+config BR2_PACKAGE_LYNX
+	bool "lynx"
+	select BR2_PACKAGE_NCURSES
+	select BR2_PACKAGE_OPENSSL if !BR2_PACKAGE_GNUTLS
+	help
+	  Text mode web browser.
+
package/lynx/lynx.hash new file +3 -0
new file mode 100644
index 0000000000..c39475aa23
@@ -0,0 +1,3 @@
+# Locally calculated:
+sha256  04318a100b052d079d0018fa371aa28cfb41ab68db3a959f3b75c2170eea1bc8  lynx2.8.9dev.16.tar.bz2
+sha256  8406a30ff3134ec23cf752d1ceda92ddaabbe41b4f2dc07ea3cfa139de12d6d6  COPYING
package/lynx/lynx.mk new file +31 -0
new file mode 100644
index 0000000000..93f0b75982
@@ -0,0 +1,31 @@
+################################################################################
+#
+# lynx
+#
+################################################################################
+
+LYNX_VERSION = 2.8.9dev.16
+LYNX_SOURCE = lynx$(LYNX_VERSION).tar.bz2
+LYNX_SITE = ftp://ftp.invisible-island.net/lynx/tarballs
+LYNX_LICENSE = GPL-2.0
+LYNX_LICENSE_FILES = COPYING
+
+LYNX_DEPENDENCIES = $(TARGET_NLS_DEPENDENCIES) ncurses
+LYNX_CONF_OPTS = --with-screen=ncurses --with-curses-dir=$(TARGET_DIR)/usr
+
+ifeq ($(BR2_PACKAGE_OPENSSL),y)
+LYNX_DEPENDENCIES += openssl
+LYNX_CONF_OPTS += --with-ssl
+else ifeq ($(BR2_PACKAGE_GNUTLS),y)
+LYNX_DEPENDENCIES += gnutls
+LYNX_CONF_OPTS += --with-gnutls
+endif
+
+ifeq ($(BR2_PACKAGE_ZLIB),y)
+LYNX_DEPENDENCIES += zlib
+LYNX_CONF_OPTS += --with-zlib
+else
+LYNX_CONF_OPTS += --without-zlib
+endif
+
+$(eval $(autotools-package))
Signature · 1 line
2.15.0
#1 lore raw

PATCH 1/1 lynx: new package

Hello Mario,

A couple of nitpicks below ? nothing that would block merging your patch, I think :-)

Quoted 44 lines · Mario Lang
---
 DEVELOPERS             |  3 +++
 package/Config.in      |  1 +
 package/lynx/Config.in |  7 +++++++
 package/lynx/lynx.hash |  3 +++
 package/lynx/lynx.mk   | 31 +++++++++++++++++++++++++++++++
 5 files changed, 45 insertions(+)
 create mode 100644 package/lynx/Config.in
 create mode 100644 package/lynx/lynx.hash
 create mode 100644 package/lynx/lynx.mk
DEVELOPERS +3 -0
index 77e3344fa4..63809f1afb 100644
@@ -1040,6 +1040,9 @@ F:	package/polkit/
 F:	package/sg3_utils/
 F:	package/udisks/
 
+N:	Mario Lang <[email protected]>
+F:	package/lynx/
+
 N:	Mario Rugiero <[email protected]>
 F:	package/ratpoison/
 
package/Config.in +1 -0
index cb2141b8f3..c3ebbfc8c4 100644
@@ -1699,6 +1699,7 @@ menu "Networking applications"
 	source "package/linuxptp/Config.in"
 	source "package/lldpd/Config.in"
 	source "package/lrzsz/Config.in"
+	source "package/lynx/Config.in"
 	source "package/macchanger/Config.in"
 	source "package/memcached/Config.in"
 	source "package/mii-diag/Config.in"
package/lynx/Config.in new file +0 -0
new file mode 100644
index 0000000000..2ccdad6f0b

package/lynx/Config.in line 7

Quoted 7 lines
package/lynx/Config.in new file +7 -0
@@ -0,0 +1,7 @@
+config BR2_PACKAGE_LYNX
+	bool "lynx"
+	select BR2_PACKAGE_NCURSES
+	select BR2_PACKAGE_OPENSSL if !BR2_PACKAGE_GNUTLS
+	help
+	  Text mode web browser.
+

You could add one additional line in the "help" section with the project URL (http://lynx.browser.org/)

Quoted 19 lines
package/lynx/lynx.hash new file +3 -0
new file mode 100644
index 0000000000..c39475aa23
@@ -0,0 +1,3 @@
+# Locally calculated:
+sha256  04318a100b052d079d0018fa371aa28cfb41ab68db3a959f3b75c2170eea1bc8  lynx2.8.9dev.16.tar.bz2
+sha256  8406a30ff3134ec23cf752d1ceda92ddaabbe41b4f2dc07ea3cfa139de12d6d6  COPYING
package/lynx/lynx.mk new file +4 -0
new file mode 100644
index 0000000000..93f0b75982
@@ -0,0 +1,31 @@
+################################################################################
+#
+# lynx
+#

package/lynx/lynx.mk line 14

Quoted 10 lines
package/lynx/lynx.mk new file +10 -0
+################################################################################
+
+LYNX_VERSION = 2.8.9dev.16
+LYNX_SOURCE = lynx$(LYNX_VERSION).tar.bz2
+LYNX_SITE = ftp://ftp.invisible-island.net/lynx/tarballs
+LYNX_LICENSE = GPL-2.0
+LYNX_LICENSE_FILES = COPYING
+
+LYNX_DEPENDENCIES = $(TARGET_NLS_DEPENDENCIES) ncurses
+LYNX_CONF_OPTS = --with-screen=ncurses --with-curses-dir=$(TARGET_DIR)/usr

It is also possible to use "--with-screen=ncursesw", and AFAIU it should be preferred when ncurses is being built with wide-character support (that is:
BR2_PACKAGE_NCURSES_WCHAR=y).

Lynx also supports being built with Slang instead of ncurses. There is a "slang" package in Buildroot: You might want to consider doing a follow-up patch which chooses slang when ncurses is not enabled (and slang is). I don't see this is very important because most builds will have ncurses anyway, but it could be a nice touch :-)

Quoted 18 lines
package/lynx/lynx.mk new file +16 -0
+ifeq ($(BR2_PACKAGE_OPENSSL),y)
+LYNX_DEPENDENCIES += openssl
+LYNX_CONF_OPTS += --with-ssl
+else ifeq ($(BR2_PACKAGE_GNUTLS),y)
+LYNX_DEPENDENCIES += gnutls
+LYNX_CONF_OPTS += --with-gnutls
+endif
+
+ifeq ($(BR2_PACKAGE_ZLIB),y)
+LYNX_DEPENDENCIES += zlib
+LYNX_CONF_OPTS += --with-zlib
+else
+LYNX_CONF_OPTS += --without-zlib
+endif
+
+$(eval $(autotools-package))
Signature · 1 line
2.15.0

--
Adri?n ?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20171210/399b0eef/attachment.asc>

#2 lore raw

PATCH 1/1 lynx: new package

Hello,

Quoted 8 lines · Adrian Perez de Castro

package/lynx/Config.in line 7

Quoted 5 lines
package/lynx/Config.in new file +5 -0
+	select BR2_PACKAGE_NCURSES
+	select BR2_PACKAGE_OPENSSL if !BR2_PACKAGE_GNUTLS
+	help
+	  Text mode web browser.
+  

You could add one additional line in the "help" section with the project URL (http://lynx.browser.org/)

Indeed.

Quoted 2 lines

package/lynx/lynx.mk line 14

Quoted 2 lines
package/lynx/lynx.mk new file +2 -0
+LYNX_DEPENDENCIES = $(TARGET_NLS_DEPENDENCIES) ncurses
+LYNX_CONF_OPTS = --with-screen=ncurses --with-curses-dir=$(TARGET_DIR)/usr  

What is the curses-dir used for? It doesn't seem correct to point to $(TARGET_DIR)/usr:

- If it's used at build time, then you should use $(STAGING_DIR)/usr

- If it's used at run time, then it's wrong, because $(TARGET_DIR)/usr doesn't exist at runtime.

Quoted 9 lines

It is also possible to use "--with-screen=ncursesw", and AFAIU it should be preferred when ncurses is being built with wide-character support (that is:
BR2_PACKAGE_NCURSES_WCHAR=y).

Lynx also supports being built with Slang instead of ncurses. There is a "slang" package in Buildroot: You might want to consider doing a follow-up patch which chooses slang when ncurses is not enabled (and slang is). I don't see this is very important because most builds will have ncurses anyway, but it could be a nice touch :-)

If slang can be used as an alternative to ncurses, it would be indeed good to support that, like the OpenSSL/GnuTLS logic that Mario has already added.

Mario, could you rework your patch according to Adrian's comments?

Thanks a lot!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com