-
Notifications
You must be signed in to change notification settings - Fork 7.5k
[dbus-cxx] add new port #47617
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[dbus-cxx] add new port #47617
Changes from 2 commits
9b1491f
59e757a
79c8780
10dbe31
328c1d6
1ac63de
1c39d17
d4b0d99
643a471
b909b83
4820c3f
9b5fde7
99acc6f
e86d0e8
4996c74
c3f3277
3365b5b
00287dc
3b48cc4
d92505b
81c77cc
5eba7aa
f8802a7
5fd03a3
485dd71
8ebfc64
82241f8
dd76bef
41bdbf0
5ab6b01
a89301e
1dd5be7
714841b
973bd70
18eccc2
3d89bd1
8ea6a34
2d5fd42
959c5ee
9069cd6
acfcd42
4d4d09a
bb0fd02
a0c6df8
aae0b1d
bb537c8
8480251
a8620c5
92fa113
b7e6457
9661198
74086ef
426d409
e1bf1f0
9dd3832
970ad64
7d5cd2a
48d925e
f4149d0
b141975
9e46379
8f5f78f
17d9e39
f18ab28
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,39 @@ | ||
| vcpkg_check_linkage(ONLY_DYNAMIC_LIBRARY) | ||
|
|
||
| vcpkg_from_github( | ||
| OUT_SOURCE_PATH SOURCE_PATH | ||
| REPO dbus-cxx/dbus-cxx | ||
| REF "${VERSION}" | ||
| SHA512 ad6551d03d0c7d499e9f0c6d77584e39d361a1464017be3c40c237d4c43306ad0ffb49b52c06b89cd62ec7346ebcb29f3d166a31b245fd978159e337a08ebafb | ||
| HEAD_REF master | ||
| ) | ||
|
|
||
| vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS | ||
| FEATURES | ||
| "glib" ENABLE_GLIB_SUPPORT # Build dbus-cxx with GLib module | ||
| "qt5" ENABLE_QT_SUPPORT # Build dbus-cxx with QT5 module | ||
| "libuv" ENABLE_UV_SUPPORT # Build dbus-cxx with libuv module | ||
| ) | ||
|
|
||
| if (EXISTS "${_VCPKG_INSTALLED_DIR}/${TARGET_TRIPLET}/lib/pkgconfig/libuv-static.pc") | ||
|
luadebug marked this conversation as resolved.
Outdated
|
||
| set(UV_STATIC ON) | ||
| else () | ||
| set(UV_STATIC OFF) | ||
| endif () | ||
|
|
||
| vcpkg_cmake_configure( | ||
| SOURCE_PATH "${SOURCE_PATH}" | ||
| OPTIONS | ||
| ${FEATURE_OPTIONS} | ||
| -DBUILD_TESTING=OFF | ||
| -DENABLE_CODE_COVERAGE_REPORT=OFF | ||
| -DENABLE_EXAMPLES=OFF | ||
| -DENABLE_TOOLS=OFF | ||
| -DBUILD_SITE=OFF | ||
| -DUV_STATIC=${UV_STATIC} | ||
| ) | ||
|
|
||
| vcpkg_cmake_install() | ||
| vcpkg_cmake_config_fixup(CONFIG_PATH "lib/cmake/dbus-cxx") | ||
| vcpkg_copy_pdbs() | ||
| vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/COPYING") | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| { | ||
| "name": "dbus-cxx", | ||
| "version": "2.6.0", | ||
| "description": "DBus-cxx provides an object-oriented interface to DBus.", | ||
| "homepage": "https://dbus-cxx.github.io/", | ||
| "license": "LGPL-3.0-or-later AND BSD-3-Clause", | ||
| "supports": "linux", | ||
| "dependencies": [ | ||
| "libsigcpp", | ||
| { | ||
| "name": "vcpkg-cmake", | ||
| "host": true | ||
| }, | ||
| { | ||
| "name": "vcpkg-cmake-config", | ||
| "host": true | ||
| } | ||
| ], | ||
| "default-features": [ | ||
| "glib", | ||
| "libuv", | ||
| "qt5" | ||
| ], | ||
|
luadebug marked this conversation as resolved.
Comment on lines
+19
to
+23
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @JavierMatosD Why is this set of default-features acceptable here and rejected in other proposal? An application wouldn't use three different dispatchers at the same time.
https://dbus-cxx.github.io/ > Features And all three options are off by default upstream.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. They are not acceptable. This was an oversight on my part and should not have been merged in its current form.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Reverting this PR @luadebug, please reopen this PR and note we generally try to avoid using "default-features" as it was intended to only provide the minimum required for the port to be usable but default features can be difficult to disable downstream. I recommend taking a look at our docs on default features: https://learn.microsoft.com/en-us/vcpkg/concepts/default-features#role-of-default-features and its constraints https://learn.microsoft.com/en-us/vcpkg/contributing/maintainer-guide#default-features-should-enable-behaviors-not-apis |
||
| "features": { | ||
| "glib": { | ||
| "description": "Build dbus-cxx with GLib module", | ||
| "dependencies": [ | ||
| "glib" | ||
| ] | ||
| }, | ||
| "libuv": { | ||
| "description": "Build dbus-cxx with libuv module", | ||
| "dependencies": [ | ||
| "libuv" | ||
| ] | ||
| }, | ||
| "qt5": { | ||
| "description": "Build dbus-cxx with QT5 module", | ||
| "dependencies": [ | ||
| "qt5" | ||
| ] | ||
| } | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| set(VCPKG_POLICY_EMPTY_PACKAGE enabled) | ||
| vcpkg_cmake_configure( | ||
| SOURCE_PATH "${CURRENT_PORT_DIR}/project" | ||
| ) | ||
| vcpkg_cmake_build() |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| cmake_minimum_required(VERSION 3.25.1) | ||
| project(dbus-cxx-test CXX) | ||
| set(CMAKE_CXX_STANDARD 17) | ||
| find_package (dbus-cxx REQUIRED CONFIG) | ||
| add_executable(main main.cpp) | ||
| target_link_libraries(main PRIVATE dbus-cxx::dbus-cxx) |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| #include <dbus-cxx.h> | ||
| int main() | ||
| { | ||
| auto connection = DBus::Connection::create(DBus::BusType::SESSION); | ||
| return 0; | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| { | ||
| "name": "vcpkg-ci-dbus-cxx", | ||
| "version-string": "ci", | ||
| "description": "Validates dbus-cxx", | ||
| "dependencies": [ | ||
| "dbus-cxx", | ||
| { | ||
| "name": "vcpkg-cmake", | ||
| "host": true | ||
| } | ||
| ] | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| { | ||
| "versions": [ | ||
| { | ||
| "git-tree": "99904d636d5ea68d7a521343463323d6490a009d", | ||
| "version": "2.6.0", | ||
| "port-version": 0 | ||
| } | ||
| ] | ||
| } |
Uh oh!
There was an error while loading. Please reload this page.