Lines 2-99
Link Here
|
2 |
# $FreeBSD: head/multimedia/gtk-youtube-viewer/Makefile 352557 2014-04-28 21:31:31Z nemysis $ |
2 |
# $FreeBSD: head/multimedia/gtk-youtube-viewer/Makefile 352557 2014-04-28 21:31:31Z nemysis $ |
3 |
|
3 |
|
4 |
PORTNAME= gtk-youtube-viewer |
4 |
PORTNAME= gtk-youtube-viewer |
5 |
PORTVERSION= 3.0.9 |
5 |
PORTVERSION= 3.1.1 |
6 |
PORTREVISION= 1 |
|
|
7 |
CATEGORIES= multimedia perl5 |
6 |
CATEGORIES= multimedia perl5 |
8 |
|
7 |
|
9 |
MAINTAINER= ports@FreeBSD.org |
8 |
MAINTAINER= ports@FreeBSD.org |
10 |
COMMENT= GTK Search and play YouTube videos streaming in MPlayer |
9 |
COMMENT= GTK Search and play YouTube videos streaming in MPlayer |
11 |
|
10 |
|
12 |
LICENSE= ART20 GPLv3 |
11 |
LICENSE= ART10 GPLv1 |
13 |
LICENSE_COMB= dual |
12 |
LICENSE_COMB= dual |
14 |
|
13 |
|
15 |
# According to Build.PL |
14 |
# According to Build.PL |
16 |
BUILD_DEPENDS= p5-Test-More-UTF8>=0:${PORTSDIR}/devel/p5-Test-More-UTF8 \ |
15 |
BUILD_DEPENDS= p5-MIME-Base64>0:${PORTSDIR}/converters/p5-MIME-Base64 \ |
17 |
p5-Scalar-List-Utils>=0:${PORTSDIR}/lang/p5-Scalar-List-Utils \ |
16 |
p5-Data-Dump>0:${PORTSDIR}/devel/p5-Data-Dump \ |
18 |
p5-MIME-Base64>=0:${PORTSDIR}/converters/p5-MIME-Base64 \ |
17 |
p5-File-Path>0:${PORTSDIR}/devel/p5-File-Path \ |
19 |
p5-LWP-Protocol-https>=0:${PORTSDIR}/www/p5-LWP-Protocol-https \ |
18 |
p5-File-Temp>0:${PORTSDIR}/devel/p5-File-Temp \ |
20 |
p5-File-Temp>=0:${PORTSDIR}/devel/p5-File-Temp \ |
19 |
p5-Getopt-Long>0:${PORTSDIR}/devel/p5-Getopt-Long \ |
21 |
p5-Text-CharWidth>=0:${PORTSDIR}/textproc/p5-Text-CharWidth \ |
20 |
p5-PathTools>0:${PORTSDIR}/devel/p5-PathTools \ |
22 |
p5-threads>=0:${PORTSDIR}/devel/p5-threads \ |
21 |
p5-ReadLine-Gnu>0:${PORTSDIR}/devel/p5-ReadLine-Gnu \ |
23 |
p5-Thread-Queue>=0:${PORTSDIR}/devel/p5-Thread-Queue \ |
22 |
p5-Term-ANSIColor>0:${PORTSDIR}/devel/p5-Term-ANSIColor \ |
24 |
p5-ReadLine-Gnu>=0:${PORTSDIR}/devel/p5-ReadLine-Gnu \ |
23 |
p5-Test-More-UTF8>0:${PORTSDIR}/devel/p5-Test-More-UTF8 \ |
25 |
p5-XML-Fast>=0:${PORTSDIR}/net/p5-XML-Fast \ |
24 |
p5-Thread-Queue>0:${PORTSDIR}/devel/p5-Thread-Queue \ |
26 |
p5-Data-Dump>=0:${PORTSDIR}/devel/p5-Data-Dump \ |
25 |
p5-threads>0:${PORTSDIR}/devel/p5-threads \ |
27 |
p5-PathTools>=0:${PORTSDIR}/devel/p5-PathTools \ |
26 |
p5-Scalar-List-Utils>0:${PORTSDIR}/lang/p5-Scalar-List-Utils \ |
28 |
p5-File-Path>=0:${PORTSDIR}/devel/p5-File-Path \ |
27 |
p5-Socket>0:${PORTSDIR}/net/p5-Socket \ |
29 |
p5-Getopt-Long>=0:${PORTSDIR}/devel/p5-Getopt-Long \ |
28 |
p5-XML-Fast>0:${PORTSDIR}/net/p5-XML-Fast \ |
30 |
p5-libwww>=0:${PORTSDIR}/www/p5-libwww \ |
29 |
p5-Text-CharWidth>0:${PORTSDIR}/textproc/p5-Text-CharWidth \ |
31 |
p5-Term-ANSIColor>=0:${PORTSDIR}/devel/p5-Term-ANSIColor \ |
30 |
p5-Text-ParseWords>0:${PORTSDIR}/textproc/p5-Text-ParseWords \ |
32 |
p5-Term-UI>=0:${PORTSDIR}/devel/p5-Term-UI \ |
31 |
p5-Text-Tabs+Wrap>0:${PORTSDIR}/textproc/p5-Text-Tabs+Wrap \ |
33 |
p5-Text-ParseWords>=0:${PORTSDIR}/textproc/p5-Text-ParseWords \ |
32 |
p5-LWP-Protocol-https>0:${PORTSDIR}/www/p5-LWP-Protocol-https \ |
34 |
p5-Text-Tabs+Wrap>=0:${PORTSDIR}/textproc/p5-Text-Tabs+Wrap \ |
33 |
p5-libwww>0:${PORTSDIR}/www/p5-libwww |
35 |
p5-Socket>=0:${PORTSDIR}/net/p5-Socket |
|
|
36 |
RUN_DEPENDS:= ${BUILD_DEPENDS} \ |
34 |
RUN_DEPENDS:= ${BUILD_DEPENDS} \ |
37 |
mplayer:${PORTSDIR}/multimedia/mplayer |
35 |
mplayer:${PORTSDIR}/multimedia/mplayer |
38 |
|
36 |
|
39 |
USE_GITHUB= yes |
37 |
USE_GITHUB= yes |
40 |
GH_ACCOUNT= trizen |
38 |
GH_ACCOUNT= trizen |
41 |
GH_PROJECT= youtube-viewer |
39 |
GH_PROJECT= youtube-viewer |
42 |
GH_COMMIT= 116eb3f |
40 |
GH_COMMIT= e3d45f7 |
43 |
|
41 |
|
44 |
WRKSRC= ${WRKDIR}/${GH_ACCOUNT}-${GH_PROJECT}-${GH_COMMIT}/WWW-YoutubeViewer |
42 |
WRKSRC_SUBDIR= WWW-YoutubeViewer |
45 |
|
43 |
|
46 |
CONFIGURE_ARGS+=${DATADIR} |
44 |
USES= perl5 shebangfix |
47 |
USES= perl5 |
45 |
SHEBANG_FILES= bin/gtk-youtube-viewer bin/youtube-viewer |
48 |
USE_PERL5= 5.16+ patch modbuild |
46 |
USE_PERL5= 5.16+ patch modbuild |
|
|
47 |
CONFIGURE_ARGS+=${DATADIR} |
49 |
|
48 |
|
50 |
PORTDOCS= Changes README |
49 |
OPTIONS_DEFINE= GCAP GTK2 |
51 |
|
50 |
OPTIONS_DEFAULT= GCAP GTK2 |
52 |
OPTIONS_DEFINE= DOCS GCAP |
51 |
OPTIONS_SUB= yes |
53 |
|
|
|
54 |
OPTIONS_MULTI= USER_INTERFACE |
55 |
OPTIONS_MULTI_USER_INTERFACE= CLI GTK2 |
56 |
|
57 |
OPTIONS_DEFAULT= CLI GCAP GTK2 |
58 |
|
59 |
CLI_DESC= Enable CLI version |
60 |
GCAP_DESC= Enable YouTube captions support |
61 |
|
62 |
OPTIONS_SUB= yes |
63 |
|
52 |
|
|
|
53 |
GCAP_DESC= YouTube closed captions support |
64 |
GCAP_RUN_DEPENDS= ${LOCALBASE}/bin/gcap:${PORTSDIR}/multimedia/gcap |
54 |
GCAP_RUN_DEPENDS= ${LOCALBASE}/bin/gcap:${PORTSDIR}/multimedia/gcap |
65 |
GTK2_BUILD_DEPENDS= p5-Gtk2>=0:${PORTSDIR}/x11-toolkits/p5-Gtk2 \ |
55 |
GTK2_BUILD_DEPENDS= p5-File-ShareDir>0:${PORTSDIR}/devel/p5-File-ShareDir \ |
66 |
p5-File-ShareDir>=0:${PORTSDIR}/devel/p5-File-ShareDir |
56 |
p5-Gtk2>0:${PORTSDIR}/x11-toolkits/p5-Gtk2 |
67 |
GTK2_RUN_DEPENDS= p5-Gtk2>=0:${PORTSDIR}/x11-toolkits/p5-Gtk2 \ |
57 |
GTK2_RUN_DEPENDS= p5-File-ShareDir>0:${PORTSDIR}/devel/p5-File-ShareDir \ |
68 |
p5-File-ShareDir>=0:${PORTSDIR}/devel/p5-File-ShareDir |
58 |
p5-Gtk2>0:${PORTSDIR}/x11-toolkits/p5-Gtk2 |
|
|
59 |
GTK2_CONFIGURE_ON= --gtk-youtube-viewer |
69 |
|
60 |
|
70 |
.include <bsd.port.options.mk> |
61 |
.include <bsd.port.options.mk> |
71 |
.include <bsd.port.pre.mk> |
|
|
72 |
|
73 |
.if ${PORT_OPTIONS:MGTK2} |
74 |
CONFIGURE_ARGS+=-gtk-youtube-viewer |
75 |
.endif |
76 |
|
77 |
post-patch: |
78 |
@${REINPLACE_CMD} -e 's|5.016|0|' ${WRKSRC}/Build.PL |
79 |
@cd ${WRKSRC}/bin && ${REINPLACE_CMD} -e 's|/usr|${PREFIX}|g' \ |
80 |
gtk-youtube-viewer youtube-viewer |
81 |
.if ${PERL_LEVEL} <= 501600 |
82 |
@${CP} ${FILESDIR}/yv_5.16_to_5.10.pl ${WRKSRC} |
83 |
@${CP} ${WRKSRC}/bin/youtube-viewer ${WRKSRC}/bin/youtube-viewer-2patch |
84 |
@${PERL} \ |
85 |
${WRKSRC}/yv_5.16_to_5.10.pl ${WRKSRC}/bin/youtube-viewer-2patch > \ |
86 |
${WRKSRC}/bin/youtube-viewer |
87 |
@${RM} ${WRKSRC}/bin/youtube-viewer-2patch |
88 |
.endif |
89 |
|
90 |
.if ! ${PORT_OPTIONS:MCLI} |
91 |
@${REINPLACE_CMD} -e "s|'bin/youtube-viewer',||" \ |
92 |
${WRKSRC}/Build.PL |
93 |
@${REINPLACE_CMD} -i '' -e \ |
94 |
'/copy(catfile($$main_dir, qw(bin youtube-viewer))/,+1d' \ |
95 |
${WRKSRC}/Build.PL |
96 |
.endif |
97 |
|
62 |
|
98 |
post-install: |
63 |
post-install: |
99 |
.if ${PORT_OPTIONS:MGTK2} |
64 |
.if ${PORT_OPTIONS:MGTK2} |
Lines 101-114
Link Here
|
101 |
${SITE_PERL}/auto/share/dist/WWW-YoutubeViewer/gtk-youtube-viewer.desktop \ |
66 |
${SITE_PERL}/auto/share/dist/WWW-YoutubeViewer/gtk-youtube-viewer.desktop \ |
102 |
${STAGEDIR}${DESKTOPDIR} |
67 |
${STAGEDIR}${DESKTOPDIR} |
103 |
${LN} -sf \ |
68 |
${LN} -sf \ |
104 |
${SITE_PERL}/auto/share/dist/WWW-YoutubeViewer/gtk-youtube-viewer.png \ |
69 |
${SITE_PERL}/auto/share/dist/WWW-YoutubeViewer/icons/gtk-youtube-viewer.png \ |
105 |
${STAGEDIR}${PREFIX}/share/pixmaps/ |
70 |
${STAGEDIR}${PREFIX}/share/pixmaps |
106 |
.endif |
71 |
.endif |
107 |
|
72 |
|
108 |
@${MKDIR} ${STAGEDIR}${DOCSDIR} |
|
|
109 |
${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|} ${STAGEDIR}${DOCSDIR} |
110 |
|
111 |
regression-test: build |
73 |
regression-test: build |
112 |
cd ${WRKSRC} && ${PERL} ./Build test |
74 |
cd ${WRKSRC} && ${PERL} ./Build test |
113 |
|
75 |
|
114 |
.include <bsd.port.post.mk> |
76 |
.include <bsd.port.mk> |