View | Details | Raw Unified | Return to bug 148851
Collapse All | Expand All

(-)/usr/ports/www/moonshine/Makefile (-12 / +14 lines)
Lines 6-25 Link Here
6
#
6
#
7
7
8
PORTNAME=	moonshine
8
PORTNAME=	moonshine
9
PORTVERSION=	0.2
9
PORTVERSION=	0.7
10
PORTREVISION=	2
11
CATEGORIES=	www multimedia
10
CATEGORIES=	www multimedia
12
MASTER_SITES=	http://abock.org/${PORTNAME}/releases/
11
MASTER_SITES=	http://github.com/abock/moonshine/tarball/${PORTVERSION}/
12
DISTNAME=	abock-${PORTNAME}-${GITCOMMIT}
13
13
14
MAINTAINER=	mono@FreeBSD.org
14
MAINTAINER=	mono@FreeBSD.org
15
COMMENT=	Windows Media playback through Moonlight and Firefox
15
COMMENT=	Windows Media playback through Moonlight and Firefox
16
16
17
BUILD_DEPENDS=	bash:${PORTSDIR}/shells/bash
17
BUILD_DEPENDS=	bash:${PORTSDIR}/shells/bash
18
FETCH_BEFORE_ARGS=	-o ${DISTNAME}${EXTRACT_SUFX}
19
FETCH_ARGS=	-apRr
20
GITCOMMIT=	35085a4
18
21
19
USE_BZIP2=	yes
20
USE_GMAKE=	yes
22
USE_GMAKE=	yes
21
USE_GECKO=	libxul
23
USE_GECKO=	libxul
22
GNU_CONFIGURE=	yes
24
USE_AUTOTOOLS=	libtool:22 libtoolize aclocal:110 autoconf:262 autoheader:262 automake:110
25
LIBTOOLIZE_ARGS=	--force --copy --automake
26
AUTOMAKE_ARGS=	--gnu --add-missing --force --copy -Wno-portability
27
ACLOCAL_ARGS=	
23
CONFIGURE_ARGS=	--with-browser-plugin-dir=${PREFIX}/lib/browser_plugins/${PORTNAME}/
28
CONFIGURE_ARGS=	--with-browser-plugin-dir=${PREFIX}/lib/browser_plugins/${PORTNAME}/
24
29
25
USE_WEBPLUGINS=		gecko19
30
USE_WEBPLUGINS=		gecko19
Lines 32-41 Link Here
32
ONLY_FOR_ARCHS=	i386 amd64
37
ONLY_FOR_ARCHS=	i386 amd64
33
ONLY_FOR_ARCHS_REASON=	"not yet ported to anything other than i386 and amd64"
38
ONLY_FOR_ARCHS_REASON=	"not yet ported to anything other than i386 and amd64"
34
39
35
.if ${ARCH} == "amd64"
36
CONFIGURE_TARGET=	x86_64-portbld-freebsd${OSREL}
37
.endif
38
39
.if defined(WITH_XPI_PLUGIN_ONLY)
40
.if defined(WITH_XPI_PLUGIN_ONLY)
40
CONFIGURE_ARGS+=--enable-xpi-build
41
CONFIGURE_ARGS+=--enable-xpi-build
41
PLIST=		${NONEXISTENT}
42
PLIST=		${NONEXISTENT}
Lines 43-52 Link Here
43
.endif
44
.endif
44
45
45
post-patch:
46
post-patch:
46
	${REINPLACE_CMD} -e 's|^SHELL=.*|SHELL=${LOCALBASE}/bin/bash|' \
47
	${REINPLACE_CMD} -e 's|#!/bin/bash|#!${LOCALBASE}/bin/bash|' \
47
		${WRKSRC}/configure
48
		${WRKSRC}/plugin/xpi/dist-build/build-all-arch \
49
		${WRKSRC}/xulrunner/icon-theme-hicolor/icon-theme-installer
48
	${REINPLACE_CMD} -e 's|sed -r|sed -E|' \
50
	${REINPLACE_CMD} -e 's|sed -r|sed -E|' \
49
		${WRKSRC}/plugin/Makefile.in \
51
		${WRKSRC}/plugin/Makefile.am \
50
		${WRKSRC}/plugin/generate-resource
52
		${WRKSRC}/plugin/generate-resource
51
53
52
.if defined(WITH_XPI_PLUGIN_ONLY)
54
.if defined(WITH_XPI_PLUGIN_ONLY)
(-)/usr/ports/www/moonshine/distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
MD5 (moonshine-0.2.tar.bz2) = 471ddae37a45395bf996645a52911456
1
MD5 (abock-moonshine-35085a4.tar.gz) = 05f358d80f5c248b3ea721506b870048
2
SHA256 (moonshine-0.2.tar.bz2) = aac0c4f8dcd2ae26f4a597c7584ed072ca6186856f4280bc048df6dd371d6984
2
SHA256 (abock-moonshine-35085a4.tar.gz) = db99dadefb81b607d191c3c7baf01efae6baca8c80586b72fb4042fa4cd93a7a
3
SIZE (moonshine-0.2.tar.bz2) = 321716
3
SIZE (abock-moonshine-35085a4.tar.gz) = 1424041
(-)/usr/ports/www/moonshine/files/patch-autogen.sh (+38 lines)
Line 0 Link Here
1
--- autogen.sh.orig	2010-06-22 21:46:11.000000000 +0200
2
+++ autogen.sh	2010-07-01 12:58:23.000000000 +0200
3
@@ -1,11 +1,11 @@
4
-#!/bin/bash
5
+#!/bin/sh
6
 
7
-function error () {
8
+error () {
9
 	echo "Error: $1" 1>&2
10
 	exit 1
11
 }
12
 
13
-function check_autotool_version () {
14
+check_autotool_version () {
15
 	which $1 &>/dev/null || {
16
 		error "$1 is not installed, and is required to configure $PACKAGE"
17
 	}
18
@@ -20,9 +20,9 @@
19
 
20
 	if [ $major -lt $major_check ]; then
21
 		do_bail=yes
22
-	elif [[ $minor -lt $minor_check && $major = $major_check ]]; then
23
+	elif [ $minor -lt $minor_check ] && [ $major = $major_check ]; then
24
 		do_bail=yes
25
-	elif [[ $rev -lt $rev_check && $minor = $minor_check && $major = $major_check ]]; then
26
+	elif [ $rev -lt $rev_check ] && [ $minor = $minor_check ] && [ $major = $major_check ]; then
27
 		do_bail=yes
28
 	fi
29
 
30
@@ -31,7 +31,7 @@
31
 	fi
32
 }
33
 
34
-function run () {
35
+run () {
36
 	echo "$@ ..."
37
 	$@ 2>.autogen.log || {
38
 		cat .autogen.log 1>&2
(-)/usr/ports/www/moonshine/files/patch-configure (-10 lines)
Lines 1-10 Link Here
1
--- configure.orig	2009-04-15 21:26:53.000000000 +0100
2
+++ configure	2009-04-15 21:28:20.000000000 +0100
3
@@ -11543,6 +11543,7 @@
4
 
5
 case "$target_os" in
6
 	*linux*) TARGET_PLATFORM="Linux" ;;
7
+	*freebsd*) TARGET_PLATFORM="FreeBSD" ;;
8
 	*) { { $as_echo "$as_me:$LINENO: error: Target os $target_os is not supported" >&5
9
 $as_echo "$as_me: error: Target os $target_os is not supported" >&2;}
10
    { (exit 1); exit 1; }; } ;;
(-)/usr/ports/www/moonshine/files/patch-configure.ac (+30 lines)
Line 0 Link Here
1
--- configure.ac.orig	2010-06-22 21:46:11.000000000 +0200
2
+++ configure.ac	2010-07-01 13:00:22.000000000 +0200
3
@@ -18,7 +18,7 @@
4
 
5
 dnl Plugin build configuration
6
 PKG_CHECK_MODULES(MOZILLA, libxul mozilla-plugin)
7
-PKG_CHECK_MODULES(GLIB, glib-2.0 >= 2.14 gmodule-2.0 >= 2.14 uuid)
8
+PKG_CHECK_MODULES(GLIB, glib-2.0 >= 2.14 gmodule-2.0 >= 2.14)
9
 PKG_CHECK_MODULES(XULRUNNER_192, libxul >= 1.9.2,
10
 	HAVE_XULRUNNER_192=yes, HAVE_XULRUNNER_192=no)
11
 if test "$HAVE_XULRUNNER_192" = "yes"; then
12
@@ -45,6 +45,7 @@
13
 
14
 case "$target_os" in
15
 	*linux*) TARGET_PLATFORM="Linux" ;;
16
+	*freebsd*) TARGET_PLATFORM="FreeBSD" ;;
17
 	*) AC_MSG_ERROR([Target os $target_os is not supported]) ;;
18
 esac
19
 
20
@@ -57,6 +58,10 @@
21
 		TARGET_PLATFORM="$TARGET_PLATFORM"_x86_64-gcc3
22
 		INSTALL_ARCH=x86_64
23
 		;;
24
+	amd64)
25
+		TARGET_PLATFORM="$TARGET_PLATFORM"_amd64
26
+		INSTALL_ARCH=x86_64
27
+		;;
28
 	*) AC_MSG_ERROR([Target cpu $target_cpu is unsupported or unknown]) ;;
29
 esac
30
 AC_SUBST([TARGET_PLATFORM])
(-)/usr/ports/www/moonshine/files/patch-plugin-generate-resource (+76 lines)
Line 0 Link Here
1
--- plugin/generate-resource.orig	2010-06-22 21:46:11.000000000 +0200
2
+++ plugin/generate-resource	2010-07-01 12:39:33.000000000 +0200
3
@@ -1,4 +1,4 @@
4
-#!/bin/bash
5
+#!/bin/sh
6
 
7
 # generate-resource by Aaron Bockover
8
 # Copyright (C) 2008 Novell
9
@@ -6,7 +6,7 @@
10
 # 
11
 # Turns a set of files into a C header file
12
 
13
-function bail () {
14
+bail () {
15
 	echo "ERROR: $1" 1>&2
16
 	exit 1
17
 }
18
@@ -23,17 +23,19 @@
19
 all_name=$1; shift
20
 all_array=""
21
 
22
-[[ -z $out ]] && 
23
+if [ -z "$out" ]; then
24
 	bail "You must specify an output file first"
25
+fi
26
 
27
-while (($# > 0)); do
28
+while [ $# -gt 0 ]; do
29
 	var=$1
30
 	input=$2
31
 	
32
-	[[ -z $var || ! -f $input ]] && 
33
+	if [ -z $var ] || [ ! -f $input ]; then
34
 		bail "Invalid variable/input file argument pair ($var, $input)"
35
+	fi
36
 
37
-	[[ $inputs -eq 0 ]] && {
38
+	if [ $inputs -eq 0 ]; then
39
 		(echo "/* "
40
 			echo " * $out: auto-generated embedded resources "
41
 			echo " */ "
42
@@ -41,24 +43,29 @@
43
 			echo "#ifndef $out_define"
44
 			echo "#define $out_define"
45
 			echo) > $out
46
-	}
47
+	fi
48
 
49
-	((inputs++))
50
+	inputs=$((inputs+1))
51
 	all_array="$all_array $var"
52
 
53
 	(echo "/* Embedded Resource $inputs ($input) */"
54
-		table=$(hexdump -e '"    " 16/1 "0x%02x, " "\n"' $input | sed -r 's/, 0x[ ,]+.*/, 0x00/')
55
+		table=$(hexdump -e '"    " 16/1 "0x%02x, " "\n"' $input | sed -E 's/, 0x[ ,]+.*/, 0x00/')
56
 		echo "static const char $var [] = {"
57
         echo "$table"
58
-        [[ ${table:$((${#table}-1))} = "," ]] && echo "    0x00"
59
+	tablelen=${#table}
60
+	tablestr=$(echo $table | awk -v var=$tablelen '{ string=substr($1, 0, var); print string; }' )
61
+	if [ $tablestr = "," ]; then
62
+		echo "    0x00"
63
+	fi
64
 		echo "};"
65
 		echo) >> $out
66
 		
67
 	shift; shift
68
 done
69
 
70
-[[ $inputs -eq 0 ]] && 
71
+if [ $inputs -eq 0 ]; then
72
 	bail "You must specify at least one variable/input file pair"
73
+fi
74
 
75
 echo "static const char const * $all_name [] = {" >> $out
76
 for var in $all_array; do
(-)/usr/ports/www/moonshine/files/patch-plugin-xpi-Makefile.am (+15 lines)
Line 0 Link Here
1
--- plugin/xpi/Makefile.am.orig	2010-06-22 21:46:11.000000000 +0200
2
+++ plugin/xpi/Makefile.am	2010-07-19 10:14:26.000000000 +0200
3
@@ -11,9 +11,9 @@
4
 	-rm -rf $(XPI_BUILD_ROOT)
5
 	mkdir -p $(XPI_BUILD_ROOT)/plugins
6
 	mkdir -p $(XPI_BUILD_ROOT)/skin
7
-	cp -aL $(srcdir)/install.rdf $(XPI_BUILD_ROOT)
8
-	cp -aL $(top_srcdir)/xulrunner/icon-theme-hicolor/moonshine-32.png $(XPI_BUILD_ROOT)/skin/icon.png
9
-	cp -aL $(PLUGIN_FILE) $(XPI_BUILD_ROOT)/plugins
10
+	cp -RpPL $(srcdir)/install.rdf $(XPI_BUILD_ROOT)
11
+	cp -RpPL $(top_srcdir)/xulrunner/icon-theme-hicolor/moonshine-32.png $(XPI_BUILD_ROOT)/skin/icon.png
12
+	cp -RpPL $(PLUGIN_FILE) $(XPI_BUILD_ROOT)/plugins
13
 	echo "$(CHROME_MANIFEST)" > $(XPI_BUILD_ROOT)/chrome.manifest
14
 	find $(XPI_BUILD_ROOT) -name \*.so -exec strip '{}' ';'
15
 	cd $(XPI_BUILD_ROOT) && zip -r9 ../$@ *
(-)/usr/ports/www/moonshine/files/patch-xulrunner-Makefile.am (+11 lines)
Line 0 Link Here
1
--- xulrunner/Makefile.am.orig	2010-06-22 21:46:11.000000000 +0200
2
+++ xulrunner/Makefile.am	2010-07-19 10:25:41.000000000 +0200
3
@@ -55,7 +55,7 @@
4
 
5
 chrome/content/player/%: $(top_srcdir)/player/%
6
 	mkdir -p $(dir $@)
7
-	cp -a $< $@
8
+	cp -RpP $< $@
9
 
10
 XULAPP_FILES = `find $(srcdir)/chrome $(srcdir)/defaults application.ini -type f | grep -v debug.js`
11
 
(-)/usr/ports/www/moonshine/files/patch-xulrunner-moonshine.in (+14 lines)
Line 0 Link Here
1
--- xulrunner/moonshine.in.orig	2010-06-22 21:46:11.000000000 +0200
2
+++ xulrunner/moonshine.in	2010-07-22 21:49:39.000000000 +0200
3
@@ -1,7 +1,8 @@
4
-#!/bin/bash
5
+#!/bin/sh
6
 
7
-XULRUNNER=$(readlink -e $(which xulrunner))
8
-BROWSER_PLUGIN_DIR=@BROWSER_PLUGIN_DIR@
9
+XULRUNNERBINARY=$(which xulrunner)
10
+XULRUNNER=$(echo $(cd $(dirname $XULRUNNERBINARY); pwd -P)/$(basename $XULRUNNERBINARY))
11
+BROWSER_PLUGIN_DIR=@BROWSER_PLUGIN_DIR@../symlinks/gecko19
12
 LIBDIR=${XULRUNNER%%/xulrunner*}
13
 
14
 FF_PROFILES_PATH="$HOME/.mozilla/firefox"
(-)/usr/ports/www/moonshine/pkg-plist (-2 / +4 lines)
Lines 1-4 Link Here
1
bin/moonshine
1
bin/moonshine
2
lib/browser_plugins/moonshine/libmoonshine-plugin.a
2
lib/browser_plugins/moonshine/libmoonshine-plugin.la
3
lib/browser_plugins/moonshine/libmoonshine-plugin.la
3
lib/browser_plugins/moonshine/libmoonshine-plugin.so
4
lib/browser_plugins/moonshine/libmoonshine-plugin.so
4
share/applications/moonshine.desktop
5
share/applications/moonshine.desktop
Lines 36-41 Link Here
36
%%DATADIR%%/chrome/skin/dialog-error.png
37
%%DATADIR%%/chrome/skin/dialog-error.png
37
%%DATADIR%%/chrome/skin/player-shell.css
38
%%DATADIR%%/chrome/skin/player-shell.css
38
%%DATADIR%%/defaults/preferences/prefs.js
39
%%DATADIR%%/defaults/preferences/prefs.js
40
@dirrmtry %%DATADIR%%/extensions
39
@dirrm %%DATADIR%%/defaults/preferences
41
@dirrm %%DATADIR%%/defaults/preferences
40
@dirrm %%DATADIR%%/defaults
42
@dirrm %%DATADIR%%/defaults
41
@dirrm %%DATADIR%%/chrome/skin
43
@dirrm %%DATADIR%%/chrome/skin
Lines 47-52 Link Here
47
@dirrm %%DATADIR%%/chrome/content/player
49
@dirrm %%DATADIR%%/chrome/content/player
48
@dirrm %%DATADIR%%/chrome/content
50
@dirrm %%DATADIR%%/chrome/content
49
@dirrm %%DATADIR%%/chrome
51
@dirrm %%DATADIR%%/chrome
50
@dirrm %%DATADIR%%
52
@dirrmtry %%DATADIR%%
51
@dirrm lib/browser_plugins/moonshine
53
@dirrm lib/browser_plugins/moonshine
52
@dirrm lib/browser_plugins
54
@dirrmtry lib/browser_plugins

Return to bug 148851