woelper / oculante

A fast and simple image viewer / editor for many operating systems
https://github.com/woelper/oculante
MIT License
868 stars 40 forks source link

Build errors while compiling with cargo #359

Closed Stoppedpuma closed 2 months ago

Stoppedpuma commented 2 months ago

Reproduced on both Arch and in a Debian 12 container:

error[E0308]: mismatched types
  --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/ui.rs:98:29
   |
98 |                 r.clicked = [true, true, true, true, true];
   |                 ---------   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found `[bool; 5]`
   |                 |
   |                 expected due to the type of this binding

error[E0277]: the trait bound `ecolor::color32::Color32: From<notan::notan_egui::Color32>` is not satisfied
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/ui.rs:679:16
    |
679 |         .color(Color32::RED);
    |          ----- ^^^^^^^^^^^^ the trait `From<notan::notan_egui::Color32>` is not implemented for `ecolor::color32::Color32`, which is required by `notan::notan_egui::Color32: Into<ecolor::color32::Color32>`
    |          |
    |          required by a bound introduced by this call
    |
    = help: the following other types implement trait `From<T>`:
              <ecolor::color32::Color32 as From<ecolor::hsva_gamma::HsvaGamma>>
              <ecolor::color32::Color32 as From<ecolor::hsva::Hsva>>
              <ecolor::color32::Color32 as From<ecolor::rgba::Rgba>>
    = note: required for `notan::notan_egui::Color32` to implement `Into<ecolor::color32::Color32>`
note: required by a bound in `egui_plot::Points::color`
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/items/mod.rs:894:40
    |
894 |     pub fn color(mut self, color: impl Into<Color32>) -> Self {
    |                                        ^^^^^^^^^^^^^ required by this bound in `Points::color`

error[E0277]: the trait bound `ecolor::color32::Color32: From<notan::notan_egui::Color32>` is not satisfied
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/ui.rs:688:16
    |
688 |         .color(Color32::GREEN);
    |          ----- ^^^^^^^^^^^^^^ the trait `From<notan::notan_egui::Color32>` is not implemented for `ecolor::color32::Color32`, which is required by `notan::notan_egui::Color32: Into<ecolor::color32::Color32>`
    |          |
    |          required by a bound introduced by this call
    |
    = help: the following other types implement trait `From<T>`:
              <ecolor::color32::Color32 as From<ecolor::hsva_gamma::HsvaGamma>>
              <ecolor::color32::Color32 as From<ecolor::hsva::Hsva>>
              <ecolor::color32::Color32 as From<ecolor::rgba::Rgba>>
    = note: required for `notan::notan_egui::Color32` to implement `Into<ecolor::color32::Color32>`
note: required by a bound in `egui_plot::Points::color`
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/items/mod.rs:894:40
    |
894 |     pub fn color(mut self, color: impl Into<Color32>) -> Self {
    |                                        ^^^^^^^^^^^^^ required by this bound in `Points::color`

error[E0277]: the trait bound `ecolor::color32::Color32: From<notan::notan_egui::Color32>` is not satisfied
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/ui.rs:697:16
    |
697 |         .color(Color32::BLUE);
    |          ----- ^^^^^^^^^^^^^ the trait `From<notan::notan_egui::Color32>` is not implemented for `ecolor::color32::Color32`, which is required by `notan::notan_egui::Color32: Into<ecolor::color32::Color32>`
    |          |
    |          required by a bound introduced by this call
    |
    = help: the following other types implement trait `From<T>`:
              <ecolor::color32::Color32 as From<ecolor::hsva_gamma::HsvaGamma>>
              <ecolor::color32::Color32 as From<ecolor::hsva::Hsva>>
              <ecolor::color32::Color32 as From<ecolor::rgba::Rgba>>
    = note: required for `notan::notan_egui::Color32` to implement `Into<ecolor::color32::Color32>`
note: required by a bound in `egui_plot::Points::color`
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/items/mod.rs:894:40
    |
894 |     pub fn color(mut self, color: impl Into<Color32>) -> Self {
    |                                        ^^^^^^^^^^^^^ required by this bound in `Points::color`

error[E0308]: mismatched types
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/ui.rs:703:19
    |
703 |             .show(ui, |plot_ui| {
    |              ---- ^^ expected `egui::ui::Ui`, found `notan::notan_egui::Ui`
    |              |
    |              arguments to this method are incorrect
    |
    = note: `notan::notan_egui::Ui` and `egui::ui::Ui` have similar names, but are actually distinct types
note: `notan::notan_egui::Ui` is defined in crate `egui`
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.27.2/src/ui.rs:31:1
    |
31  | pub struct Ui {
    | ^^^^^^^^^^^^^
note: `egui::ui::Ui` is defined in crate `egui`
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.26.2/src/ui.rs:31:1
    |
31  | pub struct Ui {
    | ^^^^^^^^^^^^^
    = note: perhaps two different versions of crate `egui` are being used?
note: method defined here
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/lib.rs:703:12
    |
703 |     pub fn show<R>(self, ui: &mut Ui, build_fn: impl FnOnce(&mut PlotUi) -> R) -> PlotResponse<R> {
    |            ^^^^

error[E0308]: mismatched types
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/main.rs:312:37
    |
312 |         egui_phosphor::add_to_fonts(&mut fonts, egui_phosphor::Variant::Regular);
    |         --------------------------- ^^^^^^^^^^ expected `FontDefinitions`, found a different `FontDefinitions`
    |         |
    |         arguments to this function are incorrect
    |
    = note: `FontDefinitions` and `FontDefinitions` have similar names, but are actually distinct types
note: `FontDefinitions` is defined in crate `epaint`
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/epaint-0.27.2/src/text/fonts.rs:235:1
    |
235 | pub struct FontDefinitions {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^
note: `FontDefinitions` is defined in crate `epaint`
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/epaint-0.26.2/src/text/fonts.rs:235:1
    |
235 | pub struct FontDefinitions {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: perhaps two different versions of crate `epaint` are being used?
note: function defined here
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-phosphor-0.4.0/src/lib.rs:4:8
    |
4   | pub fn add_to_fonts(fonts: &mut egui::FontDefinitions, variant: Variant) {
    |        ^^^^^^^^^^^^

error[E0308]: mismatched types
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/main.rs:956:27
    |
956 |         state.toasts.show(ctx);
    |                      ---- ^^^ expected `egui::context::Context`, found `notan::notan_egui::Context`
    |                      |
    |                      arguments to this method are incorrect
    |
    = note: `notan::notan_egui::Context` and `egui::context::Context` have similar names, but are actually distinct types
note: `notan::notan_egui::Context` is defined in crate `egui`
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.27.2/src/context.rs:679:1
    |
679 | pub struct Context(Arc<RwLock<ContextImpl>>);
    | ^^^^^^^^^^^^^^^^^^
note: `egui::context::Context` is defined in crate `egui`
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.26.2/src/context.rs:684:1
    |
684 | pub struct Context(Arc<RwLock<ContextImpl>>);
    | ^^^^^^^^^^^^^^^^^^
    = note: perhaps two different versions of crate `egui` are being used?
note: method defined here
   --> /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-notify-0.13.0/src/lib.rs:177:12
    |
177 |     pub fn show(&mut self, ctx: &Context) {
    |            ^^^^

Some errors have detailed explanations: E0277, E0308.
For more information about an error, try `rustc --explain E0277`.
error: could not compile `oculante` (bin "oculante") due to 7 previous errors
error: failed to compile `oculante v0.8.22`, intermediate artifacts can be found at `/tmp/cargo-installQEnr4x`.
woelper commented 2 months ago

There is a branch with a fix for it already, thanks for reporting! The CI did pass all tests for master though, did you run cargo update perhaps?

Stoppedpuma commented 2 months ago

I've tried compiling in a few different ways and none of them seem to want to compile, here's the errors I'm getting from each:

cargo build (After running cargo update):

error: failed to run custom build command for `glsl-to-spirv v0.1.7`

Caused by:
  process didn't exit successfully: `/home/user/test/oculante/target/debug/build/glsl-to-spirv-96093330fd644f98/build-script-build` (exit status: 101)
  --- stdout
  cargo:rerun-if-changed=build/glslangValidator.exe
  CMAKE_TOOLCHAIN_FILE_x86_64-unknown-linux-gnu = None
  CMAKE_TOOLCHAIN_FILE_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_TOOLCHAIN_FILE = None
  CMAKE_TOOLCHAIN_FILE = None
  CMAKE_GENERATOR_x86_64-unknown-linux-gnu = None
  CMAKE_GENERATOR_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_GENERATOR = None
  CMAKE_GENERATOR = None
  CMAKE_PREFIX_PATH_x86_64-unknown-linux-gnu = None
  CMAKE_PREFIX_PATH_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_PREFIX_PATH = None
  CMAKE_PREFIX_PATH = None
  CMAKE_x86_64-unknown-linux-gnu = None
  CMAKE_x86_64_unknown_linux_gnu = None
  HOST_CMAKE = None
  CMAKE = None
  running: cd "/home/user/test/oculante/target/debug/build/glsl-to-spirv-6acefa327ae71df6/out/build" && CMAKE_PREFIX_PATH="" "cmake" "/home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang" "-DCMAKE_INSTALL_PREFIX=/home/user/test/oculante/target/debug/build/glsl-to-spirv-6acefa327ae71df6/out" "-DCMAKE_C_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64 --target=x86_64-unknown-linux-gnu" "-DCMAKE_C_COMPILER=/usr/bin/clang" "-DCMAKE_CXX_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64 --target=x86_64-unknown-linux-gnu" "-DCMAKE_CXX_COMPILER=/usr/bin/clang++" "-DCMAKE_ASM_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64 --target=x86_64-unknown-linux-gnu" "-DCMAKE_ASM_COMPILER=/usr/bin/clang" "-DCMAKE_BUILD_TYPE=Debug"
  -- Google Mock was not found - tests based on that will not build
  -- Configuring done (0.0s)
  -- Generating done (0.1s)
  -- Build files have been written to: /home/user/test/oculante/target/debug/build/glsl-to-spirv-6acefa327ae71df6/out/build
  running: cd "/home/user/test/oculante/target/debug/build/glsl-to-spirv-6acefa327ae71df6/out/build" && MAKEFLAGS="-j --jobserver-fds=8,9 --jobserver-auth=8,9" "cmake" "--build" "." "--target" "install" "--config" "Debug"
  [  1%] Building CXX object glslang/OSDependent/Unix/CMakeFiles/OSDependent.dir/ossource.cpp.o
  [  3%] Building CXX object OGLCompilersDLL/CMakeFiles/OGLCompiler.dir/InitializeDll.cpp.o
  [  5%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslAttributes.cpp.o
  [  7%] Building CXX object StandAlone/CMakeFiles/glslang-default-resource-limits.dir/ResourceLimits.cpp.o
  [  8%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslParseHelper.cpp.o
  [ 10%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslScanContext.cpp.o
  [ 14%] Linking CXX static library libOSDependent.a
  [ 14%] Building CXX object SPIRV/CMakeFiles/SPVRemapper.dir/SPVRemapper.cpp.o
  [ 15%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslOpMap.cpp.o
  [ 17%] Building CXX object SPIRV/CMakeFiles/SPVRemapper.dir/doc.cpp.o
  [ 17%] Built target OSDependent
  [ 19%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslTokenStream.cpp.o
  [ 21%] Linking CXX static library libOGLCompiler.a
  [ 22%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslGrammar.cpp.o
  [ 24%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslParseables.cpp.o
  [ 24%] Built target OGLCompiler
  [ 26%] Linking CXX static library libglslang-default-resource-limits.a
  [ 26%] Built target glslang-default-resource-limits

  --- stderr
  fatal: not a git repository (or any parent up to mount point /)
  Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
  CMake Deprecation Warning at CMakeLists.txt:3 (cmake_minimum_required):
    Compatibility with CMake < 3.5 will be removed from a future version of
    CMake.

    Update the VERSION argument <min> value or use a ...<max> suffix to tell
    CMake that the project does not need compatibility with older versions.

  CMake Warning (dev) at /usr/share/cmake/Modules/GNUInstallDirs.cmake:253 (message):
    Unable to determine default CMAKE_INSTALL_LIBDIR directory because no
    target architecture is known.  Please enable at least one language before
    including GNUInstallDirs.
  Call Stack (most recent call first):
    CMakeLists.txt:7 (include)
  This warning is for project developers.  Use -Wno-dev to suppress it.

  CMake Warning:
    Manually-specified variables were not used by the project:

      CMAKE_ASM_COMPILER
      CMAKE_ASM_FLAGS

  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslScanContext.cpp:45:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/Include/Types.h:41:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslAttributes.cpp:36:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslAttributes.h:41:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslScanContext.h:44:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/ParseHelper.h:47:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/parseVersions.h:42:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/InfoSink.h:38:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseHelper.cpp:37:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseHelper.h:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/parseVersions.h:42:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/InfoSink.h:38:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslOpMap.cpp:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslOpMap.h:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslScanContext.h:44:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/ParseHelper.h:47:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/parseVersions.h:42:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/InfoSink.h:38:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslTokenStream.cpp:36:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslTokenStream.h:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslScanContext.h:44:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/ParseHelper.h:47:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/parseVersions.h:42:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/InfoSink.h:38:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/SPIRV/SPVRemapper.cpp:45:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/SPIRV/../glslang/Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/SPIRV/../glslang/Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/SPIRV/../glslang/Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseables.cpp:51:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseables.h:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/Initialize.h:41:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslGrammar.cpp:55:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslGrammar.h:40:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseHelper.h:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/parseVersions.h:42:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/InfoSink.h:38:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseHelper.cpp:5766:10: warning: variable 'repeated' set but not used [-Wunused-but-set-variable]
   5766 |     bool repeated = false;
        |          ^
  1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:76: hlsl/CMakeFiles/HLSL.dir/hlslAttributes.cpp.o] Error 1
  make[2]: *** Waiting for unfinished jobs....
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseHelper.cpp:8743:33: warning: lambda capture 'this' is not used [-Wunused-lambda-capture]
   8743 |     const auto isOutputPatch = [this](TFunction& patchConstantFunction, int param) {
        |                                 ^~~~
  1 error generated.
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseables.cpp:78:75: warning: use of bitwise '|' with boolean operands [-Wbitwise-instead-of-logical]
     78 |     return argOrder == '%' || argOrder == '@' || IsTextureMS(argOrder) || IsBuffer(argOrder) | IsImage(argOrder);
        |                                                                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        |                                                                                              ||
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseables.cpp:78:75: note: cast one or both operands to int to silence this warning
  make[2]: *** [SPIRV/CMakeFiles/SPVRemapper.dir/build.make:76: SPIRV/CMakeFiles/SPVRemapper.dir/SPVRemapper.cpp.o] Error 1
  make[1]: *** [CMakeFiles/Makefile2:1184: SPIRV/CMakeFiles/SPVRemapper.dir/all] Error 2
  make[1]: *** Waiting for unfinished jobs....
  1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:132: hlsl/CMakeFiles/HLSL.dir/hlslTokenStream.cpp.o] Error 1
  1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:118: hlsl/CMakeFiles/HLSL.dir/hlslOpMap.cpp.o] Error 1
  1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:104: hlsl/CMakeFiles/HLSL.dir/hlslScanContext.cpp.o] Error 1
  1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:146: hlsl/CMakeFiles/HLSL.dir/hlslGrammar.cpp.o] Error 1
  1 warning and 1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:160: hlsl/CMakeFiles/HLSL.dir/hlslParseables.cpp.o] Error 1
  2 warnings and 1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:90: hlsl/CMakeFiles/HLSL.dir/hlslParseHelper.cpp.o] Error 1
  make[1]: *** [CMakeFiles/Makefile2:1210: hlsl/CMakeFiles/HLSL.dir/all] Error 2
  make: *** [Makefile:146: all] Error 2
  thread 'main' panicked at /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cmake-0.1.50/src/lib.rs:1098:5:

  command did not execute successfully, got: exit status: 2

  build script failed, must exit now
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...

cargo install oculante --no-default-features --git https://github.com/woelper/oculante:

error: cannot find macro `vertex_shader` in this scope
  --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/notan_glyph-0.12.1/src/pipeline.rs:46:36
   |
46 | const GLYPH_VERTEX: ShaderSource = vertex_shader! {
   |                                    ^^^^^^^^^^^^^

error: cannot find macro `fragment_shader` in this scope
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/notan_glyph-0.12.1/src/pipeline.rs:100:38
    |
100 | const GLYPH_FRAGMENT: ShaderSource = fragment_shader! {
    |                                      ^^^^^^^^^^^^^^^

error: could not compile `notan_glyph` (lib) due to 2 previous errors
warning: build failed, waiting for other jobs to finish...
error: failed to compile `oculante v0.8.22 (https://github.com/woelper/oculante#4364d33a)`, intermediate artifacts can be found at `/tmp/cargo-installM3kEBx`.
To reuse those artifacts with a future compilation, set the environment variable `CARGO_TARGET_DIR` to that path.

cargo install oculante --no-default-features -F notan/shaderc:

error[E0277]: the trait bound `ecolor::color32::Color32: From<notan::notan_egui::Color32>` is not satisfied
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/ui.rs:679:16
    |
679 |         .color(Color32::RED);
    |          ----- ^^^^^^^^^^^^ the trait `From<notan::notan_egui::Color32>` is not implemented for `ecolor::color32::Color32`, which is required by `notan::notan_egui::Color32: Into<ecolor::color32::Color32>`
    |          |
    |          required by a bound introduced by this call
    |
    = help: the following other types implement trait `From<T>`:
              <ecolor::color32::Color32 as From<ecolor::hsva::Hsva>>
              <ecolor::color32::Color32 as From<ecolor::hsva_gamma::HsvaGamma>>
              <ecolor::color32::Color32 as From<ecolor::rgba::Rgba>>
    = note: required for `notan::notan_egui::Color32` to implement `Into<ecolor::color32::Color32>`
note: required by a bound in `egui_plot::Points::color`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/items/mod.rs:894:40
    |
894 |     pub fn color(mut self, color: impl Into<Color32>) -> Self {
    |                                        ^^^^^^^^^^^^^ required by this bound in `Points::color`

error[E0277]: the trait bound `ecolor::color32::Color32: From<notan::notan_egui::Color32>` is not satisfied
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/ui.rs:688:16
    |
688 |         .color(Color32::GREEN);
    |          ----- ^^^^^^^^^^^^^^ the trait `From<notan::notan_egui::Color32>` is not implemented for `ecolor::color32::Color32`, which is required by `notan::notan_egui::Color32: Into<ecolor::color32::Color32>`
    |          |
    |          required by a bound introduced by this call
    |
    = help: the following other types implement trait `From<T>`:
              <ecolor::color32::Color32 as From<ecolor::hsva::Hsva>>
              <ecolor::color32::Color32 as From<ecolor::hsva_gamma::HsvaGamma>>
              <ecolor::color32::Color32 as From<ecolor::rgba::Rgba>>
    = note: required for `notan::notan_egui::Color32` to implement `Into<ecolor::color32::Color32>`
note: required by a bound in `egui_plot::Points::color`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/items/mod.rs:894:40
    |
894 |     pub fn color(mut self, color: impl Into<Color32>) -> Self {
    |                                        ^^^^^^^^^^^^^ required by this bound in `Points::color`

error[E0277]: the trait bound `ecolor::color32::Color32: From<notan::notan_egui::Color32>` is not satisfied
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/ui.rs:697:16
    |
697 |         .color(Color32::BLUE);
    |          ----- ^^^^^^^^^^^^^ the trait `From<notan::notan_egui::Color32>` is not implemented for `ecolor::color32::Color32`, which is required by `notan::notan_egui::Color32: Into<ecolor::color32::Color32>`
    |          |
    |          required by a bound introduced by this call
    |
    = help: the following other types implement trait `From<T>`:
              <ecolor::color32::Color32 as From<ecolor::hsva::Hsva>>
              <ecolor::color32::Color32 as From<ecolor::hsva_gamma::HsvaGamma>>
              <ecolor::color32::Color32 as From<ecolor::rgba::Rgba>>
    = note: required for `notan::notan_egui::Color32` to implement `Into<ecolor::color32::Color32>`
note: required by a bound in `egui_plot::Points::color`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/items/mod.rs:894:40
    |
894 |     pub fn color(mut self, color: impl Into<Color32>) -> Self {
    |                                        ^^^^^^^^^^^^^ required by this bound in `Points::color`

error[E0308]: mismatched types
  --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/ui.rs:98:29
   |
98 |                 r.clicked = [true, true, true, true, true];
   |                 ---------   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found `[bool; 5]`
   |                 |
   |                 expected due to the type of this binding

error[E0308]: mismatched types
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/main.rs:312:37
    |
312 |         egui_phosphor::add_to_fonts(&mut fonts, egui_phosphor::Variant::Regular);
    |         --------------------------- ^^^^^^^^^^ expected `FontDefinitions`, found a different `FontDefinitions`
    |         |
    |         arguments to this function are incorrect
    |
    = note: `FontDefinitions` and `FontDefinitions` have similar names, but are actually distinct types
note: `FontDefinitions` is defined in crate `epaint`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/epaint-0.27.2/src/text/fonts.rs:235:1
    |
235 | pub struct FontDefinitions {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^
note: `FontDefinitions` is defined in crate `epaint`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/epaint-0.26.2/src/text/fonts.rs:235:1
    |
235 | pub struct FontDefinitions {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: perhaps two different versions of crate `epaint` are being used?
note: function defined here
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-phosphor-0.4.0/src/lib.rs:4:8
    |
4   | pub fn add_to_fonts(fonts: &mut egui::FontDefinitions, variant: Variant) {
    |        ^^^^^^^^^^^^

error[E0308]: mismatched types
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/main.rs:956:27
    |
956 |         state.toasts.show(ctx);
    |                      ---- ^^^ expected `egui::context::Context`, found `notan::notan_egui::Context`
    |                      |
    |                      arguments to this method are incorrect
    |
    = note: `notan::notan_egui::Context` and `egui::context::Context` have similar names, but are actually distinct types
note: `notan::notan_egui::Context` is defined in crate `egui`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.27.2/src/context.rs:679:1
    |
679 | pub struct Context(Arc<RwLock<ContextImpl>>);
    | ^^^^^^^^^^^^^^^^^^
note: `egui::context::Context` is defined in crate `egui`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.26.2/src/context.rs:684:1
    |
684 | pub struct Context(Arc<RwLock<ContextImpl>>);
    | ^^^^^^^^^^^^^^^^^^
    = note: perhaps two different versions of crate `egui` are being used?
note: method defined here
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-notify-0.13.0/src/lib.rs:177:12
    |
177 |     pub fn show(&mut self, ctx: &Context) {
    |            ^^^^

error[E0308]: mismatched types
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/oculante-0.8.22/src/ui.rs:703:19
    |
703 |             .show(ui, |plot_ui| {
    |              ---- ^^ expected `egui::ui::Ui`, found `notan::notan_egui::Ui`
    |              |
    |              arguments to this method are incorrect
    |
    = note: `notan::notan_egui::Ui` and `egui::ui::Ui` have similar names, but are actually distinct types
note: `notan::notan_egui::Ui` is defined in crate `egui`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.27.2/src/ui.rs:31:1
    |
31  | pub struct Ui {
    | ^^^^^^^^^^^^^
note: `egui::ui::Ui` is defined in crate `egui`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.26.2/src/ui.rs:31:1
    |
31  | pub struct Ui {
    | ^^^^^^^^^^^^^
    = note: perhaps two different versions of crate `egui` are being used?
note: method defined here
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/lib.rs:703:12
    |
703 |     pub fn show<R>(self, ui: &mut Ui, build_fn: impl FnOnce(&mut PlotUi) -> R) -> PlotResponse<R> {
    |            ^^^^

Some errors have detailed explanations: E0277, E0308.
For more information about an error, try `rustc --explain E0277`.
error: could not compile `oculante` (bin "oculante") due to 7 previous errors
woelper commented 2 months ago

Have you tried cargo run --no-default-features --features notan/glsl-to-spirv?

You are of course free to try, but if you don't want to spend your time, I'll hopefully push a fix soon or investigate!

Stoppedpuma commented 2 months ago

Results from cargo run --no-default-features --features notan/glsl-to-spirv

error: failed to run custom build command for `glsl-to-spirv v0.1.7`

Caused by:
  process didn't exit successfully: `/home/user/test/oculante/target/debug/build/glsl-to-spirv-96093330fd644f98/build-script-build` (exit status: 101)
  --- stdout
  cargo:rerun-if-changed=build/glslangValidator.exe
  CMAKE_TOOLCHAIN_FILE_x86_64-unknown-linux-gnu = None
  CMAKE_TOOLCHAIN_FILE_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_TOOLCHAIN_FILE = None
  CMAKE_TOOLCHAIN_FILE = None
  CMAKE_GENERATOR_x86_64-unknown-linux-gnu = None
  CMAKE_GENERATOR_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_GENERATOR = None
  CMAKE_GENERATOR = None
  CMAKE_PREFIX_PATH_x86_64-unknown-linux-gnu = None
  CMAKE_PREFIX_PATH_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_PREFIX_PATH = None
  CMAKE_PREFIX_PATH = None
  CMAKE_x86_64-unknown-linux-gnu = None
  CMAKE_x86_64_unknown_linux_gnu = None
  HOST_CMAKE = None
  CMAKE = None
  running: cd "/home/user/test/oculante/target/debug/build/glsl-to-spirv-6acefa327ae71df6/out/build" && CMAKE_PREFIX_PATH="" "cmake" "/home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang" "-DCMAKE_INSTALL_PREFIX=/home/user/test/oculante/target/debug/build/glsl-to-spirv-6acefa327ae71df6/out" "-DCMAKE_C_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64 --target=x86_64-unknown-linux-gnu" "-DCMAKE_C_COMPILER=/usr/bin/clang" "-DCMAKE_CXX_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64 --target=x86_64-unknown-linux-gnu" "-DCMAKE_CXX_COMPILER=/usr/bin/clang++" "-DCMAKE_ASM_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64 --target=x86_64-unknown-linux-gnu" "-DCMAKE_ASM_COMPILER=/usr/bin/clang" "-DCMAKE_BUILD_TYPE=Debug"
  -- Google Mock was not found - tests based on that will not build
  -- Configuring done (0.0s)
  -- Generating done (0.1s)
  -- Build files have been written to: /home/user/test/oculante/target/debug/build/glsl-to-spirv-6acefa327ae71df6/out/build
  running: cd "/home/user/test/oculante/target/debug/build/glsl-to-spirv-6acefa327ae71df6/out/build" && MAKEFLAGS="-j --jobserver-fds=8,9 --jobserver-auth=8,9" "cmake" "--build" "." "--target" "install" "--config" "Debug"
  [  3%] Built target OSDependent
  [  7%] Built target OGLCompiler
  [  8%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslAttributes.cpp.o
  [ 10%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslParseHelper.cpp.o
  [ 14%] Built target glslang-default-resource-limits
  [ 15%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslScanContext.cpp.o
  [ 17%] Building CXX object SPIRV/CMakeFiles/SPVRemapper.dir/SPVRemapper.cpp.o
  [ 19%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslOpMap.cpp.o
  [ 21%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslTokenStream.cpp.o
  [ 22%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslGrammar.cpp.o
  [ 24%] Building CXX object hlsl/CMakeFiles/HLSL.dir/hlslParseables.cpp.o

  --- stderr
  fatal: not a git repository (or any parent up to mount point /)
  Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
  CMake Deprecation Warning at CMakeLists.txt:3 (cmake_minimum_required):
    Compatibility with CMake < 3.5 will be removed from a future version of
    CMake.

    Update the VERSION argument <min> value or use a ...<max> suffix to tell
    CMake that the project does not need compatibility with older versions.

  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslAttributes.cpp:36:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslAttributes.h:41:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslScanContext.h:44:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/ParseHelper.h:47:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/parseVersions.h:42:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/InfoSink.h:38:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslScanContext.cpp:45:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/Include/Types.h:41:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseHelper.cpp:37:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseHelper.h:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/parseVersions.h:42:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/InfoSink.h:38:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslTokenStream.cpp:36:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslTokenStream.h:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslScanContext.h:44:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/ParseHelper.h:47:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/parseVersions.h:42:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/InfoSink.h:38:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslOpMap.cpp:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslOpMap.h:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslScanContext.h:44:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/ParseHelper.h:47:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/parseVersions.h:42:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/InfoSink.h:38:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslGrammar.cpp:55:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslGrammar.h:40:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseHelper.h:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/parseVersions.h:42:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/InfoSink.h:38:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/SPIRV/SPVRemapper.cpp:45:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/SPIRV/../glslang/Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/SPIRV/../glslang/Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/SPIRV/../glslang/Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseables.cpp:51:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseables.h:39:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/Initialize.h:41:
  In file included from /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/Common.h:99:
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/PoolAlloc.h:314:54: error: 'operator=' is a private member of 'glslang::TPoolAllocator'
    314 |     void setAllocator(TPoolAllocator* a) { allocator = *a; }
        |                                            ~~~~~~~~~ ^ ~~
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/../glslang/MachineIndependent/../Include/PoolAlloc.h:244:21: note: declared private here
    244 |     TPoolAllocator& operator=(const TPoolAllocator&);  // don't allow assignment operator
        |                     ^
  1 error generated.
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseHelper.cpp:5766:10: warning: variable 'repeated' set but not used [-Wunused-but-set-variable]
   5766 |     bool repeated = false;
        |          ^
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:76: hlsl/CMakeFiles/HLSL.dir/hlslAttributes.cpp.o] Error 1
  make[2]: *** Waiting for unfinished jobs....
  1 error generated.
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseables.cpp:78:75: warning: use of bitwise '|' with boolean operands [-Wbitwise-instead-of-logical]
     78 |     return argOrder == '%' || argOrder == '@' || IsTextureMS(argOrder) || IsBuffer(argOrder) | IsImage(argOrder);
        |                                                                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        |                                                                                              ||
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseables.cpp:78:75: note: cast one or both operands to int to silence this warning
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:118: hlsl/CMakeFiles/HLSL.dir/hlslOpMap.cpp.o] Error 1
  /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/glsl-to-spirv-0.1.7/glslang/hlsl/hlslParseHelper.cpp:8743:33: warning: lambda capture 'this' is not used [-Wunused-lambda-capture]
   8743 |     const auto isOutputPatch = [this](TFunction& patchConstantFunction, int param) {
        |                                 ^~~~
  1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:132: hlsl/CMakeFiles/HLSL.dir/hlslTokenStream.cpp.o] Error 1
  1 error generated.
  make[2]: *** [SPIRV/CMakeFiles/SPVRemapper.dir/build.make:76: SPIRV/CMakeFiles/SPVRemapper.dir/SPVRemapper.cpp.o] Error 1
  make[1]: *** [CMakeFiles/Makefile2:1184: SPIRV/CMakeFiles/SPVRemapper.dir/all] Error 2
  make[1]: *** Waiting for unfinished jobs....
  1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:146: hlsl/CMakeFiles/HLSL.dir/hlslGrammar.cpp.o] Error 1
  1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:104: hlsl/CMakeFiles/HLSL.dir/hlslScanContext.cpp.o] Error 1
  1 warning and 1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:160: hlsl/CMakeFiles/HLSL.dir/hlslParseables.cpp.o] Error 1
  2 warnings and 1 error generated.
  make[2]: *** [hlsl/CMakeFiles/HLSL.dir/build.make:90: hlsl/CMakeFiles/HLSL.dir/hlslParseHelper.cpp.o] Error 1
  make[1]: *** [CMakeFiles/Makefile2:1210: hlsl/CMakeFiles/HLSL.dir/all] Error 2
  make: *** [Makefile:146: all] Error 2
  thread 'main' panicked at /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cmake-0.1.50/src/lib.rs:1098:5:

  command did not execute successfully, got: exit status: 2

  build script failed, must exit now
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
woelper commented 2 months ago

Not good. What if you replace glsl-to-spirv with shaderc?

Stoppedpuma commented 2 months ago

cargo run --no-default-features --features notan/shaderc:

warning: unexpected `cfg` condition value: `dds`
 --> src/ktx2_loader/mod.rs:2:7
  |
2 | #[cfg(feature = "dds")]
  |       ^^^^^^^^^^^^^^^
  |
  = note: expected values for `feature` are: `avif-decode`, `avif_native`, `dav1d`, `default`, `file_open`, `heif`, `j2k`, `jpeg2k`, `libavif-image`, `libheif-rs`, `rfd`, `self_update`, `turbo`, `turbojpeg`, and `update`
  = help: consider adding `dds` as a feature in `Cargo.toml`
  = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
  = note: `#[warn(unexpected_cfgs)]` on by default

warning: unexpected `cfg` condition value: `dds`
  --> src/ktx2_loader/mod.rs:14:7
   |
14 | #[cfg(feature = "dds")]
   |       ^^^^^^^^^^^^^^^
   |
   = note: expected values for `feature` are: `avif-decode`, `avif_native`, `dav1d`, `default`, `file_open`, `heif`, `j2k`, `jpeg2k`, `libavif-image`, `libheif-rs`, `rfd`, `self_update`, `turbo`, `turbojpeg`, and `update`
   = help: consider adding `dds` as a feature in `Cargo.toml`
   = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: unexpected `cfg` condition value: `dds`
 --> src/ktx2_loader/image.rs:1:7
  |
1 | #[cfg(feature = "dds")]
  |       ^^^^^^^^^^^^^^^
  |
  = note: expected values for `feature` are: `avif-decode`, `avif_native`, `dav1d`, `default`, `file_open`, `heif`, `j2k`, `jpeg2k`, `libavif-image`, `libheif-rs`, `rfd`, `self_update`, `turbo`, `turbojpeg`, and `update`
  = help: consider adding `dds` as a feature in `Cargo.toml`
  = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: unexpected `cfg` condition value: `dds`
   --> src/ktx2_loader/image.rs:262:19
    |
262 |             #[cfg(feature = "dds")]
    |                   ^^^^^^^^^^^^^^^
    |
    = note: expected values for `feature` are: `avif-decode`, `avif_native`, `dav1d`, `default`, `file_open`, `heif`, `j2k`, `jpeg2k`, `libavif-image`, `libheif-rs`, `rfd`, `self_update`, `turbo`, `turbojpeg`, and `update`
    = help: consider adding `dds` as a feature in `Cargo.toml`
    = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: unexpected `cfg` condition name: `macos`
   --> src/main.rs:619:43
    |
619 |                     let divisor = if cfg!(macos) { 0.1 } else { 10. };
    |                                           ^^^^^ help: found config with similar value: `target_os = "macos"`
    |
    = help: expected names are: `clippy`, `debug_assertions`, `doc`, `docsrs`, `doctest`, `feature`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `rustfmt`, `sanitize`, `sanitizer_cfi_generalize_pointers`, `sanitizer_cfi_normalize_integers`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `ub_checks`, `unix`, and `windows`
    = help: consider using a Cargo feature instead
    = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
             [lints.rust]
             unexpected_cfgs = { level = "warn", check-cfg = ['cfg(macos)'] }
    = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(macos)");` to the top of the `build.rs`
    = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: use of deprecated method `notan::notan_egui::Response::drag_released`: Renamed 'dragged_stopped'
    --> src/ui.rs:2214:14
     |
2214 |         if r.drag_released() {
     |              ^^^^^^^^^^^^^
     |
     = note: `#[warn(deprecated)]` on by default

error[E0277]: the trait bound `ecolor::color32::Color32: From<notan::notan_egui::Color32>` is not satisfied
   --> src/ui.rs:686:16
    |
686 |         .color(Color32::RED);
    |          ----- ^^^^^^^^^^^^ the trait `From<notan::notan_egui::Color32>` is not implemented for `ecolor::color32::Color32`, which is required by `notan::notan_egui::Color32: Into<ecolor::color32::Color32>`
    |          |
    |          required by a bound introduced by this call
    |
    = help: the following other types implement trait `From<T>`:
              <ecolor::color32::Color32 as From<ecolor::hsva::Hsva>>
              <ecolor::color32::Color32 as From<ecolor::hsva_gamma::HsvaGamma>>
              <ecolor::color32::Color32 as From<ecolor::rgba::Rgba>>
    = note: required for `notan::notan_egui::Color32` to implement `Into<ecolor::color32::Color32>`
note: required by a bound in `egui_plot::Points::color`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/items/mod.rs:894:40
    |
894 |     pub fn color(mut self, color: impl Into<Color32>) -> Self {
    |                                        ^^^^^^^^^^^^^ required by this bound in `Points::color`

error[E0277]: the trait bound `ecolor::color32::Color32: From<notan::notan_egui::Color32>` is not satisfied
   --> src/ui.rs:695:16
    |
695 |         .color(Color32::GREEN);
    |          ----- ^^^^^^^^^^^^^^ the trait `From<notan::notan_egui::Color32>` is not implemented for `ecolor::color32::Color32`, which is required by `notan::notan_egui::Color32: Into<ecolor::color32::Color32>`
    |          |
    |          required by a bound introduced by this call
    |
    = help: the following other types implement trait `From<T>`:
              <ecolor::color32::Color32 as From<ecolor::hsva::Hsva>>
              <ecolor::color32::Color32 as From<ecolor::hsva_gamma::HsvaGamma>>
              <ecolor::color32::Color32 as From<ecolor::rgba::Rgba>>
    = note: required for `notan::notan_egui::Color32` to implement `Into<ecolor::color32::Color32>`
note: required by a bound in `egui_plot::Points::color`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/items/mod.rs:894:40
    |
894 |     pub fn color(mut self, color: impl Into<Color32>) -> Self {
    |                                        ^^^^^^^^^^^^^ required by this bound in `Points::color`

error[E0277]: the trait bound `ecolor::color32::Color32: From<notan::notan_egui::Color32>` is not satisfied
   --> src/ui.rs:704:16
    |
704 |         .color(Color32::BLUE);
    |          ----- ^^^^^^^^^^^^^ the trait `From<notan::notan_egui::Color32>` is not implemented for `ecolor::color32::Color32`, which is required by `notan::notan_egui::Color32: Into<ecolor::color32::Color32>`
    |          |
    |          required by a bound introduced by this call
    |
    = help: the following other types implement trait `From<T>`:
              <ecolor::color32::Color32 as From<ecolor::hsva::Hsva>>
              <ecolor::color32::Color32 as From<ecolor::hsva_gamma::HsvaGamma>>
              <ecolor::color32::Color32 as From<ecolor::rgba::Rgba>>
    = note: required for `notan::notan_egui::Color32` to implement `Into<ecolor::color32::Color32>`
note: required by a bound in `egui_plot::Points::color`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/items/mod.rs:894:40
    |
894 |     pub fn color(mut self, color: impl Into<Color32>) -> Self {
    |                                        ^^^^^^^^^^^^^ required by this bound in `Points::color`

warning: use of deprecated method `notan::notan_egui::Response::drag_released`: Renamed 'dragged_stopped'
   --> src/image_editing.rs:871:37
    |
871 |                     r0.changed = r0.drag_released() || r1.drag_released() || r2.changed();
    |                                     ^^^^^^^^^^^^^

warning: use of deprecated method `notan::notan_egui::Response::drag_released`: Renamed 'dragged_stopped'
   --> src/image_editing.rs:871:59
    |
871 |                     r0.changed = r0.drag_released() || r1.drag_released() || r2.changed();
    |                                                           ^^^^^^^^^^^^^

error[E0308]: mismatched types
  --> src/ui.rs:98:29
   |
98 |                 r.clicked = [true, true, true, true, true];
   |                 ---------   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found `[bool; 5]`
   |                 |
   |                 expected due to the type of this binding

error[E0308]: mismatched types
   --> src/main.rs:313:37
    |
313 |         egui_phosphor::add_to_fonts(&mut fonts, egui_phosphor::Variant::Regular);
    |         --------------------------- ^^^^^^^^^^ expected `FontDefinitions`, found a different `FontDefinitions`
    |         |
    |         arguments to this function are incorrect
    |
    = note: `FontDefinitions` and `FontDefinitions` have similar names, but are actually distinct types
note: `FontDefinitions` is defined in crate `epaint`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/epaint-0.27.2/src/text/fonts.rs:235:1
    |
235 | pub struct FontDefinitions {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^
note: `FontDefinitions` is defined in crate `epaint`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/epaint-0.26.2/src/text/fonts.rs:235:1
    |
235 | pub struct FontDefinitions {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: perhaps two different versions of crate `epaint` are being used?
note: function defined here
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-phosphor-0.4.0/src/lib.rs:4:8
    |
4   | pub fn add_to_fonts(fonts: &mut egui::FontDefinitions, variant: Variant) {
    |        ^^^^^^^^^^^^

error[E0308]: mismatched types
   --> src/ui.rs:710:19
    |
710 |             .show(ui, |plot_ui| {
    |              ---- ^^ expected `egui::ui::Ui`, found `notan::notan_egui::Ui`
    |              |
    |              arguments to this method are incorrect
    |
    = note: `notan::notan_egui::Ui` and `egui::ui::Ui` have similar names, but are actually distinct types
note: `notan::notan_egui::Ui` is defined in crate `egui`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.27.2/src/ui.rs:31:1
    |
31  | pub struct Ui {
    | ^^^^^^^^^^^^^
note: `egui::ui::Ui` is defined in crate `egui`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.26.2/src/ui.rs:31:1
    |
31  | pub struct Ui {
    | ^^^^^^^^^^^^^
    = note: perhaps two different versions of crate `egui` are being used?
note: method defined here
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui_plot-0.26.2/src/lib.rs:703:12
    |
703 |     pub fn show<R>(self, ui: &mut Ui, build_fn: impl FnOnce(&mut PlotUi) -> R) -> PlotResponse<R> {
    |            ^^^^

error[E0308]: mismatched types
   --> src/main.rs:958:27
    |
958 |         state.toasts.show(ctx);
    |                      ---- ^^^ expected `egui::context::Context`, found `notan::notan_egui::Context`
    |                      |
    |                      arguments to this method are incorrect
    |
    = note: `notan::notan_egui::Context` and `egui::context::Context` have similar names, but are actually distinct types
note: `notan::notan_egui::Context` is defined in crate `egui`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.27.2/src/context.rs:679:1
    |
679 | pub struct Context(Arc<RwLock<ContextImpl>>);
    | ^^^^^^^^^^^^^^^^^^
note: `egui::context::Context` is defined in crate `egui`
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-0.26.2/src/context.rs:684:1
    |
684 | pub struct Context(Arc<RwLock<ContextImpl>>);
    | ^^^^^^^^^^^^^^^^^^
    = note: perhaps two different versions of crate `egui` are being used?
note: method defined here
   --> /home/user/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-notify-0.13.0/src/lib.rs:177:12
    |
177 |     pub fn show(&mut self, ctx: &Context) {
    |            ^^^^

Some errors have detailed explanations: E0277, E0308.
For more information about an error, try `rustc --explain E0277`.
warning: `oculante` (bin "oculante") generated 8 warnings
error: could not compile `oculante` (bin "oculante") due to 7 previous errors; 8 warnings emitted
woelper commented 2 months ago

Ok, this is just an egui issue. This is easy to fix. You can try reverting the changes in Cargo.lock or checkout the update_notan branch. I'll fix master later. It seems the main reason is that spirv is problematic to build on your distro.

Stoppedpuma commented 2 months ago

Thanks, running with cargo run --no-default-features --features notan/shaderc on the notan_update branch works fine. I will mention there are still some warnings but otherwise compiles fine. Warnings:

warning: unexpected `cfg` condition value: `dds`
 --> src/ktx2_loader/mod.rs:2:7
  |
2 | #[cfg(feature = "dds")]
  |       ^^^^^^^^^^^^^^^
  |
  = note: expected values for `feature` are: `avif-decode`, `avif_native`, `dav1d`, `default`, `file_open`, `heif`, `j2k`, `jpeg2k`, `libavif-image`, `libheif-rs`, `rfd`, `self_update`, `turbo`, `turbojpeg`, and `update`
  = help: consider adding `dds` as a feature in `Cargo.toml`
  = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
  = note: `#[warn(unexpected_cfgs)]` on by default

warning: unexpected `cfg` condition value: `dds`
  --> src/ktx2_loader/mod.rs:14:7
   |
14 | #[cfg(feature = "dds")]
   |       ^^^^^^^^^^^^^^^
   |
   = note: expected values for `feature` are: `avif-decode`, `avif_native`, `dav1d`, `default`, `file_open`, `heif`, `j2k`, `jpeg2k`, `libavif-image`, `libheif-rs`, `rfd`, `self_update`, `turbo`, `turbojpeg`, and `update`
   = help: consider adding `dds` as a feature in `Cargo.toml`
   = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: unexpected `cfg` condition value: `dds`
 --> src/ktx2_loader/image.rs:1:7
  |
1 | #[cfg(feature = "dds")]
  |       ^^^^^^^^^^^^^^^
  |
  = note: expected values for `feature` are: `avif-decode`, `avif_native`, `dav1d`, `default`, `file_open`, `heif`, `j2k`, `jpeg2k`, `libavif-image`, `libheif-rs`, `rfd`, `self_update`, `turbo`, `turbojpeg`, and `update`
  = help: consider adding `dds` as a feature in `Cargo.toml`
  = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: unexpected `cfg` condition value: `dds`
   --> src/ktx2_loader/image.rs:262:19
    |
262 |             #[cfg(feature = "dds")]
    |                   ^^^^^^^^^^^^^^^
    |
    = note: expected values for `feature` are: `avif-decode`, `avif_native`, `dav1d`, `default`, `file_open`, `heif`, `j2k`, `jpeg2k`, `libavif-image`, `libheif-rs`, `rfd`, `self_update`, `turbo`, `turbojpeg`, and `update`
    = help: consider adding `dds` as a feature in `Cargo.toml`
    = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: unexpected `cfg` condition name: `macos`
   --> src/main.rs:619:43
    |
619 |                     let divisor = if cfg!(macos) { 0.1 } else { 10. };
    |                                           ^^^^^ help: found config with similar value: `target_os = "macos"`
    |
    = help: expected names are: `clippy`, `debug_assertions`, `doc`, `docsrs`, `doctest`, `feature`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `rustfmt`, `sanitize`, `sanitizer_cfi_generalize_pointers`, `sanitizer_cfi_normalize_integers`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `ub_checks`, `unix`, and `windows`
    = help: consider using a Cargo feature instead
    = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
             [lints.rust]
             unexpected_cfgs = { level = "warn", check-cfg = ['cfg(macos)'] }
    = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(macos)");` to the top of the `build.rs`
    = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: method `to_image` is never used
   --> src/utils.rs:626:8
    |
609 | pub trait ImageExt {
    |           -------- method in this trait
...
626 |     fn to_image(&self, _: &mut Graphics) -> Option<RgbaImage> {
    |        ^^^^^^^^
    |
    = note: `#[warn(dead_code)]` on by default

warning: `oculante` (bin "oculante") generated 6 warnings
Stoppedpuma commented 2 months ago

@woelper Should I close this issue since #361 has been merged or wait until the warnings have been fixed as well?

woelper commented 2 months ago

Please close. In general I will remove warnings before a release, but they are fine now. Rust is a bit strict anyways, for example an unused variable triggers a warning already.