pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
pkg/45280: sudo 1.7.7 alias.c should have errno.h before sudo.h for errno definition
>Number: 45280
>Category: pkg
>Synopsis: sudo 1.7.7 alias.c should have errno.h before sudo.h for errno
>definition
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: pkg-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sun Aug 21 15:35:00 +0000 2011
>Originator: David Shao
>Release: DragonFly BSD 2.11-DEVELOPMENT
>Organization:
>Environment:
DragonFly 2.11-DEVELOPMENT
>Description:
sudo 1.7.7 file alias.c should have errno.h included before sudo.h and not
after because errno's definition needs to be available to sudo.h before sudo.h
tries to define errno as extern int errno on systems where errno is NOT extern
int errno.
A patch is included in the fix to the problem below.
>How-To-Repeat:
In the latest pkgsrc, at least the one translated to git branch master for
DragonFly BSD 2.11-DEVELOPMENT latest commit commit
369ad7806bd3ce6f692fde2c66042bf95a743a4b Sat Aug 20 19:01:31 2011 -0700,
try to
bmake install
for security/sudo, sudo version 1.7.7
Compilation will fail with a message such as
In file included from ./alias.c:47:
/usr/include/errno.h:43: error: thread-local declaration of 'errno' follows
non-thread-local declaration
./sudo.h:369: note: previous declaration of 'errno' was here
>Fix:
diff --git a/security/sudo/distinfo b/security/sudo/distinfo
index ac646eb..a26479e 100644
--- a/security/sudo/distinfo
+++ b/security/sudo/distinfo
@@ -6,4 +6,5 @@ Size (sudo-1.7.7.tar.gz) = 1152132 bytes
SHA1 (patch-aa) = df93a99bdcecdcee7f836d1123bcf740b054ed4e
SHA1 (patch-af) = c9e09c77f520874ea165750380c3b985b31f559c
SHA1 (patch-ag) = 4c4771911b93c8760c3a8195311cf2b3456aeafd
+SHA1 (patch-alias.c) = 6dca81de404865194fb1f3675ec6517070d5929a
SHA1 (patch-logging.c) = b4f10e64564e0cece07d4211d3a3ae6723057393
diff --git a/security/sudo/patches/patch-alias.c
b/security/sudo/patches/patch-alias.c
new file mode 100644
index 0000000..3adbcaf
--- /dev/null
+++ b/security/sudo/patches/patch-alias.c
@@ -0,0 +1,17 @@
+$NetBSD$
+
+--- alias.c.orig 2011-08-21 15:00:16.032418000 +0000
++++ alias.c
+@@ -40,11 +40,11 @@
+ # include <unistd.h>
+ #endif /* HAVE_UNISTD_H */
+
++#include <errno.h>
+ #include "sudo.h"
+ #include "parse.h"
+ #include "redblack.h"
+ #include <gram.h>
+-#include <errno.h>
+
+ /*
+ * Globals
Home |
Main Index |
Thread Index |
Old Index