UBports Robot Logo UBports Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login
    1. Home
    2. Valenoern
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 2
    • Posts 5
    • Groups 0

    Valenoern

    @Valenoern

    4
    Reputation
    5
    Profile views
    5
    Posts
    0
    Followers
    0
    Following
    Joined
    Last Online
    Website floss.social/@Valenoern
    Location USA

    Valenoern Unfollow Follow

    Best posts made by Valenoern

    • RE: Including files from one directory up with CMake or basic builders

      The solution to this was laughably simple.
      all I had to do was touch CMakeLists.txt making a completely empty file in the zensekai directory, and then CMake automatically decided to continue in zensekai-click with the other CMakeLists.txt.


      edit 7-13:
      There was actually a little more required.

      in the top CMakeLists.txt I had to put

      add_subdirectory(zensekai-click)
      

      and in the zensekai-click one I accessed/disambiguated the two directories with

      # set $PR_ROOT to upper directory
      get_filename_component(PR_ROOT "../" ABSOLUTE)
      # set $CLICK_DIR to zensekai-click directory
      set(CLICK_DIR "${PR_ROOT}/zensekai-click")
      

      another thing you might run into developing a click package that copies binaries is permissions on binaries.
      I set them in the loop that copies the binaries like so:

      foreach(binary ${BINARIES})
              install(FILES ${PR_ROOT}/bin/${binary}
                      # the important part
                      PERMISSIONS OWNER_READ OWNER_EXECUTE GROUP_READ WORLD_READ WORLD_EXECUTE
                      # this might actually be unnecessarily permissive*.
                      # it might be enough to just have OWNER_READ and OWNER_EXECUTE
                      DESTINATION ${DATA_DIR}
              )
      endforeach()
      

      (* I got sidetracked thinking the permissions weren't enough when I accidentally had my project copying the x86_64 godot binary for a bit - which had bash claiming it "wasn't permitted" to execute while it actually meant that was impossible.)

      posted in App Development
      ValenoernV
      Valenoern
    • RE: Recommended approach for using openGL or other libraries in UT app?

      I have complete instructions for compiling my demo now...
      https://pages.codeberg.org/Valenoern/zensekai/docs/docs.html#CompilingDemo_godot-06-30

      ...but I had no idea I wouldn't be able to edit my post after "3600 seconds", so now I can never edit into the OP the somewhat critical information that you're not supposed to clone that "asekai-packages" repository without --depth 1 (you'll unnecessarily get 100+ mb of previous releases).

      edit: to get the files either

      • git clone --depth 1 https://codeberg.org/Valenoern/asekai-packages.git or
      • git clone https://codeberg.org/Valenoern/zensekai-demo.git && wget https://codeberg.org/Valenoern/asekai-packages/raw/branch/master/linux_x11_arm64_debug && wget https://codeberg.org/Valenoern/asekai-packages/raw/branch/master/linux_x11_arm64 (i feel like you can actually leave off the second one because the editor exports a debug version by default, but I'm not sure)

      you'll need to compile against OpenGL ES (libGLES)

      it is using GLES in the screenshot

      Yeah, I found it a bit confusing that although godot should be using "GLES 2" I was getting an error about "libGL.so". As I said, I would have been passing it a binary made on a pinebook pro (arm64 Arch/manjaro) so I guess that was using "libGL"?

      @Elleo Do you have any information about how to use the libGLES already in ubuntu touch?
      My next step apart from sorting out libraries was going to be to try to compile click packages on arm64 and I wonder if that would make the library part easier.

      posted in App Development
      ValenoernV
      Valenoern

    Latest posts made by Valenoern

    • RE: Including files from one directory up with CMake or basic builders

      The solution to this was laughably simple.
      all I had to do was touch CMakeLists.txt making a completely empty file in the zensekai directory, and then CMake automatically decided to continue in zensekai-click with the other CMakeLists.txt.


      edit 7-13:
      There was actually a little more required.

      in the top CMakeLists.txt I had to put

      add_subdirectory(zensekai-click)
      

      and in the zensekai-click one I accessed/disambiguated the two directories with

      # set $PR_ROOT to upper directory
      get_filename_component(PR_ROOT "../" ABSOLUTE)
      # set $CLICK_DIR to zensekai-click directory
      set(CLICK_DIR "${PR_ROOT}/zensekai-click")
      

      another thing you might run into developing a click package that copies binaries is permissions on binaries.
      I set them in the loop that copies the binaries like so:

      foreach(binary ${BINARIES})
              install(FILES ${PR_ROOT}/bin/${binary}
                      # the important part
                      PERMISSIONS OWNER_READ OWNER_EXECUTE GROUP_READ WORLD_READ WORLD_EXECUTE
                      # this might actually be unnecessarily permissive*.
                      # it might be enough to just have OWNER_READ and OWNER_EXECUTE
                      DESTINATION ${DATA_DIR}
              )
      endforeach()
      

      (* I got sidetracked thinking the permissions weren't enough when I accidentally had my project copying the x86_64 godot binary for a bit - which had bash claiming it "wasn't permitted" to execute while it actually meant that was impossible.)

      posted in App Development
      ValenoernV
      Valenoern
    • Including files from one directory up with CMake or basic builders

      I have an in-progress app I've been trying to create from a godot game demo.

      Mostly I've been making great progress with this. I got a click package to build and "start" godot (with a crash), and I actually contributed a fix to the docker image for arm64 hosts so it's now easier to debug + build the game on an arm64 machine before sending it to the phone.

      One thing I've been having a lot of unnecessary trouble with is keeping a reasonable directory structure and still compiling my click package. I have things arranged like this:

      repository
      |
      `--- main branch directories
      |
      `--- zensekai (experimental branch directory)
            |
            `--- bin (compiled game)
            |
            `--- zensekai-click (click package)
      

      And the Makefile in zensekai copies/compiles all the game binaries that should be needed for either the desktop version or the click package.

      From reading the clickable documentation I felt like I should be able to set the project root to ../ aka zensekai and from the zensekai-click/CMakeLists.txt file copy in binaries from bin. But CMake seems to only want to put files in zensekai-click into the container for building, and I have no idea what command or "makefile" to use for the pure or custom builders much less whether they can do this, and I'm very confused.

      posted in App Development
      ValenoernV
      Valenoern
    • RE: Recommended approach for using openGL or other libraries in UT app?

      I have complete instructions for compiling my demo now...
      https://pages.codeberg.org/Valenoern/zensekai/docs/docs.html#CompilingDemo_godot-06-30

      ...but I had no idea I wouldn't be able to edit my post after "3600 seconds", so now I can never edit into the OP the somewhat critical information that you're not supposed to clone that "asekai-packages" repository without --depth 1 (you'll unnecessarily get 100+ mb of previous releases).

      edit: to get the files either

      • git clone --depth 1 https://codeberg.org/Valenoern/asekai-packages.git or
      • git clone https://codeberg.org/Valenoern/zensekai-demo.git && wget https://codeberg.org/Valenoern/asekai-packages/raw/branch/master/linux_x11_arm64_debug && wget https://codeberg.org/Valenoern/asekai-packages/raw/branch/master/linux_x11_arm64 (i feel like you can actually leave off the second one because the editor exports a debug version by default, but I'm not sure)

      you'll need to compile against OpenGL ES (libGLES)

      it is using GLES in the screenshot

      Yeah, I found it a bit confusing that although godot should be using "GLES 2" I was getting an error about "libGL.so". As I said, I would have been passing it a binary made on a pinebook pro (arm64 Arch/manjaro) so I guess that was using "libGL"?

      @Elleo Do you have any information about how to use the libGLES already in ubuntu touch?
      My next step apart from sorting out libraries was going to be to try to compile click packages on arm64 and I wonder if that would make the library part easier.

      posted in App Development
      ValenoernV
      Valenoern
    • Recommended approach for using openGL or other libraries in UT app?

      I've been developing a game called "zensekai" using godot, which I had always intended as a linux mobile game.

      I have been trying to get the game to launch on the pinephone, and have already gotten it running (at separate times) on a pinebook pro and as a click package on x86_64 ubuntu:
      https://codeberg.org/Valenoern/zensekai-demo/issues/7

      (That part was actually really hard; the documentation for clickable might need some improving as far as troubleshooting CMake. But anyway, I built a click package that ran.)

      I then tried to build the game for arm64, basically using a binary I compiled on the pinebook. To my surprise, the result of running clickable --ssh (ip address) logs seemed to be that everything about the package was fine except the moment it tried to render graphics.

      The error I got was:
      zensekai: error while loading shared libraries: libGL.so.1: cannot open shared object file: No such file or directory

      I'm guessing what this means is my Ubuntu Touch image didn't have openGL installed while the desktop/pinebook did. (And also that there are probably a few other missing libraries clickable will only tell me about after I fix this one.)
      Is there any recommended approach for what to do when my app needs shared libraries, like including them in the app or some other method?


      If you want to help me debug my specific game, you can get the source here
      https://codeberg.org/Valenoern/zensekai-demo / https://codeberg.org/Valenoern/zensekai-demo.git

      I will try to put up a compressed folder that contains the specific set of compiled files I'm using, and/or comprehensive instructions on what the results of compiling from the git repo should look like this evening or tomorrow, so this is actually useful to anybody

      The very first caveat before you start compiling is you need to get the godot export templates from here (they start with "linux_"): https://codeberg.org/Valenoern/asekai-packages
      and make sure the godot editor exports the game using one of them (probably the debug one).
      After that you run make, and either make click-desktop (to test on ubuntu) or make click (to build for arm64)

      (Again, that's not really all the instructions, so I'll be back later to provide more complete ones.)

      The result should look something like this:
      (because funny enough, I forgot to account for compiling a helper program as arm64 so compiling right now would have the same bug as in this screenshot.)

      Screenshot of an ubuntu 20.04 desktop with the zensekai demo in one window, and in another window, the output of a program called "clickable" which just built it. In this picture the demo is just a vast green field containing one cube, as the program to add monsters didn't run correctly. The best part of the picture may be the default wallpaper filled with a bright warm orange to violet gradient

      posted in App Development
      ValenoernV
      Valenoern
    • RE: Electron apps on Ubuntu Touch

      Libertine on pinephone was returning errors trying to create even an example container the last time I tried to use it

      https://gitlab.com/ubports/community-ports/pinephone/-/issues/133
      (gitlab isn't working enough to find the main issue but that's one)

      posted in General
      ValenoernV
      Valenoern