Merge pull request #440 from kiwix/add_docoptcpp_dep
This commit is contained in:
commit
acf66e36af
|
@ -132,6 +132,7 @@ class ReleaseDownload(Source):
|
||||||
|
|
||||||
class GitClone(Source):
|
class GitClone(Source):
|
||||||
base_git_ref = "master"
|
base_git_ref = "master"
|
||||||
|
force_full_clone = False
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def release_git_ref(self):
|
def release_git_ref(self):
|
||||||
|
@ -156,7 +157,7 @@ class GitClone(Source):
|
||||||
return self.base_git_ref
|
return self.base_git_ref
|
||||||
|
|
||||||
def _git_init(self, context):
|
def _git_init(self, context):
|
||||||
if option('fast_clone'):
|
if option('fast_clone') and self.force_full_clone == False:
|
||||||
command = "git clone --depth=1 --branch {} {} {}".format(
|
command = "git clone --depth=1 --branch {} {} {}".format(
|
||||||
self.git_ref, self.git_remote, self.source_dir)
|
self.git_ref, self.git_remote, self.source_dir)
|
||||||
run_command(command, neutralEnv('source_dir'), context)
|
run_command(command, neutralEnv('source_dir'), context)
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
from .base import (
|
from .base import (
|
||||||
Dependency,
|
Dependency,
|
||||||
ReleaseDownload,
|
GitClone,
|
||||||
CMakeBuilder)
|
CMakeBuilder)
|
||||||
|
|
||||||
from kiwixbuild.utils import Remotefile
|
from kiwixbuild.utils import Remotefile
|
||||||
|
@ -10,10 +10,11 @@ from kiwixbuild.utils import Remotefile
|
||||||
class docoptcpp(Dependency):
|
class docoptcpp(Dependency):
|
||||||
name = 'docoptcpp'
|
name = 'docoptcpp'
|
||||||
|
|
||||||
class Source(ReleaseDownload):
|
class Source(GitClone):
|
||||||
archive = Remotefile('v0.6.2.tar.gz',
|
git_remote = "https://github.com/docopt/docopt.cpp.git"
|
||||||
'c05542245232420d735c7699098b1ea130e3a92bade473b64baf876cdf098a17',
|
git_dir = "docopt.cpp"
|
||||||
'https://github.com/docopt/docopt.cpp/archive/v0.6.2.tar.gz')
|
force_full_clone = True
|
||||||
|
git_ref = "3dd23e3280f213bacefdf5fcb04857bf52e90917"
|
||||||
|
|
||||||
class Builder(CMakeBuilder):
|
class Builder(CMakeBuilder):
|
||||||
make_install_target = 'install'
|
make_install_target = 'install'
|
||||||
|
|
Loading…
Reference in New Issue