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

Build Issues on Hyperland 0.37.1-1 #20

Open
avih7531 opened this issue Mar 21, 2024 · 5 comments
Open

Build Issues on Hyperland 0.37.1-1 #20

avih7531 opened this issue Mar 21, 2024 · 5 comments

Comments

@avih7531
Copy link

avih7531 commented Mar 21, 2024

Hi,

Having build issues on Hyperland 0.37.1-1 (Arch) after updating.

See below for hyprpm log:

[v] version returned: Hyprland, built from branch HEAD at commit c5e28ebcfe00a510922779b2c568cfa52a317445  (props: bump ver 0.37.1).
Date: Sat Mar 16 14:51:49 2024
Tag: v0.37.1

flags: (if any)


[v] parsed commit c5e28ebcfe00a510922779b2c568cfa52a317445 at branch HEAD
✔ adding a new plugin repository from https://github.com/VortexCoyote/hyprfocus
  MAKE SURE that you trust the authors. DO NOT install random plugins without verifying the code and author.
  Are you sure? [Y/n]

 → Cloning https://github.com/VortexCoyote/hyprfocus
✔ cloned
✔ found hyprload manifest
✔ parsed manifest, found 1 plugins:
 → hyprfocus by Vortex version 2.0
✔ Hyprland headers OK
 → Building hyprfocus
✖ Plugin hyprfocus failed to build.

 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╍━━━━━━━━━━━━━━━━━━━  3 / 5  Building plugin(s)[v] shell returned:  -> cd /tmp/hyprpm/new && PKG_CONFIG_PATH="/home/aviherman/.local/share/hyprpm/headersRoot/share/pkgconfig" make all
g++ -shared -fPIC --no-gnu-unique src/Flash.cpp src/IFocusAnimation.cpp src/main.cpp src/Shrink.cpp src/Flash.hpp src/IFocusAnimation.hpp src/Shrink.hpp  -o hyprfocus.so -g `pkg-config --cflags pixman-1 libdrm hyprland` -std=c++2b
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5,
                 from src/Flash.hpp:3,
                 from src/Flash.cpp:1:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/Flash.cpp: In member function ‘virtual void CFlash::init(void*, std::string)’:
src/Flash.cpp:10:77: error: C99 designator ‘floatValue’ outside aggregate initializer
   10 |     addConfigValue(pHandle, "flash_opacity", SConfigValue{.floatValue = 0.5f});
      |                                                                             ^
src/Flash.cpp:10:77: error: invalid use of incomplete type ‘struct SConfigValue’
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/HookSystemManager.hpp:12,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/Screencopy.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/ToplevelExport.hpp:6,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/ProtocolManager.hpp:4,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/Compositor.hpp:18,
                 from src/Flash.cpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/../plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/Flash.cpp: In member function ‘virtual void CFlash::onWindowFocus(CWindow*, void*)’:
src/Flash.cpp:16:25: error: ‘getConfigValue’ was not declared in this scope; did you mean ‘HyprlandAPI::getConfigValue’?
   16 |     pWindow->m_fAlpha = getConfigValue(pHandle, "flash_opacity")->floatValue;
      |                         ^~~~~~~~~~~~~~
      |                         HyprlandAPI::getConfigValue
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/../plugins/PluginAPI.hpp:133:37: note: ‘HyprlandAPI::getConfigValue’ declared here
  133 |     APICALL Hyprlang::CConfigValue* getConfigValue(HANDLE handle, const std::string& name);
      |                                     ^~~~~~~~~~~~~~
src/Flash.cpp: In lambda function:
src/Flash.cpp:20:100: error: ‘class Hyprlang::CConfigValue’ has no member named ‘floatValue’; did you mean ‘getValue’?
   20 |             pWindow->m_fAlpha = HyprlandAPI::getConfigValue(pHandle, "decoration:active_opacity")->floatValue;
      |                                                                                                    ^~~~~~~~~~
      |                                                                                                    getValue
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5,
                 from src/IFocusAnimation.cpp:1:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/IFocusAnimation.cpp: In member function ‘virtual void IFocusAnimation::init(void*, std::string)’:
src/IFocusAnimation.cpp:8:107: error: C99 designator ‘strValue’ outside aggregate initializer
    8 |     HyprlandAPI::addConfigValue(pHandle, configPrefix() + "in_bezier",  SConfigValue{.strValue = "default"});
      |                                                                                                           ^
src/IFocusAnimation.cpp:8:107: error: invalid use of incomplete type ‘struct SConfigValue’
In file included from src/IFocusAnimation.cpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/IFocusAnimation.cpp:9:107: error: C99 designator ‘strValue’ outside aggregate initializer
    9 |     HyprlandAPI::addConfigValue(pHandle, configPrefix() + "out_bezier", SConfigValue{.strValue = "default"});
      |                                                                                                           ^
src/IFocusAnimation.cpp:9:107: error: invalid use of incomplete type ‘struct SConfigValue’
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/IFocusAnimation.cpp:11:102: error: C99 designator ‘floatValue’ outside aggregate initializer
   11 |     HyprlandAPI::addConfigValue(pHandle, configPrefix() + "in_speed",  SConfigValue{.floatValue = 1.f});
      |                                                                                                      ^
src/IFocusAnimation.cpp:11:102: error: invalid use of incomplete type ‘struct SConfigValue’
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/IFocusAnimation.cpp:12:102: error: C99 designator ‘floatValue’ outside aggregate initializer
   12 |     HyprlandAPI::addConfigValue(pHandle, configPrefix() + "out_speed", SConfigValue{.floatValue = 5.f});
      |                                                                                                      ^
src/IFocusAnimation.cpp:12:102: error: invalid use of incomplete type ‘struct SConfigValue’
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/IFocusAnimation.cpp: In member function ‘virtual void IFocusAnimation::onWindowFocus(CWindow*, void*)’:
src/IFocusAnimation.cpp:26:117: error: ‘class Hyprlang::CConfigValue’ has no member named ‘strValue’
   26 |     m_sFocusInAnimConfig.internalBezier       = HyprlandAPI::getConfigValue(pHandle, configPrefix() + "in_bezier")->strValue;
      |                                                                                                                     ^~~~~~~~
src/IFocusAnimation.cpp:27:116: error: ‘class Hyprlang::CConfigValue’ has no member named ‘floatValue’; did you mean ‘getValue’?
   27 |     m_sFocusInAnimConfig.internalSpeed        = HyprlandAPI::getConfigValue(pHandle, configPrefix() + "in_speed")->floatValue;
      |                                                                                                                    ^~~~~~~~~~
      |                                                                                                                    getValue
src/IFocusAnimation.cpp:29:118: error: ‘class Hyprlang::CConfigValue’ has no member named ‘strValue’
   29 |     m_sFocusOutAnimConfig.internalBezier      = HyprlandAPI::getConfigValue(pHandle, configPrefix() + "out_bezier")->strValue;
      |                                                                                                                      ^~~~~~~~
src/IFocusAnimation.cpp:30:117: error: ‘class Hyprlang::CConfigValue’ has no member named ‘floatValue’; did you mean ‘getValue’?
   30 |     m_sFocusOutAnimConfig.internalSpeed       = HyprlandAPI::getConfigValue(pHandle, configPrefix() + "out_speed")->floatValue;
      |                                                                                                                     ^~~~~~~~~~
      |                                                                                                                     getValue
src/IFocusAnimation.cpp: At global scope:
src/IFocusAnimation.cpp:33:6: error: no declaration matches ‘void IFocusAnimation::addConfigValue(void*, std::string, SConfigValue)’
   33 | void IFocusAnimation::addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue) {
      |      ^~~~~~~~~~~~~~~
src/IFocusAnimation.hpp:12:21: note: candidate is: ‘void IFocusAnimation::addConfigValue(void*, std::string, int)’
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                     ^~~~~~~~~~~~~~
src/IFocusAnimation.hpp:7:7: note: ‘class IFocusAnimation’ defined here
    7 | class IFocusAnimation {
      |       ^~~~~~~~~~~~~~~
src/IFocusAnimation.cpp:37:15: error: no declaration matches ‘SConfigValue* IFocusAnimation::getConfigValue(void*, std::string)’
   37 | SConfigValue* IFocusAnimation::getConfigValue(HANDLE pHandle, std::string name) {
      |               ^~~~~~~~~~~~~~~
src/IFocusAnimation.cpp:37:15: note: no functions named ‘SConfigValue* IFocusAnimation::getConfigValue(void*, std::string)’
src/IFocusAnimation.hpp:7:7: note: ‘class IFocusAnimation’ defined here
    7 | class IFocusAnimation {
      |       ^~~~~~~~~~~~~~~
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/Compositor.hpp:10,
                 from src/main.cpp:7:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
In file included from src/main.cpp:12:
src/Shrink.hpp: At global scope:
src/Shrink.hpp:10:5: error: invalid use of template-name ‘CAnimatedVariable’ without an argument list
   10 |     CAnimatedVariable m_sShrinkAnimation;
      |     ^~~~~~~~~~~~~~~~~
src/main.cpp: In function ‘void flashWindow(CWindow*)’:
src/main.cpp:22:128: error: ‘class Hyprlang::CConfigValue’ has no member named ‘strValue’
   22 |     auto* const PTYPE = g_bMouseWasPressed  ? &HyprlandAPI::getConfigValue(PHANDLE, "plugin:hyprfocus:mouse_focus_animation")->strValue
      |                                                                                                                                ^~~~~~~~
src/main.cpp:23:131: error: ‘class Hyprlang::CConfigValue’ has no member named ‘strValue’
   23 |                                             : &HyprlandAPI::getConfigValue(PHANDLE, "plugin:hyprfocus:keyboard_focus_animation")->strValue;
      |                                                                                                                                   ^~~~~~~~
src/main.cpp: In function ‘void flashCurrentWindow(std::string)’:
src/main.cpp:29:111: error: ‘class Hyprlang::CConfigValue’ has no member named ‘intValue’; did you mean ‘getValue’?
   29 |     static auto* const PHYPRFOCUSENABLED = &HyprlandAPI::getConfigValue(PHANDLE, "plugin:hyprfocus:enabled")->intValue;
      |                                                                                                               ^~~~~~~~
      |                                                                                                               getValue
src/main.cpp: In function ‘void onActiveWindowChange(void*, std::any)’:
src/main.cpp:43:115: error: ‘class Hyprlang::CConfigValue’ has no member named ‘intValue’; did you mean ‘getValue’?
   43 |         static auto* const PHYPRFOCUSENABLED = &HyprlandAPI::getConfigValue(PHANDLE, "plugin:hyprfocus:enabled")->intValue;
      |                                                                                                                   ^~~~~~~~
      |                                                                                                                   getValue
src/main.cpp: In function ‘void onMouseButton(void*, std::any)’:
src/main.cpp:63:58: warning: comparison between ‘enum wl_pointer_button_state’ and ‘enum wlr_button_state’ [-Wenum-compare]
   63 |         g_bMouseWasPressed = PWLRMOUSEBUTTONEVENT->state == WLR_BUTTON_PRESSED;
      |                              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~
src/main.cpp: In function ‘PLUGIN_DESCRIPTION_INFO pluginInit(void*)’:
src/main.cpp:76:121: error: C99 designator ‘intValue’ outside aggregate initializer
   76 |     HyprlandAPI::addConfigValue(PHANDLE, "plugin:hyprfocus:enabled",                    SConfigValue{.intValue = 0      });
      |                                                                                                                         ^
src/main.cpp:76:121: error: invalid use of incomplete type ‘struct SConfigValue’
In file included from src/main.cpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/main.cpp:77:121: error: C99 designator ‘strValue’ outside aggregate initializer
   77 |     HyprlandAPI::addConfigValue(PHANDLE, "plugin:hyprfocus:keyboard_focus_animation",   SConfigValue{.strValue = "flash"});
      |                                                                                                                         ^
src/main.cpp:77:121: error: invalid use of incomplete type ‘struct SConfigValue’
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/main.cpp:78:121: error: C99 designator ‘strValue’ outside aggregate initializer
   78 |     HyprlandAPI::addConfigValue(PHANDLE, "plugin:hyprfocus:mouse_focus_animation",      SConfigValue{.strValue = "flash"});
      |                                                                                                                         ^
src/main.cpp:78:121: error: invalid use of incomplete type ‘struct SConfigValue’
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5,
                 from src/Shrink.hpp:3,
                 from src/Shrink.cpp:1:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/Shrink.hpp:10:5: error: invalid use of template-name ‘CAnimatedVariable’ without an argument list
   10 |     CAnimatedVariable m_sShrinkAnimation;
      |     ^~~~~~~~~~~~~~~~~
src/Shrink.cpp: In member function ‘virtual void CShrink::init(void*, std::string)’:
src/Shrink.cpp:10:81: error: C99 designator ‘floatValue’ outside aggregate initializer
   10 |     addConfigValue(pHandle, "shrink_percentage", SConfigValue{.floatValue = 0.5f});
      |                                                                                 ^
src/Shrink.cpp:10:81: error: invalid use of incomplete type ‘struct SConfigValue’
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/HookSystemManager.hpp:12,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/Screencopy.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/ToplevelExport.hpp:6,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/ProtocolManager.hpp:4,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/Compositor.hpp:18,
                 from src/Shrink.cpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/../plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/Shrink.cpp: In member function ‘virtual void CShrink::onWindowFocus(CWindow*, void*)’:
src/Shrink.cpp:20:35: error: ‘getConfigValue’ was not declared in this scope; did you mean ‘HyprlandAPI::getConfigValue’?
   20 |     const auto SHRINKPERCENTAGE = getConfigValue(pHandle, "shrink_percentage")->floatValue;
      |                                   ^~~~~~~~~~~~~~
      |                                   HyprlandAPI::getConfigValue
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/../plugins/PluginAPI.hpp:133:37: note: ‘HyprlandAPI::getConfigValue’ declared here
  133 |     APICALL Hyprlang::CConfigValue* getConfigValue(HANDLE handle, const std::string& name);
      |                                     ^~~~~~~~~~~~~~
src/Shrink.cpp: In lambda function:
src/Shrink.cpp:30:68: error: ‘class CAnimatedVariable<Vector2D>’ has no member named ‘goalv’; did you mean ‘goal’?
   30 |                 const auto GOALPOS      = pWindow->m_vRealPosition.goalv();
      |                                                                    ^~~~~
      |                                                                    goal
src/Shrink.cpp:31:64: error: ‘class CAnimatedVariable<Vector2D>’ has no member named ‘goalv’; did you mean ‘goal’?
   31 |                 const auto GOALSIZE     = pWindow->m_vRealSize.goalv();
      |                                                                ^~~~~
      |                                                                goal
src/Shrink.cpp:33:61: error: missing template arguments before ‘*’ token
   33 |                 const auto* PANIMATION  = (CAnimatedVariable*)pShrinkAnimation;
      |                                                             ^
src/Shrink.cpp:33:62: error: expected primary-expression before ‘)’ token
   33 |                 const auto* PANIMATION  = (CAnimatedVariable*)pShrinkAnimation;
      |                                                              ^
src/Shrink.cpp:36:99: error: ‘class CAnimatedVariable<Vector2D>’ has no member named ‘vec’
   36 |                 pWindow->m_vRealPosition.setValue(GOALPOS + GOALSIZE / 2.f - pWindow->m_vRealSize.vec() / 2.f);
      |                                                                                                   ^~~
src/Shrink.cpp: In lambda function:
src/Shrink.cpp:40:36: error: missing template arguments before ‘*’ token
   40 |                 ((CAnimatedVariable*)pShrinkAnimation)->resetAllCallbacks();
      |                                    ^
src/Shrink.cpp:40:37: error: expected primary-expression before ‘)’ token
   40 |                 ((CAnimatedVariable*)pShrinkAnimation)->resetAllCallbacks();
      |                                     ^
src/Shrink.cpp:40:38: error: expected ‘)’ before ‘pShrinkAnimation’
   40 |                 ((CAnimatedVariable*)pShrinkAnimation)->resetAllCallbacks();
      |                 ~                    ^~~~~~~~~~~~~~~~
      |                                      )
src/Flash.hpp:1:9: warning: #pragma once in main file
    1 | #pragma once
      |         ^~~~
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5,
                 from src/Flash.hpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/IFocusAnimation.hpp:1:9: warning: #pragma once in main file
    1 | #pragma once
      |         ^~~~
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/Shrink.hpp:1:9: warning: #pragma once in main file
    1 | #pragma once
      |         ^~~~
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5,
                 from src/Shrink.hpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/Shrink.hpp:10:5: error: invalid use of template-name ‘CAnimatedVariable’ without an argument list
   10 |     CAnimatedVariable m_sShrinkAnimation;
      |     ^~~~~~~~~~~~~~~~~
make: *** [Makefile:4: all] Error 1


✔ all plugins built
✔ installed repository
✔ you can now enable the plugin(s) with hyprpm enable
 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━  5 / 5  Done!

I recently was involved in fixing another plugin, split-monitor-workspaces, that suffered from a similar issue: Duckonaut/split-monitor-workspaces#56

@pyt0xic
Copy link

pyt0xic commented Mar 21, 2024

Hi,

Having build issues on Hyperland 0.37.1-1 (Arch) after updating.

See below for hyprpm log:

[v] version returned: Hyprland, built from branch HEAD at commit c5e28ebcfe00a510922779b2c568cfa52a317445  (props: bump ver 0.37.1).
Date: Sat Mar 16 14:51:49 2024
Tag: v0.37.1

flags: (if any)


[v] parsed commit c5e28ebcfe00a510922779b2c568cfa52a317445 at branch HEAD
✔ adding a new plugin repository from https://github.com/VortexCoyote/hyprfocus
  MAKE SURE that you trust the authors. DO NOT install random plugins without verifying the code and author.
  Are you sure? [Y/n]

 → Cloning https://github.com/VortexCoyote/hyprfocus
✔ cloned
✔ found hyprload manifest
✔ parsed manifest, found 1 plugins:
 → hyprfocus by Vortex version 2.0
✔ Hyprland headers OK
 → Building hyprfocus
✖ Plugin hyprfocus failed to build.

 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╍━━━━━━━━━━━━━━━━━━━  3 / 5  Building plugin(s)[v] shell returned:  -> cd /tmp/hyprpm/new && PKG_CONFIG_PATH="/home/aviherman/.local/share/hyprpm/headersRoot/share/pkgconfig" make all
g++ -shared -fPIC --no-gnu-unique src/Flash.cpp src/IFocusAnimation.cpp src/main.cpp src/Shrink.cpp src/Flash.hpp src/IFocusAnimation.hpp src/Shrink.hpp  -o hyprfocus.so -g `pkg-config --cflags pixman-1 libdrm hyprland` -std=c++2b
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5,
                 from src/Flash.hpp:3,
                 from src/Flash.cpp:1:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/Flash.cpp: In member function ‘virtual void CFlash::init(void*, std::string)’:
src/Flash.cpp:10:77: error: C99 designator ‘floatValue’ outside aggregate initializer
   10 |     addConfigValue(pHandle, "flash_opacity", SConfigValue{.floatValue = 0.5f});
      |                                                                             ^
src/Flash.cpp:10:77: error: invalid use of incomplete type ‘struct SConfigValue’
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/HookSystemManager.hpp:12,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/Screencopy.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/ToplevelExport.hpp:6,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/ProtocolManager.hpp:4,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/Compositor.hpp:18,
                 from src/Flash.cpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/../plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/Flash.cpp: In member function ‘virtual void CFlash::onWindowFocus(CWindow*, void*)’:
src/Flash.cpp:16:25: error: ‘getConfigValue’ was not declared in this scope; did you mean ‘HyprlandAPI::getConfigValue’?
   16 |     pWindow->m_fAlpha = getConfigValue(pHandle, "flash_opacity")->floatValue;
      |                         ^~~~~~~~~~~~~~
      |                         HyprlandAPI::getConfigValue
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/../plugins/PluginAPI.hpp:133:37: note: ‘HyprlandAPI::getConfigValue’ declared here
  133 |     APICALL Hyprlang::CConfigValue* getConfigValue(HANDLE handle, const std::string& name);
      |                                     ^~~~~~~~~~~~~~
src/Flash.cpp: In lambda function:
src/Flash.cpp:20:100: error: ‘class Hyprlang::CConfigValue’ has no member named ‘floatValue’; did you mean ‘getValue’?
   20 |             pWindow->m_fAlpha = HyprlandAPI::getConfigValue(pHandle, "decoration:active_opacity")->floatValue;
      |                                                                                                    ^~~~~~~~~~
      |                                                                                                    getValue
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5,
                 from src/IFocusAnimation.cpp:1:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/IFocusAnimation.cpp: In member function ‘virtual void IFocusAnimation::init(void*, std::string)’:
src/IFocusAnimation.cpp:8:107: error: C99 designator ‘strValue’ outside aggregate initializer
    8 |     HyprlandAPI::addConfigValue(pHandle, configPrefix() + "in_bezier",  SConfigValue{.strValue = "default"});
      |                                                                                                           ^
src/IFocusAnimation.cpp:8:107: error: invalid use of incomplete type ‘struct SConfigValue’
In file included from src/IFocusAnimation.cpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/IFocusAnimation.cpp:9:107: error: C99 designator ‘strValue’ outside aggregate initializer
    9 |     HyprlandAPI::addConfigValue(pHandle, configPrefix() + "out_bezier", SConfigValue{.strValue = "default"});
      |                                                                                                           ^
src/IFocusAnimation.cpp:9:107: error: invalid use of incomplete type ‘struct SConfigValue’
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/IFocusAnimation.cpp:11:102: error: C99 designator ‘floatValue’ outside aggregate initializer
   11 |     HyprlandAPI::addConfigValue(pHandle, configPrefix() + "in_speed",  SConfigValue{.floatValue = 1.f});
      |                                                                                                      ^
src/IFocusAnimation.cpp:11:102: error: invalid use of incomplete type ‘struct SConfigValue’
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/IFocusAnimation.cpp:12:102: error: C99 designator ‘floatValue’ outside aggregate initializer
   12 |     HyprlandAPI::addConfigValue(pHandle, configPrefix() + "out_speed", SConfigValue{.floatValue = 5.f});
      |                                                                                                      ^
src/IFocusAnimation.cpp:12:102: error: invalid use of incomplete type ‘struct SConfigValue’
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/IFocusAnimation.cpp: In member function ‘virtual void IFocusAnimation::onWindowFocus(CWindow*, void*)’:
src/IFocusAnimation.cpp:26:117: error: ‘class Hyprlang::CConfigValue’ has no member named ‘strValue’
   26 |     m_sFocusInAnimConfig.internalBezier       = HyprlandAPI::getConfigValue(pHandle, configPrefix() + "in_bezier")->strValue;
      |                                                                                                                     ^~~~~~~~
src/IFocusAnimation.cpp:27:116: error: ‘class Hyprlang::CConfigValue’ has no member named ‘floatValue’; did you mean ‘getValue’?
   27 |     m_sFocusInAnimConfig.internalSpeed        = HyprlandAPI::getConfigValue(pHandle, configPrefix() + "in_speed")->floatValue;
      |                                                                                                                    ^~~~~~~~~~
      |                                                                                                                    getValue
src/IFocusAnimation.cpp:29:118: error: ‘class Hyprlang::CConfigValue’ has no member named ‘strValue’
   29 |     m_sFocusOutAnimConfig.internalBezier      = HyprlandAPI::getConfigValue(pHandle, configPrefix() + "out_bezier")->strValue;
      |                                                                                                                      ^~~~~~~~
src/IFocusAnimation.cpp:30:117: error: ‘class Hyprlang::CConfigValue’ has no member named ‘floatValue’; did you mean ‘getValue’?
   30 |     m_sFocusOutAnimConfig.internalSpeed       = HyprlandAPI::getConfigValue(pHandle, configPrefix() + "out_speed")->floatValue;
      |                                                                                                                     ^~~~~~~~~~
      |                                                                                                                     getValue
src/IFocusAnimation.cpp: At global scope:
src/IFocusAnimation.cpp:33:6: error: no declaration matches ‘void IFocusAnimation::addConfigValue(void*, std::string, SConfigValue)’
   33 | void IFocusAnimation::addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue) {
      |      ^~~~~~~~~~~~~~~
src/IFocusAnimation.hpp:12:21: note: candidate is: ‘void IFocusAnimation::addConfigValue(void*, std::string, int)’
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                     ^~~~~~~~~~~~~~
src/IFocusAnimation.hpp:7:7: note: ‘class IFocusAnimation’ defined here
    7 | class IFocusAnimation {
      |       ^~~~~~~~~~~~~~~
src/IFocusAnimation.cpp:37:15: error: no declaration matches ‘SConfigValue* IFocusAnimation::getConfigValue(void*, std::string)’
   37 | SConfigValue* IFocusAnimation::getConfigValue(HANDLE pHandle, std::string name) {
      |               ^~~~~~~~~~~~~~~
src/IFocusAnimation.cpp:37:15: note: no functions named ‘SConfigValue* IFocusAnimation::getConfigValue(void*, std::string)’
src/IFocusAnimation.hpp:7:7: note: ‘class IFocusAnimation’ defined here
    7 | class IFocusAnimation {
      |       ^~~~~~~~~~~~~~~
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/Compositor.hpp:10,
                 from src/main.cpp:7:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
In file included from src/main.cpp:12:
src/Shrink.hpp: At global scope:
src/Shrink.hpp:10:5: error: invalid use of template-name ‘CAnimatedVariable’ without an argument list
   10 |     CAnimatedVariable m_sShrinkAnimation;
      |     ^~~~~~~~~~~~~~~~~
src/main.cpp: In function ‘void flashWindow(CWindow*)’:
src/main.cpp:22:128: error: ‘class Hyprlang::CConfigValue’ has no member named ‘strValue’
   22 |     auto* const PTYPE = g_bMouseWasPressed  ? &HyprlandAPI::getConfigValue(PHANDLE, "plugin:hyprfocus:mouse_focus_animation")->strValue
      |                                                                                                                                ^~~~~~~~
src/main.cpp:23:131: error: ‘class Hyprlang::CConfigValue’ has no member named ‘strValue’
   23 |                                             : &HyprlandAPI::getConfigValue(PHANDLE, "plugin:hyprfocus:keyboard_focus_animation")->strValue;
      |                                                                                                                                   ^~~~~~~~
src/main.cpp: In function ‘void flashCurrentWindow(std::string)’:
src/main.cpp:29:111: error: ‘class Hyprlang::CConfigValue’ has no member named ‘intValue’; did you mean ‘getValue’?
   29 |     static auto* const PHYPRFOCUSENABLED = &HyprlandAPI::getConfigValue(PHANDLE, "plugin:hyprfocus:enabled")->intValue;
      |                                                                                                               ^~~~~~~~
      |                                                                                                               getValue
src/main.cpp: In function ‘void onActiveWindowChange(void*, std::any)’:
src/main.cpp:43:115: error: ‘class Hyprlang::CConfigValue’ has no member named ‘intValue’; did you mean ‘getValue’?
   43 |         static auto* const PHYPRFOCUSENABLED = &HyprlandAPI::getConfigValue(PHANDLE, "plugin:hyprfocus:enabled")->intValue;
      |                                                                                                                   ^~~~~~~~
      |                                                                                                                   getValue
src/main.cpp: In function ‘void onMouseButton(void*, std::any)’:
src/main.cpp:63:58: warning: comparison between ‘enum wl_pointer_button_state’ and ‘enum wlr_button_state’ [-Wenum-compare]
   63 |         g_bMouseWasPressed = PWLRMOUSEBUTTONEVENT->state == WLR_BUTTON_PRESSED;
      |                              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~
src/main.cpp: In function ‘PLUGIN_DESCRIPTION_INFO pluginInit(void*)’:
src/main.cpp:76:121: error: C99 designator ‘intValue’ outside aggregate initializer
   76 |     HyprlandAPI::addConfigValue(PHANDLE, "plugin:hyprfocus:enabled",                    SConfigValue{.intValue = 0      });
      |                                                                                                                         ^
src/main.cpp:76:121: error: invalid use of incomplete type ‘struct SConfigValue’
In file included from src/main.cpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/main.cpp:77:121: error: C99 designator ‘strValue’ outside aggregate initializer
   77 |     HyprlandAPI::addConfigValue(PHANDLE, "plugin:hyprfocus:keyboard_focus_animation",   SConfigValue{.strValue = "flash"});
      |                                                                                                                         ^
src/main.cpp:77:121: error: invalid use of incomplete type ‘struct SConfigValue’
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/main.cpp:78:121: error: C99 designator ‘strValue’ outside aggregate initializer
   78 |     HyprlandAPI::addConfigValue(PHANDLE, "plugin:hyprfocus:mouse_focus_animation",      SConfigValue{.strValue = "flash"});
      |                                                                                                                         ^
src/main.cpp:78:121: error: invalid use of incomplete type ‘struct SConfigValue’
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5,
                 from src/Shrink.hpp:3,
                 from src/Shrink.cpp:1:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/Shrink.hpp:10:5: error: invalid use of template-name ‘CAnimatedVariable’ without an argument list
   10 |     CAnimatedVariable m_sShrinkAnimation;
      |     ^~~~~~~~~~~~~~~~~
src/Shrink.cpp: In member function ‘virtual void CShrink::init(void*, std::string)’:
src/Shrink.cpp:10:81: error: C99 designator ‘floatValue’ outside aggregate initializer
   10 |     addConfigValue(pHandle, "shrink_percentage", SConfigValue{.floatValue = 0.5f});
      |                                                                                 ^
src/Shrink.cpp:10:81: error: invalid use of incomplete type ‘struct SConfigValue’
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/HookSystemManager.hpp:12,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/Screencopy.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/ToplevelExport.hpp:6,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/ProtocolManager.hpp:4,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/Compositor.hpp:18,
                 from src/Shrink.cpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/../plugins/PluginAPI.hpp:63:8: note: forward declaration of ‘struct SConfigValue’
   63 | struct SConfigValue;
      |        ^~~~~~~~~~~~
src/Shrink.cpp: In member function ‘virtual void CShrink::onWindowFocus(CWindow*, void*)’:
src/Shrink.cpp:20:35: error: ‘getConfigValue’ was not declared in this scope; did you mean ‘HyprlandAPI::getConfigValue’?
   20 |     const auto SHRINKPERCENTAGE = getConfigValue(pHandle, "shrink_percentage")->floatValue;
      |                                   ^~~~~~~~~~~~~~
      |                                   HyprlandAPI::getConfigValue
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/managers/../protocols/../managers/../plugins/PluginAPI.hpp:133:37: note: ‘HyprlandAPI::getConfigValue’ declared here
  133 |     APICALL Hyprlang::CConfigValue* getConfigValue(HANDLE handle, const std::string& name);
      |                                     ^~~~~~~~~~~~~~
src/Shrink.cpp: In lambda function:
src/Shrink.cpp:30:68: error: ‘class CAnimatedVariable<Vector2D>’ has no member named ‘goalv’; did you mean ‘goal’?
   30 |                 const auto GOALPOS      = pWindow->m_vRealPosition.goalv();
      |                                                                    ^~~~~
      |                                                                    goal
src/Shrink.cpp:31:64: error: ‘class CAnimatedVariable<Vector2D>’ has no member named ‘goalv’; did you mean ‘goal’?
   31 |                 const auto GOALSIZE     = pWindow->m_vRealSize.goalv();
      |                                                                ^~~~~
      |                                                                goal
src/Shrink.cpp:33:61: error: missing template arguments before ‘*’ token
   33 |                 const auto* PANIMATION  = (CAnimatedVariable*)pShrinkAnimation;
      |                                                             ^
src/Shrink.cpp:33:62: error: expected primary-expression before ‘)’ token
   33 |                 const auto* PANIMATION  = (CAnimatedVariable*)pShrinkAnimation;
      |                                                              ^
src/Shrink.cpp:36:99: error: ‘class CAnimatedVariable<Vector2D>’ has no member named ‘vec’
   36 |                 pWindow->m_vRealPosition.setValue(GOALPOS + GOALSIZE / 2.f - pWindow->m_vRealSize.vec() / 2.f);
      |                                                                                                   ^~~
src/Shrink.cpp: In lambda function:
src/Shrink.cpp:40:36: error: missing template arguments before ‘*’ token
   40 |                 ((CAnimatedVariable*)pShrinkAnimation)->resetAllCallbacks();
      |                                    ^
src/Shrink.cpp:40:37: error: expected primary-expression before ‘)’ token
   40 |                 ((CAnimatedVariable*)pShrinkAnimation)->resetAllCallbacks();
      |                                     ^
src/Shrink.cpp:40:38: error: expected ‘)’ before ‘pShrinkAnimation’
   40 |                 ((CAnimatedVariable*)pShrinkAnimation)->resetAllCallbacks();
      |                 ~                    ^~~~~~~~~~~~~~~~
      |                                      )
src/Flash.hpp:1:9: warning: #pragma once in main file
    1 | #pragma once
      |         ^~~~
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5,
                 from src/Flash.hpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/IFocusAnimation.hpp:1:9: warning: #pragma once in main file
    1 | #pragma once
      |         ^~~~
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/Shrink.hpp:1:9: warning: #pragma once in main file
    1 | #pragma once
      |         ^~~~
In file included from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../Window.hpp:8,
                 from /home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/ConfigManager.hpp:16,
                 from src/IFocusAnimation.hpp:5,
                 from src/Shrink.hpp:3:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp: In member function ‘virtual std::string CGradientValueData::toString()’:
/home/aviherman/.local/share/hyprpm/headersRoot/include/hyprland/src/config/../config/ConfigDataValues.hpp:64:5: warning: no return statement in function returning non-void [-Wreturn-type]
   64 |     }
      |     ^
src/IFocusAnimation.hpp: At global scope:
src/IFocusAnimation.hpp:12:70: error: ‘SConfigValue’ has not been declared
   12 |     void            addConfigValue(HANDLE pHandle, std::string name, SConfigValue sValue);
      |                                                                      ^~~~~~~~~~~~
src/IFocusAnimation.hpp:13:5: error: ‘SConfigValue’ does not name a type
   13 |     SConfigValue*   getConfigValue(HANDLE pHandle, std::string name);
      |     ^~~~~~~~~~~~
src/Shrink.hpp:10:5: error: invalid use of template-name ‘CAnimatedVariable’ without an argument list
   10 |     CAnimatedVariable m_sShrinkAnimation;
      |     ^~~~~~~~~~~~~~~~~
make: *** [Makefile:4: all] Error 1


✔ all plugins built
✔ installed repository
✔ you can now enable the plugin(s) with hyprpm enable
 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━  5 / 5  Done!

I recently was involved in fixing another plugin, split-monitor-workspaces, that suffered from a similar issue: Duckonaut/split-monitor-workspaces#56

Please try my fork, I am currently using it with v0.37.1.

@avih7531
Copy link
Author

Hi, thanks for your help! Your fork compiled which is amazing, thanks!

I have the following in my hyprland.conf, but the effects aren't taking place:

plugin:hyprfocus {
    enabled = yes

    keyboard_focus_animation = shrink
    mouse_focus_animation = flash

    bezier = bezIn, 0.5,0.0,1.0,0.5
    bezier = bezOut, 0.0,0.5,0.5,1.0

    flash {
        flash_opacity = .9

        in_bezier = bezIn
        in_speed = 0.5

        out_bezier = bezOut
        out_speed = 3
    }

   shrink {
	shrink_percentage = .99
	in_bezier = bezIn
	in_speed = 1
	out_bezier = bezOut
	out_speed = 3
   }
}

@avih7531
Copy link
Author

@pyt0xic I take that back, it totally works, but it looks like shrinking is broken and only flashing functions

@pyt0xic
Copy link

pyt0xic commented Mar 21, 2024

@pyt0xic I take that back, it totally works, but it looks like shrinking is broken and only flashing functions

Check the example config in the README.

mouse_focus_animation and keyboard_focus_animation have been replaced with a single setting focus_animation

@avih7531
Copy link
Author

Got it working, thanks for your work!

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

No branches or pull requests

2 participants