Merge lp:~devvmh/mnemosyne-proj/mnemosyne-proj into lp:~peter-bienstman/mnemosyne-proj/trunk

Proposed by Devin Howard
Status: Merged
Merge reported by: Peter Bienstman
Merged at revision: not available
Proposed branch: lp:~devvmh/mnemosyne-proj/mnemosyne-proj
Merge into: lp:~peter-bienstman/mnemosyne-proj/trunk
Diff against target: 55 lines (+20/-4)
2 files modified
mnemosyne/README (+10/-2)
mnemosyne/mnemosyne/pyqt_ui/review_wdgt.py (+10/-2)
To merge this branch: bzr merge lp:~devvmh/mnemosyne-proj/mnemosyne-proj
Reviewer Review Type Date Requested Status
Peter Bienstman Pending
Review via email: mp+323090@code.launchpad.net

Description of the change

fix mplayer error in 2.4.1 on MacOS

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'mnemosyne/README'
--- mnemosyne/README 2017-01-30 15:24:43 +0000
+++ mnemosyne/README 2017-04-25 03:48:43 +0000
@@ -37,10 +37,18 @@
37 - Make sure you are using the latest version of Homebrew:37 - Make sure you are using the latest version of Homebrew:
3838
39 brew update39 brew update
40
41 - Patch the python3 formula so you'll get python 3.5 and not a later version (pyinstaller still requires python 3.5):
42
43 brew uninstall python3
44 brew edit python3
45 # replace the file with the contents of https://raw.githubusercontent.com/Homebrew/homebrew-core/1e62c645b2fc2d82042d9f7c364c6a246f2e11ed/Formula/python3.rb and save it
46 brew install python3
47 brew pin python3
40 48
41 - Install the dependencies for Mnemosyne. You may need to install qt5 or python3 manually to get the correct version.49 - Install the dependencies for Mnemosyne. You may need to install qt5 or python3 manually to get the correct version.
42 50
43 brew install python3 qt5 mplayer51 brew install qt@5.7 mplayer
44 pip3 install virtualenv52 pip3 install virtualenv
45 virtualenv --python=python3 venv53 virtualenv --python=python3 venv
46 source venv/bin/activate54 source venv/bin/activate
@@ -49,7 +57,7 @@
49 - Build it:57 - Build it:
50 58
51 export PYTHON=python359 export PYTHON=python3
52 export QT5DIR=/usr/local/opt/qt5 # help pyinstaller find the qt5 path60 export QT5DIR=/usr/local/opt/qt@5.7 # help pyinstaller find the qt5 path
53 make clean61 make clean
54 make osx62 make osx
5563
5664
=== modified file 'mnemosyne/mnemosyne/pyqt_ui/review_wdgt.py'
--- mnemosyne/mnemosyne/pyqt_ui/review_wdgt.py 2017-03-23 18:40:10 +0000
+++ mnemosyne/mnemosyne/pyqt_ui/review_wdgt.py 2017-04-25 03:48:43 +0000
@@ -506,8 +506,16 @@
506 command = "mplayer.exe -slave -ao win32 -quiet \"" + filename + \506 command = "mplayer.exe -slave -ao win32 -quiet \"" + filename + \
507 "\" -ss " + str(start) + " -endpos " + str(duration) 507 "\" -ss " + str(start) + " -endpos " + str(duration)
508 elif sys.platform == "darwin":508 elif sys.platform == "darwin":
509 command = "mplayer -slave -ao coreaudio -quiet \"" + filename + \509 # e.g. /path/to/Mnemosyne.app/Contents/MacOS/mnemosyne/pyqt_ui/review_wdgt.py
510 "\" -ss " + str(start) + " -endpos " + str(duration)510 SCRIPT_PATH = os.path.dirname(os.path.realpath(__file__))
511 # e.g. /path/to/Mnemosyne.app/Contents
512 CONTENTS_FOLDER = SCRIPT_PATH[:SCRIPT_PATH.index("/MacOS")]
513 # e.g. /path/to/Mnemosyne.app/Contents/MacOS/mplayer
514 MPLAYER_PATH = CONTENTS_FOLDER + "/MacOS/mplayer"
515
516 command = "{} -slave -ao coreaudio -quiet \"{}\" -ss {} -endpos {}".format(
517 MPLAYER_PATH, filename, str(start), str(duration)
518 )
511 else:519 else:
512 command = "mplayer -slave -quiet \"" + filename + \520 command = "mplayer -slave -quiet \"" + filename + \
513 "\" -ss " + str(start) + " -endpos " + str(duration)521 "\" -ss " + str(start) + " -endpos " + str(duration)

Subscribers

People subscribed via source and target branches