Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot compile with newest Hyprland #120

Closed
SimonBrandner opened this issue Jun 11, 2024 · 14 comments
Closed

Cannot compile with newest Hyprland #120

SimonBrandner opened this issue Jun 11, 2024 · 14 comments

Comments

@SimonBrandner
Copy link
Contributor

warning: The interpretation of store paths arguments ending in `.drv` recently changed. If this command is now failing try again with '/nix/store/3l01bvf0kjgfgfga8m4k0kzxvpj778vh-hy3-hl0.41.0.drv^*'
@nix { "action": "setPhase", "phase": "unpackPhase" }
Running phase: unpackPhase
unpacking source archive /nix/store/8kvv42qmx2gm0mjijv3gb9s2x3hcxv00-f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source
source root is f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source
@nix { "action": "setPhase", "phase": "patchPhase" }
Running phase: patchPhase
@nix { "action": "setPhase", "phase": "updateAutotoolsGnuConfigScriptsPhase" }
Running phase: updateAutotoolsGnuConfigScriptsPhase
@nix { "action": "setPhase", "phase": "configurePhase" }
Running phase: configurePhase
fixing cmake files...
cmake flags: -GNinja -DCMAKE_FIND_USE_SYSTEM_PACKAGE_REGISTRY=OFF -DCMAKE_FIND_USE_PACKAGE_REGISTRY=OFF -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo -DBUILD>
-- The C compiler identification is GNU 13.2.0
-- The CXX compiler identification is GNU 13.2.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /nix/store/9bv7dcvmfcjnmg5mnqwqlq2wxfn8d7yi-gcc-wrapper-13.2.0/bin/gcc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /nix/store/9bv7dcvmfcjnmg5mnqwqlq2wxfn8d7yi-gcc-wrapper-13.2.0/bin/g++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found PkgConfig: /nix/store/zdvrzlvzbn9ymb0z8na50w995j8np16z-pkg-config-wrapper-0.29.2/bin/pkg-config (found version "0.29.2")
-- Checking for modules 'hyprland;pixman-1;libdrm;pango;pangocairo'
--   Found hyprland, version 0.41.0
--   Found pixman-1, version 0.43.4
--   Found libdrm, version 2.4.120
--   Found pango, version 1.52.2
--   Found pangocairo, version 1.52.2
-- Configuring done (0.8s)
-- Generating done (0.0s)
CMake Warning:
  Manually-specified variables were not used by the project:

    BUILD_TESTING
    CMAKE_EXPORT_NO_PACKAGE_REGISTRY
    CMAKE_INSTALL_BINDIR
    CMAKE_INSTALL_DOCDIR
    CMAKE_INSTALL_INCLUDEDIR
    CMAKE_INSTALL_INFODIR
    CMAKE_INSTALL_LIBEXECDIR
    CMAKE_INSTALL_LOCALEDIR
    CMAKE_INSTALL_MANDIR
    CMAKE_INSTALL_OLDINCLUDEDIR
    CMAKE_INSTALL_SBINDIR
    CMAKE_POLICY_DEFAULT_CMP0025


-- Build files have been written to: /build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/build
@nix { "action": "setPhase", "phase": "buildPhase" }
Running phase: buildPhase
build flags: -j8
[1/7] Building CXX object CMakeFiles/hy3.dir/src/TabGroup.cpp.o
FAILED: CMakeFiles/hy3.dir/src/TabGroup.cpp.o 
/nix/store/9bv7dcvmfcjnmg5mnqwqlq2wxfn8d7yi-gcc-wrapper-13.2.0/bin/g++ -DWLR_USE_UNSTABLE -Dhy3_EXPORTS -I/nix/store/14l0278acylv7w1dqj5s8rfx48q1fd3w-hyprland-0.41.0+date=2024-06-11_e>
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/TabGroup.cpp:14:10: fatal error: src/helpers/memory/SharedPtr.hpp: No such file or directory
   14 | #include "src/helpers/memory/SharedPtr.hpp"
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
[2/7] Building CXX object CMakeFiles/hy3.dir/src/dispatchers.cpp.o
FAILED: CMakeFiles/hy3.dir/src/dispatchers.cpp.o 
/nix/store/9bv7dcvmfcjnmg5mnqwqlq2wxfn8d7yi-gcc-wrapper-13.2.0/bin/g++ -DWLR_USE_UNSTABLE -Dhy3_EXPORTS -I/nix/store/14l0278acylv7w1dqj5s8rfx48q1fd3w-hyprland-0.41.0+date=2024-06-11_e>
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/dispatchers.cpp: In function 'void dispatch_focustab(std::string)':
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/dispatchers.cpp:177:22: error: 'isNumber' was not declared in this scope
  177 |                 if (!isNumber(args[i])) return;
      |                      ^~~~~~~~
[3/7] Building CXX object CMakeFiles/hy3.dir/src/main.cpp.o
[4/7] Building CXX object CMakeFiles/hy3.dir/src/SelectionHook.cpp.o
[5/7] Building CXX object CMakeFiles/hy3.dir/src/Hy3Node.cpp.o
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Node.cpp: In member function 'PHLWINDOW Hy3Node::bringToTop()':
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Node.cpp:212:1: warning: control reaches end of non-void function [-Wreturn-type]
  212 | }
      | ^
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Node.cpp: In member function 'Hy3Node* Hy3Node::getFocusedNode(bool, bool)':
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Node.cpp:275:1: warning: control reaches end of non-void function [-Wreturn-type]
  275 | }
      | ^
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Node.cpp: In member function 'bool Hy3Node::isUrgent()':
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Node.cpp:620:1: warning: control reaches end of non-void function [-Wreturn-type]
  620 | }
      | ^
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Node.cpp: In member function 'void Hy3Node::recalcSizePosRecursive(bool)':
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Node.cpp:381:71: warning: 'constraint' may be used uninitialized [-Wmaybe-uninitialized]
  381 |             group.layout != Hy3GroupLayout::Tabbed ? child_count <= 0 ? 0 : constraint / child_count : 0;
      |                                                      ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Node.cpp:362:16: note: 'constraint' was declared here
  362 |         double constraint;
      |                ^~~~~~~~~~
[6/7] Building CXX object CMakeFiles/hy3.dir/src/Hy3Layout.cpp.o
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Layout.cpp: In member function 'bool Hy3Layout::shouldRenderSelected(const PHLWINDOW&)':
/build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Layout.cpp:1401:1: warning: control reaches end of non-void function [-Wreturn-type]
 1401 | }
      | ^
ninja: build stopped: subcommand failed.
@ndom91
Copy link

ndom91 commented Jun 11, 2024

Running into this as well.

Using the folloiwng two flake inputs:

    hyprland.url = "git+https://github.com/hyprwm/Hyprland?submodules=1&tag=v0.41.0";
    hy3 = {
      url = "github:outfoxxed/hy3?ref=hl0.41.0";
      inputs.hyprland.follows = "hyprland";
    };
building the system configuration...
error: builder for '/nix/store/3l01bvf0kjgfgfga8m4k0kzxvpj778vh-hy3-hl0.41.0.drv' failed with exit code 1;
       last 10 log lines:
       >       |                                                      ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
       > /build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Node.cpp:362:16: note: 'constraint' was declared here
       >   362 |         double constraint;
       >       |                ^~~~~~~~~~
       > [6/7] Building CXX object CMakeFiles/hy3.dir/src/Hy3Layout.cpp.o
       > /build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Layout.cpp: In member function 'bool Hy3Layout::shouldRenderSelected(const PHLWINDOW&)':
       > /build/f7g04kx8p2gsjalb7fn3xnns8fw71vsi-source/src/Hy3Layout.cpp:1401:1: warning: control reaches end of non-void function [-Wreturn-type]
       >  1401 | }
       >       | ^
       > ninja: build stopped: subcommand failed.
       For full logs, run 'nix log /nix/store/3l01bvf0kjgfgfga8m4k0kzxvpj778vh-hy3-hl0.41.0.drv'.
error: 1 dependencies of derivation '/nix/store/lya6j0f0wcvc01v5j0yhnps51f1g08wy-hm_hyprhyprland.conf.drv' failed to build
error: 1 dependencies of derivation '/nix/store/ch5crqadnx7sspfb2h7096m7bmxm0i5w-activation-script.drv' failed to build
error: 1 dependencies of derivation '/nix/store/wyg7z2kzx5f2dycpz61jqj2lcf54ihpc-home-manager-generation.drv' failed to build
error: 1 dependencies of derivation '/nix/store/a24a45634jfrdhx6p9b4ml59q19vkcsm-unit-home-manager-ndo.service.drv' failed to build
error: 1 dependencies of derivation '/nix/store/g3spa6xibwszriz9y5brgiyk6y9jd7mn-system-units.drv' failed to build
error: 1 dependencies of derivation '/nix/store/d8y55g1qz86pxcsdvriyl8zfk1rc4ig3-etc.drv' failed to build
error: 1 dependencies of derivation '/nix/store/df72rmsh1292h7cwhzzw0kc85blavycj-nixos-system-ndo4-24.05.20240605.0b8e7a1.drv' failed to build

@SimonBrandner
Copy link
Contributor Author

This is caused by hyprwm/Hyprland@8c64a4b, FWIW

@ndom91
Copy link

ndom91 commented Jun 12, 2024

yeah, trying the following inputs, i.e. pinning hyprland to the same commit that [email protected] is following.

hyprland.url = "git+https://github.com/hyprwm/Hyprland?submodules=1&rev=ea2501d4556f84d3de86a4ae2f4b22a474555b9f";
hy3 = {
  url = "github:outfoxxed/hy3?ref=hl0.41.0";
  inputs.hyprland.follows = "hyprland";
};

Looks like thats a few commits before that one ^^

@ndom91
Copy link

ndom91 commented Jun 12, 2024

Yeah that seems to have worked 👍

Guess @outfoxxed just has to update one more time for 0.41.0 ( 😅 ) for the hyprutil changes

@SimonBrandner
Copy link
Contributor Author

I think you're using a version of Hyprland before the hyprutils changes actually... I had to make some changes to the code to fix this: #121

@Dregorio1
Copy link

I did what you suggest and I have got:

Failed to load the following plugins:
/nix/store/0pcqr4zc3in2c5zi33ydlxxwsklv07vg-hy3-hl0.41.0/lib/libhy3.so

Flake:

inputs = {
   nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
    hyprland = {
      type = "git";
      url = "https://github.com/hyprwm/Hyprland";
      submodules = true;
      rev="ea2501d4556f84d3de86a4ae2f4b22a474555b9f";
    };

    hy3 = {
      url = "github:outfoxxed/hy3?ref=hl0.41.0";
      inputs.hyprland.follows = "hyprland";
    };
}

@outfoxxed
Copy link
Owner

outfoxxed commented Jun 12, 2024

0.41 should be before the hyprutils changes. It builds correctly here. The revision in the hy3 flake matches the one on the hyprland tag.

@SimonBrandner
Copy link
Contributor Author

Argh, wasn't very clear and my bug fix isn't entirely correct... It's failing to build against the newest commit in Hyprland, so the PR should also update the flake.nix file...

@outfoxxed
Copy link
Owner

Merged the changes, will try updating everything to latest myself.

@outfoxxed
Copy link
Owner

Latest works on my machine with the current changes.

@fufexan
Copy link

fufexan commented Jun 20, 2024

@outfoxxed would you mind creating a 0.41.1 release? It would be helpful for Nixpkgs NixOS/nixpkgs#320347 (comment).

@JohnRTitor
Copy link

@outfoxxed would you mind creating a 0.41.1 release? It would be helpful for Nixpkgs NixOS/nixpkgs#320347 (comment).

+1, NixOS 24.05 backport is pending due to this not compiling

@outfoxxed
Copy link
Owner

@fufexan done

@fufexan
Copy link

fufexan commented Jun 21, 2024

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants