From ecdbfa032eca40c3b10725831d85a31d2d639f44 Mon Sep 17 00:00:00 2001 From: Erwin Nindl Date: Mon, 12 Aug 2024 20:40:56 +0200 Subject: [PATCH] (#24893) magic_enum/0.9.6: add legacy include directory --- recipes/magic_enum/all/conanfile.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/recipes/magic_enum/all/conanfile.py b/recipes/magic_enum/all/conanfile.py index b91a3af1cb2d9..9b0f3868a9d81 100644 --- a/recipes/magic_enum/all/conanfile.py +++ b/recipes/magic_enum/all/conanfile.py @@ -1,7 +1,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd -from conan.tools.files import copy, get, rmdir +from conan.tools.files import copy, get, mkdir, rmdir from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.scm import Version import os @@ -68,6 +68,9 @@ def build(self): def package(self): cmake = CMake(self) cmake.install() + if Version(self.version) >= "0.9.4" and Version(self.version) <= "0.9.6": + mkdir(self, os.path.join(self.package_folder, "include/magic_enum")) + copy(self, "*", src=os.path.join(self.package_folder, "include"), dst=os.path.join(self.package_folder, "include/magic_enum")) copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig"))