Live video on the AT Protocol

iroh: possibly-working meson compilation?

+7 -15
+1
Cargo.toml
··· 1 [workspace] 2 resolver = "3" 3 members = ["rust/iroh-streamplace"]
··· 1 [workspace] 2 resolver = "3" 3 members = ["rust/iroh-streamplace"] 4 + exclude = ["subprojects/c2pa_go"]
+2 -6
meson.build
··· 80 ) 81 c2pa_go_dep = c2pa_go_proj.get_variable('c2pa_go_dep') 82 83 - iroh_streamplace_opts = {} 84 - triple = meson.get_external_property('RUST_TRIPLE', '') 85 - if triple != '' 86 - iroh_streamplace_opts += {'RUST_TRIPLE': triple} 87 - endif 88 - 89 streamplace_deps = [] 90 # if host_machine.system() == 'linux' 91 # mistserver_proj = subproject( ··· 236 build_always_stale: true, 237 env: env, 238 ) 239 240 if host_machine.system() == 'darwin' 241 streamplace_deps += [dependency('appleframeworks', modules: ['CoreFoundation', 'Security', 'SystemConfiguration'])]
··· 80 ) 81 c2pa_go_dep = c2pa_go_proj.get_variable('c2pa_go_dep') 82 83 streamplace_deps = [] 84 # if host_machine.system() == 'linux' 85 # mistserver_proj = subproject( ··· 230 build_always_stale: true, 231 env: env, 232 ) 233 + 234 + subdir('rust/iroh-streamplace') 235 236 if host_machine.system() == 'darwin' 237 streamplace_deps += [dependency('appleframeworks', modules: ['CoreFoundation', 'Security', 'SystemConfiguration'])]
+2 -1
pkg/iroh/iroh_streamplace.go
··· 4 _ "stream.place/streamplace/pkg/iroh/generated/iroh_streamplace" 5 ) 6 7 - // #cgo LDFLAGS: -L../../target/release -liroh_streamplace -lm 8 // #cgo darwin LDFLAGS: -framework Security -framework SystemConfiguration 9 import "C"
··· 4 _ "stream.place/streamplace/pkg/iroh/generated/iroh_streamplace" 5 ) 6 7 + // #cgo LDFLAGS: -lm 8 + // #cgo pkg-config: streamplacedeps-uninstalled 9 // #cgo darwin LDFLAGS: -framework Security -framework SystemConfiguration 10 import "C"
+1 -1
pkg/iroh/iroh_streamplace_test.go
··· 5 6 "github.com/stretchr/testify/assert" 7 8 - iroh "github.com/n0-computer/iroh-streamplace/pkg/iroh_streamplace/generated/iroh_streamplace" 9 ) 10 11 type TestHandler struct {
··· 5 6 "github.com/stretchr/testify/assert" 7 8 + iroh "stream.place/streamplace/pkg/iroh/generated/iroh_streamplace" 9 ) 10 11 type TestHandler struct {
+1 -6
rust/iroh-streamplace/meson.build
··· 1 - project( 2 - 'iroh-streamplace', 3 - default_options: ['default_library=static'], 4 - ) 5 - 6 prog_cargo = find_program('cargo') 7 8 cargo_cmd = '@0@ build --release --target-dir "@1@"'.format(prog_cargo.full_path(), meson.current_build_dir()) 9 archive_dir = meson.current_build_dir() 10 11 - triple = get_option('RUST_TRIPLE') 12 if triple != '' 13 cargo_cmd += ' --target @0@'.format(triple) 14 archive_dir += '/' + triple
··· 1 prog_cargo = find_program('cargo') 2 3 cargo_cmd = '@0@ build --release --target-dir "@1@"'.format(prog_cargo.full_path(), meson.current_build_dir()) 4 archive_dir = meson.current_build_dir() 5 6 + triple = meson.get_external_property('RUST_TRIPLE', '') 7 if triple != '' 8 cargo_cmd += ' --target @0@'.format(triple) 9 archive_dir += '/' + triple
-1
rust/iroh-streamplace/meson.options
··· 1 - option('RUST_TRIPLE', type : 'string', description : 'Rust triple for cross-compilation')
···