Skip to content

Manifests

linglong.yaml is the description file of a Linglong project, which records the relevant information required for construction. Such as the name, version, source address, build dependencies, etc. of the build product.

Project directory structure

{project-root}
├── linglong.yaml
└── .linglong-target

{user-home}
└── .cache
    └── linglong-builder
        ├── repo
        └── layers

Field definitions

App meta infos

package:
  id: org.deepin.reader
  version: 5.9.17
  kind: app
  description: |
    reader for deepin os.
namedescription
descriptionDetailed description of the build product
idUnique name of the build product
kindThe type of the build product: app, runtime, lib, representing application, runtime, library in turn
versionversion of the build product

runtime

Describe the build and run dependencies of the application.

runtime:
  id: org.deepin.runtime
  version: 20.0.0
  # NOT IMPLEMENTATION NOW
  digest: 4d85525f09211381c77d2085c9c1057

It can also be written as:

runtime:
  id: org.deepin.Runtime/20.5.0
namedescription
idUnique name of the runtime
versionRuntime version
digest(not used yet, this field can be used to bind a unique version of the runtime (runtime)

Dependencies

Describes the build dependencies and runtime dependencies of the application.

depends:
  - id: libopenjp2
    version: 2.4.0
  - id: libopenjp
    version: 2.1.0
    type: runtime
  - id: djvu
    version: 3.5.28
    # NOT IMPLEMENTATION NOW
    digest: 381c77d2085c9c10574d85525f09211
namedescription
idUnique name of the dependency
typeThe type of the dependency, the type of runtime dependency, will be submitted with the build content
versionDependent version
digest(not used yet, this field can be used to bind a unique version of the dependency)

ll-builder will pull dependencies from the remote repository to the local when the project is built. If the dependency does not exist in the remote repository or cannot meet the requirements, you can add source and build content, and ll-builder will build and apply this type of dependency first to the project build.

depends: 
  - id: icu
    version: 63.1.0
    source:
      kind: git
      url: "https://github.com/linuxdeepin/deepin-reader.git"
      version: master
      commit: 3c651bcc40748fc5d02d9134fcaee14fda44ab62
    build:
      kind: autotools

source

Describe source information.

source:
  kind: git
  url: "https://github.com/linuxdeepin/deepin-reader.git"
  version: master
  commit: 3c651bcc40748fc5d02d9134fcaee14fda44ab62
  patch:
    -patches/fix-install-prefix-path.patch
    - patches/fix-lib-install-path.patch
namedescription
kindSource code type, optional types local, archive, git
urlSource address, fill in when the type is archive or git
versionSource branch version, fill in when the type is git
commitThe hash value of a source code commit, fill in when the type is git
patchSource patch path

build rules

Describe build rules.

build:
  kind: manual
  manual:
    configure: |
      mkdir build
      cd build
      qmake -r PREFIX=${PREFIX} ..
    build: |
      make -j
      make test
    install: |
      make -j install
build:
  kind: autotools
  manual:
    configure: |
      ./bootstrap.sh
namedescription
buildbuild rules at build time
configurebuild-time configure rules
installbuild-time install rules
kindBuild type, optional manual, autotools, cmake, qmake
manualBuild rules, when manual is declared, it means custom rules, that is, rewriting build, install, configure

variables

Describes the variables that can be used by the build, used with the build build.

variables:
  build_dir: |
  dest_dir: |
  conf_args: |
    --prefix=${PREFIX}
    --libdir=lib/${TRIPLET}
  extra_args: |
    --doc=enable
  jobs: |
    -j64

build:
  kind: manual
  manual:
    configure: |
      ./configure ${conf_args} ${extra_args}
    build: |
      make ${jobs}
    install: |
      make DESTDIR=${dest_dir} install
namedescription
build_dirBuilt-in variables, assigned in the variable field, used in the build field
dest_dirSame as build_dir
conf_argsSame as build_dir
extra_argsSame as build_dir
jobsSame as build_dir
PREFIXOne of the environment variables, which can be used under the variable and build fields; provide the installation path when building
TRIPLETOne of the environment variables, which can be used under the variable and build fields; provide a triple containing architecture information, such as x86_64-linux-gnu

complete example

Build app

package:
  id: org.deepin.reader
  version: 5.9.17
  kind: app
  description: |
    reader for deepin os.

runtime:
  id: org.deepin.runtime
  version: 20.0.0

depends:
  - id: libopenjp2
    version: 2.4.0
  - id: djvu
    version: 3.5.28

source:
  kind: git
  url: "https://github.com/linuxdeepin/deepin-reader.git"
  version: master
  commit: 3c651bcc40748fc5d02d9134fcaee14fda44ab62

build:
  kind: qmake

Build dependencies

package:
   id: libopenjp2
   kind: lib
   version: 2.4.0

base:
   id: org.deepin.base
   version: 20.5.0

source:
   kind: git
   url: https://github.com/uclouvain/openjpeg
   version: 2.4.0
   commit: 37ac30ceff6640bbab502388c5e0fa0bff23f505

build:
   kind: cmake

Build runtime

package:
   id: org.deepin.Runtime
   kind: runtime
   version: 20.5.0
   description: |
     runtime of deepin

base:
   id: org.deepin.base/20.5.0

depends:
   - id: qtbase/5.11.3.15
   - id: qttool/5.11.3
   - id: qtx11extras/5.11.3
   - id: qtsvg/5.11.3
   - id: qtxdg/3.5.0
   - id: qtmultimedia/5.11.3
   - id: "gsettings-qt/0.2"
   - id: dtkcommon/5.5.21
   - id: dtkcore/5.5.27
   - id: dtkgui/5.5.22
   - id: dtkwidget/5.5.40
   - id: "qt5platform-plugins/5.0.46"
   - id: qt5integration/5.5.19

build:
   kind: manual
   manual:
     configure: |
       echo skip configure

When the package type is runtime, all dependencies will be submitted.

build tools template

automake type build template

autotools.yaml provides a generic automake type build template, the template file is as follows:

variables:
   build_dir: build_dir
   conf_args: |
     --prefix=${PREFIX} \
     --libdir=${PREFIX}/lib/${TRIPLET}
   extra_args: |
   dest_dir: |
   jobs: -j${JOBS}

build:
   kind: autotools
   manual:
     configure: |
       #autogon.sh, bootstrap.sh
       autoreconf -ivf
       ./configure ${conf_args} ${extra_args}
     build: |
       make ${jobs}
     install: |
       make ${jobs} DESTDIR=${dest_dir} install

build tool:

build:
   kind: autotools

qmake build template

qmake.yaml provides a generic qmake build template, the template file is as follows:

variables:
   build_dir: build_dir
   conf_args: |
     PREFIX=${PREFIX} \
     LIB_INSTALL_DIR=${PREFIX}/lib/${TRIPLET}
   extra_args: |
   dest_dir: |
   jobs: -j${JOBS}

build:
   kind: qmake
   manual :
     configure: |
       qmake -makefile ${conf_args} ${extra_args}
     build: |
       make ${jobs}
     install: |
       make ${jobs} DESTDIR=${dest_dir} install

build tool:

build:
   kind: qmake

cmake build templates

cmake.yaml provides a generic cmake build template, the template file is as follows:

variables:
   build_dir: build_dir
   conf_args: |
     -DCMAKE_INSTALL_PREFIX=${PREFIX} \
     -DCMAKE_INSTALL_LIBDIR=${PREFIX}/lib/${TRIPLET}
   extra_args: |
   dest_dir: |
   jobs: -j${JOBS}

build:
   kind: cmake
   manual :
     configure: |
       cmake -B ${build_dir} ${conf_args} ${extra_args}
     build: |
       cmake --build ${build_dir} -- ${jobs}
     install: |
       env DESTDIR=${dest_dir} cmake --build ${build_dir} --target install

build tool:

build:
   kind: cmake

runtime 20.5.0 includes dependencies

idversion
qtbase5.11.3.15
qt3d5.11.3
qtcharts5.11.3
qtconnectivity5.11.3
qtgamepad5.11.3
qtsensors5.11.3
qtspeech5.11.3
qtvirtualkeyboard5.11.3
qtserialport5.11.3
qtnetworkauth5.11.3
qttools5.11.3
qtx11extras5.11.3
qtdeclarative5.11.3
qtsvg5.11.3
qtscript5.11.3
qtgraphicaleffects5.11.3
qtquickcontrols5.11.3
qtquickcontrols25.11.3
qtxmlpatterns5.11.3
qtwayland5.15.1.7
qtmultimedia5.11.3
qtwebchannel5.11.3
qtwebsockets5.11.3
qtimageformats5.11.3
qtlocation5.11.3
dtkcommon5.5.3
dtkcore5.5.26
dtkgui5.5.22
dtkwidget5.5.39
dtkdeclarative5.0.1
qtxdg3.3.1.1
qt5integration5.1.17
double-conversion3.1.0.2
deepin-shortcut-viewer5.0.5
fcitx-qt51.2.6.4
gsettings-qt0.2
qt5platform-plugins5.0.58

Other available dependencies

idversion
aria21.34.0
bzip21.0.6
cdparanoia3.10.2
dde-control-center5.5.23
dde-dock5.5.15
disomaster5.0.7
djvulibre3.5.27.1
ffmpeg4.1.8
ffmpegthumbnailer2.1.1
freeimage3.18.0
gio-qt0.0.11
gst-plugins-good1.01.14.5
gstreamer1.01.14.6
ilmbase2.2.1
image-editor1.0.9
jxrlib1.1.1
karchive5.54.0
kcodecs5.54.0
kconfig5.54.0
kcoreaddons5.54.0
kcrash5.54.0
kdbusaddons5.54.0
kglobalaccel5.54.0
ki18n5.54.0
kservice5.54.0
ksyntax-highlighting5.54.0
kwayland5.57.0
kwindowsystem5.54.0
leveldb1.20
libarchive3.3.3
libchardet1.0.4
libdbusmenu-qt0.9.3
libdmr5.9.13
libdv1.0.0
libepoxy1.5.3
libevent2.1.8
libraw0.19.2
libvisual0.4.0
libxrandr1.5.1
libxtst5.5.15
libzip1.5.1.8
minizip1.1.1
mpv0.29.1.37
opencv3.2.0
openexr2.2.1.4
procps3.3.15
qtdbusextended0.0.3
qtmpris0.1.0.1
sqlite33.27.2.3
taglib1.11.1
uchardet0.0.6
udisks2-qt55.0.3
vlc3.0.11
xcb-util0.3.8.1
icu63.1
dde-qt-dbus-factory5.5.12
gst-plugins-base1.01.14.4.2
libdvdnav6.0.0
libdvdread6.0.0
libical33.0.4
libva2.4.0
libxcursor1.1.15
orc0.4.28
poppler0.71.0.2
kmod26.1
pciutils3.5.2.4
xz-utils5.2.4.1
libxslt1.1.32.3
v4l-utils1.20.0
portaudio1919.6.0
gst-plugins-bad1.01.14.4.2
gst-plugins-ugly1.01.14.4.2
nettle3.4.1.2
aom1.0.0.1
codec20.8.1
libdc13942.2.5
libmysofa0.6
x2640.155.2917
x2652.9
xavs21.4.1
cunit2.1
lapack3.8.0.1
openblas0.3.5
crystalhd0.0.1
davs21.7.1
elfutils0.176.2