Make it build on DragonFly.

This commit is contained in:
hasso 2009-04-28 11:57:54 +00:00
parent bbca8569e7
commit c82ffb7e64
7 changed files with 44 additions and 26 deletions

View file

@ -1,4 +1,4 @@
$NetBSD: distinfo,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
$NetBSD: distinfo,v 1.2 2009/04/28 11:57:54 hasso Exp $
SHA1 (handbrake/HandBrake-0.9.3.tar.gz) = f52389b1226bf81ba58bca67f3a1aa468cfee624
RMD160 (handbrake/HandBrake-0.9.3.tar.gz) = 50085816875439ee82bc213252f683352bbdbbb0
@ -63,13 +63,13 @@ Size (handbrake/xvidcore-1.1.3.tar.gz) = 739835 bytes
SHA1 (handbrake/zlib-1.2.3.tar.gz) = db9f8380cd0652b5b8e75e43bcf7c4a4431df9f8
RMD160 (handbrake/zlib-1.2.3.tar.gz) = 292c1bc8d80040bf446bc6ca59341cf50d64dca2
Size (handbrake/zlib-1.2.3.tar.gz) = 502411 bytes
SHA1 (patch-aa) = 03362c540efc30c28ecb5f31f583883795b89b9e
SHA1 (patch-ab) = 9122a96f4f2aa847c7cd0f23aae3d883d00f8967
SHA1 (patch-ac) = e2d1e35ec81bfb290bcb402cd163f6bcf582c8cd
SHA1 (patch-aa) = b7c4057caf6aebca7cc47f0435e67937dd25a6f2
SHA1 (patch-ab) = 45443e0cd7fdc37420f29e526327ebd008f25e15
SHA1 (patch-ac) = a42d8ae30e4550064eeb3de8f6fcc5312a170982
SHA1 (patch-ad) = 4059de9d2242f13f9fb5f00e9bddca744796f2d1
SHA1 (patch-ae) = cace5dc913f68a6d16bcedc21f456d90cc8c3ff5
SHA1 (patch-af) = 51de27bfa474bf134f97e105ef5fb8b7c0b14862
SHA1 (patch-ag) = 5b8d90b34a2302c54354c6b9742778658c5024c8
SHA1 (patch-ae) = 136cbda7c23b5aab2c211444c07c4ec57dc5f06d
SHA1 (patch-af) = 8f0606f5a44c27e418110a47713ccad7d0b05adf
SHA1 (patch-ag) = b5a6882280b9f907334618be5ab617d5596fe360
SHA1 (patch-ah) = c6c050245b990429751c6fe243fb488028253af4
SHA1 (patch-ai) = d1a77b07ca338f522f7eaec3c2a4a71dacd61268
SHA1 (patch-aj) = 3855b048017581adac91c8a4d146d41a27840486

View file

@ -1,8 +1,8 @@
$NetBSD: patch-aa,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
$NetBSD: patch-aa,v 1.2 2009/04/28 11:57:54 hasso Exp $
--- Makefile.orig 2008-11-21 15:54:03.000000000 -0500
+++ Makefile
@@ -1,6 +1,12 @@
@@ -1,6 +1,15 @@
include Makefile.config
SYSTEM = $(shell uname -s)
@ -11,11 +11,14 @@ $NetBSD: patch-aa,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
+endif
+ifeq ($(SYSTEM),NetBSD)
+ SYSTEM = UNIX
+endif
+ifeq ($(SYSTEM),DragonFly)
+ SYSTEM = UNIX
+endif
# Special case for Mac OS X: everything is handled from the Xcode project
@@ -65,9 +71,9 @@ cli-snapshot-release:
@@ -68,9 +74,9 @@ cli-snapshot-release:
endif
#

View file

@ -1,8 +1,8 @@
$NetBSD: patch-ab,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
$NetBSD: patch-ab,v 1.2 2009/04/28 11:57:54 hasso Exp $
--- contrib/Makefile.orig 2008-06-17 18:32:05.000000000 -0400
+++ contrib/Makefile
@@ -1,6 +1,13 @@
@@ -1,6 +1,16 @@
# Contrib Makefile
SYSTEM = $(shell uname -s)
@ -12,11 +12,14 @@ $NetBSD: patch-ab,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
+ifeq ($(SYSTEM),NetBSD)
+ SYSTEM = UNIX
+endif
+ifeq ($(SYSTEM),DragonFly)
+ SYSTEM = UNIX
+endif
+
# Special case for Mac OS X: everything is handled from the Xcode project
ifeq ($(SYSTEM),Darwin)
@@ -8,7 +15,7 @@ ifeq ($(SYSTEM),Darwin)
@@ -11,7 +18,7 @@ ifeq ($(SYSTEM),Darwin)
all: .contrib
.contrib:
@ -25,7 +28,7 @@ $NetBSD: patch-ab,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
clean:
( echo "Do a make mrproper to remove the contrib libraries )
@@ -18,7 +25,7 @@ mrproper:
@@ -21,7 +28,7 @@ mrproper:
endif

View file

@ -1,7 +1,7 @@
$NetBSD: patch-ac,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
$NetBSD: patch-ac,v 1.2 2009/04/28 11:57:55 hasso Exp $
--- configure.orig 2008-09-30 15:17:10.000000000 -0400
+++ configure
--- configure.orig 2008-09-30 22:17:10 +0300
+++ configure 2009-03-22 03:12:13 +0200
@@ -5,7 +5,7 @@ CXX="g++"
CCFLAGS="$CCFLAGS -Wall -g"
OPTIM="$OPTIM -O3 -funroll-loops"
@ -11,7 +11,19 @@ $NetBSD: patch-ac,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
# System-specific flags
SYSTEM=`uname -s`
@@ -85,19 +85,6 @@ else
@@ -46,6 +46,11 @@ case $SYSTEM in
DEFINES="$DEFINES SYS_NETBSD USE_PTHREAD"
LINKLIBS="$LINKLIBS -lpthread"
;;
+
+ DragonFly)
+ DEFINES="$DEFINES SYS_DRAGONFLY USE_PTHREAD"
+ LINKLIBS="$LINKLIBS -lpthread"
+ ;;
Linux)
DEFINES="$DEFINES SYS_LINUX USE_PTHREAD _LARGEFILE_SOURCE _FILE_OFFSET_BITS=64"
@@ -85,19 +90,6 @@ else
fi
rm -f testconf.c testconf

View file

@ -1,4 +1,4 @@
$NetBSD: patch-ae,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
$NetBSD: patch-ae,v 1.2 2009/04/28 11:57:55 hasso Exp $
--- libhb/fifo.c.orig 2009-01-20 20:53:21.000000000 -0500
+++ libhb/fifo.c
@ -7,7 +7,7 @@ $NetBSD: patch-ae,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
if (size)
{
-#if defined( SYS_DARWIN ) || defined( SYS_FREEBSD )
+#if defined( SYS_DARWIN ) || defined( SYS_FREEBSD ) || defined( SYS_NETBSD )
+#if defined( SYS_DARWIN ) || defined( SYS_FREEBSD ) || defined( SYS_NETBSD ) || defined( SYS_DRAGONFLY )
b->data = malloc( b->alloc );
#elif defined( SYS_CYGWIN )
/* FIXME */

View file

@ -1,4 +1,4 @@
$NetBSD: patch-af,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
$NetBSD: patch-af,v 1.2 2009/04/28 11:57:55 hasso Exp $
--- libhb/ports.c.orig 2008-10-09 20:41:15.000000000 -0400
+++ libhb/ports.c 2009-01-21 08:57:58.000000000 -0500
@ -6,7 +6,7 @@ $NetBSD: patch-af,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
#include <sys/processor.h>
#endif
+#if defined( SYS_NETBSD )
+#if defined( SYS_NETBSD ) || defined( SYS_DRAGONFLY )
+#include <sys/param.h>
+#include <sys/sysctl.h>
+#endif
@ -19,7 +19,7 @@ $NetBSD: patch-af,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
#if defined( SYS_BEOS )
snooze( 1000 * delay );
-#elif defined( SYS_DARWIN ) || defined( SYS_LINUX ) || defined( SYS_FREEBSD) || defined( SYS_SunOS )
+#elif defined( SYS_DARWIN ) || defined( SYS_LINUX ) || defined( SYS_FREEBSD) || defined( SYS_SunOS ) || defined( SYS_NETBSD )
+#elif defined( SYS_DARWIN ) || defined( SYS_LINUX ) || defined( SYS_FREEBSD) || defined( SYS_SunOS ) || defined( SYS_NETBSD ) || defined( SYS_DRAGONFLY )
usleep( 1000 * delay );
#elif defined( SYS_CYGWIN )
Sleep( delay );
@ -27,7 +27,7 @@ $NetBSD: patch-af,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
fclose( info );
}
+#elif defined( SYS_NETBSD )
+#elif defined( SYS_NETBSD ) || defined( SYS_DRAGONFLY )
+ size_t oldlen = sizeof( cpu_count );
+
+ if ( sysctlbyname( "hw.ncpu", &cpu_count, &oldlen, NULL, 0 ) != 0 )

View file

@ -1,4 +1,4 @@
$NetBSD: patch-ag,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
$NetBSD: patch-ag,v 1.2 2009/04/28 11:57:55 hasso Exp $
--- libhb/ports.h.orig 2009-01-20 20:52:23.000000000 -0500
+++ libhb/ports.h
@ -7,7 +7,7 @@ $NetBSD: patch-ag,v 1.1.1.1 2009/01/21 14:15:15 jmcneill Exp $
# define HB_LOW_PRIORITY 0
# define HB_NORMAL_PRIORITY 31
-#elif defined( SYS_LINUX ) || defined( SYS_FREEBSD ) || defined ( SYS_SunOS )
+#elif defined( SYS_LINUX ) || defined( SYS_FREEBSD ) || defined ( SYS_SunOS ) || defined( SYS_NETBSD )
+#elif defined( SYS_LINUX ) || defined( SYS_FREEBSD ) || defined ( SYS_SunOS ) || defined( SYS_NETBSD ) || defined( SYS_DRAGONFLY )
# define HB_LOW_PRIORITY 0
# define HB_NORMAL_PRIORITY 0
#elif defined( SYS_CYGWIN )