All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [pull request v2] Pull request for branch for-2012.05/systemd
@ 2012-03-22  9:27 Maxime Ripard
  2012-03-22  9:27 ` [Buildroot] [PATCH 1/5] Add the systemd package Maxime Ripard
                   ` (4 more replies)
  0 siblings, 5 replies; 14+ messages in thread
From: Maxime Ripard @ 2012-03-22  9:27 UTC (permalink / raw)
  To: buildroot

Hi list,

This is the updated version of the previous patchset concerning systemd to take
into account the comments made mostly by Arnout.

The following changes since commit 5b84ec26c8981c6ab0e119b455e807152ded449a:

  libconfig: bump to 1.4.8 and cleanup (2012-03-21 23:08:25 +0100)

are available in the git repository at:
  git://git.free-electrons.com/users/maxime-ripard/buildroot.git for-2012.05/systemd

Maxime Ripard (5):
      Add the systemd package
      Enable cgroups in Linux if we use systemd
      Rework of the init system
      Fix installation for the lighttpd package
      Add systemd unit for lighttpd

 linux/linux.mk                                     |    2 +
 package/Config.in                                  |    1 +
 package/Makefile.package.in                        |    8 +++
 package/dbus/dbus.mk                               |    4 +
 .../lighttpd-1.4.30-Fix-default-config-file.patch  |   64 ++++++++++++++++++++
 package/lighttpd/lighttpd.mk                       |   43 +++++++++++++
 package/lighttpd/lighttpd.service                  |   10 +++
 package/systemd/Config.in                          |   19 ++++++
 package/systemd/systemd-37-fix-getty-unit.patch    |   26 ++++++++
 package/systemd/systemd.mk                         |   62 +++++++++++++++++++
 package/sysvinit/Config.in                         |    1 +
 package/udev/udev.mk                               |    4 +
 target/generic/Config.in                           |   28 +++++++++
 13 files changed, 272 insertions(+), 0 deletions(-)
 create mode 100644 package/lighttpd/lighttpd-1.4.30-Fix-default-config-file.patch
 create mode 100644 package/lighttpd/lighttpd.service
 create mode 100644 package/systemd/Config.in
 create mode 100644 package/systemd/systemd-37-fix-getty-unit.patch
 create mode 100644 package/systemd/systemd.mk

Thanks,
-- 
Maxime Ripard

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 1/5] Add the systemd package
  2012-03-22  9:27 [Buildroot] [pull request v2] Pull request for branch for-2012.05/systemd Maxime Ripard
@ 2012-03-22  9:27 ` Maxime Ripard
  2012-03-22 20:39   ` Peter Korsgaard
  2012-03-22  9:27 ` [Buildroot] [PATCH 2/5] Enable cgroups in Linux if we use systemd Maxime Ripard
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 14+ messages in thread
From: Maxime Ripard @ 2012-03-22  9:27 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
---
 package/Config.in                               |    1 +
 package/dbus/dbus.mk                            |    4 ++
 package/systemd/Config.in                       |   19 +++++++
 package/systemd/systemd-37-fix-getty-unit.patch |   26 ++++++++++
 package/systemd/systemd.mk                      |   62 +++++++++++++++++++++++
 package/udev/udev.mk                            |    4 ++
 6 files changed, 116 insertions(+), 0 deletions(-)
 create mode 100644 package/systemd/Config.in
 create mode 100644 package/systemd/systemd-37-fix-getty-unit.patch
 create mode 100644 package/systemd/systemd.mk

diff --git a/package/Config.in b/package/Config.in
index 85583c6..623c79a 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -577,6 +577,7 @@ source "package/rsyslog/Config.in"
 source "package/sysklogd/Config.in"
 source "package/sysvinit/Config.in"
 endif
+source "package/systemd/Config.in"
 source "package/util-linux/Config.in"
 source "package/dsp-tools/Config.in"
 endmenu
diff --git a/package/dbus/dbus.mk b/package/dbus/dbus.mk
index e18e291..0942b33 100644
--- a/package/dbus/dbus.mk
+++ b/package/dbus/dbus.mk
@@ -39,6 +39,10 @@ else
 DBUS_CONF_OPT += --without-x
 endif
 
+ifeq ($(BR2_PACKAGE_SYSTEMD),y)
+DBUS_CONF_OPT += --with-systemdsystemunitdir=/lib/systemd/system
+endif
+
 # fix rebuild (dbus makefile errors out if /var/lib/dbus is a symlink)
 define DBUS_REMOVE_VAR_LIB_DBUS
 	rm -rf $(TARGET_DIR)/var/lib/dbus
diff --git a/package/systemd/Config.in b/package/systemd/Config.in
new file mode 100644
index 0000000..d114ddd
--- /dev/null
+++ b/package/systemd/Config.in
@@ -0,0 +1,19 @@
+config BR2_PACKAGE_SYSTEMD
+	bool "systemd"
+	depends on BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_UDEV
+	select BR2_PACKAGE_DBUS
+	select BR2_PACKAGE_LIBCAP
+	help
+	  systemd is a system and service manager for Linux, compatible with
+	  SysV and LSB init scripts. systemd provides aggressive parallelization
+	  capabilities, uses socket and D-Bus activation for starting services,
+	  offers on-demand starting of daemons, keeps track of processes using
+	  Linux cgroups, supports snapshotting and restoring of the system
+	  state, maintains mount and automount points and implements an
+	  elaborate transactional dependency-based service control logic.
+	  It can work as a drop-in replacement for sysvinit.
+
+	  http://freedesktop.org/wiki/Software/systemd
+
+comment "systemd not available (depends on udev)"
+	depends on !BR2_PACKAGE_UDEV
diff --git a/package/systemd/systemd-37-fix-getty-unit.patch b/package/systemd/systemd-37-fix-getty-unit.patch
new file mode 100644
index 0000000..211fb4d
--- /dev/null
+++ b/package/systemd/systemd-37-fix-getty-unit.patch
@@ -0,0 +1,26 @@
+Index: systemd-37/units/getty at .service.m4
+===================================================================
+--- systemd-37.orig/units/getty at .service.m4	2012-03-21 10:05:23.868674099 +0100
++++ systemd-37/units/getty at .service.m4	2012-03-21 10:06:50.332671834 +0100
+@@ -32,7 +32,7 @@
+ 
+ [Service]
+ Environment=TERM=linux
+-ExecStart=-/sbin/agetty %I 38400
++ExecStart=-/sbin/getty -L %I 115200 vt100
+ Restart=always
+ RestartSec=0
+ UtmpIdentifier=%I
+Index: systemd-37/units/serial-getty at .service.m4
+===================================================================
+--- systemd-37.orig/units/serial-getty at .service.m4	2012-03-21 10:07:05.176671445 +0100
++++ systemd-37/units/serial-getty at .service.m4	2012-03-21 10:07:21.580671015 +0100
+@@ -32,7 +32,7 @@
+ 
+ [Service]
+ Environment=TERM=vt100
+-ExecStart=-/sbin/agetty -s %I 115200,38400,9600
++ExecStart=-/sbin/getty -L %I 115200 vt100
+ Restart=always
+ RestartSec=0
+ UtmpIdentifier=%I
diff --git a/package/systemd/systemd.mk b/package/systemd/systemd.mk
new file mode 100644
index 0000000..d615bbf
--- /dev/null
+++ b/package/systemd/systemd.mk
@@ -0,0 +1,62 @@
+#############################################################
+#
+# systemd
+#
+#############################################################
+SYSTEMD_VERSION = 37
+SYSTEMD_SITE = http://www.freedesktop.org/software/systemd/
+SYSTEMD_SOURCE = systemd-$(SYSTEMD_VERSION).tar.bz2
+SYSTEMD_DEPENDENCIES = \
+	host-intltool \
+	libcap \
+	udev \
+	dbus
+
+# Make sure that systemd will always be built after busybox so that we have
+# a consitent init setup between two builds
+ifeq ($(BR2_PACKAGE_BUSYBOX),y)
+	SYSTEMD_DEPENDENCIES += busybox
+endif
+
+SYSTEMD_CONF_OPT += \
+	--with-distro=other \
+	--disable-selinux \
+	--disable-pam \
+	--disable-libcryptsetup \
+	--disable-gtk \
+	--disable-plymouth \
+	--with-rootdir=/ \
+	--with-dbuspolicydir=/etc/dbus-1/system.d \
+	--with-dbussessionservicedir=/usr/share/dbus-1/services \
+	--with-dbussystemservicedir=/usr/share/dbus-1/system-services \
+	--with-dbusinterfacedir=/usr/share/dbus-1/interfaces \
+	--with-udevrulesdir=/etc/udev/rules.d \
+	--with-sysvinit-path=/etc/init.d/ \
+	--without-sysvrcd-path
+
+ifeq ($(BR2_PACKAGE_ACL),y)
+	SYSTEMD_CONF_OPT += --enable-acl
+	SYSTEMD_DEPENDENCIES += acl
+else
+	SYSTEMD_CONF_OPT += --disable-acl
+endif
+
+define SYSTEMD_INSTALL_INIT_HOOK
+	ln -fs ../bin/systemd $(TARGET_DIR)/sbin/init
+	ln -fs ../bin/systemctl $(TARGET_DIR)/sbin/halt
+	ln -fs ../bin/systemctl $(TARGET_DIR)/sbin/poweroff
+	ln -fs ../bin/systemctl $(TARGET_DIR)/sbin/reboot
+
+	ln -fs ../../../../lib/systemd/system/multi-user.target $(TARGET_DIR)/etc/systemd/system/default.target
+endef
+
+define SYSTEMD_INSTALL_TTY_HOOK
+	rm -f $(TARGET_DIR)/etc/systemd/system/getty.target.wants/getty at tty1.service
+	ln -fs ../../../../lib/systemd/system/serial-getty at .service $(TARGET_DIR)/etc/systemd/system/getty.target.wants/serial-getty@$(BR2_TARGET_GENERIC_GETTY_PORT).service
+endef
+
+SYSTEMD_POST_INSTALL_TARGET_HOOKS += \
+	SYSTEMD_INSTALL_INIT_HOOK \
+	SYSTEMD_INSTALL_TTY_HOOK \
+
+$(eval $(call AUTOTARGETS))
diff --git a/package/udev/udev.mk b/package/udev/udev.mk
index d445a2f..ed41511 100644
--- a/package/udev/udev.mk
+++ b/package/udev/udev.mk
@@ -35,6 +35,10 @@ UDEV_CONF_OPT +=		\
 	--disable-gudev
 endif
 
+ifeq ($(BR2_PACKAGE_SYSTEMD),y)
+	UDEV_CONF_OPT += --with-systemdsystemunitdir=/lib/systemd/system/
+endif
+
 define UDEV_INSTALL_INITSCRIPT
 	$(INSTALL) -m 0755 package/udev/S10udev $(TARGET_DIR)/etc/init.d/S10udev
 endef
-- 
1.7.5.4

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 2/5] Enable cgroups in Linux if we use systemd
  2012-03-22  9:27 [Buildroot] [pull request v2] Pull request for branch for-2012.05/systemd Maxime Ripard
  2012-03-22  9:27 ` [Buildroot] [PATCH 1/5] Add the systemd package Maxime Ripard
@ 2012-03-22  9:27 ` Maxime Ripard
  2012-03-22  9:27 ` [Buildroot] [PATCH 3/5] Rework of the init system Maxime Ripard
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 14+ messages in thread
From: Maxime Ripard @ 2012-03-22  9:27 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
---
 linux/linux.mk |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/linux/linux.mk b/linux/linux.mk
index 6cb1efc..93dd008 100644
--- a/linux/linux.mk
+++ b/linux/linux.mk
@@ -163,6 +163,8 @@ define LINUX_CONFIGURE_CMDS
 	$(if $(BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_MDEV),
 		$(call KCONFIG_SET_OPT,CONFIG_UEVENT_HELPER_PATH,\"/sbin/mdev\",$(@D)/.config))
 	yes '' | $(TARGET_MAKE_ENV) $(MAKE1) $(LINUX_MAKE_FLAGS) -C $(@D) oldconfig
+	$(if $(BR2_PACKAGE_SYSTEMD),
+		$(call KCONFIG_ENABLE_OPT,CONFIG_CGROUPS,$(@D)/.config))
 endef
 
 # Compilation. We make sure the kernel gets rebuilt when the
-- 
1.7.5.4

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 3/5] Rework of the init system
  2012-03-22  9:27 [Buildroot] [pull request v2] Pull request for branch for-2012.05/systemd Maxime Ripard
  2012-03-22  9:27 ` [Buildroot] [PATCH 1/5] Add the systemd package Maxime Ripard
  2012-03-22  9:27 ` [Buildroot] [PATCH 2/5] Enable cgroups in Linux if we use systemd Maxime Ripard
@ 2012-03-22  9:27 ` Maxime Ripard
  2012-03-22  9:27 ` [Buildroot] [PATCH 4/5] Fix installation for the lighttpd package Maxime Ripard
  2012-03-22  9:27 ` [Buildroot] [PATCH 5/5] Add systemd unit for lighttpd Maxime Ripard
  4 siblings, 0 replies; 14+ messages in thread
From: Maxime Ripard @ 2012-03-22  9:27 UTC (permalink / raw)
  To: buildroot

Since we have now two uncompatible init systems, and we want only one of
them at the same time in use in the rootfs, we need to select a
particular init system. This patch also adds $(PKG)_INSTALL_INIT_SYSTEMD
and $(PKG)_INSTALL_INIT_SYSV hooks that are called when the matching
init systems are selected to install properly the init scripts of the
package.

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
---
 package/Makefile.package.in |    8 ++++++++
 package/sysvinit/Config.in  |    1 +
 target/generic/Config.in    |   28 ++++++++++++++++++++++++++++
 3 files changed, 37 insertions(+), 0 deletions(-)

diff --git a/package/Makefile.package.in b/package/Makefile.package.in
index f7b6566..3992247 100644
--- a/package/Makefile.package.in
+++ b/package/Makefile.package.in
@@ -427,6 +427,10 @@ $(BUILD_DIR)/%/.stamp_images_installed:
 # Install to target dir
 $(BUILD_DIR)/%/.stamp_target_installed:
 	@$(call MESSAGE,"Installing to target")
+	$(if $(BR2_INIT_SYSTEMD),\
+		$($(PKG)_INSTALL_INIT_SYSTEMD))
+	$(if $(BR2_INIT_SYSV)$(BR2_INIT_BUSYBOX),\
+		$($(PKG)_INSTALL_INIT_SYSV))
 	$($(PKG)_INSTALL_TARGET_CMDS)
 	$(foreach hook,$($(PKG)_POST_INSTALL_TARGET_HOOKS),$(call $(hook))$(sep))
 	$(Q)touch $@
@@ -445,6 +449,10 @@ $(BUILD_DIR)/%/.stamp_uninstalled:
 	rm -f $($(PKG)_TARGET_INSTALL_TARGET)
 	$($(PKG)_UNINSTALL_STAGING_CMDS)
 	$($(PKG)_UNINSTALL_TARGET_CMDS)
+	$(if $(BR2_INIT_SYSTEMD),\
+		$($(PKG)_UNINSTALL_INIT_SYSTEMD))
+	$(if $(BR2_INIT_SYSV)$(BR2_INIT_BUSYBOX),\
+		$($(PKG)_UNINSTALL_INIT_SYSV))
 
 # Remove package sources
 $(BUILD_DIR)/%/.stamp_dircleaned:
diff --git a/package/sysvinit/Config.in b/package/sysvinit/Config.in
index 34ec391..d91c643 100644
--- a/package/sysvinit/Config.in
+++ b/package/sysvinit/Config.in
@@ -1,5 +1,6 @@
 config BR2_PACKAGE_SYSVINIT
 	bool "sysvinit"
+	depends on BR2_INIT_SYSV
 	help
 	  /sbin/init - parent of all processes
 
diff --git a/target/generic/Config.in b/target/generic/Config.in
index 88f0718..40009bd 100644
--- a/target/generic/Config.in
+++ b/target/generic/Config.in
@@ -37,6 +37,34 @@ comment "udev requires a toolchain with LARGEFILE + WCHAR support"
 
 endchoice
 
+choice
+	prompt "Init system"
+	default BR2_INIT_BUSYBOX
+	help
+	  To select systemd, you first need to have dbus and udev enabled
+
+config BR2_INIT_BUSYBOX
+	bool "Busybox init"
+	select BR2_PACKAGE_BUSYBOX
+
+config BR2_INIT_SYSV
+	bool "Use systemV init"
+	select BR2_PACKAGE_SYSVINIT
+
+config BR2_INIT_SYSTEMD
+	bool "Use systemd"
+	depends on BR2_LARGEFILE
+	depends on BR2_USE_WCHAR
+	depends on BR2_INET_IPV6
+	select BR2_PACKAGE_DBUS
+	select BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_UDEV
+	select BR2_PACKAGE_SYSTEMD
+
+comment 'systemd requires largefile, wchar and IPv6 support'
+	depends on !(BR2_LARGEFILE && BR2_USE_WCHAR && BR2_INET_IPV6)
+
+endchoice
+
 config BR2_ROOTFS_DEVICE_TABLE
 	string "Path to the permission tables"
 	default "target/generic/device_table.txt"
-- 
1.7.5.4

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 4/5] Fix installation for the lighttpd package
  2012-03-22  9:27 [Buildroot] [pull request v2] Pull request for branch for-2012.05/systemd Maxime Ripard
                   ` (2 preceding siblings ...)
  2012-03-22  9:27 ` [Buildroot] [PATCH 3/5] Rework of the init system Maxime Ripard
@ 2012-03-22  9:27 ` Maxime Ripard
  2012-03-22 20:59   ` Arnout Vandecappelle
  2012-03-22 22:02   ` Peter Korsgaard
  2012-03-22  9:27 ` [Buildroot] [PATCH 5/5] Add systemd unit for lighttpd Maxime Ripard
  4 siblings, 2 replies; 14+ messages in thread
From: Maxime Ripard @ 2012-03-22  9:27 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
---
 .../lighttpd-1.4.30-Fix-default-config-file.patch  |   64 ++++++++++++++++++++
 package/lighttpd/lighttpd.mk                       |   32 ++++++++++
 2 files changed, 96 insertions(+), 0 deletions(-)
 create mode 100644 package/lighttpd/lighttpd-1.4.30-Fix-default-config-file.patch

diff --git a/package/lighttpd/lighttpd-1.4.30-Fix-default-config-file.patch b/package/lighttpd/lighttpd-1.4.30-Fix-default-config-file.patch
new file mode 100644
index 0000000..76afbf8
--- /dev/null
+++ b/package/lighttpd/lighttpd-1.4.30-Fix-default-config-file.patch
@@ -0,0 +1,64 @@
+Index: lighttpd-1.4.30/doc/config/lighttpd.conf
+===================================================================
+--- lighttpd-1.4.30.orig/doc/config/lighttpd.conf	2011-12-18 13:57:25.000000000 +0100
++++ lighttpd-1.4.30/doc/config/lighttpd.conf	2012-03-22 09:55:31.402424839 +0100
+@@ -13,7 +13,7 @@
+ ## if you add a variable here. Add the corresponding variable in the
+ ## chroot example aswell.
+ ##
+-var.log_root    = "/var/log/lighttpd"
++var.log_root    = "/var/log"
+ var.server_root = "/srv/www"
+ var.state_dir   = "/var/run"
+ var.home_dir    = "/var/lib/lighttpd"
+@@ -90,7 +90,7 @@
+ ##
+ ## Use IPv6?
+ ##
+-server.use-ipv6 = "enable"
++# server.use-ipv6 = "enable"
+ 
+ ##
+ ## bind to a specific IP
+@@ -101,8 +101,8 @@
+ ## Run as a different username/groupname.
+ ## This requires root permissions during startup. 
+ ##
+-server.username  = "lighttpd"
+-server.groupname = "lighttpd"
++# server.username  = "lighttpd"
++# server.groupname = "lighttpd"
+ 
+ ## 
+ ## enable core files.
+@@ -138,7 +138,7 @@
+ ##
+ ## Path to the error log file
+ ##
+-server.errorlog             = log_root + "/error.log"
++server.errorlog             = log_root + "/lighttpd-error.log"
+ 
+ ##
+ ## If you want to log to syslog you have to unset the 
+@@ -188,7 +188,7 @@
+ ## linux-sendfile - is recommended for small files.
+ ## writev         - is recommended for sending many large files
+ ##
+-server.network-backend = "linux-sendfile"
++server.network-backend = "writev"
+ 
+ ##
+ ## As lighttpd is a single-threaded server, its main resource limit is
+@@ -311,9 +311,9 @@
+ ## disable range requests for pdf files
+ ## workaround for a bug in the Acrobat Reader plugin.
+ ##
+-$HTTP["url"] =~ "\.pdf$" {
+-  server.range-requests = "disable"
+-}
++# $HTTP["url"] =~ "\.pdf$" {
++#  server.range-requests = "disable"
++# }
+ 
+ ##
+ ## url handling modules (rewrite, redirect)
diff --git a/package/lighttpd/lighttpd.mk b/package/lighttpd/lighttpd.mk
index b8aa310..8d1f212 100644
--- a/package/lighttpd/lighttpd.mk
+++ b/package/lighttpd/lighttpd.mk
@@ -56,6 +56,38 @@ else
 LIGHTTPD_CONF_OPT += --without-lua
 endif
 
+define LIGHTTPD_INSTALL_CONFIG
+	mkdir -p $(TARGET_DIR)/etc/lighttpd
+	mkdir -p $(TARGET_DIR)/etc/lighttpd/conf.d
+	mkdir -p $(TARGET_DIR)/srv/www/htdocs
+
+	[ -f $(TARGET_DIR)/etc/lighttpd/lighttpd.conf ] || \
+		$(INSTALL) -D -m 755 $(@D)/doc/config/lighttpd.conf \
+			$(TARGET_DIR)/etc/lighttpd/lighttpd.conf
+
+	[ -f $(TARGET_DIR)/etc/lighttpd/modules.conf ] || \
+		$(INSTALL) -D -m 755 $(@D)/doc/config/modules.conf \
+			$(TARGET_DIR)/etc/lighttpd/modules.conf
+
+	[ -f $(TARGET_DIR)/etc/lighttpd/conf.d/access_log.conf ] || \
+		$(INSTALL) -D -m 755 $(@D)/doc/config/conf.d/access_log.conf \
+			$(TARGET_DIR)/etc/lighttpd/conf.d/access_log.conf
+
+	[ -f $(TARGET_DIR)/etc/lighttpd/conf.d/debug.conf ] || \
+		$(INSTALL) -D -m 755 $(@D)/doc/config/conf.d/debug.conf \
+			$(TARGET_DIR)/etc/lighttpd/conf.d/debug.conf
+
+	[ -f $(TARGET_DIR)/etc/lighttpd/conf.d/dirlisting.conf ] || \
+		$(INSTALL) -D -m 755 $(@D)/doc/config/conf.d/dirlisting.conf \
+			$(TARGET_DIR)/etc/lighttpd/conf.d/dirlisting.conf
+
+	[ -f $(TARGET_DIR)/etc/lighttpd/conf.d/mime.conf ] || \
+		$(INSTALL) -D -m 755 $(@D)/doc/config/conf.d/mime.conf \
+			$(TARGET_DIR)/etc/lighttpd/conf.d/mime.conf
+endef
+
+LIGHTTPD_POST_INSTALL_TARGET_HOOKS += LIGHTTPD_INSTALL_CONFIG
+
 define LIGHTTPD_UNINSTALL_TARGET_CMDS
 	rm -f $(TARGET_DIR)/usr/sbin/lighttpd
 	rm -f $(TARGET_DIR)/usr/sbin/lighttpd-angel
-- 
1.7.5.4

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 5/5] Add systemd unit for lighttpd
  2012-03-22  9:27 [Buildroot] [pull request v2] Pull request for branch for-2012.05/systemd Maxime Ripard
                   ` (3 preceding siblings ...)
  2012-03-22  9:27 ` [Buildroot] [PATCH 4/5] Fix installation for the lighttpd package Maxime Ripard
@ 2012-03-22  9:27 ` Maxime Ripard
  4 siblings, 0 replies; 14+ messages in thread
From: Maxime Ripard @ 2012-03-22  9:27 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
---
 package/lighttpd/lighttpd.mk      |   11 +++++++++++
 package/lighttpd/lighttpd.service |   10 ++++++++++
 2 files changed, 21 insertions(+), 0 deletions(-)
 create mode 100644 package/lighttpd/lighttpd.service

diff --git a/package/lighttpd/lighttpd.mk b/package/lighttpd/lighttpd.mk
index 8d1f212..1f2f283 100644
--- a/package/lighttpd/lighttpd.mk
+++ b/package/lighttpd/lighttpd.mk
@@ -88,6 +88,17 @@ endef
 
 LIGHTTPD_POST_INSTALL_TARGET_HOOKS += LIGHTTPD_INSTALL_CONFIG
 
+define LIGHTTPD_INSTALL_INIT_SYSTEMD
+	[ -f $(TARGET_DIR)/etc/systemd/system/lighttpd.service ] || \
+		$(INSTALL) -D -m 755 package/lighttpd/lighttpd.service \
+			$(TARGET_DIR)/etc/systemd/system/lighttpd.service
+
+	mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
+
+	ln -fs ../lighttpd.service \
+		$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/lighttpd.service
+endef
+
 define LIGHTTPD_UNINSTALL_TARGET_CMDS
 	rm -f $(TARGET_DIR)/usr/sbin/lighttpd
 	rm -f $(TARGET_DIR)/usr/sbin/lighttpd-angel
diff --git a/package/lighttpd/lighttpd.service b/package/lighttpd/lighttpd.service
new file mode 100644
index 0000000..0ca5357
--- /dev/null
+++ b/package/lighttpd/lighttpd.service
@@ -0,0 +1,10 @@
+[Unit]
+Description=Lighttpd Web Server
+After=network.target
+
+[Service]
+ExecStart=/usr/sbin/lighttpd-angel -f /etc/lighttpd/lighttpd.conf -D
+ExecReload=/bin/kill -HUP $MAINPID
+
+[Install]
+WantedBy=multi-user.target
-- 
1.7.5.4

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 1/5] Add the systemd package
  2012-03-22  9:27 ` [Buildroot] [PATCH 1/5] Add the systemd package Maxime Ripard
@ 2012-03-22 20:39   ` Peter Korsgaard
  2012-03-23  8:51     ` Maxime Ripard
  0 siblings, 1 reply; 14+ messages in thread
From: Peter Korsgaard @ 2012-03-22 20:39 UTC (permalink / raw)
  To: buildroot

>>>>> "Maxime" == Maxime Ripard <maxime.ripard@free-electrons.com> writes:

Hi,

 Maxime> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
 Maxime> ---
 Maxime>  package/Config.in                               |    1 +
 Maxime>  package/dbus/dbus.mk                            |    4 ++
 Maxime>  package/systemd/Config.in                       |   19 +++++++
 Maxime>  package/systemd/systemd-37-fix-getty-unit.patch |   26 ++++++++++
 Maxime>  package/systemd/systemd.mk                      |   62 +++++++++++++++++++++++
 Maxime>  package/udev/udev.mk                            |    4 ++
 Maxime>  6 files changed, 116 insertions(+), 0 deletions(-)
 Maxime>  create mode 100644 package/systemd/Config.in
 Maxime>  create mode 100644 package/systemd/systemd-37-fix-getty-unit.patch
 Maxime>  create mode 100644 package/systemd/systemd.mk

 Maxime> +++ b/package/systemd/Config.in
 Maxime> @@ -0,0 +1,19 @@
 Maxime> +config BR2_PACKAGE_SYSTEMD
 Maxime> +	bool "systemd"
 Maxime> +	depends on BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_UDEV
 Maxime> +	select BR2_PACKAGE_DBUS
 Maxime> +	select BR2_PACKAGE_LIBCAP
 Maxime> +	help

Systemd also depends on BR2_INET_IPV6.


 Maxime> +	  systemd is a system and service manager for Linux, compatible with
 Maxime> +	  SysV and LSB init scripts. systemd provides aggressive parallelization
 Maxime> +	  capabilities, uses socket and D-Bus activation for starting services,
 Maxime> +	  offers on-demand starting of daemons, keeps track of processes using
 Maxime> +	  Linux cgroups, supports snapshotting and restoring of the system
 Maxime> +	  state, maintains mount and automount points and implements an
 Maxime> +	  elaborate transactional dependency-based service control logic.
 Maxime> +	  It can work as a drop-in replacement for sysvinit.
 Maxime> +
 Maxime> +	  http://freedesktop.org/wiki/Software/systemd
 Maxime> +
 Maxime> +comment "systemd not available (depends on udev)"
 Maxime> +	depends on !BR2_PACKAGE_UDEV

As you changed the depend on, this should also say something like:

(depends on /dev management with udev)

and depend on !BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_UDEV


 Maxime> diff --git a/package/systemd/systemd-37-fix-getty-unit.patch b/package/systemd/systemd-37-fix-getty-unit.patch
 Maxime> new file mode 100644
 Maxime> index 0000000..211fb4d
 Maxime> --- /dev/null
 Maxime> +++ b/package/systemd/systemd-37-fix-getty-unit.patch
 Maxime> @@ -0,0 +1,26 @@

Please add a git-style header with description and signed-off-by on all
patches.

 Maxime> +Index: systemd-37/units/getty at .service.m4
 Maxime> +===================================================================
 Maxime> +--- systemd-37.orig/units/getty at .service.m4	2012-03-21 10:05:23.868674099 +0100
 Maxime> ++++ systemd-37/units/getty at .service.m4	2012-03-21 10:06:50.3326

Otherwise it looks good. Care to fix?

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 4/5] Fix installation for the lighttpd package
  2012-03-22  9:27 ` [Buildroot] [PATCH 4/5] Fix installation for the lighttpd package Maxime Ripard
@ 2012-03-22 20:59   ` Arnout Vandecappelle
  2012-03-22 22:02   ` Peter Korsgaard
  1 sibling, 0 replies; 14+ messages in thread
From: Arnout Vandecappelle @ 2012-03-22 20:59 UTC (permalink / raw)
  To: buildroot

On Thursday 22 March 2012 10:27:19 Maxime Ripard wrote:
> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>

 This one is actually independent of the rest of the systemd stuff.

 Regards,
 Arnout

-- 
Arnout Vandecappelle                               arnout at mind be
Senior Embedded Software Architect                 +32-16-286540
Essensium/Mind                                     http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium                BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20120322/9bb1215b/attachment.html>

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 4/5] Fix installation for the lighttpd package
  2012-03-22  9:27 ` [Buildroot] [PATCH 4/5] Fix installation for the lighttpd package Maxime Ripard
  2012-03-22 20:59   ` Arnout Vandecappelle
@ 2012-03-22 22:02   ` Peter Korsgaard
  2012-03-23  9:07     ` Maxime Ripard
  1 sibling, 1 reply; 14+ messages in thread
From: Peter Korsgaard @ 2012-03-22 22:02 UTC (permalink / raw)
  To: buildroot

>>>>> "Maxime" == Maxime Ripard <maxime.ripard@free-electrons.com> writes:

Hi,

 Maxime> ++++ lighttpd-1.4.30/doc/config/lighttpd.conf	2012-03-22 09:55:31.402424839 +0100

Please add a git-style description of what the patch does and your
signed-off-by.


 Maxime> +@@ -13,7 +13,7 @@
 Maxime> + ## if you add a variable here. Add the corresponding variable in the
 Maxime> + ## chroot example aswell.
 Maxime> + ##
 Maxime> +-var.log_root    = "/var/log/lighttpd"
 Maxime> ++var.log_root    = "/var/log"
 Maxime> + var.server_root = "/srv/www"
 Maxime> + var.state_dir   = "/var/run"
 Maxime> + var.home_dir    = "/var/lib/lighttpd"
 Maxime> +@@ -90,7 +90,7 @@
 Maxime> + ##
 Maxime> + ## Use IPv6?
 Maxime> + ##
 Maxime> +-server.use-ipv6 = "enable"
 Maxime> ++# server.use-ipv6 = "enable"
 Maxime> + 
 Maxime> + ##
 Maxime> + ## bind to a specific IP
 Maxime> +@@ -101,8 +101,8 @@
 Maxime> + ## Run as a different username/groupname.
 Maxime> + ## This requires root permissions during startup. 
 Maxime> + ##
 Maxime> +-server.username  = "lighttpd"
 Maxime> +-server.groupname = "lighttpd"
 Maxime> ++# server.username  = "lighttpd"
 Maxime> ++# server.groupname = "lighttpd"
 Maxime> + 
 Maxime> + ## 
 Maxime> + ## enable core files.
 Maxime> +@@ -138,7 +138,7 @@
 Maxime> + ##
 Maxime> + ## Path to the error log file
 Maxime> + ##
 Maxime> +-server.errorlog             = log_root + "/error.log"
 Maxime> ++server.errorlog             = log_root + "/lighttpd-error.log"

Why? The access log is still called access.log, so why rename this?

 Maxime> + 
 Maxime> + ##
 Maxime> + ## If you want to log to syslog you have to unset the 
 Maxime> +@@ -188,7 +188,7 @@
 Maxime> + ## linux-sendfile - is recommended for small files.
 Maxime> + ## writev         - is recommended for sending many large files
 Maxime> + ##
 Maxime> +-server.network-backend = "linux-sendfile"
 Maxime> ++server.network-backend = "writev"

Why?

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 1/5] Add the systemd package
  2012-03-22 20:39   ` Peter Korsgaard
@ 2012-03-23  8:51     ` Maxime Ripard
  2012-03-23  9:04       ` Peter Korsgaard
  0 siblings, 1 reply; 14+ messages in thread
From: Maxime Ripard @ 2012-03-23  8:51 UTC (permalink / raw)
  To: buildroot

Hi Peter,

Le 22/03/2012 21:39, Peter Korsgaard a ?crit :
>>>>>> "Maxime" == Maxime Ripard <maxime.ripard@free-electrons.com> writes:
> 
> Hi,
> 
>  Maxime> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
>  Maxime> ---
>  Maxime>  package/Config.in                               |    1 +
>  Maxime>  package/dbus/dbus.mk                            |    4 ++
>  Maxime>  package/systemd/Config.in                       |   19 +++++++
>  Maxime>  package/systemd/systemd-37-fix-getty-unit.patch |   26 ++++++++++
>  Maxime>  package/systemd/systemd.mk                      |   62 +++++++++++++++++++++++
>  Maxime>  package/udev/udev.mk                            |    4 ++
>  Maxime>  6 files changed, 116 insertions(+), 0 deletions(-)
>  Maxime>  create mode 100644 package/systemd/Config.in
>  Maxime>  create mode 100644 package/systemd/systemd-37-fix-getty-unit.patch
>  Maxime>  create mode 100644 package/systemd/systemd.mk
> 
>  Maxime> +++ b/package/systemd/Config.in
>  Maxime> @@ -0,0 +1,19 @@
>  Maxime> +config BR2_PACKAGE_SYSTEMD
>  Maxime> +	bool "systemd"
>  Maxime> +	depends on BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_UDEV
>  Maxime> +	select BR2_PACKAGE_DBUS
>  Maxime> +	select BR2_PACKAGE_LIBCAP
>  Maxime> +	help
> 
> Systemd also depends on BR2_INET_IPV6.

Ah, yes, I forgot to add it here.

>  Maxime> +	  systemd is a system and service manager for Linux, compatible with
>  Maxime> +	  SysV and LSB init scripts. systemd provides aggressive parallelization
>  Maxime> +	  capabilities, uses socket and D-Bus activation for starting services,
>  Maxime> +	  offers on-demand starting of daemons, keeps track of processes using
>  Maxime> +	  Linux cgroups, supports snapshotting and restoring of the system
>  Maxime> +	  state, maintains mount and automount points and implements an
>  Maxime> +	  elaborate transactional dependency-based service control logic.
>  Maxime> +	  It can work as a drop-in replacement for sysvinit.
>  Maxime> +
>  Maxime> +	  http://freedesktop.org/wiki/Software/systemd
>  Maxime> +
>  Maxime> +comment "systemd not available (depends on udev)"
>  Maxime> +	depends on !BR2_PACKAGE_UDEV
> 
> As you changed the depend on, this should also say something like:
> 
> (depends on /dev management with udev)
> 
> and depend on !BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_UDEV

Of course.
I forgot LARGEFILE and WCHAR as well..

>  Maxime> diff --git a/package/systemd/systemd-37-fix-getty-unit.patch b/package/systemd/systemd-37-fix-getty-unit.patch
>  Maxime> new file mode 100644
>  Maxime> index 0000000..211fb4d
>  Maxime> --- /dev/null
>  Maxime> +++ b/package/systemd/systemd-37-fix-getty-unit.patch
>  Maxime> @@ -0,0 +1,26 @@
> 
> Please add a git-style header with description and signed-off-by on all
> patches.

Ok


>  Maxime> +Index: systemd-37/units/getty at .service.m4
>  Maxime> +===================================================================
>  Maxime> +--- systemd-37.orig/units/getty at .service.m4	2012-03-21 10:05:23.868674099 +0100
>  Maxime> ++++ systemd-37/units/getty at .service.m4	2012-03-21 10:06:50.3326
> 
> Otherwise it looks good. Care to fix?

Not at all, I'll resend it today.


-- 
Maxime Ripard, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 1/5] Add the systemd package
  2012-03-23  8:51     ` Maxime Ripard
@ 2012-03-23  9:04       ` Peter Korsgaard
  0 siblings, 0 replies; 14+ messages in thread
From: Peter Korsgaard @ 2012-03-23  9:04 UTC (permalink / raw)
  To: buildroot

>>>>> "Maxime" == Maxime Ripard <maxime.ripard@free-electrons.com> writes:

Hi,
 >> As you changed the depend on, this should also say something like:
 >> 
 >> (depends on /dev management with udev)
 >> 
 >> and depend on !BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_UDEV

 Maxime> Of course.
 Maxime> I forgot LARGEFILE and WCHAR as well..

That's not needed as BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_UDEV already
depends on those.

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 4/5] Fix installation for the lighttpd package
  2012-03-22 22:02   ` Peter Korsgaard
@ 2012-03-23  9:07     ` Maxime Ripard
  0 siblings, 0 replies; 14+ messages in thread
From: Maxime Ripard @ 2012-03-23  9:07 UTC (permalink / raw)
  To: buildroot

Hi,

Le 22/03/2012 23:02, Peter Korsgaard a ?crit :
>>>>>> "Maxime" == Maxime Ripard <maxime.ripard@free-electrons.com> writes:
> 
> Hi,
> 
>  Maxime> ++++ lighttpd-1.4.30/doc/config/lighttpd.conf	2012-03-22 09:55:31.402424839 +0100
> 
> Please add a git-style description of what the patch does and your
> signed-off-by.

Will do.

>  Maxime> +@@ -13,7 +13,7 @@
>  Maxime> + ## if you add a variable here. Add the corresponding variable in the
>  Maxime> + ## chroot example aswell.
>  Maxime> + ##
>  Maxime> +-var.log_root    = "/var/log/lighttpd"
>  Maxime> ++var.log_root    = "/var/log"
>  Maxime> + var.server_root = "/srv/www"
>  Maxime> + var.state_dir   = "/var/run"
>  Maxime> + var.home_dir    = "/var/lib/lighttpd"
>  Maxime> +@@ -90,7 +90,7 @@
>  Maxime> + ##
>  Maxime> + ## Use IPv6?
>  Maxime> + ##
>  Maxime> +-server.use-ipv6 = "enable"
>  Maxime> ++# server.use-ipv6 = "enable"
>  Maxime> + 
>  Maxime> + ##
>  Maxime> + ## bind to a specific IP
>  Maxime> +@@ -101,8 +101,8 @@
>  Maxime> + ## Run as a different username/groupname.
>  Maxime> + ## This requires root permissions during startup. 
>  Maxime> + ##
>  Maxime> +-server.username  = "lighttpd"
>  Maxime> +-server.groupname = "lighttpd"
>  Maxime> ++# server.username  = "lighttpd"
>  Maxime> ++# server.groupname = "lighttpd"
>  Maxime> + 
>  Maxime> + ## 
>  Maxime> + ## enable core files.
>  Maxime> +@@ -138,7 +138,7 @@
>  Maxime> + ##
>  Maxime> + ## Path to the error log file
>  Maxime> + ##
>  Maxime> +-server.errorlog             = log_root + "/error.log"
>  Maxime> ++server.errorlog             = log_root + "/lighttpd-error.log"
> 
> Why? The access log is still called access.log, so why rename this?

I guess I missed access log :)
I renamed it because I found having a file called "error.log" in
/var/log was way too generic...

I changed the access log path as well.

>  Maxime> + 
>  Maxime> + ##
>  Maxime> + ## If you want to log to syslog you have to unset the 
>  Maxime> +@@ -188,7 +188,7 @@
>  Maxime> + ## linux-sendfile - is recommended for small files.
>  Maxime> + ## writev         - is recommended for sending many large files
>  Maxime> + ##
>  Maxime> +-server.network-backend = "linux-sendfile"
>  Maxime> ++server.network-backend = "writev"
> 
> Why?
> 
I'm not sure really why, but in our current configuration, lighttpd
refuses to boot if the backend is set to "linux-sendfile", while it
starts with writev.


-- 
Maxime Ripard, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 5/5] Add systemd unit for lighttpd
  2012-03-23 15:49 [Buildroot] [pull request v4] Pull request for branch for-2012.05/systemd Maxime Ripard
@ 2012-03-23 15:49 ` Maxime Ripard
  0 siblings, 0 replies; 14+ messages in thread
From: Maxime Ripard @ 2012-03-23 15:49 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
---
 package/lighttpd/lighttpd.mk      |   11 +++++++++++
 package/lighttpd/lighttpd.service |   10 ++++++++++
 2 files changed, 21 insertions(+), 0 deletions(-)
 create mode 100644 package/lighttpd/lighttpd.service

diff --git a/package/lighttpd/lighttpd.mk b/package/lighttpd/lighttpd.mk
index 8d1f212..1f2f283 100644
--- a/package/lighttpd/lighttpd.mk
+++ b/package/lighttpd/lighttpd.mk
@@ -88,6 +88,17 @@ endef
 
 LIGHTTPD_POST_INSTALL_TARGET_HOOKS += LIGHTTPD_INSTALL_CONFIG
 
+define LIGHTTPD_INSTALL_INIT_SYSTEMD
+	[ -f $(TARGET_DIR)/etc/systemd/system/lighttpd.service ] || \
+		$(INSTALL) -D -m 755 package/lighttpd/lighttpd.service \
+			$(TARGET_DIR)/etc/systemd/system/lighttpd.service
+
+	mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
+
+	ln -fs ../lighttpd.service \
+		$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/lighttpd.service
+endef
+
 define LIGHTTPD_UNINSTALL_TARGET_CMDS
 	rm -f $(TARGET_DIR)/usr/sbin/lighttpd
 	rm -f $(TARGET_DIR)/usr/sbin/lighttpd-angel
diff --git a/package/lighttpd/lighttpd.service b/package/lighttpd/lighttpd.service
new file mode 100644
index 0000000..0ca5357
--- /dev/null
+++ b/package/lighttpd/lighttpd.service
@@ -0,0 +1,10 @@
+[Unit]
+Description=Lighttpd Web Server
+After=network.target
+
+[Service]
+ExecStart=/usr/sbin/lighttpd-angel -f /etc/lighttpd/lighttpd.conf -D
+ExecReload=/bin/kill -HUP $MAINPID
+
+[Install]
+WantedBy=multi-user.target
-- 
1.7.5.4

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [Buildroot] [PATCH 5/5] Add systemd unit for lighttpd
  2012-03-23  9:26 [Buildroot] [pull request v3] Pull request for branch for-2012.05/systemd Maxime Ripard
@ 2012-03-23  9:26 ` Maxime Ripard
  0 siblings, 0 replies; 14+ messages in thread
From: Maxime Ripard @ 2012-03-23  9:26 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
---
 package/lighttpd/lighttpd.mk      |   11 +++++++++++
 package/lighttpd/lighttpd.service |   10 ++++++++++
 2 files changed, 21 insertions(+), 0 deletions(-)
 create mode 100644 package/lighttpd/lighttpd.service

diff --git a/package/lighttpd/lighttpd.mk b/package/lighttpd/lighttpd.mk
index 8d1f212..1f2f283 100644
--- a/package/lighttpd/lighttpd.mk
+++ b/package/lighttpd/lighttpd.mk
@@ -88,6 +88,17 @@ endef
 
 LIGHTTPD_POST_INSTALL_TARGET_HOOKS += LIGHTTPD_INSTALL_CONFIG
 
+define LIGHTTPD_INSTALL_INIT_SYSTEMD
+	[ -f $(TARGET_DIR)/etc/systemd/system/lighttpd.service ] || \
+		$(INSTALL) -D -m 755 package/lighttpd/lighttpd.service \
+			$(TARGET_DIR)/etc/systemd/system/lighttpd.service
+
+	mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
+
+	ln -fs ../lighttpd.service \
+		$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/lighttpd.service
+endef
+
 define LIGHTTPD_UNINSTALL_TARGET_CMDS
 	rm -f $(TARGET_DIR)/usr/sbin/lighttpd
 	rm -f $(TARGET_DIR)/usr/sbin/lighttpd-angel
diff --git a/package/lighttpd/lighttpd.service b/package/lighttpd/lighttpd.service
new file mode 100644
index 0000000..0ca5357
--- /dev/null
+++ b/package/lighttpd/lighttpd.service
@@ -0,0 +1,10 @@
+[Unit]
+Description=Lighttpd Web Server
+After=network.target
+
+[Service]
+ExecStart=/usr/sbin/lighttpd-angel -f /etc/lighttpd/lighttpd.conf -D
+ExecReload=/bin/kill -HUP $MAINPID
+
+[Install]
+WantedBy=multi-user.target
-- 
1.7.5.4

^ permalink raw reply related	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2012-03-23 15:49 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-03-22  9:27 [Buildroot] [pull request v2] Pull request for branch for-2012.05/systemd Maxime Ripard
2012-03-22  9:27 ` [Buildroot] [PATCH 1/5] Add the systemd package Maxime Ripard
2012-03-22 20:39   ` Peter Korsgaard
2012-03-23  8:51     ` Maxime Ripard
2012-03-23  9:04       ` Peter Korsgaard
2012-03-22  9:27 ` [Buildroot] [PATCH 2/5] Enable cgroups in Linux if we use systemd Maxime Ripard
2012-03-22  9:27 ` [Buildroot] [PATCH 3/5] Rework of the init system Maxime Ripard
2012-03-22  9:27 ` [Buildroot] [PATCH 4/5] Fix installation for the lighttpd package Maxime Ripard
2012-03-22 20:59   ` Arnout Vandecappelle
2012-03-22 22:02   ` Peter Korsgaard
2012-03-23  9:07     ` Maxime Ripard
2012-03-22  9:27 ` [Buildroot] [PATCH 5/5] Add systemd unit for lighttpd Maxime Ripard
2012-03-23  9:26 [Buildroot] [pull request v3] Pull request for branch for-2012.05/systemd Maxime Ripard
2012-03-23  9:26 ` [Buildroot] [PATCH 5/5] Add systemd unit for lighttpd Maxime Ripard
2012-03-23 15:49 [Buildroot] [pull request v4] Pull request for branch for-2012.05/systemd Maxime Ripard
2012-03-23 15:49 ` [Buildroot] [PATCH 5/5] Add systemd unit for lighttpd Maxime Ripard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.