読者です 読者をやめる 読者になる 読者になる

つれづれなるままに。

webテストの自動化について備忘録のつもりで書いています

mimmsをインストール

完全個人備忘録

公式からmacportsのpkgをダウンロードしてきてインストール後

doli:~ Dolias$ port version
Version: 2.2.0
doli:~ Dolias$ sudo port -v selfupdate
Password:
--->  Updating MacPorts base sources using rsync
receiving file list ... done

sent 36 bytes  received 69 bytes  70.00 bytes/sec
total size is 4925440  speedup is 46908.95
receiving file list ... done

sent 36 bytes  received 76 bytes  74.67 bytes/sec
total size is 512  speedup is 4.57
MacPorts base version 2.2.0 installed,
MacPorts base version 2.2.0 downloaded.
--->  Updating the ports tree
Synchronizing local ports tree from rsync://rsync.macports.org/release/tarballs/ports.tar
receiving file list ... done

sent 36 bytes  received 70 bytes  70.67 bytes/sec
total size is 54149120  speedup is 510840.75
receiving file list ... done

sent 36 bytes  received 77 bytes  75.33 bytes/sec
total size is 512  speedup is 4.53
Creating port index in /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/ports

Total number of ports parsed:	0 
Ports successfully parsed:	0 
Ports failed:			0 
Up-to-date ports skipped:	17531

--->  MacPorts base is already the latest version

The ports tree has been updated. To upgrade your installed ports, you should run
  port upgrade outdated
doli:~ Dolias$ sudo port sync
--->  Updating the ports tree
doli:~ Dolias$ sudo port -v selfupdate
--->  Updating MacPorts base sources using rsync
receiving file list ... done

sent 36 bytes  received 69 bytes  70.00 bytes/sec
total size is 4925440  speedup is 46908.95
receiving file list ... done

sent 36 bytes  received 76 bytes  74.67 bytes/sec
total size is 512  speedup is 4.57
MacPorts base version 2.2.0 installed,
MacPorts base version 2.2.0 downloaded.
--->  Updating the ports tree
Synchronizing local ports tree from rsync://rsync.macports.org/release/tarballs/ports.tar
receiving file list ... done

sent 36 bytes  received 70 bytes  70.67 bytes/sec
total size is 54149120  speedup is 510840.75
receiving file list ... done

sent 36 bytes  received 77 bytes  75.33 bytes/sec
total size is 512  speedup is 4.53
Creating port index in /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/ports

Total number of ports parsed:	0 
Ports successfully parsed:	0 
Ports failed:			0 
Up-to-date ports skipped:	17531

--->  MacPorts base is already the latest version

The ports tree has been updated. To upgrade your installed ports, you should run
  port upgrade outdated

portsがインストールできたので mimmsをインストールする

doli:~ Dolias$ sudo port search mimms
mimms @3.2.1_1 (multimedia)
    MiMMS isn't an MMS Message Sender, it's an MMS (e.g. mms://) stream
    downloader.
doli:~ Dolias$ sudo port info mimms
mimms @3.2.1_1 (multimedia)

Description:          MiMMS is a program designed to allow you to download
                      streams using the MMS protocol and save them to your
                      computer, as opposed to watching them live. Similar
                      functionality is available in full media player suites
                      such as Xine and MPlayer, but MiMMS is quick and easy to
                      use, and for the time being, remains a useful program.
Homepage:             http://savannah.nongnu.org/projects/mimms/

Library Dependencies: python26, libmms
Platforms:            darwin
License:              GPL-3+
Maintainers:          cedric.luthi@gmail.com, openmaintainer@macports.org
doli:~ Dolias$ sudo port install mimms
--->  Computing dependencies for mimms
--->  Dependencies to be installed: libmms gettext expat libiconv ncurses glib2 libffi perl5 perl5.12 gdbm zlib python26 bzip2 db46 db_select libedit openssl python_select sqlite3
--->  Fetching archive for expat
--->  Attempting to fetch expat-2.1.0_0.darwin_12.x86_64.tbz2 from http://packages.macports.org/expat
--->  Attempting to fetch expat-2.1.0_0.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/expat
--->  Installing expat @2.1.0_0
--->  Activating expat @2.1.0_0
--->  Cleaning expat
--->  Fetching archive for libiconv
--->  Attempting to fetch libiconv-1.14_0.darwin_12.x86_64.tbz2 from http://packages.macports.org/libiconv
--->  Attempting to fetch libiconv-1.14_0.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/libiconv
--->  Installing libiconv @1.14_0
--->  Activating libiconv @1.14_0
--->  Cleaning libiconv
--->  Fetching archive for ncurses
--->  Attempting to fetch ncurses-5.9_2.darwin_12.x86_64.tbz2 from http://packages.macports.org/ncurses
--->  Attempting to fetch ncurses-5.9_2.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/ncurses
--->  Installing ncurses @5.9_2
--->  Activating ncurses @5.9_2
--->  Cleaning ncurses
--->  Fetching archive for gettext
--->  Attempting to fetch gettext-0.18.3.1_0.darwin_12.x86_64.tbz2 from http://packages.macports.org/gettext
--->  Attempting to fetch gettext-0.18.3.1_0.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/gettext
--->  Installing gettext @0.18.3.1_0
--->  Activating gettext @0.18.3.1_0
--->  Cleaning gettext
--->  Fetching archive for libffi
--->  Attempting to fetch libffi-3.0.13_0.darwin_12.x86_64.tbz2 from http://packages.macports.org/libffi
--->  Attempting to fetch libffi-3.0.13_0.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/libffi
--->  Installing libffi @3.0.13_0
--->  Activating libffi @3.0.13_0
--->  Cleaning libffi
--->  Fetching archive for gdbm
--->  Attempting to fetch gdbm-1.10_2.darwin_12.x86_64.tbz2 from http://packages.macports.org/gdbm
--->  Attempting to fetch gdbm-1.10_2.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/gdbm
--->  Installing gdbm @1.10_2
--->  Activating gdbm @1.10_2
--->  Cleaning gdbm
--->  Fetching archive for perl5.12
--->  Attempting to fetch perl5.12-5.12.4_2.darwin_12.x86_64.tbz2 from http://packages.macports.org/perl5.12
--->  Attempting to fetch perl5.12-5.12.4_2.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/perl5.12
--->  Installing perl5.12 @5.12.4_2
--->  Activating perl5.12 @5.12.4_2
--->  Cleaning perl5.12
--->  Fetching archive for perl5
--->  Attempting to fetch perl5-5.12.4_0+perl5_12.darwin_12.noarch.tbz2 from http://packages.macports.org/perl5
--->  Attempting to fetch perl5-5.12.4_0+perl5_12.darwin_12.noarch.tbz2.rmd160 from http://packages.macports.org/perl5
--->  Installing perl5 @5.12.4_0+perl5_12
--->  Activating perl5 @5.12.4_0+perl5_12
--->  Cleaning perl5
--->  Fetching archive for zlib
--->  Attempting to fetch zlib-1.2.8_0.darwin_12.x86_64.tbz2 from http://packages.macports.org/zlib
--->  Attempting to fetch zlib-1.2.8_0.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/zlib
--->  Installing zlib @1.2.8_0
--->  Activating zlib @1.2.8_0
--->  Cleaning zlib
--->  Fetching archive for glib2
--->  Attempting to fetch glib2-2.36.4_0.darwin_12.x86_64.tbz2 from http://packages.macports.org/glib2
--->  Attempting to fetch glib2-2.36.4_0.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/glib2
--->  Installing glib2 @2.36.4_0
--->  Activating glib2 @2.36.4_0
--->  Cleaning glib2
--->  Fetching archive for libmms
--->  Attempting to fetch libmms-0.6.2_0.darwin_12.x86_64.tbz2 from http://packages.macports.org/libmms
--->  Attempting to fetch libmms-0.6.2_0.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/libmms
--->  Installing libmms @0.6.2_0
--->  Activating libmms @0.6.2_0
--->  Cleaning libmms
--->  Fetching archive for bzip2
--->  Attempting to fetch bzip2-1.0.6_0.darwin_12.x86_64.tbz2 from http://packages.macports.org/bzip2
--->  Attempting to fetch bzip2-1.0.6_0.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/bzip2
--->  Installing bzip2 @1.0.6_0
--->  Activating bzip2 @1.0.6_0
--->  Cleaning bzip2
--->  Fetching archive for db_select
--->  Attempting to fetch db_select-0.1_2.darwin_12.noarch.tbz2 from http://packages.macports.org/db_select
--->  Attempting to fetch db_select-0.1_2.darwin_12.noarch.tbz2.rmd160 from http://packages.macports.org/db_select
--->  Installing db_select @0.1_2
--->  Activating db_select @0.1_2
--->  Cleaning db_select
--->  Fetching archive for db46
--->  Attempting to fetch db46-4.6.21_8.darwin_12.x86_64.tbz2 from http://packages.macports.org/db46
--->  Attempting to fetch db46-4.6.21_8.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/db46
--->  Installing db46 @4.6.21_8
--->  Activating db46 @4.6.21_8
--->  Cleaning db46
--->  Fetching archive for libedit
--->  Attempting to fetch libedit-20121213-3.0_0.darwin_12.x86_64.tbz2 from http://packages.macports.org/libedit
--->  Attempting to fetch libedit-20121213-3.0_0.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/libedit
--->  Installing libedit @20121213-3.0_0
--->  Activating libedit @20121213-3.0_0
--->  Cleaning libedit
--->  Fetching archive for openssl
--->  Attempting to fetch openssl-1.0.1e_1.darwin_12.x86_64.tbz2 from http://packages.macports.org/openssl
--->  Attempting to fetch openssl-1.0.1e_1.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/openssl
--->  Installing openssl @1.0.1e_1
--->  Activating openssl @1.0.1e_1
--->  Cleaning openssl
--->  Fetching archive for python_select
--->  Attempting to fetch python_select-0.3_2.darwin_12.noarch.tbz2 from http://packages.macports.org/python_select
--->  Attempting to fetch python_select-0.3_2.darwin_12.noarch.tbz2 from http://jog.id.packages.macports.org/macports/packages/python_select
--->  Attempting to fetch python_select-0.3_2.darwin_12.noarch.tbz2 from http://mse.uk.packages.macports.org/sites/packages.macports.org/python_select
--->  Fetching distfiles for python_select
--->  Verifying checksums for python_select
--->  Extracting python_select
--->  Configuring python_select
--->  Building python_select
--->  Staging python_select into destroot
--->  Installing python_select @0.3_2
--->  Activating python_select @0.3_2
--->  Cleaning python_select
--->  Fetching archive for sqlite3
--->  Attempting to fetch sqlite3-3.8.0.2_0.darwin_12.x86_64.tbz2 from http://packages.macports.org/sqlite3
--->  Attempting to fetch sqlite3-3.8.0.2_0.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/sqlite3
--->  Installing sqlite3 @3.8.0.2_0
--->  Activating sqlite3 @3.8.0.2_0
--->  Cleaning sqlite3
--->  Fetching archive for python26
--->  Attempting to fetch python26-2.6.8_0.darwin_12.x86_64.tbz2 from http://packages.macports.org/python26
--->  Attempting to fetch python26-2.6.8_0.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/python26
--->  Installing python26 @2.6.8_0
--->  Activating python26 @2.6.8_0

To make python 2.6 the default (i.e. the version you get when you run 'python'),
please run:

sudo port select --set python python26

--->  Cleaning python26
--->  Fetching archive for mimms
--->  Attempting to fetch mimms-3.2.1_1.darwin_12.noarch.tbz2 from http://packages.macports.org/mimms
--->  Attempting to fetch mimms-3.2.1_1.darwin_12.noarch.tbz2 from http://jog.id.packages.macports.org/macports/packages/mimms
--->  Attempting to fetch mimms-3.2.1_1.darwin_12.noarch.tbz2 from http://mse.uk.packages.macports.org/sites/packages.macports.org/mimms
--->  Fetching distfiles for mimms
--->  Attempting to fetch mimms-3.2.1.tar.bz2 from http://cjj.kr.distfiles.macports.org/mimms
--->  Attempting to fetch mimms-3.2.1.tar.bz2 from http://distfiles.macports.org/mimms
--->  Verifying checksums for mimms
--->  Extracting mimms
--->  Configuring mimms
--->  Building mimms
--->  Staging mimms into destroot
--->  Installing mimms @3.2.1_1
--->  Activating mimms @3.2.1_1
--->  Cleaning mimms
--->  Updating database of binaries: 100.0%
--->  Scanning binaries for linking errors: 100.0%
--->  No broken files found.
doli:~ Dolias$ mimms
Usage: mimms [options] <url> [filename]

mimms: error: url must be specified

asfファイルを取得してみる

doli:~ Dolias$ ./hibiki.sh xxxx
mms://wms.uliza.jp/uliza/910/130910_love-lab_130910_love-lab-wm.wma => xxxx13.asf
23.71 MB / 23.72 MB (12.09 kB/s, 00:00:00 remaining)                                                         
Download complete!
mms://wms.uliza.jp/uliza/910/130910_love-lab_130910_love-lab-wm.wma => xxxx13.asf

Download complete!

asfファイルをmp3に変換

doli:~ Dolias$ mv xxxx13.asf love_lab13.asf
doli:~ Dolias$ ffmpeg -i love_lab13.asf love_lab13.mp3
FFmpeg version SVN-r20230, Copyright (c) 2000-2009 Fabrice Bellard, et al.
  built on Oct 14 2009 10:27:43 with gcc 4.2.1 (Apple Inc. build 5577)
  configuration: --enable-cross-compile --arch=i386 --cpu=pentium-m --cc=gcc-4.2 --enable-small --enable-pthreads --enable-gpl --enable-postproc --enable-nonfree --disable-ffserver --disable-ffplay --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libxvid --enable-libx264 --disable-decoder=aac
  libavutil     50. 3. 0 / 50. 3. 0
  libavcodec    52.37. 0 / 52.37. 0
  libavformat   52.39. 1 / 52.39. 1
  libavdevice   52. 2. 0 / 52. 2. 0
  libswscale     0. 7. 1 /  0. 7. 1
  libpostproc   51. 2. 0 / 51. 2. 0
Input #0, asf, from 'love_lab13.asf':
  Duration: 00:32:42.03, start: 1.579000, bitrate: 96 kb/s
    Stream #0.0(jpn): Audio: wmav2, 44100 Hz, 2 channels, s16, 96 kb/s
  Metadata
    WMFSDKVersion   : 12.0.7601.17514
    WMFSDKNeeded    : 0.0.0.0000
    IsVBR           : 0
Output #0, mp3, to 'love_lab13.mp3':
    Stream #0.0(jpn): Audio: libmp3lame, 44100 Hz, 2 channels, s16, 64 kb/s
Stream mapping:
  Stream #0.0 -> #0.0
Press [q] to stop encoding
Error while decoding stream #0.0ate=  64.0kbits/s    
[libmp3lame @ 0x134f200]lame: output buffer too small (buffer index: 9404, free bytes: 388)
Audio encoding failed
doli:~ Dolias$ 

ところどころfailed って文字が見えるのだが・・・