Nir Soffer
2021-Nov-02 20:15 UTC
[Libguestfs] [PATCH libnbd 0/2] Flatten the golang directory
Move the libnbd source to the golang directory to make the project easier to work with and publish. Nir Soffer (2): configure:golang: Cleanup golang check golang: Flatten source tree configure.ac | 10 +-- generator/generator.ml | 12 +-- .../libguestfs.org/libnbd => }/.gitignore | 0 .../{src/libguestfs.org/libnbd => }/LICENSE | 0 golang/Makefile.am | 86 +++++++++---------- .../{src/libguestfs.org/libnbd => }/README.md | 17 ++-- .../libguestfs.org/libnbd => }/aio_buffer.go | 0 .../libguestfs.org/libnbd => }/callbacks.go | 0 golang/configure/go.mod | 4 + golang/{config-test.go => configure/test.go} | 7 ++ golang/examples/get_size/go.mod | 2 +- golang/examples/read_first_sector/go.mod | 2 +- golang/{src/libguestfs.org/libnbd => }/go.mod | 0 .../{src/libguestfs.org/libnbd => }/handle.go | 0 .../libnbd => }/libnbd_010_load_test.go | 0 .../libnbd => }/libnbd_100_handle_test.go | 0 .../libnbd => }/libnbd_110_defaults_test.go | 0 .../libnbd_120_set_non_defaults_test.go | 0 .../libnbd_200_connect_command_test.go | 0 .../libnbd => }/libnbd_210_opt_abort_test.go | 0 .../libnbd => }/libnbd_220_opt_list_test.go | 0 .../libnbd => }/libnbd_230_opt_info_test.go | 0 .../libnbd_240_opt_list_meta_test.go | 0 .../libnbd => }/libnbd_300_get_size_test.go | 0 .../libnbd => }/libnbd_400_pread_test.go | 0 .../libnbd_405_pread_structured_test.go | 0 .../libnbd => }/libnbd_410_pwrite_test.go | 0 .../libnbd_460_block_status_test.go | 0 .../libnbd => }/libnbd_500_aio_pread_test.go | 0 .../libnbd => }/libnbd_510_aio_pwrite_test.go | 0 .../libnbd => }/libnbd_590_aio_copy_test.go | 0 .../libnbd_600_debug_callback_test.go | 0 .../libnbd => }/libnbd_610_error_test.go | 0 golang/run-tests.sh | 2 - 34 files changed, 73 insertions(+), 69 deletions(-) rename golang/{src/libguestfs.org/libnbd => }/.gitignore (100%) rename golang/{src/libguestfs.org/libnbd => }/LICENSE (100%) rename golang/{src/libguestfs.org/libnbd => }/README.md (71%) rename golang/{src/libguestfs.org/libnbd => }/aio_buffer.go (100%) rename golang/{src/libguestfs.org/libnbd => }/callbacks.go (100%) create mode 100644 golang/configure/go.mod rename golang/{config-test.go => configure/test.go} (95%) rename golang/{src/libguestfs.org/libnbd => }/go.mod (100%) rename golang/{src/libguestfs.org/libnbd => }/handle.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_010_load_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_100_handle_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_110_defaults_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_120_set_non_defaults_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_200_connect_command_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_210_opt_abort_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_220_opt_list_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_230_opt_info_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_240_opt_list_meta_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_300_get_size_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_400_pread_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_405_pread_structured_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_410_pwrite_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_460_block_status_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_500_aio_pread_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_510_aio_pwrite_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_590_aio_copy_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_600_debug_callback_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_610_error_test.go (100%) -- 2.31.1
Nir Soffer
2021-Nov-02 20:15 UTC
[Libguestfs] [PATCH libnbd 1/2] configure:golang: Cleanup golang check
Move the configure test module to configure/test.go, and create new module for this directory, so it does not clash with the real libnbd module, that I want to move up to the golang/ directory. Instead of running "go version", print runtime.Version() in the test program. $ go run golang/configure/test.go go1.16.8 Instead of running "go help modules" for checking if modules are supported, using "go mod tidy". This will fail if the installed go version is to old, since the go.mod file specify go 1.13, like the real libnbd go.mod. $ (cd golang/configure/ && go mod tidy) go mod tidy: go.mod file indicates go 1.17, but maximum supported version is 1.16 I did not try to verify the go version, since it seems impossible given the crazy versioning. However if we want to verify the version we can do this using the test output outside of go. Signed-off-by: Nir Soffer <nsoffer at redhat.com> --- configure.ac | 10 +++++----- golang/Makefile.am | 3 ++- golang/configure/go.mod | 4 ++++ golang/{config-test.go => configure/test.go} | 7 +++++++ 4 files changed, 18 insertions(+), 6 deletions(-) create mode 100644 golang/configure/go.mod rename golang/{config-test.go => configure/test.go} (95%) diff --git a/configure.ac b/configure.ac index 82ac5ea..e1a0198 100644 --- a/configure.ac +++ b/configure.ac @@ -508,12 +508,12 @@ AS_IF([test "x$enable_golang" != "xno"],[ AC_CHECK_PROG([GOLANG],[go],[go],[no]) AS_IF([test "x$GOLANG" != "xno"],[ AC_MSG_CHECKING([if $GOLANG is usable]) - AS_IF([ $GOLANG run $srcdir/golang/config-test.go 2>&AS_MESSAGE_LOG_FD && \ - $GOLANG help modules 2>&AS_MESSAGE_LOG_FD 1>&2 ],[ + AS_IF([ ( + cd $srcdir/golang/configure + $GOLANG run . 2>&AS_MESSAGE_LOG_FD 1>&2 + $GOLANG mod tidy 2>&AS_MESSAGE_LOG_FD 1>&2 + ) ],[ AC_MSG_RESULT([yes]) - - # Print the version to help with debugging. - $GOLANG version ],[ AC_MSG_RESULT([no]) AC_MSG_WARN([golang ($GOLANG) is installed but not usable]) diff --git a/golang/Makefile.am b/golang/Makefile.am index 93089e2..397cae7 100644 --- a/golang/Makefile.am +++ b/golang/Makefile.am @@ -58,7 +58,8 @@ generator_built = \ EXTRA_DIST = \ $(generator_built) \ - config-test.go \ + configure/go.mod \ + configure/test.go \ libnbd-golang.pod \ run-tests.sh \ src/$(pkg)/.gitignore \ diff --git a/golang/configure/go.mod b/golang/configure/go.mod new file mode 100644 index 0000000..ce3e4f3 --- /dev/null +++ b/golang/configure/go.mod @@ -0,0 +1,4 @@ +module libguestfs.org/configure + +// First version of golang with working module support. +go 1.13 diff --git a/golang/config-test.go b/golang/configure/test.go similarity index 95% rename from golang/config-test.go rename to golang/configure/test.go index e104c71..53ce8ab 100644 --- a/golang/config-test.go +++ b/golang/configure/test.go @@ -22,7 +22,14 @@ package main +import ( + "fmt" + "runtime" +) + func main() { + fmt.Println(runtime.Version()) + /* XXX Check for minimum runtime.Version() >= "go1.1.1" * Unfortunately go version numbers are not easy to parse. * They have the 3 formats "goX.Y.Z", "release.rN" or -- 2.31.1
Nir Soffer
2021-Nov-02 20:15 UTC
[Libguestfs] [PATCH libnbd 2/2] golang: Flatten source tree
Move the libnbd module to the golang directory to make it easier to work with the source, and to match other bindings. I think that src/libguestfs.org/libnbd/ tree is left over from older Go versions using GOPATH. Modern Go uses modules so it does not matter where you put your source. With this change, we can add a nice tag for every release: golang/v1.11.2 This exposes the package version to "go get". This will also fix: https://pkg.go.dev/github.com/libguestfs/libnbd/golang This is not enough to consume the module directly from the source, we still have to solve the issue of the generated files, and returning the right metadata from https://libguestfs.org/libnbd. Signed-off-by: Nir Soffer <nsoffer at redhat.com> --- generator/generator.ml | 12 +-- .../libguestfs.org/libnbd => }/.gitignore | 0 .../{src/libguestfs.org/libnbd => }/LICENSE | 0 golang/Makefile.am | 83 +++++++++---------- .../{src/libguestfs.org/libnbd => }/README.md | 17 ++-- .../libguestfs.org/libnbd => }/aio_buffer.go | 0 .../libguestfs.org/libnbd => }/callbacks.go | 0 golang/examples/get_size/go.mod | 2 +- golang/examples/read_first_sector/go.mod | 2 +- golang/{src/libguestfs.org/libnbd => }/go.mod | 0 .../{src/libguestfs.org/libnbd => }/handle.go | 0 .../libnbd => }/libnbd_010_load_test.go | 0 .../libnbd => }/libnbd_100_handle_test.go | 0 .../libnbd => }/libnbd_110_defaults_test.go | 0 .../libnbd_120_set_non_defaults_test.go | 0 .../libnbd_200_connect_command_test.go | 0 .../libnbd => }/libnbd_210_opt_abort_test.go | 0 .../libnbd => }/libnbd_220_opt_list_test.go | 0 .../libnbd => }/libnbd_230_opt_info_test.go | 0 .../libnbd_240_opt_list_meta_test.go | 0 .../libnbd => }/libnbd_300_get_size_test.go | 0 .../libnbd => }/libnbd_400_pread_test.go | 0 .../libnbd_405_pread_structured_test.go | 0 .../libnbd => }/libnbd_410_pwrite_test.go | 0 .../libnbd_460_block_status_test.go | 0 .../libnbd => }/libnbd_500_aio_pread_test.go | 0 .../libnbd => }/libnbd_510_aio_pwrite_test.go | 0 .../libnbd => }/libnbd_590_aio_copy_test.go | 0 .../libnbd_600_debug_callback_test.go | 0 .../libnbd => }/libnbd_610_error_test.go | 0 golang/run-tests.sh | 2 - 31 files changed, 55 insertions(+), 63 deletions(-) rename golang/{src/libguestfs.org/libnbd => }/.gitignore (100%) rename golang/{src/libguestfs.org/libnbd => }/LICENSE (100%) rename golang/{src/libguestfs.org/libnbd => }/README.md (71%) rename golang/{src/libguestfs.org/libnbd => }/aio_buffer.go (100%) rename golang/{src/libguestfs.org/libnbd => }/callbacks.go (100%) rename golang/{src/libguestfs.org/libnbd => }/go.mod (100%) rename golang/{src/libguestfs.org/libnbd => }/handle.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_010_load_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_100_handle_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_110_defaults_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_120_set_non_defaults_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_200_connect_command_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_210_opt_abort_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_220_opt_list_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_230_opt_info_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_240_opt_list_meta_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_300_get_size_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_400_pread_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_405_pread_structured_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_410_pwrite_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_460_block_status_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_500_aio_pread_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_510_aio_pwrite_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_590_aio_copy_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_600_debug_callback_test.go (100%) rename golang/{src/libguestfs.org/libnbd => }/libnbd_610_error_test.go (100%) diff --git a/generator/generator.ml b/generator/generator.ml index 804d9ea..4192815 100644 --- a/generator/generator.ml +++ b/generator/generator.ml @@ -57,11 +57,7 @@ let () output_to "ocaml/NBD.ml" OCaml.generate_ocaml_nbd_ml; output_to "ocaml/nbd-c.c" OCaml.generate_ocaml_nbd_c; - output_to "golang/src/libguestfs.org/libnbd/bindings.go" - GoLang.generate_golang_bindings_go; - output_to "golang/src/libguestfs.org/libnbd/closures.go" - GoLang.generate_golang_closures_go; - output_to "golang/src/libguestfs.org/libnbd/wrappers.go" - GoLang.generate_golang_wrappers_go; - output_to "golang/src/libguestfs.org/libnbd/wrappers.h" - GoLang.generate_golang_wrappers_h; + output_to "golang/bindings.go" GoLang.generate_golang_bindings_go; + output_to "golang/closures.go" GoLang.generate_golang_closures_go; + output_to "golang/wrappers.go" GoLang.generate_golang_wrappers_go; + output_to "golang/wrappers.h" GoLang.generate_golang_wrappers_h; diff --git a/golang/src/libguestfs.org/libnbd/.gitignore b/golang/.gitignore similarity index 100% rename from golang/src/libguestfs.org/libnbd/.gitignore rename to golang/.gitignore diff --git a/golang/src/libguestfs.org/libnbd/LICENSE b/golang/LICENSE similarity index 100% rename from golang/src/libguestfs.org/libnbd/LICENSE rename to golang/LICENSE diff --git a/golang/Makefile.am b/golang/Makefile.am index 397cae7..1ceef1f 100644 --- a/golang/Makefile.am +++ b/golang/Makefile.am @@ -17,59 +17,56 @@ include $(top_srcdir)/subdir-rules.mk -# http://golang.org/doc/code.html#Organization -pkg = libguestfs.org/libnbd - source_files = \ - src/$(pkg)/aio_buffer.go \ - src/$(pkg)/bindings.go \ - src/$(pkg)/callbacks.go \ - src/$(pkg)/closures.go \ - src/$(pkg)/handle.go \ - src/$(pkg)/wrappers.go \ - src/$(pkg)/wrappers.h \ - src/$(pkg)/libnbd_010_load_test.go \ - src/$(pkg)/libnbd_100_handle_test.go \ - src/$(pkg)/libnbd_110_defaults_test.go \ - src/$(pkg)/libnbd_120_set_non_defaults_test.go \ - src/$(pkg)/libnbd_200_connect_command_test.go \ - src/$(pkg)/libnbd_210_opt_abort_test.go \ - src/$(pkg)/libnbd_220_opt_list_test.go \ - src/$(pkg)/libnbd_230_opt_info_test.go \ - src/$(pkg)/libnbd_240_opt_list_meta_test.go \ - src/$(pkg)/libnbd_300_get_size_test.go \ - src/$(pkg)/libnbd_400_pread_test.go \ - src/$(pkg)/libnbd_405_pread_structured_test.go \ - src/$(pkg)/libnbd_410_pwrite_test.go \ - src/$(pkg)/libnbd_460_block_status_test.go \ - src/$(pkg)/libnbd_500_aio_pread_test.go \ - src/$(pkg)/libnbd_510_aio_pwrite_test.go \ - src/$(pkg)/libnbd_590_aio_copy_test.go \ - src/$(pkg)/libnbd_600_debug_callback_test.go \ - src/$(pkg)/libnbd_610_error_test.go \ + aio_buffer.go \ + bindings.go \ + callbacks.go \ + closures.go \ + handle.go \ + wrappers.go \ + wrappers.h \ + libnbd_010_load_test.go \ + libnbd_100_handle_test.go \ + libnbd_110_defaults_test.go \ + libnbd_120_set_non_defaults_test.go \ + libnbd_200_connect_command_test.go \ + libnbd_210_opt_abort_test.go \ + libnbd_220_opt_list_test.go \ + libnbd_230_opt_info_test.go \ + libnbd_240_opt_list_meta_test.go \ + libnbd_300_get_size_test.go \ + libnbd_400_pread_test.go \ + libnbd_405_pread_structured_test.go \ + libnbd_410_pwrite_test.go \ + libnbd_460_block_status_test.go \ + libnbd_500_aio_pread_test.go \ + libnbd_510_aio_pwrite_test.go \ + libnbd_590_aio_copy_test.go \ + libnbd_600_debug_callback_test.go \ + libnbd_610_error_test.go \ $(NULL) generator_built = \ - src/$(pkg)/bindings.go \ - src/$(pkg)/closures.go \ - src/$(pkg)/wrappers.go \ - src/$(pkg)/wrappers.h \ + bindings.go \ + closures.go \ + wrappers.go \ + wrappers.h \ $(NULL) EXTRA_DIST = \ $(generator_built) \ + .gitignore \ + LICENSE \ + README.md \ + aio_buffer.go \ + callbacks.go \ configure/go.mod \ configure/test.go \ + go.mod \ + handle.go \ libnbd-golang.pod \ + libnbd_*_test.go \ run-tests.sh \ - src/$(pkg)/.gitignore \ - src/$(pkg)/LICENSE \ - src/$(pkg)/README.md \ - src/$(pkg)/aio_buffer.go \ - src/$(pkg)/callbacks.go \ - src/$(pkg)/go.mod \ - src/$(pkg)/handle.go \ - src/$(pkg)/libnbd_*_test.go \ $(NULL) if HAVE_POD @@ -87,13 +84,11 @@ endif HAVE_POD if HAVE_GOLANG all-local: $(source_files) - cd src/$(pkg) && \ $(abs_top_builddir)/run $(GOLANG) build TESTS_ENVIRONMENT = \ LIBNBD_DEBUG=1 \ $(MALLOC_CHECKS) \ - pkg=$(pkg) \ abs_top_srcdir=$(abs_top_srcdir) \ $(NULL) LOG_COMPILER = $(top_builddir)/run @@ -101,4 +96,4 @@ TESTS = run-tests.sh endif -CLEANFILES += src/$(pkg)/*~ +CLEANFILES += *~ diff --git a/golang/src/libguestfs.org/libnbd/README.md b/golang/README.md similarity index 71% rename from golang/src/libguestfs.org/libnbd/README.md rename to golang/README.md index be32e6a..aeadcf6 100644 --- a/golang/src/libguestfs.org/libnbd/README.md +++ b/golang/README.md @@ -18,18 +18,21 @@ extract it from the tarball. wget https://download.libguestfs.org/libnbd/1.10-stable/libnbd-1.10.1.tar.gz -2. Extract the go binding directory +2. Extract the sources from the golang directory - tar xvf libnbd-1.10.1.tar.gz \ - --directory pkg \ - --strip 3 \ + mkdir pkg/libnbd + + tar xvf libnbd-1.11.1.tar.gz \ + --directory pkg/libnbd \ + --strip 2 \ --exclude "*_test.go" \ - --exclude ".gitignore" \ - libnbd-1.10.1/golang/src/libguestfs.org/libnbd + --exclude "examples" \ + --exclude "configure" \ + libnbd-1.11.1/golang/{go.mod,README.md,LICENSE,*.go,*.h} 3. Edit your go mode file to use the local copy - go mod edit -replace libguestfs.org/libnbd=./pkg/libguestfs.org/libnbd + go mod edit -replace libguestfs.org/libnbd=./pkg/libnbd 4. Install the libnbd development package diff --git a/golang/src/libguestfs.org/libnbd/aio_buffer.go b/golang/aio_buffer.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/aio_buffer.go rename to golang/aio_buffer.go diff --git a/golang/src/libguestfs.org/libnbd/callbacks.go b/golang/callbacks.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/callbacks.go rename to golang/callbacks.go diff --git a/golang/examples/get_size/go.mod b/golang/examples/get_size/go.mod index 077ff31..3559751 100644 --- a/golang/examples/get_size/go.mod +++ b/golang/examples/get_size/go.mod @@ -1,4 +1,4 @@ module main -replace libguestfs.org/libnbd => ../../src/libguestfs.org/libnbd +replace libguestfs.org/libnbd => ../../ require libguestfs.org/libnbd v1.0.0 diff --git a/golang/examples/read_first_sector/go.mod b/golang/examples/read_first_sector/go.mod index 077ff31..3559751 100644 --- a/golang/examples/read_first_sector/go.mod +++ b/golang/examples/read_first_sector/go.mod @@ -1,4 +1,4 @@ module main -replace libguestfs.org/libnbd => ../../src/libguestfs.org/libnbd +replace libguestfs.org/libnbd => ../../ require libguestfs.org/libnbd v1.0.0 diff --git a/golang/src/libguestfs.org/libnbd/go.mod b/golang/go.mod similarity index 100% rename from golang/src/libguestfs.org/libnbd/go.mod rename to golang/go.mod diff --git a/golang/src/libguestfs.org/libnbd/handle.go b/golang/handle.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/handle.go rename to golang/handle.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_010_load_test.go b/golang/libnbd_010_load_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_010_load_test.go rename to golang/libnbd_010_load_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_100_handle_test.go b/golang/libnbd_100_handle_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_100_handle_test.go rename to golang/libnbd_100_handle_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_110_defaults_test.go b/golang/libnbd_110_defaults_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_110_defaults_test.go rename to golang/libnbd_110_defaults_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_120_set_non_defaults_test.go b/golang/libnbd_120_set_non_defaults_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_120_set_non_defaults_test.go rename to golang/libnbd_120_set_non_defaults_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_200_connect_command_test.go b/golang/libnbd_200_connect_command_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_200_connect_command_test.go rename to golang/libnbd_200_connect_command_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_210_opt_abort_test.go b/golang/libnbd_210_opt_abort_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_210_opt_abort_test.go rename to golang/libnbd_210_opt_abort_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_220_opt_list_test.go b/golang/libnbd_220_opt_list_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_220_opt_list_test.go rename to golang/libnbd_220_opt_list_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_230_opt_info_test.go b/golang/libnbd_230_opt_info_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_230_opt_info_test.go rename to golang/libnbd_230_opt_info_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_240_opt_list_meta_test.go b/golang/libnbd_240_opt_list_meta_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_240_opt_list_meta_test.go rename to golang/libnbd_240_opt_list_meta_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_300_get_size_test.go b/golang/libnbd_300_get_size_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_300_get_size_test.go rename to golang/libnbd_300_get_size_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_400_pread_test.go b/golang/libnbd_400_pread_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_400_pread_test.go rename to golang/libnbd_400_pread_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_405_pread_structured_test.go b/golang/libnbd_405_pread_structured_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_405_pread_structured_test.go rename to golang/libnbd_405_pread_structured_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_410_pwrite_test.go b/golang/libnbd_410_pwrite_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_410_pwrite_test.go rename to golang/libnbd_410_pwrite_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_460_block_status_test.go b/golang/libnbd_460_block_status_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_460_block_status_test.go rename to golang/libnbd_460_block_status_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_500_aio_pread_test.go b/golang/libnbd_500_aio_pread_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_500_aio_pread_test.go rename to golang/libnbd_500_aio_pread_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_510_aio_pwrite_test.go b/golang/libnbd_510_aio_pwrite_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_510_aio_pwrite_test.go rename to golang/libnbd_510_aio_pwrite_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_590_aio_copy_test.go b/golang/libnbd_590_aio_copy_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_590_aio_copy_test.go rename to golang/libnbd_590_aio_copy_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_600_debug_callback_test.go b/golang/libnbd_600_debug_callback_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_600_debug_callback_test.go rename to golang/libnbd_600_debug_callback_test.go diff --git a/golang/src/libguestfs.org/libnbd/libnbd_610_error_test.go b/golang/libnbd_610_error_test.go similarity index 100% rename from golang/src/libguestfs.org/libnbd/libnbd_610_error_test.go rename to golang/libnbd_610_error_test.go diff --git a/golang/run-tests.sh b/golang/run-tests.sh index 6857047..f83fa18 100755 --- a/golang/run-tests.sh +++ b/golang/run-tests.sh @@ -23,8 +23,6 @@ set -x requires nbdkit --version -cd src/$pkg - # The -count=1 parameter is the "idiomatic way to bypass test caching". # https://golang.org/doc/go1.10#test # The -v option enables verbose output. -- 2.31.1