forslund / pymimic

A python wrapper for mimic TTS
5 stars 4 forks source link

Simplify build step by assuming mimic is installed? #1

Open zeehio opened 8 years ago

zeehio commented 8 years ago

This is just a suggestion. Have you considered to simplify a lot the package by assuming that mimic is installed in the virtual environment (or in the system)?

Eventually mimic will be installable by using git, or a debian package or a windows installer or as a default in most distributions (evil "rule the world" laugh: "muahahahahah") so I am not sure of the advantages of having a build procedure inside pymimic. Maybe some documentation on how to install mimic in the virtual environment would be enough:

Dependencies for pymimic:

# Create virtual environment for pymimic
virtualenv ./pymimicvenv
# Install mimic into the environment using prefix
git clone git@github.com:MycroftAI/mimic.git
cd mimic
./configure --prefix="$PWD/pymimicvenv" --enable-shared --with-audio=none
make
make install

Installation

Now that we rely on having mimic installed, pymimic is a very simple package so the setup.py may only need to copy a py file to pymimic path.

# Activate virtual environment
source pymimicvenv/bin/activate
# Install pymimic (once it is on pypi)
pip install pymimic 

By doing that you may be able to drop dirname(abspath(__file__)) to find the .so files too.

forslund commented 8 years ago

Yes now that the special version of mimic isn't needed the build should be simplified and use standard library directories.

I would like to have some sort of automatic install of mimic (to make installation from the cheeseshop simple) but the current setup isn't optimal. I might create a separate install package for mimic and simplify the pymimic install. I just need to do some more research before I begin.