From owner-svn-ports-all@FreeBSD.ORG Tue Feb 3 14:56:27 2015 Return-Path: Delivered-To: svn-ports-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9655FAAE; Tue, 3 Feb 2015 14:56:27 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 81C6AA16; Tue, 3 Feb 2015 14:56:27 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id t13EuR97093799; Tue, 3 Feb 2015 14:56:27 GMT (envelope-from mi@FreeBSD.org) Received: (from mi@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id t13EuQRj093796; Tue, 3 Feb 2015 14:56:26 GMT (envelope-from mi@FreeBSD.org) Message-Id: <201502031456.t13EuQRj093796@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: mi set sender to mi@FreeBSD.org using -f From: Mikhail Teterin Date: Tue, 3 Feb 2015 14:56:26 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r378355 - in head/audio/fapg: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Feb 2015 14:56:27 -0000 Author: mi Date: Tue Feb 3 14:56:26 2015 New Revision: 378355 URL: https://svnweb.freebsd.org/changeset/ports/378355 QAT: https://qat.redports.org/buildarchive/r378355/ Log: Upgrade from 0.41 to 0.42. Use configure and otherwise simplify the port. Resolve compiler-warnings (mostly about signed vs. unsigned char). Do not install the COPYING-file -- it is nothing but the recitation of GPLv2 -- declare GPLv2 as LICENSE instead. Do not install the README -- there is nothing in it, that the man-page does not cover. With only two files remaining -- the program and the man-page -- do away with pkg-plist and simply list the two in PLIST_FILES. Deleted: head/audio/fapg/pkg-plist Modified: head/audio/fapg/Makefile head/audio/fapg/distinfo head/audio/fapg/files/patch-fapg.c Modified: head/audio/fapg/Makefile ============================================================================== --- head/audio/fapg/Makefile Tue Feb 3 14:51:03 2015 (r378354) +++ head/audio/fapg/Makefile Tue Feb 3 14:56:26 2015 (r378355) @@ -2,32 +2,19 @@ # $FreeBSD$ PORTNAME= fapg -PORTVERSION= 0.41 +PORTVERSION= 0.42 CATEGORIES= audio MASTER_SITES= http://royale.zerezo.com/${PORTNAME}/ MAINTAINER= ports@FreeBSD.org COMMENT= Fast Audio Playlist Generator -LIB_DEPENDS= liburiparser.so:${PORTSDIR}/net/uriparser - -MAKE_ARGS+= CC="${CC}" - -OPTIONS_DEFINE= DOCS +LICENSE= GPLv2 -.include - -do-build: - @cd ${WRKSRC} && ${MAKE} ${PORTNAME} +LIB_DEPENDS= liburiparser.so:${PORTSDIR}/net/uriparser -do-install: - ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin - ${INSTALL_MAN} ${WRKSRC}/fapg.1 ${STAGEDIR}${MAN1PREFIX}/man/man1 -.if ${PORT_OPTIONS:MDOCS} - @${MKDIR} ${STAGEDIR}${DOCSDIR} -.for file in COPYING README - ${INSTALL_DATA} ${WRKSRC}/${file} ${STAGEDIR}${DOCSDIR} -.endfor -.endif +GNU_CONFIGURE= yes +CONFIGURE_ARGS+=--with-uriparser="${LOCALBASE}" +PLIST_FILES= bin/fapg man/man1/fapg.1.gz .include Modified: head/audio/fapg/distinfo ============================================================================== --- head/audio/fapg/distinfo Tue Feb 3 14:51:03 2015 (r378354) +++ head/audio/fapg/distinfo Tue Feb 3 14:56:26 2015 (r378355) @@ -1,2 +1,2 @@ -SHA256 (fapg-0.41.tar.gz) = 0c09229c1473999f5939770326d8294adfa1847ae3da5f0c7827747284fc54ae -SIZE (fapg-0.41.tar.gz) = 94315 +SHA256 (fapg-0.42.tar.gz) = f324eca6d5fe958be74beb6336d685aa305133c5da26c99b2c0dbc17c68c0076 +SIZE (fapg-0.42.tar.gz) = 94920 Modified: head/audio/fapg/files/patch-fapg.c ============================================================================== --- head/audio/fapg/files/patch-fapg.c Tue Feb 3 14:51:03 2015 (r378354) +++ head/audio/fapg/files/patch-fapg.c Tue Feb 3 14:56:26 2015 (r378355) @@ -1,16 +1,198 @@ ---- fapg.c.orig 2008-03-11 02:18:04.000000000 +0800 -+++ fapg.c 2008-05-01 17:46:37.000000000 +0800 -@@ -1514,8 +1514,7 @@ +--- fapg.c 2015-02-02 13:27:58.000000000 -0500 ++++ fapg.c 2015-02-03 09:47:00.000000000 -0500 +@@ -57,27 +57,27 @@ + + int debug = 0; + int format = FORMAT_M3U; +-char *genrelist = NULL; +-unsigned char *prefix = ""; +-unsigned char *base = ""; +-unsigned char *dir = ""; +-unsigned char *hostname = "fritzserver.de"; ++static char *genrelist = NULL; ++static char *prefix = ""; ++static char *base = ""; ++static char *dir = ""; ++static const char *hostname = "fritzserver.de"; + // unsigned char *referal="/usr/local/bin/fapg-rss.sh"; +-unsigned char *referal = NULL; ++static const char *referal = NULL; + //int windows=0; + int fromstdin = 0; + int recursive = 0; + int avoidhlinked = 0; + int separator = '/'; +-unsigned char *eol = "\n"; +-unsigned char buffer[MAX]; ++static const char *eol = "\n"; ++static char buffer[MAX]; + + int counter = 0; + +-unsigned char artist[1024]; +-unsigned char title[1024]; +-unsigned char genrebuf[1024]; +-unsigned char genre = 0; ++static char artist[1024]; ++static char title[1024]; ++static char genrebuf[1024]; ++static unsigned char genre = 0; + int duration; + #define MP2ENC 1 + #define MP3ENC 2 +@@ -87,7 +87,7 @@ + #define WAVENC 6 + #define WMAENC 7 + +-char *magic[] = { NULL, ++static const char *magic[] = { NULL, + "audio/mpeg", "audio/mpeg", + "audio/mpeg", "audio/mpeg", + "audio/ogg-vorbis", "audio/x-wav", +@@ -95,7 +95,7 @@ + NULL + }; + +-unsigned char unix2dos[] = ++static unsigned char unix2dos[] = + { 0, 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, 70, 35, 36, 37, 38, 39, 40, 41, 82, 43, 44, 45, 46, 47, +@@ -126,7 +126,7 @@ + + unsigned char *basemap; + unsigned char *winorunix; +-unsigned char one2one[] = ++static unsigned char one2one[] = + { 0, 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, +@@ -160,7 +160,7 @@ + 248, 249, 250, 251, 252, 253, 254, 255 + }; /* identical mapping */ + +-unsigned char noand[256] = ++static unsigned char noand[256] = + { 0, 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, +@@ -194,7 +194,7 @@ + 248, 249, 250, 251, 252, 253, 254, 255 + }; /* only '&' is mapped to '+' */ + +-unsigned char *iso2web[256] = { ++static const char *iso2web[256] = { + "%00", "%01", "%02", "%03", "%04", "%05", "%06", "%07", + "%08", "%09", "%0a", "%0b", "%0c", "%0d", "%0e", "%0f", + "%10", "%11", "%12", "%13", "%14", "%15", "%16", "%17", +@@ -308,7 +308,7 @@ + int pos = 0; + int cnt = 0; + char b; +- unsigned char *prefx; ++ char *prefx; + + prefx = prefix; + +@@ -344,7 +344,7 @@ + { + int cnt = 0; + int pos; +- unsigned char *prefx; ++ char *prefx; + + txxputnameoffset(c); + +@@ -669,7 +669,7 @@ + } + } + +-void parse_mp3(unsigned char *file) ++void parse_mp3(const char *file) + { + int bitrates[2][3][15] = + { {{0, 32, 64, 96, 128, 160, 192, 224, 256, 288, 320, 352, 384, +@@ -683,7 +683,7 @@ + {0, 8, 16, 24, 32, 40, 48, 56, 64, 80, 96, 112, 128, 144, 160}} + }; + FILE *fic; +- unsigned char *c; ++ char *c; + int lus; + + genre = 0; +@@ -773,7 +773,7 @@ + } + + while(c < buffer + lus - 10) { +- if(*c == 0xFF && (*(c + 1) & 0xF0) == 0xF0) { ++ if((unsigned char)*c == 0xFF && (*(c + 1) & 0xF0) == 0xF0) { + int version; + int lay; + int bitrate_index; +@@ -823,10 +823,10 @@ + fclose(fic); + } + +-void parse_ogg(unsigned char *file) ++void parse_ogg(const char *file) + { + FILE *fic; +- unsigned char *c; ++ char *c; + int lus; + int sample_rate; + int samples; +@@ -911,10 +911,10 @@ + fclose(fic); + } + +-void parse_mpc(unsigned char *file) ++void parse_mpc(const char *file) + { + FILE *fic; +- unsigned char *c; ++ char *c; + int lus; + int sample_rates[4] = { 44100, 48000, 37800, 32000 }; + int frame_count; +@@ -1253,9 +1253,9 @@ + } + #endif + +-void parse_file(unsigned char *newpath, unsigned char * original_path) ++void parse_file(char *newpath, const char * original_path) + { +- unsigned char ext[5]; ++ char ext[5]; + int j, encoding = 0; + + for(j = 0; j < 5; j++) +@@ -1457,11 +1457,11 @@ + } + } + +-void parse_directory(unsigned char *path, unsigned char * original_path) ++void parse_directory(char *path, const char * original_path) + { + int i, n; + struct dirent **namelist; +- unsigned char newpath[PATH_MAX]; ++ char newpath[PATH_MAX]; + struct stat infos; + + if(debug) +@@ -1520,8 +1520,7 @@ break; case FORMAT_HTML: printf - ("%s%s%s%s%sPlaylist generated by FAPG " - VERSION -+ ("<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\">%s%s<html>%s%s<head>%s<title>Playlist generated by FAPG 0.41" ++ ("<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\">%s%s<html>%s%s<head>%s<title>Playlist generated by FAPG 0.42" "%s%s%s%s%s%s%s

Playlist

%s%s%s%s", eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, eol, -@@ -1532,10 +1531,8 @@ +@@ -1538,10 +1537,8 @@ strftime(timebuffer, 255, "%a %d %b %Y %T %z", localtime(&zeit)); printf @@ -18,26 +200,35 @@ - VERSION - " -->%s%s %s\t%s - %s - %s%s\tDirectory Tree %s%s\t%s%s\t%s\t%s%s\tFAPG " - VERSION -+ ("%s%s%s %s\t%s - %s - %s%s\tDirectory Tree %s%s\t%s%s\t%s\t%s%s\tFAPG 0.41" ++ ("%s%s%s %s\t%s - %s - %s%s\tDirectory Tree %s%s\t%s%s\t%s\t%s%s\tFAPG 0.42" "%s\t%s\t\t%s/podcast.jpg%s\t\tServer Logo%s\t\t%s%s\t\tFeed provided by FAPG. Click to visit.%s\t%s\t%s\t\tAdmin %s%s\t\tpodcast@%s%s\t%s\tVarious%s\tDirectory Tree %s%s\t%s%s\tunknown%s\t%s%s\tNo%s\t1800%s", eol, eol, eol, eol, hostname, dir, argv[optind], eol, prefix, eol, base, eol, prefix, eol, timebuffer, eol, eol, -@@ -1560,7 +1557,7 @@ +@@ -1566,7 +1563,7 @@ #ifdef HAVE_LIBURIPARSER case FORMAT_XSPF: printf("\n" - "\n" -+ "\n" ++ "\n" "\n" "\n"); break; -@@ -1615,7 +1612,7 @@ +@@ -1581,7 +1578,7 @@ + sprintf(pwd, "%s/", pwd_source); + + if(fromstdin) { +- unsigned char path[PATH_MAX]; ++ char path[PATH_MAX]; + int i; + while(fgets(path, PATH_MAX, stdin)) { + for(i = 0; i < PATH_MAX; i++) +@@ -1621,7 +1618,7 @@ case FORMAT_HTML: printf ("
EntryArtistTitleLength
%s%s

Playlist generated by FAPG " - VERSION "

%s%s%s%s", eol, eol, eol, eol, -+ "0.41

%s%s%s%s", eol, eol, eol, eol, ++ "0.42

%s%s%s%s", eol, eol, eol, eol, eol, eol); break; case FORMAT_RSS: