accumulator / Quickddit

Reddit client for Jolla's SailfishOS, Ubuntu Touch and Nokia N9
GNU General Public License v3.0
53 stars 21 forks source link

Update to the latest youtube-dl to fix missing token and fix invalid dates #49

Closed omartijn closed 5 years ago

omartijn commented 5 years ago

Since a day or two/three, youtube videos stopped working. This was fixed in the latest youtube-dl. I have updated the submodule so it uses the latest version. Building and installing fixes video playback.

I have also fixed some invalid dates mentioned in the changes file. No idea how you managed to build it, but for me the build would error out due to the invalid dates.

One thing I still don't understand is that I can't build from the harbour-quickddit-harbour.yaml file. This results in the following error:

Project ERROR: keepalive development package not found

I guess it makes some kind of sense as it indeed does not specify it as a dependency, and is thus not installed, but I thought the whole point of it was that it doesn't even use it (because it wouldn't be allowed in the jolla store).

Building the nonharbour file worked, however.

omartijn commented 5 years ago

This PR fixes issue https://github.com/accumulator/Quickddit/issues/48

accumulator commented 5 years ago

The harbour build variant is selected by adding 'harbour' to the CONFIG variable in the .pro file. If not, the non-harbour/default build variant is built (which enables notification sounds and screen keepalive/awake features).

The .pro file (qmake) then selects the correct yaml file by symlinking, which pulls in the correct dependencies.

If you're getting dependency issues, it's probably because there's a leftover .spec file generated from the wrong .yaml file.

omartijn commented 5 years ago

Ah, so to build the harbour build you have to change the .pro file besides using the harbour yaml file for specify? That must be what I was missing then.

accumulator commented 5 years ago

You can pass CONFIG+=harbour on the qmake command line, so no need to actually change the .pro file, nor change the yaml symlink yourself.

accumulator commented 5 years ago

This is actually my build script for use outside of QtCreator (uses the SDK, vbox build engine must be running):

#!/bin/sh
set -e

if [ $USER != "mersdk" ]; then
  echo "Delegating build to SDK"
  ssh -p 2222 -i /opt/SailfishOS/vmshare/ssh/private_keys/engine/mersdk mersdk@localhost /home/src1/quickddit/Quickddit/buildall
  exit
fi

echo "[SDK] Starting build"

cd /home/mersdk/share/projects/quickddit/Quickddit
BASE=$(pwd)
OS=SailfishOS-3.0.2.8

mkdir -p $BASE/build/harbour
mkdir -p $BASE/build/standard

# i486
rm -rf  $BASE/build/tmp && mkdir -p $BASE/build/tmp
cd $BASE/build/tmp

mb2 -t ${OS}-i486 -p $BASE/sailfish qmake "CONFIG+=harbour" $BASE/sailfish/harbour-quickddit.pro -r -spec linux-g++
mb2 -t ${OS}-i486 -p $BASE/sailfish make -j 4
mb2 -t ${OS}-i486 -p $BASE/sailfish rpm
mv RPMS/* $BASE/build/harbour

mb2 -t ${OS}-i486 -p $BASE/sailfish qmake "CONFIG-=harbour" $BASE/sailfish/harbour-quickddit.pro -r -spec linux-g++
mb2 -t ${OS}-i486 -p $BASE/sailfish make -j 4
mb2 -t ${OS}-i486 -p $BASE/sailfish rpm
mv RPMS/* $BASE/build/standard

# armv7hl
rm -rf  $BASE/build/tmp && mkdir -p $BASE/build/tmp
cd $BASE/build/tmp

mb2 -t ${OS}-armv7hl -p $BASE/sailfish qmake "CONFIG+=harbour" $BASE/sailfish/harbour-quickddit.pro -r -spec linux-g++
mb2 -t ${OS}-armv7hl -p $BASE/sailfish make -j 4
mb2 -t ${OS}-armv7hl -p $BASE/sailfish rpm
mv RPMS/* $BASE/build/harbour
mb2 -t ${OS}-armv7hl -p $BASE/sailfish qmake "CONFIG-=harbour" $BASE/sailfish/harbour-quickddit.pro -r -spec linux-g++
mb2 -t ${OS}-armv7hl -p $BASE/sailfish make -j 4
mb2 -t ${OS}-armv7hl -p $BASE/sailfish rpm
mv RPMS/* $BASE/build/standard

echo "Done."
omartijn commented 5 years ago

BTW: I get why you closed this PR, but the issue with the invalid dates is still there. This breaks builds using mb2. Could you fix this or shall I split that change off into another PR for you to merge?

accumulator commented 5 years ago

Ah sorry, didn't notice. Fixed.