kfirewall: build fix

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
Ivailo Monev 2023-06-20 04:48:50 +03:00
parent 3ef1e6cc9e
commit ce37613433
5 changed files with 14 additions and 6 deletions

View file

@ -3,8 +3,8 @@ project(kfirewall)
if(${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_CURRENT_SOURCE_DIR})
include(FeatureSummary)
find_package(KDE4 4.21.0 REQUIRED)
include(KDE4Defaults)
find_package(KDELibs4 4.21.0 REQUIRED)
include_directories(${KDE4_INCLUDES})
add_definitions(${QT_DEFINITIONS} ${KDE4_DEFINITIONS})
endif()

View file

@ -8,8 +8,8 @@ set(kfirewallconfig_SRCS
kde4_add_plugin(kcm_kfirewallconfig ${kfirewallconfig_SRCS})
target_link_libraries(kcm_kfirewallconfig
${KDE4_KDEUI_LIBS}
${KDE4_KCMUTILS_LIBS}
KDE4::kdeui
KDE4::kcmutils
)
install(
@ -26,7 +26,7 @@ install(
add_executable(kcmkfirewallhelper kfirewallhelper.cpp)
target_link_libraries(kcmkfirewallhelper
${KDE4_KDECORE_LIBS}
KDE4::kdecore
)
install(

View file

@ -128,6 +128,12 @@ static int applyRules(KFirewallHelper *helper, const QString &iptablesexe,
return KAuthorization::NoError;
}
KFirewallHelper::KFirewallHelper(const char* const helper, QObject *parent)
: KAuthorization(helper, parent)
{
}
int KFirewallHelper::apply(const QVariantMap &parameters)
{
if (parameters.isEmpty()) {

View file

@ -24,6 +24,8 @@
class KFirewallHelper : public KAuthorization
{
Q_OBJECT
public:
KFirewallHelper(const char* const helper, QObject *parent);
public slots:
int apply(const QVariantMap &parameters);
int revert(const QVariantMap &parameters);

View file

@ -9,7 +9,7 @@ qt4_generate_dbus_interface(kded_kfirewall.h org.kde.kfirewall.xml )
kde4_add_plugin(kded_kfirewall ${kded_kfirewall_SRCS})
target_link_libraries(kded_kfirewall PRIVATE
${KDE4_KDECORE_LIBS}
KDE4::kdecore
)
install(