Hello,

Here is in attachment the latest patch we made for fcoe-utils-1.0.29+git20140505 version for Debian.

All is working and ifdown/ifup is no longer necessary to see hosts in /sys/class/fc_host/

Regards,


--
 🐧 M. Sylvain COSTARD
 🎓 Université Rennes 2
     Direction du Système d'Information
      Pôle Infrastructure / Serveurs
 🔗http://www.univ-rennes2.fr/dsi


diff -rNbu a/debian/patches/0028-systemctl-cannot-start-fcoemon.socket.patch b/debian/patches/0028-systemctl-cannot-start-fcoemon.socket.patch
--- a/debian/patches/0028-systemctl-cannot-start-fcoemon.socket.patch	1970-01-01 01:00:00.000000000 +0100
+++ b/debian/patches/0028-systemctl-cannot-start-fcoemon.socket.patch	2017-01-18 13:46:06.858325287 +0100
@@ -0,0 +1,31 @@
+From 444f3c66ee5a2b59a563d78cb70db7da2326d446 Mon Sep 17 00:00:00 2001
+From: Hannes Reinecke <h...@suse.de>
+Date: Fri, 21 Mar 2014 14:46:40 +0100
+Subject: systemctl cannot start fcoemon.socket
+
+systemctl start fcoemon.socket fails, as systemd cannot find
+the referenced service.
+
+References: bnc#869392
+
+Signed-off-by: Hannes Reinecke <h...@suse.de>
+---
+ etc/systemd/fcoemon.socket | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/etc/systemd/fcoemon.socket b/etc/systemd/fcoemon.socket
+index 4de8715..fdf7141 100644
+--- a/etc/systemd/fcoemon.socket
++++ b/etc/systemd/fcoemon.socket
+@@ -1,4 +1,8 @@
++[Unit]
++Description=Open-FCoE daemon control socket
++
+ [Socket]
++Service=fcoe.service
+ ListenDatagram=@/com/intel/fcoemon
+ PassCredentials=true
+ 
+-- 
+1.8.1.4
+
diff -rNbu a/debian/patches/0029-fcoemon-Correctly-handle-options-in-the-service-file.patch b/debian/patches/0029-fcoemon-Correctly-handle-options-in-the-service-file.patch
--- a/debian/patches/0029-fcoemon-Correctly-handle-options-in-the-service-file.patch	1970-01-01 01:00:00.000000000 +0100
+++ b/debian/patches/0029-fcoemon-Correctly-handle-options-in-the-service-file.patch	2017-01-18 13:46:06.862325394 +0100
@@ -0,0 +1,121 @@
+From 5216ae2ef4434d92ff3d49c4d5a7b73b438aee2d Mon Sep 17 00:00:00 2001
+From: Hannes Reinecke <h...@suse.de>
+Date: Fri, 11 Apr 2014 15:38:26 +0200
+Subject: fcoemon: Correctly handle options in the service file
+
+When runnig under systemd we can't really modify the arguments
+to provide an 'FCOEMON_OPTS' variable. Instead we should be
+modifying fcoemon --debug and --syslog to accept 'yes' or 'no'
+as parameters; that way we can use the variables directly.
+
+References: bnc#872732
+
+Signed-off-by: Hannes Reinecke <h...@suse.de>
+---
+ doc/fcoemon.txt          |  6 +++---
+ etc/systemd/fcoe.service |  4 ++--
+ fcoemon.c                | 24 +++++++++++++++---------
+ 3 files changed, 20 insertions(+), 14 deletions(-)
+
+diff --git a/doc/fcoemon.txt b/doc/fcoemon.txt
+index 7ccf892..7449601 100644
+--- a/doc/fcoemon.txt
++++ b/doc/fcoemon.txt
+@@ -53,13 +53,13 @@ OPTIONS
+ -------
+ *-f*, *--foreground*::
+ 	Run *fcoemon* in the foreground.
+-*-d*, *--debug*::
+-	Enable debugging messages.
++*-d*, *--debug=yes|no*::
++	Enable or disable debugging messages.
+ *-l*, *--legacy*::
+ 	Force fcoemon to use the legacy /sys/module/libfcoe/parameters/
+ 	interface. The default is to use the newer /sys/bus/fcoe/ interfaces
+ 	if they are available.
+-*-s*, *--syslog*::
++*-s*, *--syslog=yes|no*::
+ 	Use syslogd for logging. The default behavior is to log to stdout
+ 	and stderr.
+ *-h*, *--help*::
+diff --git a/etc/systemd/fcoe.service b/etc/systemd/fcoe.service
+index 5e5c8a2..2e10bcd 100644
+--- a/etc/systemd/fcoe.service
++++ b/etc/systemd/fcoe.service
+@@ -4,9 +4,9 @@ After=syslog.target network.target
+ 
+ [Service]
+ Type=simple
+-EnvironmentFile=/etc/sysconfig/fcoe
++EnvironmentFile=/etc/fcoe/config
+ ExecStartPre=/sbin/modprobe -qa $SUPPORTED_DRIVERS
+-ExecStart=/usr/sbin/fcoemon $FCOEMON_OPTS
++ExecStart=/usr/sbin/fcoemon --debug=$DEBUG --syslog=$SYSLOG
+ 
+ [Install]
+ WantedBy=multi-user.target
+diff --git a/fcoemon.c b/fcoemon.c
+index 5e4f8d7..23fc2f6 100644
+--- a/fcoemon.c
++++ b/fcoemon.c
+@@ -336,9 +336,9 @@ static int fcoe_vid_from_ifname(const char *ifname);
+  * Table for getopt_long(3).
+  */
+ static struct option fcm_options[] = {
+-	{"debug", 0, NULL, 'd'},
++	{"debug", 1, NULL, 'd'},
+ 	{"legacy", 0, NULL, 'l'},
+-	{"syslog", 0, NULL, 's'},
++	{"syslog", 1, NULL, 's'},
+ 	{"exec", 1, NULL, 'e'},
+ 	{"foreground", 0, NULL, 'f'},
+ 	{"version", 0, NULL, 'v'},
+@@ -3192,9 +3192,9 @@ static void fcm_usage(void)
+ {
+ 	printf("Usage: %s\n"
+ 	       "\t [-f|--foreground]\n"
+-	       "\t [-d|--debug]\n"
++	       "\t [-d|--debug=yes|no]\n"
+ 	       "\t [-l|--legacy]\n"
+-	       "\t [-s|--syslog]\n"
++	       "\t [-s|--syslog=yes|no]\n"
+ 	       "\t [-v|--version]\n"
+ 	       "\t [-h|--help]\n\n", progname);
+ 	exit(1);
+@@ -3648,22 +3648,28 @@ int main(int argc, char **argv)
+ 	sa_log_flags = 0;
+ 	openlog(sa_log_prefix, LOG_CONS, LOG_DAEMON);
+ 
+-	while ((c = getopt_long(argc, argv, "fdhlsv",
++	while ((c = getopt_long(argc, argv, "fd:hls:v",
+ 				fcm_options, NULL)) != -1) {
+ 		switch (c) {
+ 		case 'f':
+ 			fcm_fg = 1;
+ 			break;
+ 		case 'd':
+-			fcoe_config.debug = 1;
+-			enable_debug_log(1);
++			if (!strncmp(optarg, "yes", 3) ||
++			    !strncmp(optarg, "YES", 3)) {
++				fcoe_config.debug = 1;
++				enable_debug_log(1);
++			}
+ 			break;
+ 		case 'l':
+ 			force_legacy = true;
+ 			break;
+ 		case 's':
+-			fcoe_config.use_syslog = 1;
+-			enable_syslog(1);
++			if (!strncmp(optarg, "yes", 3) ||
++			    !strncmp(optarg, "YES", 3)) {
++				fcoe_config.use_syslog = 1;
++				enable_syslog(1);
++			}
+ 			break;
+ 		case 'v':
+ 			printf("%s\n", FCOE_UTILS_VERSION);
+-- 
+1.8.1.4
+
diff -rNbu a/debian/patches/0030-fcoe.service-Add-foreground-to-prevent-fcoemon-to-be.patch b/debian/patches/0030-fcoe.service-Add-foreground-to-prevent-fcoemon-to-be.patch
--- a/debian/patches/0030-fcoe.service-Add-foreground-to-prevent-fcoemon-to-be.patch	1970-01-01 01:00:00.000000000 +0100
+++ b/debian/patches/0030-fcoe.service-Add-foreground-to-prevent-fcoemon-to-be.patch	2017-01-18 13:46:06.862325394 +0100
@@ -0,0 +1,33 @@
+From 1b7dc959d70679a3536ccbeb6b3a8d0905606537 Mon Sep 17 00:00:00 2001
+From: Hannes Reinecke <h...@suse.de>
+Date: Wed, 16 Apr 2014 13:30:47 +0200
+Subject: fcoe.service: Add '--foreground' to prevent fcoemon to be killed
+
+fcoemon is running as a daemon per default, so when using
+Type=simple in the service file systemd will kill the fcoemon
+daemon immediately as it just sees the return code from the
+first fork() call.
+
+References: bnc#873269
+
+Signed-off-by: Hannes Reinecke <h...@suse.de>
+---
+ etc/systemd/fcoe.service | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/etc/systemd/fcoe.service b/etc/systemd/fcoe.service
+index 2e10bcd..b1d9567 100644
+--- a/etc/systemd/fcoe.service
++++ b/etc/systemd/fcoe.service
+@@ -6,7 +6,7 @@ After=syslog.target network.target
+ Type=simple
+ EnvironmentFile=/etc/fcoe/config
+ ExecStartPre=/sbin/modprobe -qa $SUPPORTED_DRIVERS
+-ExecStart=/usr/sbin/fcoemon --debug=$DEBUG --syslog=$SYSLOG
++ExecStart=/usr/sbin/fcoemon --foreground --debug=$DEBUG --syslog=$SYSLOG
+ 
+ [Install]
+ WantedBy=multi-user.target
+-- 
+1.7.12.4
+
diff -rNbu a/debian/patches/0032-fipvlan-Fix-crash-in-create_and_start_vlan.patch b/debian/patches/0032-fipvlan-Fix-crash-in-create_and_start_vlan.patch
--- a/debian/patches/0032-fipvlan-Fix-crash-in-create_and_start_vlan.patch	1970-01-01 01:00:00.000000000 +0100
+++ b/debian/patches/0032-fipvlan-Fix-crash-in-create_and_start_vlan.patch	2017-01-18 13:46:06.862325394 +0100
@@ -0,0 +1,58 @@
+From 0d006642c34e360fb7d3c3adbbb1295e784c03bf Mon Sep 17 00:00:00 2001
+From: Hannes Reinecke <h...@suse.de>
+Date: Mon, 12 May 2014 14:55:50 +0200
+Subject: fipvlan: Fix crash in create_and_start_vlan()
+
+create_and_start_vlan() will issue a netlink command to create
+a new VLAN device. As this device isn't present yet we need
+to exit here and retry the vlan configuration once we get the
+appropriate message from netlink.
+
+References: bnc#877275
+
+Signed-off-by: Hannes Reinecke <h...@suse.de>
+---
+ fipvlan.c | 25 +++++++++++++------------
+ 1 file changed, 13 insertions(+), 12 deletions(-)
+
+diff --git a/fipvlan.c b/fipvlan.c
+index cc71412..7202f03 100644
+--- a/fipvlan.c
++++ b/fipvlan.c
+@@ -626,20 +626,21 @@ create_and_start_vlan(struct fcf *fcf, bool vn2vn)
+ 		vlan = real_dev;
+ 	} else {
+ 		vlan = lookup_vlan(fcf->ifindex, fcf->vlan);
+-		if (vlan) {
+-			FIP_LOG_DBG("VLAN %s.%d already exists as %s\n",
+-				    real_dev->ifname, fcf->vlan, vlan->ifname);
++		if (!vlan) {
++			snprintf(vlan_name, IFNAMSIZ, "%s.%d%s",
++				 real_dev->ifname, fcf->vlan, config.suffix);
++			rc = vlan_create(fcf->ifindex, fcf->vlan, vlan_name);
++			if (rc < 0) {
++				printf("Failed to create VLAN device %s\n"
++				       "\t%s\n",
++				       vlan_name, strerror(-rc));
++				return rc;
++			}
++			printf("Created VLAN device %s\n", vlan_name);
+ 			return 0;
+ 		}
+-		snprintf(vlan_name, IFNAMSIZ, "%s.%d%s",
+-			 real_dev->ifname, fcf->vlan, config.suffix);
+-		rc = vlan_create(fcf->ifindex, fcf->vlan, vlan_name);
+-		if (rc < 0) {
+-			printf("Failed to create VLAN device %s\n\t%s\n",
+-			       vlan_name, strerror(-rc));
+-			return rc;
+-		}
+-		printf("Created VLAN device %s\n", vlan_name);
++		FIP_LOG_DBG("VLAN %s.%d already exists as %s\n",
++			    real_dev->ifname, fcf->vlan, vlan->ifname);
+ 	}
+ 	if (!config.start)
+ 		return rc;
+-- 
+1.7.12.4
+
diff -rNbu a/debian/patches/0033-fipvlan-suppress-warning-interface-already-exists.patch b/debian/patches/0033-fipvlan-suppress-warning-interface-already-exists.patch
--- a/debian/patches/0033-fipvlan-suppress-warning-interface-already-exists.patch	1970-01-01 01:00:00.000000000 +0100
+++ b/debian/patches/0033-fipvlan-suppress-warning-interface-already-exists.patch	2017-01-18 13:46:06.862325394 +0100
@@ -0,0 +1,31 @@
+From 798a5ff4a205fa26d37447ff77fc27861103440a Mon Sep 17 00:00:00 2001
+From: Hannes Reinecke <h...@suse.de>
+Date: Mon, 12 May 2014 14:59:13 +0200
+Subject: fipvlan: suppress warning 'interface already exists'
+
+When fipvlan is called for just the parent interface we should
+not select the vlan interface, too, otherwise we'll be getting
+those annoying warning messages.
+
+Signed-off-by: Hannes Reinecke <h...@suse.de>
+---
+ fipvlan.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/fipvlan.c b/fipvlan.c
+index 7202f03..163d21e 100644
+--- a/fipvlan.c
++++ b/fipvlan.c
+@@ -451,7 +451,8 @@ static void rtnl_recv_newlink(struct nlmsghdr *nh)
+ 		int i, iff_selected = 0;
+ 
+ 		for (i = 0; i < config.namec; i++) {
+-			if (!strcmp(iff->ifname, config.namev[i]))
++			if (!strncmp(iff->ifname, config.namev[i],
++				     strlen(config.namev[i])))
+ 				iff_selected = 1;
+ 		}
+ 		if (!iff_selected) {
+-- 
+1.7.12.4
+
diff -rNbu a/debian/patches/0034-fipvlan-do-not-crash-on-empty-MAC-address-in-lookup_.patch b/debian/patches/0034-fipvlan-do-not-crash-on-empty-MAC-address-in-lookup_.patch
--- a/debian/patches/0034-fipvlan-do-not-crash-on-empty-MAC-address-in-lookup_.patch	1970-01-01 01:00:00.000000000 +0100
+++ b/debian/patches/0034-fipvlan-do-not-crash-on-empty-MAC-address-in-lookup_.patch	2017-01-18 13:46:06.862325394 +0100
@@ -0,0 +1,31 @@
+From eb7451d0dcffb1c247e2b070b6101c2c878faee4 Mon Sep 17 00:00:00 2001
+From: Hannes Reinecke <h...@suse.de>
+Date: Mon, 12 May 2014 15:24:48 +0200
+Subject: fipvlan: do not crash on empty MAC address in lookup_fcf()
+
+We're calling lookup_fcf() with a NULL macaddress, so we need
+to ensure we don't crash here.
+
+References: bnc#877275
+
+Signed-off-by: Hannes Reinecke <h...@suse.de>
+---
+ fipvlan.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/fipvlan.c b/fipvlan.c
+index 163d21e..c5f3d3f 100644
+--- a/fipvlan.c
++++ b/fipvlan.c
+@@ -169,7 +169,7 @@ static struct fcf *lookup_fcf(struct fcf_list_head *head, int ifindex,
+ 
+ 	TAILQ_FOREACH(fcf, head, list_node)
+ 		if ((ifindex == fcf->ifindex) && (vlan == fcf->vlan) &&
+-		    (memcmp(mac, fcf->mac_addr, ETHER_ADDR_LEN) == 0))
++		    (!mac || memcmp(mac, fcf->mac_addr, ETHER_ADDR_LEN) == 0))
+ 			return fcf;
+ 	return NULL;
+ }
+-- 
+1.7.12.4
+
diff -rNbu a/debian/patches/0035-fipvlan-fixup-return-value-on-error.patch b/debian/patches/0035-fipvlan-fixup-return-value-on-error.patch
--- a/debian/patches/0035-fipvlan-fixup-return-value-on-error.patch	1970-01-01 01:00:00.000000000 +0100
+++ b/debian/patches/0035-fipvlan-fixup-return-value-on-error.patch	2017-01-18 13:46:06.862325394 +0100
@@ -0,0 +1,38 @@
+From 16765b7b091f8130ae001af7693895ffe0886a0e Mon Sep 17 00:00:00 2001
+From: Hannes Reinecke <h...@suse.de>
+Date: Tue, 13 May 2014 09:44:17 +0200
+Subject: fipvlan: fixup return value on error
+
+fipvlan should return 1 on error or ENODEV (=19) if no interfaces
+were found.
+
+Signed-off-by: Hannes Reinecke <h...@suse.de>
+---
+ fipvlan.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/fipvlan.c b/fipvlan.c
+index c5f3d3f..3300c68 100644
+--- a/fipvlan.c
++++ b/fipvlan.c
+@@ -982,7 +982,7 @@ int main(int argc, char **argv)
+ 
+ 	ns = rtnl_socket();
+ 	if (ns < 0) {
+-		rc = ns;
++		rc = 1;
+ 		goto ns_err;
+ 	}
+ 	pfd_add(ns);
+@@ -1002,7 +1002,7 @@ int main(int argc, char **argv)
+ 				    "no interfaces to perform discovery on");
+ 		else
+ 			FIP_LOG("no interfaces to perform discovery on");
+-		exit(1);
++		exit(ENODEV);
+ 	}
+ 
+ 	do_vlan_discovery();
+-- 
+1.7.12.4
+
diff -rNbu a/debian/patches/0036-fipvlan-clean-up-state-machine-for-pfd_add.patch b/debian/patches/0036-fipvlan-clean-up-state-machine-for-pfd_add.patch
--- a/debian/patches/0036-fipvlan-clean-up-state-machine-for-pfd_add.patch	1970-01-01 01:00:00.000000000 +0100
+++ b/debian/patches/0036-fipvlan-clean-up-state-machine-for-pfd_add.patch	2017-01-18 13:46:06.862325394 +0100
@@ -0,0 +1,67 @@
+From b19353bfa3186334611109456b232e596335c15e Mon Sep 17 00:00:00 2001
+From: Hannes Reinecke <h...@suse.de>
+Date: Wed, 14 May 2014 16:01:10 +0200
+Subject: fipvlan: clean up state machine for pfd_add
+
+pfd_add just adds the fd to the internal list without any checking.
+So use the 'fip_ready' flag to track this.
+
+Signed-off-by: Hannes Reinecke <h...@suse.de>
+---
+ fipvlan.c | 17 ++++++++++++++---
+ 1 file changed, 14 insertions(+), 3 deletions(-)
+
+diff --git a/fipvlan.c b/fipvlan.c
+index 3300c68..2211fd1 100644
+--- a/fipvlan.c
++++ b/fipvlan.c
+@@ -397,10 +397,17 @@ static void rtnl_recv_newlink(struct nlmsghdr *nh)
+ 		/* already tracking, update operstate and return */
+ 		iff->running = running;
+ 		if (!iff->running) {
+-			pfd_remove(iff->ps);
++			if (iff->fip_ready) {
++				pfd_remove(iff->ps);
++				iff->fip_ready = false;
++			}
+ 			return;
+ 		}
+-		pfd_add(iff->ps);
++		if (iff->ps >= 0 && !iff->fip_ready) {
++			pfd_add(iff->ps);
++			iff->fip_ready = true;
++		}
++
+ 		if (!config.start)
+ 			return;
+ 
+@@ -440,6 +447,7 @@ static void rtnl_recv_newlink(struct nlmsghdr *nh)
+ 	iff->ifindex = ifm->ifi_index;
+ 	iff->running = running;
+ 	iff->fip_ready = false;
++	iff->ps = -1;
+ 	if (ifla[IFLA_LINK])
+ 		iff->iflink = *(int *)RTA_DATA(ifla[IFLA_LINK]);
+ 	else
+@@ -827,7 +835,8 @@ static int probe_fip_interface(struct iff *iff)
+ 	if (iff->req_sent)
+ 		return 0;
+ 
+-	if (!iff->fip_ready) {
++	if (iff->ps < 0) {
++		iff->fip_ready = false;
+ 		iff->ps = fip_socket(iff->ifindex, FIP_NONE);
+ 		if (iff->ps < 0) {
+ 			FIP_LOG_DBG("if %d not ready\n", iff->ifindex);
+@@ -835,6 +844,8 @@ static int probe_fip_interface(struct iff *iff)
+ 		}
+ 		setsockopt(iff->ps, SOL_PACKET, PACKET_ORIGDEV,
+ 			   &origdev, sizeof(origdev));
++	}
++	if (!iff->fip_ready) {
+ 		pfd_add(iff->ps);
+ 		iff->fip_ready = true;
+ 	}
+-- 
+1.7.12.4
+
diff -rNbu a/debian/patches/0037-Use-correct-socket-for-fcoemon.socket.patch b/debian/patches/0037-Use-correct-socket-for-fcoemon.socket.patch
--- a/debian/patches/0037-Use-correct-socket-for-fcoemon.socket.patch	1970-01-01 01:00:00.000000000 +0100
+++ b/debian/patches/0037-Use-correct-socket-for-fcoemon.socket.patch	2017-01-18 13:46:06.862325394 +0100
@@ -0,0 +1,31 @@
+From 348489108793c83ec6ebbdba87888888219ca59d Mon Sep 17 00:00:00 2001
+From: Hannes Reinecke <h...@suse.de>
+Date: Mon, 28 Jul 2014 11:24:19 +0200
+Subject: Use correct socket for fcoemon.socket
+
+fcoeadm/fcoemon is using a socket 'fcm_clif', so we need to
+refer to that one in fcoemon.socket.
+
+References: bnc#881205
+
+Signed-off-by: Hannes Reinecke <h...@suse.de>
+---
+ etc/systemd/fcoemon.socket | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/etc/systemd/fcoemon.socket b/etc/systemd/fcoemon.socket
+index fdf7141..6768515 100644
+--- a/etc/systemd/fcoemon.socket
++++ b/etc/systemd/fcoemon.socket
+@@ -3,7 +3,7 @@ Description=Open-FCoE daemon control socket
+ 
+ [Socket]
+ Service=fcoe.service
+-ListenDatagram=@/com/intel/fcoemon
++ListenDatagram=@fcm_clif
+ PassCredentials=true
+ 
+ [Install]
+-- 
+1.8.4.5
+
diff -rNbu a/debian/patches/0038-Makes-fcoe.service-starting-before-network.patch b/debian/patches/0038-Makes-fcoe.service-starting-before-network.patch
--- a/debian/patches/0038-Makes-fcoe.service-starting-before-network.patch	1970-01-01 01:00:00.000000000 +0100
+++ b/debian/patches/0038-Makes-fcoe.service-starting-before-network.patch	2017-01-20 12:43:28.884038235 +0100
@@ -0,0 +1,18 @@
+--- a/etc/systemd/fcoe.service      2017-01-20 11:27:07.404752666 +0100
++++ b/etc/systemdfcoe.service      2017-01-20 11:27:54.326176592 +0100
+@@ -1,6 +1,7 @@
+ [Unit]
+ Description=Open-FCoE initiator daemon
+-After=syslog.target network.target
++After=syslog.target
++Before=network.target
+ 
+ [Service]
+ Type=simple
+@@ -10,5 +11,4 @@
+ 
+ [Install]
+ WantedBy=multi-user.target
+-Also=lldpad.socket
+ Also=fcoemon.socket
+
diff -rNbu a/debian/patches/series b/debian/patches/series
--- a/debian/patches/series	2014-11-02 20:45:13.000000000 +0100
+++ b/debian/patches/series	2017-01-20 12:45:13.411222141 +0100
@@ -1,2 +1,12 @@
 libsa-Fix-build-warning-on-sparc.patch
 dont-ship-init.patch
+0028-systemctl-cannot-start-fcoemon.socket.patch
+0029-fcoemon-Correctly-handle-options-in-the-service-file.patch
+0030-fcoe.service-Add-foreground-to-prevent-fcoemon-to-be.patch
+0032-fipvlan-Fix-crash-in-create_and_start_vlan.patch
+0033-fipvlan-suppress-warning-interface-already-exists.patch
+0034-fipvlan-do-not-crash-on-empty-MAC-address-in-lookup_.patch
+0035-fipvlan-fixup-return-value-on-error.patch
+0036-fipvlan-clean-up-state-machine-for-pfd_add.patch
+0037-Use-correct-socket-for-fcoemon.socket.patch
+0038-Makes-fcoe.service-starting-before-network.patch
diff -rNbu a/debian/rules b/debian/rules
--- a/debian/rules	2014-11-02 20:45:13.000000000 +0100
+++ b/debian/rules	2017-01-18 13:56:51.739637355 +0100
@@ -9,15 +9,22 @@
 
 
 %:
-	dh $@;
+	dh $@ --with systemd;
 
 override_dh_auto_configure:
 	./bootstrap.sh
-	./configure --prefix=/usr --sysconfdir=/etc
+	./configure --prefix=/usr --sysconfdir=/etc --with-systemdsystemunitdir=$(DESTDIR)/lib/systemd/system
 
 override_dh_installinit:
 	dh_installinit -u 'start 45 S . stop 81 0 1 6 .' --no-start
 
+override_dh_systemd_enable:
+	dh_systemd_enable etc/systemd/fcoe.service etc/systemd/fcoemon.socket
+
+override_dh_systemd_start:
+	dh_systemd_start etc/systemd/fcoe.service
+	dh_systemd_start --no-start etc/systemd/fcoemon.socket
+
 override_dh_auto_clean:
 
 	[ ! -f Makefile ] || make clean;

Attachment: smime.p7s
Description: Signature cryptographique S/MIME

Reply via email to