Your message dated Fri, 14 Feb 2014 14:22:40 +0100
with message-id <87eh35esm7....@turbotape.w.bitbit.net>
and subject line Fixed in 0.30
has caused the Debian Bug report #734312,
regarding src:cpm: cpm FTBFS on SPARC and SPARC64 do to undefined PT_SYSCALL
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)


-- 
734312: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=734312
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: src:cpm
Version: 0.28-1
Severity: serious
Tags: upstream patch
Justification: fails to build from source (but built successfully in the past)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

cpm fails to build from source [1] on SPARC and SPARC64 do to upstream commit
2ba8958a7c. As that commit was needed to build on kFreeBSD, my guess is
that a check should be implemented to see if PT_SYSCALL is defined and if
not use PTRACE_SYSCALL. Be aware, I have no idea what I am doing code-wise
here, but the package builds on SPARC (porterbox) with the attached patch
applied.

Paul

[1] 
https://buildd.debian.org/status/fetch.php?pkg=cpm&arch=sparc&ver=0.28-1&stamp=1368555383
security.c:531:26: error: 'PT_SYSCALL' undeclared (first use in this function)

- -- System Information:
Debian Release: 7.3
  APT prefers stable
  APT policy: (500, 'stable'), (99, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.2.0-4-amd64 (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iQEcBAEBCAAGBQJSycBMAAoJEJxcmesFvXUKzacH/j0edA2kNxPNI2L26MY2hhyO
AykzdWDbevtWXgt64gDLmBJ4dSYAYmwDn6xcyqkF+9OjX/KeXxiUVo6h7QulLH/1
S3ibxFsDHXZC90BuquNOQPlyCjQmqJK6/59bwTJXhlgr3stW+qP1E7KQYTba9rhA
mCgJJHCmqn4yFXKaXZ0WHrfrGwcaUCQ4ZwTaSfi52PMF4x2HXWMkdP+mBabJcYzp
pdRV/joRCfPwyhGVcdO7YnT/giRWgDEY113JxULhA8hegh/p6qLmaSToq/tGpWb6
NAdTgbuRQ/SKip46d/HVT7I3SCGVoa9bsb3lI/FLXDBCgL3pHxAtsk60g3/A54c=
=jEjt
-----END PGP SIGNATURE-----
Description: cpm fails to build on SPARC as PT_ATTACH/PT_SYSCALL is not available
 The original upstream implementation used PTRACE_ATTCACH/PTRACE_SYSCALL but
 that FTBFS on kFreeBSD. So apperently we need to check what we have
Author: Paul Gevers <elb...@debian.org>
Comment: Upstream commit is
 https://github.com/comotion/cpm/commit/2ba8958a7c935d96b4db183b70f6747ca8151b02

diff --git a/security.c b/security.c
index 4735636..7e4b6b2 100644
--- a/security.c
+++ b/security.c
@@ -521,14 +521,22 @@ int initSecurity(int* max_mem_lock, int* memory_safe, int* ptrace_safe,
            }
 #endif
 
+#if defined(PT_ATTACH)
            if (ptrace(PT_ATTACH, p0, 0, 0) != 0) {
+#else
+           if (ptrace(PTRACE_ATTACH, p0, 0, 0) != 0) {
+#endif
                // someone is already attached to us; shoot the parent in the head
                fprintf(stderr, "Can't attach to parent!\n");
                kill(p0, SIGKILL);
                _exit(1);
            }
            while (1) {
+#if defined(PT_SYSCALL)
                if(ptrace(PT_SYSCALL, p0, 0, 0) == 0)
+#else
+               if(ptrace(PTRACE_SYSCALL, p0, 0, 0) == 0)
+#endif
                    waitpid(p0, &status, 0);
                if(errno == ESRCH && kill(p0, 0) == -1)
                    exit(0); // parent is dead

--- End Message ---
--- Begin Message ---
Version: 0.30-1

Hello,

A workaround for the missing PT_SYSCALL in the sparc glibc headers has
been included.

-- 
Stig Sandbeck Mathisen <s...@debian.org>

--- End Message ---

Reply via email to