We have moved to a new Sailfish OS Forum. Please start new discussions there.
6

SDK version 1807 released

asked 2018-09-20 18:16:23 +0200

Jare gravatar image

Hello,

The Sailfish OS SDK update 1807 has been released. This update has the latest 2.2.1.18 build environment, which matches the Jolla Release 2.2.1 (Nurmonjoki). It also contains an updated Qt Creator, and a bunch of usability and bug fixes. Find out more about these features and the release content from the release notes.

If you have an older beta release of the SDK, you should see an update notification in the Sailfish OS IDE. View more information in the SDK wiki page and also check out the known issues page.

Happy hacking!

edit retag flag offensive close delete

Comments

@cy8aer Is the source code of your project available somewhere? If not, a small example would be appreciated. (Please consider converting your comments to a separate question or at least an answer.)

martyone ( 2018-09-20 23:03:30 +0200 )edit

Hi.

I have noticed a new entry inside the 'Devices' options: I mean Tools --> Options --> Devices called Android :).

Was this option there before or may it be related to the upcoming Android upgrade for SFOS 3?

Regards.

Pasko ( 2018-09-28 18:47:40 +0200 )edit

@Pasko Unfortunately this is a regression introduced with Qt Creator upgrade - the Android plugin should be still disabled in our fork of Qt Creator.

martyone ( 2018-10-01 09:15:29 +0200 )edit

5 Answers

Sort by » oldest newest most voted
1

answered 2018-09-20 21:38:04 +0200

cy8aer gravatar image

updated 2018-09-20 23:49:12 +0200

oups:

import QtQuick 2.0
import Sailfish.Silica 1.0
import io.thp.pyotherside 1.4

Python {
    id: archivehandler

    signal createArchiveList(var data)

    Component.onCompleted: {
        setHandler("createArchiveList", createArchiveList)

        addImportPath(Qt.resolvedUrl('.'));
        importModule('ArchiveHandler', function () {
            console.log('ArchiveHandler is now imported')
        })
    }

    function getArchiveEntries() {
        call("ArchiveHandler.archivehandler.getarchiveposts", function() {});
    }
}

This is straitforward code like in https://sailfishos.org/wiki/Tutorial_-_Creating_an_application_in_Python

In the Editor the Python line is declared as "an unkknown component (M300)"

edit flag offensive delete publish link more

Comments

Did you get it fixed?

lispy ( 2018-11-16 14:17:57 +0200 )edit
0

answered 2018-09-20 20:54:02 +0200

cy8aer gravatar image

updated 2018-09-20 20:56:21 +0200

can anyone help me with this new ERROR:

Provides
========
ERROR [application()] 'Provides: application()' not allowed in RPM
ERROR [application(harbour-myapp.desktop)] 'Provides: application(harbour-myapp.desktop)' not     allowed in RPM
FAILED

This is a new check fail, wasn't with sdk 1804...

edit flag offensive delete publish link more

Comments

This is a false positive error. Please ignore it.

martyone ( 2018-09-20 22:45:11 +0200 )edit
0

answered 2018-09-20 20:55:55 +0200

cy8aer gravatar image

updated 2018-09-21 00:27:32 +0200

Sorry about the not existing code yet: I am just in the last steps before publishing both source and package. But for understanding some snippets.

I have defined a Singleton class in python (like e. g. described here: https://stackoverflow.com/questions/6760685/creating-a-singleton-in-python Method 3A - python3 part)

class Singleton(type):
    _instances = {}

    def __call__(cls, *args, **kwargs):
        if cls not in cls._instances:
            cls._instances[cls] = super(Singleton, cls).__call__(*args, **kwargs)
        return cls._instances[cls]

And then a Singleton member class is defined like this (it is a factory for an Archive class defined somewhere else, uses another Factory class):

class ArchiveFactory(metaclass=Singleton):
    """
    Factory  which creates an Archive if it does not exist or gets the pickle
    otherwise if returns the Singleton
    """

    def __init__(self, progname=('podqast')):
        """
        Initialization
        """

        self.archive = None

    def get_archive(self):
        """
        Get the Archive
        """

        if not self.archive:
            self.archive = Factory().get_store().get(archivename)
            if not self.archive:
                self.archive = Archive()
                self.have_archive = True
                return self.archive

        return self.archive

When packaging the python code is compiled to pyc files. And in this step I get a error message with 1807:

Compiling /home/deploy/installroot/usr/share/harbour-podqast/python/podcast/archive.py ...
  File "/usr/share/harbour-podqast/python/podcast/archive.py", line 66
    class ArchiveFactory(metaclass=Singleton):
                                  ^
SyntaxError: invalid syntax

But this is no syntax error in python3.

edit flag offensive delete publish link more

Comments

cy8aer try if adding %global __python %{__python3} on top of your .spec file helps.

martyone ( 2018-09-21 08:51:43 +0200 )edit
1

@maryone: yes this option does the trick:

+ /usr/lib/rpm/brp-python-bytecompile /usr/bin/python3

is done instead of

+ /usr/lib/rpm/brp-python-bytecompile /usr/bin/python

without. Is there a possibility to get it in the .yaml?

cy8aer ( 2018-09-21 15:35:38 +0200 )edit
0

answered 2018-09-20 21:20:06 +0200

syrja gravatar image

The SDK is missing SSH keys and cannot connect virtual machines. Directory SailfishOS/vmshare/ssh/ was missing and SailfishOS/emulator/1/ssh/ was empty.

Copied key directories from the SDK version 1804 and authorized keys in Tools / Options / Sailfish OS / Build Engine. Seems to help.

Tested with SailfishOSSDK-Beta-1807-Qt5-linux-64-offline.run in OpenSuse Leap 15.

edit flag offensive delete publish link more

Comments

@syrja could you please install it again, passing --verbose to the installer, and paste content of the InstallationLog.txtfile found in the root of the installation directory?

martyone ( 2018-09-20 22:25:23 +0200 )edit

Ok. here it comes: https://pastebin.com/6AqUPBpb

syrja ( 2018-09-20 22:47:13 +0200 )edit

Just noticed that I used installation directory /home/mikko/Code/SailfishOS, but it generated ssh keys to default directory /home/mikko/SailfishOS.

syrja ( 2018-09-20 22:54:51 +0200 )edit
0

answered 2018-10-27 20:08:00 +0200

Alex gravatar image

updated 2018-10-28 00:07:52 +0200

EDIT:

Ok I just figured out what caused the issue described below:

My project folder 'SFOS Apps' contains a space character and this seems to cause issues in the latest SDK version. Renaming my project folder to e.g. 'SFOS_Apps' fixed this issue. :)


After updating to this version I am unable to deploy to my devices with the option 'Deploy as RPM Package'. Only the option 'Deploy By Copying Binaries' is working.

I already did a fresh reinstallation but this did not solve the issue. Has anyone an idea how to solve this issue?

While trying to deploy with 'Deploy as RPM Package' I am getting the following output:

[...]
21:41:49: Test Device Connection: Testing connection to "Jolla (ARM)"...
21:41:49: Deploying RPM package...
21:41:49: Starte "/home/alex/.config/SailfishOS-SDK/mer-sdk-tools/Sailfish OS Build Engine/SailfishOS-2.2.1.18-armv7hl/deploy" --sdk
Building target platforms: armv7hl-meego-linux
Building for target armv7hl-meego-linux
Executing(%install): /bin/sh -e /var/tmp/rpm-tmp.r7Uxig
+ umask 022
+ cd '/home/mersdk/share/SFOS Apps/build-App-SailfishOS_2_2_1_18_armv7hl_in_Sailfish_OS_Build_Engine-Debug'
+ '[' /home/deploy/installroot '!=' / ']'
+ rm -rf /home/deploy/installroot
++ dirname /home/deploy/installroot
+ mkdir -p /home/deploy
+ mkdir /home/deploy/installroot
+ LANG=C
+ export LANG
+ unset DISPLAY
+ rm -rf /home/deploy/installroot
+ export QT_SELECT=5
+ QT_SELECT=5
+ make install INSTALL_ROOT=/home/deploy/installroot
lupdate -noobsolete /home/mersdk/share/SFOS Apps/App/src /home/mersdk/share/SFOS Apps/App/qml -ts /home/mersdk/share/SFOS Apps/App/translations/App.ts /home/mersdk/share/SFOS Apps/App/translations/App-de.ts && mkdir -p translations && [ "/home/mersdk/share/SFOS Apps/build-App-SailfishOS_2_2_1_18_armv7hl_in_Sailfish_OS_Build_Engine-Debug" != "/home/mersdk/share/SFOS Apps/App" -a 1 -eq 1 ] && cp -af /home/mersdk/share/SFOS Apps/App/translations/App-de.ts /home/mersdk/share/SFOS Apps/build-App-SailfishOS_2_2_1_18_armv7hl_in_Sailfish_OS_Build_Engine-Debug/translations || : ; [ 1 -eq 1 ] && lrelease -nounfinished /home/mersdk/share/SFOS Apps/build-App-SailfishOS_2_2_1_18_armv7hl_in_Sailfish_OS_Build_Engine-Debug/translations/App-de.ts || :
lupdate error: File '/home/mersdk/share/SFOS' does not exist.
lrelease error: Cannot open /home/mersdk/share/SFOS: No such file or directory
install -m 644 -p /home/mersdk/share/SFOS\ Apps/build-App-SailfishOS_2_2_1_18_armv7hl_in_Sailfish_OS_Build_Engine-Debug/translations/App-de.qm /home/deploy/installroot/usr/share/App/translations/
install: cannot stat `/home/mersdk/share/SFOS Apps/build-App-SailfishOS_2_2_1_18_armv7hl_in_Sailfish_OS_Build_Engine-Debug/translations/App-de.qm': No such file or directory
make: [install_qm] Error 1 (ignored)
cp -f -R /home/mersdk/share/SFOS\ Apps/App/qml /home/deploy/installroot/usr/share/App/
install -m 755 -p App /home/deploy/installroot/usr/bin/App
install -m 644 -p /home/mersdk/share/SFOS\ Apps/App/App.desktop /home/deploy/installroot/usr/share/applications/
install -m 644 -p /home/mersdk/share/SFOS\ Apps/App/icons/86x86/App.png /home/deploy/installroot/usr/share/icons/hicolor/86x86/apps/
install -m 644 -p /home/mersdk/share/SFOS\ Apps/App/icons/108x108/App.png /home/deploy/installroot/usr/share/icons/hicolor/108x108/apps/
install -m 644 -p /home/mersdk/share/SFOS\ Apps/App/icons/128x128/App.png /home/deploy/installroot/usr/share/icons/hicolor/128x128/apps/
install -m 644 -p /home/mersdk/share/SFOS\ Apps/App/icons/256x256/App.png /home/deploy/installroot/usr/share/icons/hicolor/256x256/apps/
+ desktop-file-install --delete-original --dir /home/deploy/installroot/usr/share/applications /home/deploy/installroot/usr/share/applications/App.desktop
+ /usr/lib/rpm/find-debuginfo.sh --strict-build-id --build-id-seed 0.1-1 --unique-debug-suffix -0.1-1.arm --unique-debug-src-base App-0.1-1.arm -S debugsourcefiles.list '/home/mersdk/share/SFOS Apps/build-App-SailfishOS_2_2_1_18_armv7hl_in_Sailfish_OS_Build_Engine-Debug/'
extracting debug info from /home/deploy/installroot/usr/bin/App
0 blocks
+ /usr/lib/rpm/check-buildroot
+ /usr/lib/rpm/meego/brp-compress
+ /usr/lib/rpm/meego/brp-strip-static-archive /usr/bin/strip
+ /usr/lib/rpm/meego/brp-strip-comment-note /usr/bin/strip /usr/bin/objdump
+ /usr/lib/rpm/brp-python-bytecompile /usr/bin/python
+ /usr/lib/rpm/meego/brp-python-hardlink
+ /usr/lib/rpm/meego/find-docs.sh /home/deploy/installroot
+ /usr/lib/rpm/meego/brp-java-repack-jars
Processing files: App-0.1-1.armv7hl
warning: File listed twice: /usr/share/App/translations
Provides: App = 0.1-1 App(armv7hl-32) = 0.1-1 application() application(App.desktop)
Requires(rpmlib): rpmlib(CompressedFileNames) <= 3.0.4-1 rpmlib(FileDigests) <= 4.6.0-1 rpmlib(PayloadFilesHavePrefix) <= 4.0-1
Requires: libGLESv2.so.2 libQt5Core.so.5 libQt5Core.so.5(Qt_5) libQt5Gui.so.5 libQt5Gui.so.5(Qt_5) libQt5Network.so.5 libQt5Qml.so.5 libQt5Qml.so.5(Qt_5) libQt5Quick.so.5 libQt5Quick.so.5(Qt_5) libc.so.6 libc.so.6(GLIBC_2.4) libgcc_s.so.1 libgcc_s.so.1(GCC_3.5) libm.so.6 libmdeclarativecache5.so.0 libpthread.so.0 libsailfishapp.so.1 libstdc++.so.6 libstdc++.so.6(CXXABI_1.3) rtld(GNU_HASH)
Processing files: App-debuginfo-0.1-1.armv7hl
Provides: App-debuginfo = 0.1-1 App-debuginfo(armv7hl-32) = 0.1-1 debuginfo(build-id) = 8b21d3bf31f613b32a16c66a9de7810186595895
Requires(rpmlib): rpmlib(CompressedFileNames) <= 3.0.4-1 rpmlib(FileDigests) <= 4.6.0-1 rpmlib(PayloadFilesHavePrefix) <= 4.0-1
Recommends: App-debugsource(armv7hl-32) = 0.1-1
Processing files: App-debugsource-0.1-1.armv7hl
Provides: App-debugsource = 0.1-1 App-debugsource(armv7hl-32) = 0.1-1
Requires(rpmlib): rpmlib(CompressedFileNames) <= 3.0.4-1 rpmlib(FileDigests) <= 4.6.0-1 rpmlib(PayloadFilesHavePrefix) <= 4.0-1
Checking for unpackaged file(s): /usr/lib/rpm/check-files /home/deploy/installroot
Wrote: /home/mersdk/share/SFOS Apps/build-App-SailfishOS_2_2_1_18_armv7hl_in_Sailfish_OS_Build_Engine-Debug/RPMS/App-0.1-1.armv7hl.rpm
Wrote: /home/mersdk/share/SFOS Apps/build-App-SailfishOS_2_2_1_18_armv7hl_in_Sailfish_OS_Build_Engine-Debug/RPMS/App-debuginfo-0.1-1.armv7hl.rpm
Wrote: /home/mersdk/share/SFOS Apps/build-App-SailfishOS_2_2_1_18_armv7hl_in_Sailfish_OS_Build_Engine-Debug/RPMS/App-debugsource-0.1-1.armv7hl.rpm
find: /home/mersdk/share/SFOS: No such file or directory
find: Apps/build-App-SailfishOS_2_2_1_18_armv7hl_in_Sailfish_OS_Build_Engine-Debug: No such file or directory
receiving incremental file list
drwxrwxrwx              0 2018/10/26 16:19:01 .

sent 20 bytes  received 54 bytes  49.33 bytes/sec
total size is 0  speedup is 0.00
Usage:
   sdk-deploy-rpm [OPTION] filename.rpm [...]

Options:
   -v | --verbose   verbose output when installing packages
   -h | --help      this help

Deploy failed
21:41:56: Der Prozess "/home/alex/.config/SailfishOS-SDK/mer-sdk-tools/Sailfish OS Build Engine/SailfishOS-2.2.1.18-armv7hl/deploy" wurde mit dem Rückgabewert 1 beendet.
Fehler beim Erstellen/Deployment des Projekts App (Kit: SailfishOS-2.2.1.18-armv7hl (in Sailfish OS Build Engine))
Bei der Ausführung von Schritt "RPM"
21:41:56: Verstrichene Zeit: 00:13.
edit flag offensive delete publish link more

Comments

In the output you pasted the path with space still figures.

martyone ( 2018-10-29 09:12:43 +0200 )edit

Ah, OK, initially I did not get the order of your messages correctly

martyone ( 2018-10-29 09:13:44 +0200 )edit
Login/Signup to Answer

Question tools

Follow
5 followers

Stats

Asked: 2018-09-20 18:16:23 +0200

Seen: 1,096 times

Last updated: Oct 28 '18