system/flashcards: Fix app failing to start.

Signed-off-by: B. Watson <yalhcru@gmail.com>
This commit is contained in:
B. Watson 2020-01-17 23:09:25 -05:00 committed by Willy Sudiarto Raharjo
parent a31fe40dd0
commit 822fed53a1
No known key found for this signature in database
GPG key ID: 887B8374D7333381
2 changed files with 30 additions and 0 deletions

View file

@ -0,0 +1,24 @@
diff -Naur flashcards-2.4/flashcards/configure.py flashcards-2.4.patched/flashcards/configure.py
--- flashcards-2.4/flashcards/configure.py 2012-02-06 03:32:51.000000000 -0500
+++ flashcards-2.4.patched/flashcards/configure.py 2020-01-17 23:03:15.495097878 -0500
@@ -29,6 +29,8 @@
documents = os.path.join(home_path, 'Documents')
ROOT = os.path.join(documents, 'flashcards')
+if not os.path.isdir(documents):
+ os.mkdir(documents)
if not os.path.isdir(ROOT):
os.mkdir(ROOT)
diff -Naur flashcards-2.4/setup.py flashcards-2.4.patched/setup.py
--- flashcards-2.4/setup.py 2012-02-06 03:45:22.000000000 -0500
+++ flashcards-2.4.patched/setup.py 2020-01-17 23:03:32.311096350 -0500
@@ -14,7 +14,7 @@
author_email = "luisnaranjo733@hotmail.com",
description = ("A simple command line flashcards utility, similar to physical flashcards."),
license = "GNU GPL",
- install_requires= ['argparse','configobj',],
+ install_requires= ['configobj',],
entry_points = {
'console_scripts': ['flashcards = flashcards.flashcards:main']
},

View file

@ -69,6 +69,12 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
# 20200117 bkw: this has apparently been broken for a LONG time. It
# complains that there's no "distribution" called argparse... but
# argparse ships with Slackware. Also, application fails to start if
# $HOME/Documents doesn't already exist. Patch fixes both issues.
patch -p1 < $CWD/fixes.diff
python setup.py install --root=$PKG
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \