Package: wodim Version: 9:1.1.10-1 Severity: normal Tags: upstream patch patch
Hi, the current version of cdrkit (1.1.10) does not build on MacOS X systems anymore. I wrote a patch based on a patch written by Ray Kohler [1]. I tested the patch and cdrkit now builds properly both on MacOS X (10.6.3) and Debian Squeeze. However, since I'm having the same issue as reported in Debian Bug #495184 [2], I'm not absolutely sure whether the patch is correct. Please find the attached patch. Regards, Adrian [1] http://lists.alioth.debian.org/pipermail/debburn-devel/2008-October/000600.html [2] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=495184 -- System Information: Debian Release: squeeze/sid APT prefers testing APT policy: (500, 'testing') Architecture: amd64 (x86_64) Kernel: Linux 2.6.32-3-amd64 (SMP w/2 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) (ignored: LC_ALL set to en_US.UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages wodim depends on: ii libc6 2.10.2-6 Embedded GNU C Library: Shared lib ii libcap2 1:2.17-2 support for getting/setting POSIX. Versions of packages wodim recommends: ii genisoimage 9:1.1.10-1 Creates ISO-9660 CD-ROM filesystem Versions of packages wodim suggests: pn cdrkit-doc <none> (no description available) -- no debconf information
diff -ru cdrkit-1.1.10/genisoimage/sha256.c cdrkit-1.1.10-mac/genisoimage/sha256.c --- cdrkit-1.1.10/genisoimage/sha256.c 2009-10-11 20:27:59.000000000 +0200 +++ cdrkit-1.1.10-mac/genisoimage/sha256.c 2010-05-07 09:29:21.000000000 +0200 @@ -24,7 +24,11 @@ /* Written by Ulrich Drepper <drep...@redhat.com>, 2007. */ +#if defined(__APPLE__) +#include <machine/endian.h> +#else #include <endian.h> +#endif #include <stdlib.h> #include <string.h> #include <sys/types.h> diff -ru cdrkit-1.1.10/genisoimage/sha256.h cdrkit-1.1.10-mac/genisoimage/sha256.h --- cdrkit-1.1.10/genisoimage/sha256.h 2009-05-10 23:49:54.000000000 +0200 +++ cdrkit-1.1.10-mac/genisoimage/sha256.h 2010-05-07 09:31:21.000000000 +0200 @@ -28,7 +28,9 @@ #include <limits.h> #include <stdint.h> #include <stdio.h> - +#if defined(__APPLE__) +#define __THROW +#endif /* Structure to save state of computation between the single steps. */ struct sha256_ctx diff -ru cdrkit-1.1.10/genisoimage/sha512.c cdrkit-1.1.10-mac/genisoimage/sha512.c --- cdrkit-1.1.10/genisoimage/sha512.c 2009-10-11 20:27:59.000000000 +0200 +++ cdrkit-1.1.10-mac/genisoimage/sha512.c 2010-05-07 09:29:39.000000000 +0200 @@ -24,7 +24,11 @@ /* Written by Ulrich Drepper <drep...@redhat.com>, 2007. */ +#if defined(__APPLE__) +#include <machine/endian.h> +#else #include <endian.h> +#endif #include <stdlib.h> #include <string.h> #include <sys/types.h> diff -ru cdrkit-1.1.10/genisoimage/sha512.h cdrkit-1.1.10-mac/genisoimage/sha512.h --- cdrkit-1.1.10/genisoimage/sha512.h 2009-05-10 23:49:54.000000000 +0200 +++ cdrkit-1.1.10-mac/genisoimage/sha512.h 2010-05-07 09:31:41.000000000 +0200 @@ -28,7 +28,9 @@ #include <limits.h> #include <stdint.h> #include <stdio.h> - +#if defined(__APPLE__) +#define __THROW +#endif /* Structure to save state of computation between the single steps. */ struct sha512_ctx diff -ru cdrkit-1.1.10/include/AddScgBits.cmake cdrkit-1.1.10-mac/include/AddScgBits.cmake --- cdrkit-1.1.10/include/AddScgBits.cmake 2006-11-23 19:57:28.000000000 +0100 +++ cdrkit-1.1.10-mac/include/AddScgBits.cmake 2010-05-07 09:32:43.000000000 +0200 @@ -1,5 +1,5 @@ -IF(NOT GUARD_SCGCONFIG) +If(NOT GUARD_SCGCONFIG) SET(GUARD_SCGCONFIG 1) @@ -58,8 +58,18 @@ CHECK_C_SOURCE_COMPILES("${TESTSRC}" LIBC_SCHED) IF(NOT LIBC_SCHED) - LIST(APPEND EXTRA_LIBS -lrt) - #MESSAGE("Using librt for realtime functions") + SET(CMAKE_REQUIRED_LIBRARIES librt) + CHECK_C_SOURCE_COMPILES("${TESTSRC}" LIBRT_SCHED) + IF(LIBRT_SCHED) + LIST(APPEND EXTRA_LIBS -lrt) + #MESSAGE("Using librt for realtime functions") + ENDIF(LIBRT_SCHED) ENDIF(NOT LIBC_SCHED) +IF(APPLE) + FIND_LIBRARY(COREFOUNDATION CoreFoundation) + FIND_LIBRARY(IOKIT IOKit) + LIST(APPEND EXTRA_LIBS ${COREFOUNDATION} ${IOKIT}) +ENDIF(APPLE) + ENDIF(NOT GUARD_SCGCONFIG) diff -ru cdrkit-1.1.10/libusal/scsi-mac-iokit.c cdrkit-1.1.10-mac/libusal/scsi-mac-iokit.c --- cdrkit-1.1.10/libusal/scsi-mac-iokit.c 2006-12-08 14:38:43.000000000 +0100 +++ cdrkit-1.1.10-mac/libusal/scsi-mac-iokit.c 2010-05-07 09:32:43.000000000 +0200 @@ -62,7 +62,7 @@ #include <Carbon/Carbon.h> #include <IOKit/IOKitLib.h> #include <IOKit/IOCFPlugIn.h> -#include <IOKit/scsi-commands/SCSITaskLib.h> +#include <IOKit/scsi/SCSITaskLib.h> #include <mach/mach_error.h> struct usal_local {