build: Replace missing crates.io dependency with Purism-hosted one
This commit is contained in:
@ -29,4 +29,4 @@ features = ["v3_22"]
|
||||
|
||||
[dependencies.gtk-sys]
|
||||
version = "0.9"
|
||||
features = ["v3_22"]
|
||||
features = ["v3_22"]
|
||||
4
Cargo.deps.online
Normal file
4
Cargo.deps.online
Normal file
@ -0,0 +1,4 @@
|
||||
# Dependencies which are only used with online, crates.io builds.
|
||||
[patch.crates-io]
|
||||
# Dependency was yanked, but gio 0.7 needs it.
|
||||
fragile = { git = "https://source.puri.sm/dorota.czaplejewicz/fragile.git", tag = "0.3.0" }
|
||||
1
debian/cargo/config
vendored
1
debian/cargo/config
vendored
@ -9,4 +9,3 @@ replace-with = 'vendored-sources'
|
||||
|
||||
[source.vendored-sources]
|
||||
directory = '/usr/share/cargo/registry'
|
||||
|
||||
|
||||
2
debian/rules
vendored
2
debian/rules
vendored
@ -38,6 +38,6 @@ endif
|
||||
# causing Cargo to refuse to build with a crates.io copy
|
||||
override_dh_auto_configure:
|
||||
[ ! -f Cargo.lock ] || rm Cargo.lock
|
||||
dh_auto_configure -- -Dnewer=$(newer)
|
||||
dh_auto_configure -- -Dnewer=$(newer) -Donline=false
|
||||
|
||||
override_dh_autoreconf:
|
||||
|
||||
12
meson.build
12
meson.build
@ -96,19 +96,23 @@ cargo_toml_base = configure_file(
|
||||
configuration: path_data,
|
||||
)
|
||||
|
||||
|
||||
cargo_deps = files('Cargo.deps')
|
||||
cargo_patch = []
|
||||
|
||||
if get_option('newer') == true
|
||||
cargo_build_flags += ['--features', 'glib_v0_14']
|
||||
cargo_deps = files('Cargo.deps.newer')
|
||||
else
|
||||
cargo_deps = files('Cargo.deps')
|
||||
if get_option('online') == true
|
||||
cargo_patch = [files('Cargo.deps.online')]
|
||||
endif
|
||||
endif
|
||||
|
||||
|
||||
cat = find_program('cat')
|
||||
cargo_toml = custom_target(
|
||||
'Cargo.toml',
|
||||
output: 'Cargo.toml',
|
||||
command: [cat, cargo_toml_base, cargo_deps],
|
||||
command: [cat, cargo_toml_base, cargo_deps] + cargo_patch,
|
||||
capture: true,
|
||||
)
|
||||
|
||||
|
||||
@ -11,6 +11,10 @@ option('newer',
|
||||
type: 'boolean', value: false,
|
||||
description: 'Build with dependencies newer than those of Byzantium')
|
||||
|
||||
option('online',
|
||||
type: 'boolean', value: true,
|
||||
description: 'Pull packages from the internet while building, as opposed to a local regstry.')
|
||||
|
||||
option('strict',
|
||||
type: 'boolean', value: true,
|
||||
description: 'Turn more warnings into errors')
|
||||
|
||||
Reference in New Issue
Block a user