UBports Robot Logo UBports Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Clickable: C++ template does not work on Focal (20.04)

    Scheduled Pinned Locked Moved App Development
    focal fossa20.04clickablec++
    7 Posts 3 Posters 601 Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
      Reply
      • Reply as topic
      Log in to reply
      This topic has been deleted. Only users with topic management privileges can see it.
      • B Offline
        Bokken
        last edited by

        The default C++ project stub generated by Clickable cannot run on my Pixel 3a (20.04 Stable channel).

        When I build the project with the command CLICKABLE_FRAMEWORK=ubuntu-sdk-20.04 clickable, it fails at the installation step with this message:

        Installing the app.
        Error: GDBus.Error:com.lomiri.click.OperationFailed: failed to install /home/phablet/appname.yourname_1.0.0_amd64.click
        Command ran on device via ADB failed. See output above.
        

        The only thing I've changed from the freshly generated stub is in the appname.apparmor file. I changed "policy_version": 16.04 to "policy_version": 20.04.

        Some things I've tried:

        • The pure QML, Python and HTML templates work fine. The Rust template gives the same error as the C++ template. The Go and Godot templates gave each their own unrelated error.
        • Using CLICKABLE_FRAMEWORK=ubuntu-sdk-20.04 clickable versus just clickable and specifying framework: ubuntu-sdk-20.04 in clickable.yaml.
        • I cleared my cache a few times ("Is it okay to delete and re-download it?" -> yes) and created a few different projects to ensure it wasn't a problem with a project in particular.
        • I reinstalled the core apps on my phone through the Settings app.
        • I switched to the 20.04 Development channel.

        Is there something I can do to narrow down the problem? I found no other issue about this, so I'm not sure if it's a problem with my device or if it's a bug in Clickable.

        arubislanderA 1 Reply Last reply Reply Quote 0
        • arubislanderA Offline
          arubislander @Bokken
          last edited by

          @Bokken What version of clickable are you using?

          πŸ‡¦πŸ‡Ό πŸ‡³πŸ‡± πŸ‡ΊπŸ‡Έ πŸ‡ͺπŸ‡Έ
          Happily running Ubuntu Touch
          Google Pixel 3a (20.04 DEV)
          JingPad (24.04 preview)
          Meizu Pro 5 (16.04 DEV)

          B 1 Reply Last reply Reply Quote 0
          • B Offline
            Bokkenn @arubislander
            last edited by

            @arubislander Clickable 7.12.1, which says is the latest version.

            Sorry for the new name, I lost access to my original account.

            arubislanderA 1 Reply Last reply Reply Quote 0
            • arubislanderA Offline
              arubislander @Bokkenn
              last edited by

              @Bokkenn I have seen reports similar to yours on Telegram, but I thought they would have been solved with the latest version.

              Will have to give it a try when I get home.

              πŸ‡¦πŸ‡Ό πŸ‡³πŸ‡± πŸ‡ΊπŸ‡Έ πŸ‡ͺπŸ‡Έ
              Happily running Ubuntu Touch
              Google Pixel 3a (20.04 DEV)
              JingPad (24.04 preview)
              Meizu Pro 5 (16.04 DEV)

              arubislanderA 1 Reply Last reply Reply Quote 1
              • arubislanderA Offline
                arubislander @arubislander
                last edited by arubislander

                @arubislander I just tried this. I updated clickable to 7.12.1, then I created a new C++ app and did the same as you did. The app installed and ran fine. I am on the devel channel.

                πŸ‡¦πŸ‡Ό πŸ‡³πŸ‡± πŸ‡ΊπŸ‡Έ πŸ‡ͺπŸ‡Έ
                Happily running Ubuntu Touch
                Google Pixel 3a (20.04 DEV)
                JingPad (24.04 preview)
                Meizu Pro 5 (16.04 DEV)

                B 1 Reply Last reply Reply Quote 0
                • B Offline
                  Bokkenn @arubislander
                  last edited by

                  @arubislander I solved the problem.

                  Despite reinstalling my phone entirely from the UBports installer, the issue persisted.

                  I tried to see if I could at least trace back the issue further... until I spotted somewhere in the logs: "For interaction with a target device you might want to specify the device architecture via --arch."

                  I forgot to specify the architecture.

                  Needless to say, adding --arch arm64 to the command fixed the problem. Sorry for taking your time for such a trivial issue.

                  I believe it would be good to have some mechanism in place to warn me if I attempt to install a .click with the wrong architecture. It only said "failed to install" from the command line, and installing manually though the phone only gave an "incorrect package format" from the OpenStore.

                  arubislanderA 1 Reply Last reply Reply Quote 0
                  • arubislanderA Offline
                    arubislander @Bokkenn
                    last edited by

                    @Bokkenn said in Clickable: C++ template does not work on Focal (20.04):

                    I forgot to specify the architecture.
                    Needless to say, adding --arch arm64 to the command fixed the problem. Sorry for taking your time for such a trivial issue.

                    Glad you got it sorted, although it is odd, as since a few versions --arch arm64 has been the default for clickable. Very odd indeed. Do you have setup somewhere in some configuration that amd64 should be the default on your development machine?

                    I believe it would be good to have some mechanism in place to warn me if I attempt to install a .click with the wrong architecture. It only said "failed to install" from the command line, and installing manually though the phone only gave an "incorrect package format" from the OpenStore.

                    Well, the 'failed to install' bit on the command line and especially the 'incorrect package format' that the OpenStore throws are the mechanisms I guess.

                    Now looking back at your original post, I see that the answer was staring us right in the face, in the name of the click: /home/phablet/appname.yourname_1.0.0_amd64.click.

                    I guess now we know.

                    πŸ‡¦πŸ‡Ό πŸ‡³πŸ‡± πŸ‡ΊπŸ‡Έ πŸ‡ͺπŸ‡Έ
                    Happily running Ubuntu Touch
                    Google Pixel 3a (20.04 DEV)
                    JingPad (24.04 preview)
                    Meizu Pro 5 (16.04 DEV)

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post