summaryrefslogtreecommitdiff
path: root/net/DarwinStreamingServer/files/patch-Buildit
blob: 4e5960a8c1cec8c178fb56e08b28a6ec4a41194f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
--- Buildit.orig	2008-03-26 09:42:48.000000000 +0900
+++ Buildit	2008-06-01 04:24:51.000000000 +0900
@@ -9,19 +9,19 @@
 fi
 
 SHOW_HELP=0
-if [ "$1" = "-v" ] ; then
+if [ x"$1" = x"-v" ] ; then
    SHOW_HELP=1
 fi
 
-if [ "$1" = "-h" ] ; then
+if [ x"$1" = x"-h" ] ; then
    SHOW_HELP=1
 fi
 
-if [ "$1" = "?" ] ; then
+if [ x"$1" = x"?" ] ; then
    SHOW_HELP=1
 fi
 
-if [ "$1" = "help" ] ; then
+if [ x"$1" = x"help" ] ; then
    SHOW_HELP=1
 fi
 
@@ -42,7 +42,7 @@
 fi
 
 
-if [ "$1" = "install" ] ; then
+if [ x"$1" = x"install" ] ; then
     if [ $PLATFORM = dss ] ; then
       echo "OS X Darwin Streaming Server"
       ./BuildOSXInstallerPkg $2 $3
@@ -128,20 +128,20 @@
 		fi
 		;;
 
-	FreeBSD.i386)
+	FreeBSD.*)
         echo "Configuring for the "$OSNAME" "$HARDWARENAME" platform"
-		CPLUS=gcc
-		CCOMP=gcc
-		LINKER="gcc"
- 		MAKE=make
+		CPLUS=${CXX}
+		CCOMP=${CC}
+		LINKER="${CXX}"
+ 		MAKE=${MAKE}
  		
-		COMPILER_FLAGS=
-        INCLUDE_FLAG="-include"
+		COMPILER_FLAGS="${CFLAGS} ${PTHREAD_CFLAGS} -fPIC -funsigned-char"
+		INCLUDE_FLAG="-include"
 		
-		CORE_LINK_LIBS="-pthread -lm -lcrypt"
+		CORE_LINK_LIBS="${PTHREAD_LIBS} -lm -lcrypt"
 
 		SHARED=-shared
-		MODULE_LIBS="-lgcc -lstdc++"
+		MODULE_LIBS=""
 		;;
 	
 #	SunOS.sun4m | \
@@ -241,7 +241,7 @@
 		;;
 esac
 
-if [ "$*" = "install" ] ; then
+if [ x"$1" = x"install" ] ; then
 
         if [ `uname` != "SunOS" ]; then
                 USERID=`id -u`
@@ -329,7 +329,7 @@
 	echo Building QTFileLib internal for $PLAT with $CPLUS
 	cd ../QTFileLib/
 	
-	if [ "$*" = "clean" ] ; then
+	if [ x"$*" = x"clean" ] ; then
 		$MAKE -f Makefile.POSIX $*
 	else
 		$MAKE -f Makefile.POSIX all $*
@@ -421,7 +421,7 @@
 			$MAKE -f Makefile.POSIX $*
 	fi
 
-	if [ "$*" = "install" ] ; then
+	if [ x"$1" = x"install" ] ; then
 		cd ..
 		pwdi
 		echo