Skip to content

Commit

Permalink
Added parent folder for commit instead of recipe folder and BUILD_VOI…
Browse files Browse the repository at this point in the history
…CE_SUPPORT by default
  • Loading branch information
MikeRavenelle committed Jan 21, 2024
1 parent d5dd3f6 commit ffa9cd5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions conan/conanfile.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import os
from conan import ConanFile
from conan.tools.cmake import CMakeToolchain, CMake, cmake_layout, CMakeDeps
from conan.tools.scm import Git
from conan.tools.files import load, update_conandata

Check notice on line 5 in conan/conanfile.py

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

conan/conanfile.py#L5

'conan.tools.files.load' imported but unused (F401)

Check warning on line 5 in conan/conanfile.py

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

conan/conanfile.py#L5

Unused load imported from conan.tools.files

class DPPConan(ConanFile):
name = "dpp"
version = "0.1"
Expand Down Expand Up @@ -35,7 +36,7 @@ def layout(self):
cmake_layout(self)

def export(self):
git = Git(self, self.recipe_folder)
git = Git(self, os.path.dirname(self.recipe_folder))
scm_url, scm_commit = git.get_url_and_commit()
update_conandata(self, {"sources": {"commit": scm_commit, "url": scm_url}})

Expand All @@ -50,6 +51,7 @@ def generate(self):
deps.generate()
tc = CMakeToolchain(self)
tc.cache_variables["CONAN_EXPORTED"] = True
tc.cache_variables["BUILD_VOICE_SUPPORT"] = True
tc.generate()

def build(self):
Expand Down

0 comments on commit ffa9cd5

Please sign in to comment.