diff options
Diffstat (limited to '')
-rwxr-xr-x | calibre/build/calibre.SlackBuild | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/calibre/build/calibre.SlackBuild b/calibre/build/calibre.SlackBuild index 80fb37d7..4733141a 100755 --- a/calibre/build/calibre.SlackBuild +++ b/calibre/build/calibre.SlackBuild @@ -264,6 +264,9 @@ BUILD_PYTHON="YES" # allows us to be independant of Slackware's ImageMagick upgrades. BUILD_MAGICK=${BUILD_MAGICK:-NO} +# Sometimes we need to generate a new user-agent-strings file: +BUILD_NEWUAS=${BUILD_NEWUAS:-NO} + # Allow the package builder to override BUILD_QT: if [ -z "$BUILD_QT" ]; then if pkg-config --exists "Qt6Core >= $REQUIRED_QT" && pkg-config --exists "Qt6Core <= $INT_QT" ; @@ -2355,13 +2358,13 @@ make_calibre () { LANG='en_US.UTF-8' \ python3 setup.py gui \ 2>&1 | tee -a $OUTPUT/make-${PRGNAM}.log - if [ ! -f $SRCDIR/sources/user-agent-data.json ]; then + if [ ! -f $SRCDIR/sources/user-agent-data.json ] || [ "${BUILD_NEWUAS}" != "NO" ]; then # Generate the UserAgent-strings file by collecting online data: LANG='en_US.UTF-8' \ python3 setup.py recent_uas \ 2>&1 | tee -a $OUTPUT/make-${PRGNAM}.log # For later re-use: - cp -a resources/user-agent-data.json $OUTPUT/ + cp -a resources/user-agent-data.json $SRCDIR/sources/ else install -m0644 $SRCDIR/sources/user-agent-data.json \ resources/user-agent-data.json |