Bug 174185 - audio/autozen: Update MASTER_SITES
Summary: audio/autozen: Update MASTER_SITES
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Marcelo Araujo
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-12-05 18:10 UTC by tkato432
Modified: 2013-05-27 10:10 UTC (History)
0 users

See Also:


Attachments
file.diff (6.31 KB, patch)
2012-12-05 18:10 UTC, tkato432
no flags Details | Diff
audio_autozen.diff (6.09 KB, patch)
2013-01-18 17:55 UTC, tkato432
no flags Details | Diff
audio_autozen.diff (6.09 KB, patch)
2013-01-27 17:55 UTC, tkato432
no flags Details | Diff
audio_autozen.diff (6.47 KB, patch)
2013-04-24 18:54 UTC, tkato432
no flags Details | Diff
audio_autozen.diff (6.52 KB, patch)
2013-05-07 18:58 UTC, tkato432
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description tkato432 2012-12-05 18:10:08 UTC
- Update MASTER_SITES
- Add option for GTK2 support

Remove file:
files/patch-Makefile
Comment 1 Marcelo Araujo freebsd_committer 2012-12-11 11:17:17 UTC
Responsible Changed
From-To: freebsd-ports-bugs->araujo

I'll take it.
Comment 2 Marcelo Araujo freebsd_committer 2013-01-18 07:34:12 UTC
State Changed
From-To: open->feedback

The patch does not apply clean. Also add DOCS in OPTIONS_DEFINE.
Comment 3 tkato432 2013-01-18 17:55:51 UTC
Remake of the patch against current tree.
Comment 4 tkato432 2013-01-27 17:55:43 UTC
Remake of the patch against current tree.
Comment 5 Marcelo Araujo freebsd_committer 2013-02-27 07:22:44 UTC
State Changed
From-To: feedback->open

Feedback received.
Comment 6 tkato432 2013-04-24 18:54:09 UTC
Remake of the patch against current tree.
Comment 7 tkato432 2013-05-07 18:58:11 UTC
Remake of the patch against current tree.
Comment 8 dfilter service freebsd_committer 2013-05-27 10:03:16 UTC
Author: araujo
Date: Mon May 27 09:03:02 2013
New Revision: 319180
URL: http://svnweb.freebsd.org/changeset/ports/319180

Log:
  - Update MASTER_SITES.
  - Add option for GTK2 support.
  - Add LICENSE.
  
  PR:		ports/174185
  Submitted by:	KATO Tsuguru <tkato432@yahoo.com>

Deleted:
  head/audio/autozen/files/patch-Makefile
Modified:
  head/audio/autozen/Makefile
  head/audio/autozen/files/patch-autozen.c   (contents, props changed)
  head/audio/autozen/pkg-descr   (contents, props changed)

Modified: head/audio/autozen/Makefile
==============================================================================
--- head/audio/autozen/Makefile	Mon May 27 08:57:05 2013	(r319179)
+++ head/audio/autozen/Makefile	Mon May 27 09:03:02 2013	(r319180)
@@ -3,33 +3,65 @@
 
 PORTNAME=	autozen
 PORTVERSION=	2.1
-PORTREVISION=	3
+PORTREVISION=	4
 CATEGORIES=	audio
-MASTER_SITES=	ftp://ftp.springdaemons.com/soft/
+MASTER_SITES=	ftp://ftp.springdaemons.com/soft/ \
+		http://www.sourcefiles.org/Miscellaneous/
 
 MAINTAINER=	ports@FreeBSD.org
 COMMENT=	Adjust brain waves with sound
 
-MAKE_ENV+=	PTHREAD_FLAGS="${PTHREAD_CFLAGS} ${PTHREAD_LIBS}" \
-		DATADIR="${DATADIR}" DOCSDIR="${DOCSDIR}" MKDIR="${MKDIR}"
+LICENSE=	GPLv2
+
+OPTIONS_DEFINE=	GTK2 DOCS
 
 USES=		shebangfix
-USE_GNOME=	gtk12
-USE_PERL5_RUN=	yes
 SHEBANG_FILES=	zentime
+USE_PERL5_RUN=	yes
+
+DESKTOP_ENTRIES="AutoZen" \
+		"BrainWave Generator/Synchronizator" \
+		"" \
+		"${PORTNAME}" \
+		"AudioVideo;Player;GTK;" \
+		false
 
-PORTDOCS=	*
 MAN1=		autozen.1
+PORTDOCS=	*
 
 .include <bsd.port.options.mk>
-post-patch:
-	@${RM} -f ${WRKSRC}/autozen ${WRKSRC}/seq2wav
-.if exists(/usr/include/sys/soundcard.h)
-	@${REINPLACE_CMD} "s=machine/soundcard.h=sys/soundcard.h=g" \
-		${WRKSRC}/autozen.c
+
+.if ${PORT_OPTIONS:MGTK2}
+USES+=		pkgconfig
+USE_GNOME=	gtk20
+MAKE_ENV+=	GTK_CONFIG="pkg-config gtk+-2.0"
+.else
+USE_GNOME=	gtk12
 .endif
+
+post-extract:
+	@cd ${WRKSRC} && ${RM} -f autozen seq2wav
+
+post-patch:
+	@${REINPLACE_CMD} -e \
+		'/^CC/s| =| ?=| ; \
+		 /^CFLAGS/s| =| ?=| ; \
+		 /^PREFIX/s| =| ?=| ; \
+		 s|share/AutoZen|${DATADIR_REL}| ; \
+		 s|gtk-config|$${GTK_CONFIG}|g ; \
+		 s|$$(CC) seq2wav|$$(CC) $$(CFLAGS) seq2wav|' \
+		${WRKSRC}/Makefile
+
+do-install:
+	${INSTALL_PROGRAM} ${WRKSRC}/autozen ${PREFIX}/bin/
+	${INSTALL_PROGRAM} ${WRKSRC}/seq2wav ${PREFIX}/bin/
+	${INSTALL_SCRIPT} ${WRKSRC}/zentime ${PREFIX}/bin/
+	${INSTALL_MAN} ${WRKSRC}/doc/autozen.1 ${MANPREFIX}/man/man1/
+	${MKDIR} ${DATADIR}
+	(cd ${WRKSRC} && ${INSTALL_DATA} *.seq ${DATADIR})
 .if ${PORT_OPTIONS:MDOCS}
-	@${REINPLACE_CMD} "s=#%%DOCS%%==g" ${WRKSRC}/Makefile
+	${MKDIR} ${DOCSDIR}
+	${COPYTREE_SHARE} ${WRKSRC}/doc/HTML ${DOCSDIR}
 .endif
 
 .include <bsd.port.mk>

Modified: head/audio/autozen/files/patch-autozen.c
==============================================================================
--- head/audio/autozen/files/patch-autozen.c	Mon May 27 08:57:05 2013	(r319179)
+++ head/audio/autozen/files/patch-autozen.c	Mon May 27 09:03:02 2013	(r319180)
@@ -36,3 +36,44 @@
  }
  
  gint volTimeOut(gpointer data) {
+@@ -729,6 +729,11 @@
+ 	GtkWidget *help_text;
+ 	GtkWidget *HelpQuit;
+ 
++#if GTK_MAJOR_VERSION >= 2
++	GtkTextIter help_text_iter;
++	GtkTextBuffer *help_text_buf;
++#endif
++
+ 	HelpWindow = gtk_window_new (GTK_WINDOW_TOPLEVEL);
+ 	gtk_object_set_data (GTK_OBJECT (HelpWindow), "HelpWindow", HelpWindow);
+ 	gtk_window_set_title (GTK_WINDOW (HelpWindow), "AutoZen Help");
+@@ -740,9 +745,16 @@
+ 	gtk_widget_show (vbox1);
+ 	gtk_container_add (GTK_CONTAINER (HelpWindow), vbox1);
+ 
++#if GTK_MAJOR_VERSION >= 2
++	help_text = gtk_text_view_new ();
++	help_text_buf = gtk_text_view_get_buffer (GTK_TEXT_VIEW (help_text));
++	gtk_text_buffer_get_iter_at_offset (help_text_buf, &help_text_iter, 0);
++	gtk_text_view_set_wrap_mode(GTK_TEXT_VIEW (help_text), GTK_WRAP_WORD);
++#else
+ 	help_text = gtk_text_new (NULL, NULL);
+ 	gtk_text_set_word_wrap( GTK_TEXT( help_text ), TRUE);
+ 	gtk_text_set_line_wrap( GTK_TEXT( help_text ), TRUE);
++#endif
+ 
+ 
+ 	gtk_object_set_data (GTK_OBJECT (HelpWindow), "help_text", help_text);
+@@ -751,7 +763,11 @@
+ //	gtk_widget_set_sensitive (help_text, FALSE);
+ 	GTK_WIDGET_UNSET_FLAGS (help_text, GTK_CAN_FOCUS);
+ 	gtk_widget_realize (help_text);
++#if GTK_MAJOR_VERSION >= 2
++	gtk_text_buffer_insert (help_text_buf, &help_text_iter, text, strlen(text));
++#else
+ 	gtk_text_insert (GTK_TEXT (help_text), NULL, NULL, NULL, text, strlen(text));
++#endif
+ 
+ 	HelpQuit = gtk_button_new_with_label ("Close");
+ 	gtk_object_set_data (GTK_OBJECT (HelpWindow), "HelpQuit", HelpQuit);

Modified: head/audio/autozen/pkg-descr
==============================================================================
--- head/audio/autozen/pkg-descr	Mon May 27 08:57:05 2013	(r319179)
+++ head/audio/autozen/pkg-descr	Mon May 27 09:03:02 2013	(r319180)
@@ -9,5 +9,5 @@ all.  The effect depends on each ear rec
 and the combination of the inputs in the brain.  If you are deaf
 in one ear, it will not work.
 
-Author:	Steven James <pyro@linuxlabs.com>
+Author: Steven James <pyro@linuxlabs.com>
 WWW: http://www.linuxlabs.com/autozen.shtml
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 9 Marcelo Araujo freebsd_committer 2013-05-27 10:03:25 UTC
State Changed
From-To: open->closed

Committed, with minor changes. Thanks!