[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

procps: FTBFS on hurd-i386



Source: procps
Version: 3.3.11
Severity: important
Tags: patch
User: debian-hurd@lists.debian.org
Usertags: hurd
X-DebBugs-CC: debian-hurd@lists.debian.org

Hi,

This patch solves the build problems for GNU/Hurd due to missing
sys/prctl.h. And then macro PR_SET_NAME is used conditionally.
There are also problem with installation paths. Namely tmp/bin/
is renamed to tmp/bbin/.

(Not submitted yet, comments are welcome.)

-Aapo Rantalainen
diff -Naur old/procps-3.3.11/debian/patches/hurd_test_process procps-3.3.11/debian/patches/hurd_test_process
--- old/procps-3.3.11/debian/patches/hurd_test_process	1969-12-31 19:00:00.000000000 -0500
+++ procps-3.3.11/debian/patches/hurd_test_process	2016-05-24 12:52:46.000000000 -0400
@@ -0,0 +1,24 @@
+Description: No PR_SET_NAME for Hurd in test_process.c
+
+--- procps-3.3.11.orig/lib/test_process.c
++++ procps-3.3.11/lib/test_process.c
+@@ -21,7 +21,9 @@
+ #include <stdlib.h>
+ #include <unistd.h>
+ #include <signal.h>
++#ifndef __GNU__
+ #include <sys/prctl.h>
++#endif
+ #include "c.h"
+ 
+ #define DEFAULT_SLEEPTIME 300
+@@ -79,7 +81,9 @@
+     sigaction(SIGUSR2, &signal_action, NULL);
+ 
+     /* set process name */
++#ifdef PR_SET_NAME
+     prctl(PR_SET_NAME, MY_NAME, NULL, NULL, NULL);
++#endif
+ 
+     while (sleep_time > 0) {
+ 	sleep_time = sleep(sleep_time);
diff -Naur old/procps-3.3.11/debian/patches/series procps-3.3.11/debian/patches/series
--- old/procps-3.3.11/debian/patches/series	2016-05-24 12:32:45.000000000 -0400
+++ procps-3.3.11/debian/patches/series	2016-05-24 12:52:44.000000000 -0400
@@ -1,3 +1,4 @@
 disable_sched_test
 uptime_test
 main_cached
+hurd_test_process
diff -Naur old/procps-3.3.11/debian/procps.install.hurd procps-3.3.11/debian/procps.install.hurd
--- old/procps-3.3.11/debian/procps.install.hurd	2016-05-24 12:32:45.000000000 -0400
+++ procps-3.3.11/debian/procps.install.hurd	2016-05-24 12:34:15.000000000 -0400
@@ -1,4 +1,3 @@
 # Files to install for hurd systems
-bin/kill bin
-bin/ps bin
-bin/* /usr/bin
+bbin/* bin
+bin/* usr/bin
diff -Naur old/procps-3.3.11/debian/rules procps-3.3.11/debian/rules
--- old/procps-3.3.11/debian/rules	2016-05-24 12:32:45.000000000 -0400
+++ procps-3.3.11/debian/rules	2016-05-24 12:34:15.000000000 -0400
@@ -72,7 +72,7 @@
 		$(DEBROOT)/usr/share/man/man1/pmap.1 \
 		$(NULL)
     # Rename kill as there are two of them
-	(cd $(DEBROOT)/bin && mv kill kill.procps )
+	(cd $(DEBROOT)/bbin && mv kill kill.procps )
 	(cd $(DEBROOT)/usr/share/man/man1 && mv kill.1 kill.procps.1 )
 
 	# Rename vmstat as there are two of them
@@ -84,7 +84,7 @@
 	(cd $(DEBROOT)/usr/share/man/man1 && mv uptime.1 uptime.procps.1 )
 
 	# Rename ps as there are two of them
-	(cd $(DEBROOT)/bin && mv ps ps.procps )
+	(cd $(DEBROOT)/bbin && mv ps ps.procps )
 	(cd $(DEBROOT)/usr/share/man/man1 && mv ps.1 ps.procps.1 )
 endif
 

Reply to: