Skip to content

Commit

Permalink
Fill package with source code and add dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
wroyca committed Jun 9, 2024
1 parent d2148ea commit ad727a7
Show file tree
Hide file tree
Showing 460 changed files with 72,869 additions and 5 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Continuous Integration
on:
push:
branches: [main]
pull_request:

jobs:
build:
runs-on: ubuntu-latest
container:
image: ghcr.io/${{ github.repository }}:latest

steps:
- uses: actions/checkout@v4
id: checkout
name: Setup checkout
with:
submodules: recursive

# BUG: required; build2 doesn't proceed with local "safe directory" from
# checkout.
#
- run: git config --global --add safe.directory '*'

# BUG: required; bdep will pass "-n/assumeno" to DNF when running under
# GitHub CI.
#
- run: sudo dnf install -y gtk4-devel glib2-devel appstream-devel

# BUG: FIXME: skip tests; GTK Tests will attempt to open display. This
# doesn't work when we're running in GitHub CI.
#
- run: |
bdep init -C @gcc cc config.cxx=g++ -- ?sys:gtk4-devel ?sys:glib2-devel ?sys:appstream-devel --sys-no-stub --sys-install
bdep update
bpkg bindist -d ../libadwaita-gcc/ libadwaita
- uses: actions/upload-artifact@v4
id: upload-artifact
with:
path: '/github/home/rpmbuild/RPMS/x86_64/**'
42 changes: 42 additions & 0 deletions .github/workflows/cr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Container Registry
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- uses: docker/login-action@v3
id: login
name: Setup login
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- uses: docker/metadata-action@v5
id: metadata
name: Setup metadata
with:
images: ghcr.io/${{ github.repository }}
tags: |
type=raw,value=latest
type=ref,event=branch
- uses: docker/setup-buildx-action@v3
id: setup-buildx
name: Setup build

- uses: docker/build-push-action@v5
id: build-push
name: Build and push
with:
push: true
tags: ${{ steps.metadata.outputs.tags }}
labels: ${{ steps.metadata.outputs.labels }}
cache-to: type=registry,ref=ghcr.io/${{ github.repository }}:buildcache,mode=max
cache-from: type=registry,ref=ghcr.io/${{ github.repository }}:buildcache
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "upstream"]
path = upstream
url = https://gitlab.gnome.org/GNOME/libadwaita.git
25 changes: 25 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
FROM registry.fedoraproject.org/fedora:latest

RUN <<-EOT
set -x # Print trace of simple commands.

dnf upgrade -y
dnf install -y \
--enablerepo=fedora-debuginfo,updates-debuginfo \
--disablerepo=updates-testing,updates-testing-debuginfo \
--setopt=install_weak_deps=False \
\
gcc \
gcc-c++ \
gcc-plugin-devel \
clang \
clang-tools-extra \
rpmdevtools \
\
dbus-x11 \
dbus-devel \
\
build2 \
bdep \
bpkg
EOT
9 changes: 4 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
# libadwaita - <SUMMARY>
# libadwaita - Building blocks for modern GNOME applications

This is a `build2` package repository for [`libadwaita`](https://<UPSTREAM-URL>),
a <SUMMARY-OF-FUNCTIONALITY>.
This is a `build2` package repository for [`libadwaita`](https://gitlab.gnome.org/GNOME/libadwaita), a GTK 4 library implementing the GNOME HIG, complementing GTK.

This file contains setup instructions and other details that are more
appropriate for development rather than consumption. If you want to use
`libadwaita` in your `build2`-based project, then instead see the accompanying
[`PACKAGE-README.md`](<PACKAGE>/PACKAGE-README.md) file.
[`PACKAGE-README.md`](libadwaita/PACKAGE-README.md) file.

The development setup for `libadwaita` uses the standard `bdep`-based workflow.
For example:
Expand All @@ -15,7 +14,7 @@ For example:
git clone .../libadwaita.git
cd libadwaita
bdep init -C @gcc cc config.cxx=g++
bdep init -C @gcc cc config.cxx=g++ -- ?sys:gtk4-devel ?sys:glib2-devel ?sys:appstream-devel --sys-no-stub --sys-install
bdep update
bdep test
```
6 changes: 6 additions & 0 deletions buildfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Glue buildfile that "pulls" all the packages in the project.
#
import pkgs = [dir_paths] $process.run_regex(\
cat $src_root/packages.manifest, '\s*location\s*:\s*(\S+)\s*', '\1')

./: $pkgs
25 changes: 25 additions & 0 deletions libadwaita/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Compiler/linker output.
#
*.d
*.t
*.i
*.i.*
*.ii
*.ii.*
*.o
*.obj
*.gcm
*.pcm
*.ifc
*.so
*.dylib
*.dll
*.a
*.lib
*.exp
*.pdb
*.ilk
*.exe
*.exe.dlls/
*.exe.manifest
*.pc
18 changes: 18 additions & 0 deletions libadwaita/PACKAGE-README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# libadwaita - A C library

This is a `build2` package for the [`libadwaita`](https://gitlab.gnome.org/GNOME/libadwaita) C library. It provides Building blocks for modern GNOME applications.

## Usage

To start using `libadwaita` in your project, add the following `depends`
value to your `manifest`, adjusting the version constraint as appropriate:

```
depends: libadwaita ^1.5.0
```

Then import the library in your `buildfile`:

```
import libs = libadwaita%lib{adwaita}
```
4 changes: 4 additions & 0 deletions libadwaita/build/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/config.build
/root/
/bootstrap/
build/
7 changes: 7 additions & 0 deletions libadwaita/build/bootstrap.build
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
project = libadwaita

using version
using config
using test
using install
using dist
6 changes: 6 additions & 0 deletions libadwaita/build/export.build
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
$out_root/
{
include libadwaita/
}

export $out_root/libadwaita/$import.target
12 changes: 12 additions & 0 deletions libadwaita/build/root.build
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Uncomment to suppress warnings coming from external libraries.
#
#c.internal.scope = current

using c

h{*}: extension = h
c{*}: extension = c

# The test target for cross-testing (running tests under Wine, etc).
#
test.target = $c.target
13 changes: 13 additions & 0 deletions libadwaita/buildfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# FIXME: rpaths will prevent tests from compiling. For some reason, the
# includes for GTK and Pango (among others) are stripped. e.g:
#
# gcc -DADWAITA_COMPILATION -DADW_LOG_DOMAIN="Adwaita" -D_FORTIFY_SOURCE=3 -D_GLIBCXX_ASSERTIONS -DLIBGTK_4_SHARED -DLIBPANGO_1_0_SHARED -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-6 -I/usr/include/freetype2 -DWITH_GZFILEOP -I/usr/include/libpng16 -DWITH_GZFILEOP -DLIBPANGOCAIRO_1_0_SHARED -DLIBGDK_PIXBUF_2_0_SHARED -I/usr/include/cairo -DWITH_GZFILEOP -I/usr/include/libpng16 -DWITH_GZFILEOP -I/usr/include/freetype2 -DWITH_GZFILEOP -DWITH_GZFILEOP -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-6 -I/usr/include/libxml2 -DWITH_GZFILEOP -DWITH_GZFILEOP -DWITH_GZFILEOP -I/usr/include/pixman-1 -DWITH_GZFILEOP -DWITH_GZFILEOP -DWITH_GZFILEOP -DWITH_GZFILEOP -DWITH_GZFILEOP -DWITH_GZFILEOP -DWITH_GZFILEOP -I/usr/include/cairo -DWITH_GZFILEOP -I/usr/include/libpng16 -DWITH_GZFILEOP -I/usr/include/freetype2 -DWITH_GZFILEOP -DWITH_GZFILEOP -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-6 -I/usr/include/libxml2 -DWITH_GZFILEOP -DWITH_GZFILEOP -DWITH_GZFILEOP -I/usr/include/pixman-1 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-6 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-6 -I/usr/include/graphene-1.0 -I/usr/lib64/graphene-1.0/include -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-6 -I/usr/include/appstream -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-6 -DWITH_GZFILEOP -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-6 -DWITH_GZFILEOP -I/usr/include/libmount -I/usr/include/blkid -Wall -O2 -fstack-protector-strong -std=c17 -finput-charset=UTF-8 -o build-installed/tests/about-window/test-about-window.o -c -x c /tmp/dist/libadwaita-1.5.0/tests/about-window/test-about-window.c
#
# For now, tests are disabled on CI and must be enabled manually when
# developping locally.

./: {*/ -build/ -tests/} doc{PACKAGE-README.md} manifest

# Don't install tests.
#
tests/: install = false
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-about-dialog.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-about-dialog.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-about-dialog.ui
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-about-window.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-about-window.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-about-window.ui
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-action-row-private.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-action-row.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-action-row.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-action-row.ui
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-alert-dialog.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-alert-dialog.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-alert-dialog.ui
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-animation-private.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-animation-target-private.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-animation-target.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-animation-target.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-animation-util.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-animation-util.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-animation.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-animation.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-application-window.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-application-window.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-application.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-application.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-avatar.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-avatar.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-back-button-private.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-back-button.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-banner.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-banner.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-banner.ui
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-bidi-private.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-bidi.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-bin.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-bin.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-bottom-sheet-private.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-bottom-sheet.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-breakpoint-bin-private.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-breakpoint-bin.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-breakpoint-bin.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-breakpoint-private.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-breakpoint.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-breakpoint.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-button-content.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-button-content.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-carousel-indicator-dots.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-carousel-indicator-dots.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-carousel-indicator-lines.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-carousel-indicator-lines.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-carousel.c
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-carousel.h
1 change: 1 addition & 0 deletions libadwaita/libadwaita/adw-clamp-layout.c
Loading

0 comments on commit ad727a7

Please sign in to comment.