Skip to contentSkip to conversation

new package: ratpoison

PATCH Superseded Mario J. Rugiero 2 participants 6 messages May 12, 2017 – Jun 7, 2017

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 new package: ratpoison

Tested with:
nitrogen6sx_defconfig

---
 package/Config.in                |  1 +
 package/ratpoison/Config.in      | 22 ++++++++++++++++++++++
 package/ratpoison/ratpoison.hash |  2 ++
 package/ratpoison/ratpoison.mk   | 22 ++++++++++++++++++++++
 4 files changed, 47 insertions(+)
 create mode 100644 package/ratpoison/Config.in
 create mode 100644 package/ratpoison/ratpoison.hash
 create mode 100644 package/ratpoison/ratpoison.mk
package/Config.in +1 -0
index 3876ffa93..6ad761bc1 100644
@@ -339,6 +339,7 @@ comment "X window managers"
 	source "package/matchbox/Config.in"
 	source "package/metacity/Config.in"
 	source "package/openbox/Config.in"
+	source "package/ratpoison/Config.in"
 endmenu
 
 menu "Hardware handling"
package/ratpoison/Config.in new file +22 -0
new file mode 100644
index 000000000..c5c5cc774
@@ -0,0 +1,22 @@
+config BR2_PACKAGE_RATPOISON
+	bool "ratpoison"
+	depends on BR2_PACKAGE_XORG || BR2_PACKAGE_XORG7
+	depends on BR2_PACKAGE_XLIB_LIBX11
+	select BR2_PACKAGE_LIBERATION
+	select BR2_PACKAGE_FONTCONFIG
+	help
+	  Ratpoison is a simple Window Manager. It is largely modelled after
+	  GNU Screen and focuses on the keyboard instead of a mouse.
+
+	  The screen can be split into non-overlapping frames.
+	  All windows are kept maximized inside their frames to take full
+	  advantage of your precious screen real estate. 
+
+	  http://www.nongnu.org/ratpoison/
+
+config BR2_PACKAGE_RATPOISON_RANDR
+	bool "Xrandr support"
+	depends on BR2_PACKAGE_RATPOISON
+	depends on BR2_PACKAGE_XLIB_LIBXRANDR
+	help
+	  Build ratpoison with randr support, mainly for multihead.
package/ratpoison/ratpoison.hash new file +2 -0
new file mode 100644
index 000000000..0f6e169d4
@@ -0,0 +1,2 @@
+#Locally computed
+sha256 d98fa4be025ecca453c407ff311ab3949f29f20d6d8abedf8f0716b85fc8d1f1 ratpoison-1.4.9.tar.xz
package/ratpoison/ratpoison.mk new file +22 -0
new file mode 100644
index 000000000..1545cb17c
@@ -0,0 +1,22 @@
+#############################################################
+#
+# ratpoison
+#
+#############################################################
+
+RATPOISON_VERSION = 1.4.9
+RATPOISON_SOURCE = ratpoison-$(RATPOISON_VERSION).tar.xz
+RATPOISON_SITE = http://download.savannah.nongnu.org/releases/ratpoison
+
+RATPOISON_CONF_OPTS = --x-includes=$(STAGING_DIR)/usr/include/X11 \
+		      --x-libraries=$(STAGING_DIR)/usr/lib
+
+RATPOISON_DEPENDENCIES = $(XSERVER) xlib_libX11
+
+ifeq ($(BR2_PACKAGE_RATPOISON_RANDR),y)
+	RATPOISON_DEPENDENCIES += xlib_libXrandr
+else
+	RATPOISON_CONF_OPTS += --without-xrandr
+endif
+
+$(eval $(autotools-package))
Signature · 1 line
2.13.0
#1 lore raw

PATCH 1/1 new package: ratpoison

Hello,

Thanks for your contribution. However, there's a number of things that aren't really correct in the patch. See my comments below.

Quoted 4 lines · Mario J. Rugiero
 package/Config.in                |  1 +
 package/ratpoison/Config.in      | 22 ++++++++++++++++++++++
 package/ratpoison/ratpoison.hash |  2 ++
 package/ratpoison/ratpoison.mk   | 22 ++++++++++++++++++++++

Missing addition to the DEVELOPERS file.

package/ratpoison/Config.in line 3

Quoted 3 lines
package/ratpoison/Config.in new file +3 -0
+config BR2_PACKAGE_RATPOISON
+	bool "ratpoison"
+	depends on BR2_PACKAGE_XORG || BR2_PACKAGE_XORG7

BR2_PACKAGE_XORG doesn't exist, so this should just be:

depends on BR2_PACKAGE_XORG7

package/ratpoison/Config.in line 4

Quoted 1 line
package/ratpoison/Config.in new file +1 -0
+	depends on BR2_PACKAGE_XLIB_LIBX11

This should be a "select".

package/ratpoison/Config.in line 6

Quoted 2 lines
package/ratpoison/Config.in new file +2 -0
+	select BR2_PACKAGE_LIBERATION
+	select BR2_PACKAGE_FONTCONFIG

And please order selects by alphabetic ordering.

Quoted 6 lines
package/ratpoison/Config.in new file +6 -0
+	help
+	  Ratpoison is a simple Window Manager. It is largely modelled after
+	  GNU Screen and focuses on the keyboard instead of a mouse.
+
+	  The screen can be split into non-overlapping frames.
+	  All windows are kept maximized inside their frames to take full

package/ratpoison/Config.in line 22

Quoted 10 lines
package/ratpoison/Config.in new file +10 -0
+	  advantage of your precious screen real estate. 
+
+	  http://www.nongnu.org/ratpoison/
+
+config BR2_PACKAGE_RATPOISON_RANDR
+	bool "Xrandr support"
+	depends on BR2_PACKAGE_RATPOISON
+	depends on BR2_PACKAGE_XLIB_LIBXRANDR
+	help
+	  Build ratpoison with randr support, mainly for multihead.

No need for a sub-option, just enable xrandr support in the .mk file when BR2_PACKAGE_XLIB_LIBXRANDR is enabled.

package/ratpoison/ratpoison.hash line 1

Quoted 7 lines
package/ratpoison/ratpoison.hash new file +1 -0
new file mode 100644
index 000000000..0f6e169d4
@@ -0,0 +1,2 @@
+#Locally computed

Space between # and Locally.

package/ratpoison/ratpoison.mk line 5

Quoted 12 lines
package/ratpoison/ratpoison.hash new file +1 -0
+sha256 d98fa4be025ecca453c407ff311ab3949f29f20d6d8abedf8f0716b85fc8d1f1 ratpoison-1.4.9.tar.xz
package/ratpoison/ratpoison.mk new file +5 -0
new file mode 100644
index 000000000..1545cb17c
@@ -0,0 +1,22 @@
+#############################################################
+#
+# ratpoison
+#
+#############################################################

Wrong number of #. Please pass your package through supports/scripts/check-package before submission.

package/ratpoison/ratpoison.mk line 9

Quoted 3 lines
package/ratpoison/ratpoison.mk new file +3 -0
+RATPOISON_VERSION = 1.4.9
+RATPOISON_SOURCE = ratpoison-$(RATPOISON_VERSION).tar.xz
+RATPOISON_SITE = http://download.savannah.nongnu.org/releases/ratpoison

Missing license and license file.

package/ratpoison/ratpoison.mk line 14

Quoted 5 lines
package/ratpoison/ratpoison.mk new file +5 -0
+
+RATPOISON_CONF_OPTS = --x-includes=$(STAGING_DIR)/usr/include/X11 \
+		      --x-libraries=$(STAGING_DIR)/usr/lib
+
+RATPOISON_DEPENDENCIES = $(XSERVER) xlib_libX11

$(XSERVER) doesn't exist.

package/ratpoison/ratpoison.mk line 20

Quoted 6 lines
package/ratpoison/ratpoison.mk new file +6 -0
+
+ifeq ($(BR2_PACKAGE_RATPOISON_RANDR),y)
+	RATPOISON_DEPENDENCIES += xlib_libXrandr
+else
+	RATPOISON_CONF_OPTS += --without-xrandr
+endif

Please replace with:

ifeq ($(BR2_PACKAGE_XLIB_LIBXRANDR),y)
RATPOISON_DEPENDENCIES += xlib_libXrandr
RATPOISON_CONF_OPTS += --with-xrandr
else
RATPOISON_CONF_OPTS += --without-xrandr
endif

Thanks,

Thomas

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

PATCH v2 1/1 new package: ratpoison

In reply to Mario J. Rugiero

Tested with:
nitrogen6sx_defconfig

---
v2: fix inexistent variables, add license and license files, fix style
issues, add myself to DEVELOPERS.
v1: create the package.

 DEVELOPERS                       |  3 +++
 package/Config.in                |  1 +
 package/ratpoison/Config.in      | 15 +++++++++++++++
 package/ratpoison/ratpoison.hash |  2 ++
 package/ratpoison/ratpoison.mk   | 25 +++++++++++++++++++++++++
 5 files changed, 46 insertions(+)
 create mode 100644 package/ratpoison/Config.in
 create mode 100644 package/ratpoison/ratpoison.hash
 create mode 100644 package/ratpoison/ratpoison.mk
DEVELOPERS +3 -0
index 4936b81bd..7a00e6b29 100644
@@ -1046,6 +1046,9 @@ F:	package/polkit/
 F:	package/sg3_utils/
 F:	package/udisks/
 
+N:	Mario Rugiero <[email protected]>
+F:	package/ratpoison/
+
 N:	Markos Chandras <[email protected]>
 F:	package/harfbuzz/
 F:	package/libsecret/
package/Config.in +1 -0
index 43d75a9c7..3e7c45dc1 100644
@@ -339,6 +339,7 @@ comment "X window managers"
 	source "package/matchbox/Config.in"
 	source "package/metacity/Config.in"
 	source "package/openbox/Config.in"
+	source "package/ratpoison/Config.in"
 endmenu
 
 menu "Hardware handling"
package/ratpoison/Config.in new file +15 -0
new file mode 100644
index 000000000..e16a2fac7
@@ -0,0 +1,15 @@
+config BR2_PACKAGE_RATPOISON
+	bool "ratpoison"
+	depends on BR2_PACKAGE_XORG7
+	select BR2_PACKAGE_FONTCONFIG
+	select BR2_PACKAGE_LIBERATION
+	select BR2_PACKAGE_XLIB_LIBX11
+	help
+	  Ratpoison is a simple Window Manager. It is largely modelled after
+	  GNU Screen and focuses on the keyboard instead of a mouse.
+
+	  The screen can be split into non-overlapping frames.
+	  All windows are kept maximized inside their frames to take full
+	  advantage of your precious screen real estate. 
+
+	  http://www.nongnu.org/ratpoison/
package/ratpoison/ratpoison.hash new file +2 -0
new file mode 100644
index 000000000..44781b07a
@@ -0,0 +1,2 @@
+# Locally computed
+sha256 d98fa4be025ecca453c407ff311ab3949f29f20d6d8abedf8f0716b85fc8d1f1 ratpoison-1.4.9.tar.xz
package/ratpoison/ratpoison.mk new file +25 -0
new file mode 100644
index 000000000..18222c217
@@ -0,0 +1,25 @@
+################################################################################
+#
+# ratpoison
+#
+################################################################################
+
+RATPOISON_VERSION = 1.4.9
+RATPOISON_SOURCE = ratpoison-$(RATPOISON_VERSION).tar.xz
+RATPOISON_SITE = http://download.savannah.nongnu.org/releases/ratpoison
+RATPOISON_LICENSE = GPL-2.0
+RATPOISON_LICENSE_FILES = COPYING
+
+RATPOISON_CONF_OPTS = --x-includes=$(STAGING_DIR)/usr/include/X11 \
+		      --x-libraries=$(STAGING_DIR)/usr/lib
+
+RATPOISON_DEPENDENCIES = xlib_libX11
+
+ifeq ($(BR2_PACKAGE_XLIB_LIBXRANDR),y)
+	RATPOISON_DEPENDENCIES += xlib_libXrandr
+	RATPOISON_CONF_OPTS += --with-xrandr
+else
+	RATPOISON_CONF_OPTS += --without-xrandr
+endif
+
+$(eval $(autotools-package))
Signature · 1 line
2.13.0
#3 lore raw

PATCH v2 1/1 new package: ratpoison

Hello,

I've applied, after doing a number of fixes.

First, the commit title should have been "ratpoison: new package".

Quoted 6 lines · Mario J. Rugiero
package/ratpoison/ratpoison.mk new file +0 -0
new file mode 100644
index 000000000..18222c217

package/ratpoison/ratpoison.mk line 10

Quoted 10 lines
package/ratpoison/ratpoison.mk new file +10 -0
@@ -0,0 +1,25 @@
+################################################################################
+#
+# ratpoison
+#
+################################################################################
+
+RATPOISON_VERSION = 1.4.9
+RATPOISON_SOURCE = ratpoison-$(RATPOISON_VERSION).tar.xz
+RATPOISON_SITE = http://download.savannah.nongnu.org/releases/ratpoison
+RATPOISON_LICENSE = GPL-2.0

The license really was GPL-2.0+, not GPL-2.0.

package/ratpoison/ratpoison.mk line 14

Quoted 4 lines
package/ratpoison/ratpoison.mk new file +4 -0
+RATPOISON_LICENSE_FILES = COPYING
+
+RATPOISON_CONF_OPTS = --x-includes=$(STAGING_DIR)/usr/include/X11 \
+		      --x-libraries=$(STAGING_DIR)/usr/lib

Indentation on the second line should be done with just one tab. And also, explicitly disabling options not handled is a good practice. So in the end, this looked like this:

+RATPOISON_CONF_OPTS = \

+       --x-includes=$(STAGING_DIR)/usr/include/X11 \
+       --x-libraries=$(STAGING_DIR)/usr/lib \
+       --without-xkb \
+       --without-xft

If you want to send another patch to optionally enable XKB and XFT support, that would be welcome.

package/ratpoison/ratpoison.mk line 20

Quoted 3 lines
package/ratpoison/ratpoison.mk new file +3 -0
+ifeq ($(BR2_PACKAGE_XLIB_LIBXRANDR),y)
+	RATPOISON_DEPENDENCIES += xlib_libXrandr
+	RATPOISON_CONF_OPTS += --with-xrandr

Do not indent such variable definitions.

Applied with those fixes. Thanks!

Thomas

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

PATCH v2 1/1 new package: ratpoison

2017-06-06 18:01 GMT-03:00 Thomas Petazzoni
<[email protected]>:

Quoted 1 line

Hello,

Hello.

Quoted 4 lines

I've applied, after doing a number of fixes.

First, the commit title should have been "ratpoison: new package".

Noted.

Quoted 12 lines · Mario J. Rugiero
Quoted 10 lines
package/ratpoison/ratpoison.mk new file +4 -0
new file mode 100644
index 000000000..18222c217
@@ -0,0 +1,25 @@
+################################################################################
+#
+# ratpoison
+#
Quoted 8 lines

package/ratpoison/ratpoison.mk line 10

Quoted 6 lines
package/ratpoison/ratpoison.mk new file +6 -0
+################################################################################
+
+RATPOISON_VERSION = 1.4.9
+RATPOISON_SOURCE = ratpoison-$(RATPOISON_VERSION).tar.xz
+RATPOISON_SITE = http://download.savannah.nongnu.org/releases/ratpoison
+RATPOISON_LICENSE = GPL-2.0

The license really was GPL-2.0+, not GPL-2.0.

It didn't seem like it was GPL-2.0+ in the COPYING file, but I may be wrong.

Quoted 10 lines

package/ratpoison/ratpoison.mk line 14

Quoted 5 lines
package/ratpoison/ratpoison.mk new file +4 -0
+RATPOISON_LICENSE_FILES = COPYING
+
+RATPOISON_CONF_OPTS = --x-includes=$(STAGING_DIR)/usr/include/X11 \
+                   --x-libraries=$(STAGING_DIR)/usr/lib

Indentation on the second line should be done with just one tab. And also, explicitly disabling options not handled is a good practice. So in the end, this looked like this:

Review

Quoted 5 lines
(quoted diff) +5 -0
+RATPOISON_CONF_OPTS = \
+       --x-includes=$(STAGING_DIR)/usr/include/X11 \
+       --x-libraries=$(STAGING_DIR)/usr/lib \
+       --without-xkb \
+       --without-xft

Noted.

Quoted 3 lines

If you want to send another patch to optionally enable XKB and XFT support, that would be welcome.

I'll probably send a new patch during this week.

Quoted 6 lines

package/ratpoison/ratpoison.mk line 20

Quoted 4 lines
package/ratpoison/ratpoison.mk new file +3 -0
+ifeq ($(BR2_PACKAGE_XLIB_LIBXRANDR),y)
+     RATPOISON_DEPENDENCIES += xlib_libXrandr
+     RATPOISON_CONF_OPTS += --with-xrandr

Do not indent such variable definitions.

Noted

Quoted 4 lines

Applied with those fixes. Thanks!

Thomas

Thanks for the feedback.
Mario.

Quoted 4 lines

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

#5 lore raw

PATCH v2 1/1 new package: ratpoison

Hello,

Quoted 2 lines · Mario Rugiero
Quoted 1 line

The license really was GPL-2.0+, not GPL-2.0.

It didn't seem like it was GPL-2.0+ in the COPYING file, but I may be wrong.

The COPYING file never specifies if it's "or later" or not. The COPYING file contains the text of one specific version of the license. It's then the copyright notice at the beginning of source files that will say "covered by GPL version 2" or "covered by GPL version 2 or later".

Check the ratpoison source files, they say "or later". Hence the GPL-2.0+.

Best regards,

Thomas

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