# Flatpak manifest for BioView (Linux). # # Hybrid UHD: unlike the macOS/Windows bundles (which reuse a prebuilt UHD), the # Flatpak builds UHD -- and its Boost/libusb dependencies -- from source inside # the sandbox with the Python API enabled, so the resulting bundle is fully # self-contained (libuhd + bindings + FPGA images all live under /app). # # The bioview-client package exposes a `bioview` console script (its launcher), # which pip installs to /app/bin/bioview -- that is the app command. # # Build: flatpak-builder --force-clean --user --install-deps-from=flathub \ # build/flatpak org.bioview.BioView.yaml # Bundle: flatpak build-bundle BioView.flatpak org.bioview.BioView # Freedesktop runtime 24.08 ships Python 3.12, which satisfies every BioView # package's requires-python (>=3.12, <3.14). The older 23.08 runtime shipped # Python 3.11 and so failed to install the packages. app-id: org.bioview.BioView runtime: org.freedesktop.Platform runtime-version: '24.08' sdk: org.freedesktop.Sdk command: bioview finish-args: - --share=ipc - --share=network # localhost + LAN server/client sockets - --socket=x11 - --socket=fallback-x11 - --socket=wayland - --device=all # USB access for USRP devices - --filesystem=home # user-chosen recording directories # Allow network access during the build so pip/cmake/b2 can fetch what they need. build-options: build-args: - --share=network modules: # --- libusb (USB backend for UHD) ------------------------------------------ - name: libusb buildsystem: autotools sources: - type: git url: https://github.com/libusb/libusb.git tag: v1.0.27 # --- Boost (UHD build/runtime dependency) ---------------------------------- - name: boost buildsystem: simple build-commands: # UHD's CMake always requires boost_unit_test_framework even with ENABLE_TESTS=OFF. # In Boost 1.83+ the b2 library name is "test" (not unit_test_framework). - ./bootstrap.sh --prefix=/app --with-libraries=program_options,system,filesystem,thread,date_time,chrono,atomic,regex,serialization,test - ./b2 -j ${FLATPAK_BUILDER_N_JOBS} install sources: - type: git url: https://github.com/boostorg/boost.git tag: boost-1.83.0 # --- Python build helpers needed to compile the UHD Python API ------------- - name: uhd-build-deps buildsystem: simple build-commands: - pip3 install --prefix=/app mako numpy setuptools wheel # --- UHD with Python bindings + FPGA images -------------------------------- - name: uhd buildsystem: cmake-ninja subdir: host config-opts: - -DENABLE_PYTHON_API=ON - -DENABLE_TESTS=OFF - -DENABLE_MANUAL=OFF - -DENABLE_DOXYGEN=OFF - -DENABLE_EXAMPLES=OFF - -DPYTHON_EXECUTABLE=/usr/bin/python3 - -DCMAKE_INSTALL_PREFIX=/app post-install: # Bundle the FPGA/firmware images so USRPs work with no external download. # UHD looks in /share/uhd/images by default. - /app/bin/uhd_images_downloader || true sources: - type: git url: https://github.com/EttusResearch/uhd.git tag: v4.10.0.0 # --- BioView Python/Qt runtime dependencies -------------------------------- - name: python-deps buildsystem: simple build-commands: # Pin the Qt stack to the same versions BioView is tested against (matches # bioview-client's constraints) so the Flatpak builds a known-good combo. - pip3 install --prefix=/app "PyQt6>=6.9.1,<7.0.0" "pyqtgraph>=0.13.7,<0.14.0" "qtawesome>=1.4.0,<2.0.0" "pyqtdarktheme2>=2.1.2,<3.0.0" "darkdetect>=0.7.1,<0.8.0" numpy scipy h5py pygame # --- The three BioView packages + desktop integration ---------------------- - name: bioview buildsystem: simple build-commands: - pip3 install --prefix=/app --no-deps ./bioview-common - pip3 install --prefix=/app --no-deps ./bioview-server - pip3 install --prefix=/app --no-deps ./bioview-client - install -Dm644 org.bioview.BioView.desktop /app/share/applications/org.bioview.BioView.desktop - install -Dm644 org.bioview.BioView.metainfo.xml /app/share/metainfo/org.bioview.BioView.metainfo.xml - install -Dm644 icon.png /app/share/icons/hicolor/256x256/apps/org.bioview.BioView.png sources: - type: git url: https://github.com/bioview/bioview-common.git tag: v0.9.7.3 dest: bioview-common - type: git url: https://github.com/bioview/bioview-server.git tag: v0.9.7.3 dest: bioview-server - type: git url: https://github.com/bioview/bioview-client.git tag: v0.9.7.3 dest: bioview-client - type: file path: org.bioview.BioView.desktop - type: file path: org.bioview.BioView.metainfo.xml - type: file path: ../assets/icon.png