Skip to content
This repository was archived by the owner on Aug 10, 2022. It is now read-only.

Installing pianobarfly on Cygwin

nega0 edited this page Aug 2, 2013 · 4 revisions

This page was originally posted by @ghost as issue #28

We had some luck installing pianobarfly on Windows the other night and wanted to share.

Prerequisites

Beyond the base Cygwin system, you will need to install the following packages using the Cygwin installer:

  • git
  • gcc4 (not gcc)
  • make
  • pkg-config
  • gnutls-devel
  • libao-devel
  • libid3tag-devel
  • wget
  • nano, or some other text editor

You'll also need to compile a couple of libraries from source.

Installing faad

    wget http://downloads.sourceforge.net/faac/faad2-2.7.tar.gz
    tar xvf faad2-2.7.tar.gz
    cd faad2-2.7
    ./configure --prefix=/usr && make install

We're changing the install prefix from the default /usr/local to /usr so that it will be easier for libpiano to find the installed libraries.

Installing libmad

    wget ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz
    tar xvf libmad-0.15.1b.tar.gz
    cd libmad-0.15.1b
    ./configure --prefix=/usr

Before compiling libmad, edit the Makefile in the base directory. Remove the -fforce-mem flag from the CFLAGS line of the Makefile (line 129). Now, continue with the build:

    make install

We also need to create a mad.pc file so that pkg-config will know that libmad is installed.

Save the following as /usr/lib/pkgconfig/mad.pc

    ## start of mad.pc
    prefix=/usr
    exec_prefix=${prefix}
    libdir=${exec_prefix}/lib
    includedir=${prefix}/include

    Name: mad
    Description: MPEG audio decoder
    Requires:
    Version: 0.15.1b
    Libs: -L${libdir} -lmad
    Cflags: -I${includedir}
    ## end of mad.pc

Now we can proceed with pianobarfly.

Installing pianobarfly

Check out the source from GitHub and the installed libraries.

Installing libmad

    wget ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz
    tar xvf libmad-0.15.1b.tar.gz

    cd libmad-0.15.1b
    ./configure --prefix=/usr

Before compiling libmad, edit the Makefile in the base directory. Remove the -fforce-mem flag from the CFLAGS line of the Makefile (line 129). Now, continue with the build:

    make install

We also need to create a mad.pc file so that pkg-config will know that libmad is installed.

Save the following as /usr/lib/ pkgconfig/mad.pc

    ## start of mad.pc
    prefix=/usr
    exec_prefix=${prefix}
    libdir=${exec_prefix}/lib
    includedir=${prefix}/include

    Name: mad
    Description: MPEG audio decoder

Requires:
    Version: 0.15.1b
    Libs: -L${libdir} -lmad

Cflags: -I${includedir} ## end of mad.pc

Now we can proceed with p ianobarfly.

Installing pianobarfly

Check out the source from GitHub

    git clone https://github.com/ghuntley/pianobarfly.git
    cd pianobarfly

Edit the Makefile

    nano Makefile

Change line 3 from PREFIX:=/usr/local to PREFIX:=usr and change line 15 from CC=c99 to CC=cc -std=c99

    make install

Run pianobarfly, and celebrate!

Saving login information

Login information is saved in the file ~/.config/pianobarfly/config. Create the file as follows:

    mkdir -p ~/.config/pianobarfly
    nano ~/.config/pianobarfly/config

And type your login information:

    user = [email protected]
    password = wooly_mammoth

Good luck!