diff --git a/.github/workflows/ni_upload_to_jfrog.yml b/.github/workflows/ni_upload_to_jfrog.yml index fb785dc453daf1..374e87a1990591 100644 --- a/.github/workflows/ni_upload_to_jfrog.yml +++ b/.github/workflows/ni_upload_to_jfrog.yml @@ -31,3 +31,7 @@ jobs: # add the -pre repo - run: conan remote add rnd-conan-pre ${{ env.REPO_PRE }} - run: conan remote login rnd-conan-pre ${{ vars.JFROG_USERNAME }} --password ${{ secrets.JFROG_ACCESS_TOKEN }} + # upload dbus-cxx + - run: conan create recipes/dbus-cxx/2.x.x --version 2.4.0 --build=missing + - run: conan upload --remote rnd-conan-ci --only-recipe dbus-cxx/2.4.0 + - run: conan upload --remote rnd-conan-pre --only-recipe dbus-cxx/2.4.0 diff --git a/recipes/dbus-cxx/2.x.x/conandata.yml b/recipes/dbus-cxx/2.x.x/conandata.yml index b9937eb9cad90a..81db1901fadb69 100644 --- a/recipes/dbus-cxx/2.x.x/conandata.yml +++ b/recipes/dbus-cxx/2.x.x/conandata.yml @@ -1,4 +1,5 @@ sources: "2.4.0": - url: "https://github.com/dbus-cxx/dbus-cxx/archive/refs/tags/2.4.0.tar.gz" - sha256: "c38456ed70023d93e6e689087e4bbe030f1650bbda9de7c035d6f4ebac788379" + url: "https://github.com/ni/dbus-cxx" + sha: "52460c2e2ef1c8f522b36d8cc9db312f98f855ff" + diff --git a/recipes/dbus-cxx/2.x.x/conanfile.py b/recipes/dbus-cxx/2.x.x/conanfile.py index 02438ffb8c8afe..f570c13c0595c1 100644 --- a/recipes/dbus-cxx/2.x.x/conanfile.py +++ b/recipes/dbus-cxx/2.x.x/conanfile.py @@ -1,6 +1,6 @@ from conan import ConanFile from conan.tools.cmake import cmake_layout, CMake -import conan.tools.files +import conan.tools.scm class DbusCXX(ConanFile): name = "dbus-cxx" @@ -28,13 +28,24 @@ def requirements(self): self.requires("libsigcpp/[^3.0.7]", transitive_headers=True) self.requires("expat/[^2.5.0]") + # Our branch presumes libuv. This should be replaced by an + # option upstream eventually + self.requires("libuv/[>=1.0 <2.0]") + def source(self): - conan.tools.files.get(self, **self.conan_data["sources"][self.version], strip_root=True) + # Note: We don't use a conditional for our customization + # because Conan does not allow conditionals in the source() + # method (conan caches sources independent of the configuration). + git = conan.tools.scm.Git(self) + git.clone(url=self.conan_data["sources"][self.version]["url"], target=".") + git.checkout(commit=self.conan_data["sources"][self.version]["sha"]) def layout(self): cmake_layout(self) - generators = "CMakeToolchain", "PkgConfigDeps" + # Our branch changed to find_package(). We should change back + # and drop this customization + generators = "CMakeToolchain", "CMakeDeps" def build(self): cmake = CMake(self) @@ -46,5 +57,11 @@ def package(self): cmake.install() def package_info(self): + # Our branch adds the libuv integration which should be made + # an option upstream + self.cpp_info.libs.append("dbus-cxx-uv") + self.cpp_info.libs.append("dbus-cxx") - self.cpp_info.includedirs = ['include/dbus-cxx-2.0'] + + # Our branch drops the versioned include path. We should + # restore that and drop this customization