mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 03:30:05 +02:00
KStars: bump version
This commit is contained in:
@@ -12,7 +12,7 @@ COPYRIGHT="2010-2017 KDE Organisation"
|
||||
LICENSE="GNU LGPL v2"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/KDE/kstars/archive/v$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="fdd515b0e1c8ab5620049f6cf0d1058d4fa79a5b7c2fd67f7949cec8781d5e6f"
|
||||
CHECKSUM_SHA256="693358877d58e8eaa347841b442059edd5f49e5c91aac8b087b8abe946a5b258"
|
||||
PATCHES="kstars-$portVersion.patchset"
|
||||
ADDITIONAL_FILES="kstars.rdef.in"
|
||||
|
||||
@@ -1,82 +0,0 @@
|
||||
From 3922d6f415fbfa9154d36bef777fc78e29c11a08 Mon Sep 17 00:00:00 2001
|
||||
From: Gerasim Troeglazov <3dEyes@gmail.com>
|
||||
Date: Mon, 20 Nov 2017 22:44:37 +1000
|
||||
Subject: Fix build for Haiku
|
||||
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 641c144..5a5a12b 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -231,6 +231,14 @@ if (UNIX)
|
||||
endif(UNIX)
|
||||
|
||||
# Add security (hardening flags)
|
||||
+IF (HAIKU)
|
||||
+ SET(SEC_COMP_FLAGS "-D_FORTIFY_SOURCE=2 -Wcast-align -fPIE -Wa,--noexecstack")
|
||||
+ SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${SEC_COMP_FLAGS}")
|
||||
+ SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${SEC_COMP_FLAGS}")
|
||||
+ SET(SEC_LINK_FLAGS "-Wl,-z,nodump -Wl,-z,noexecstack -Wl,-z,relro -Wl,-z,now -pie")
|
||||
+ SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${SEC_LINK_FLAGS}")
|
||||
+ SET(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${SEC_LINK_FLAGS}")
|
||||
+ELSE ()
|
||||
IF (UNIX OR APPLE OR ANDROID)
|
||||
SET(SEC_COMP_FLAGS "-D_FORTIFY_SOURCE=2 -fstack-protector-all -Wcast-align -fPIE")
|
||||
IF (NOT ANDROID AND NOT CMAKE_CXX_COMPILER_ID STREQUAL "Clang" AND NOT APPLE)
|
||||
@@ -248,6 +256,7 @@ IF (UNIX OR APPLE OR ANDROID)
|
||||
SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${SEC_LINK_FLAGS}")
|
||||
SET(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${SEC_LINK_FLAGS}")
|
||||
ENDIF ()
|
||||
+ENDIF ()
|
||||
|
||||
# Clang Format support
|
||||
IF (UNIX OR APPLE)
|
||||
@@ -358,7 +367,9 @@ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/kstars/version.h.cmake
|
||||
# let our config.h be found first in any case
|
||||
include_directories (BEFORE ${CMAKE_CURRENT_BINARY_DIR})
|
||||
|
||||
+IF (NOT HAIKU)
|
||||
add_subdirectory(doc)
|
||||
+ENDIF()
|
||||
add_subdirectory(kstars)
|
||||
add_subdirectory(datahandlers)
|
||||
|
||||
@@ -371,7 +382,9 @@ IF (NOT ANDROID)
|
||||
ki18n_install("${CMAKE_CURRENT_BINARY_DIR}/po")
|
||||
ENDIF ()
|
||||
|
||||
+IF (NOT HAIKU)
|
||||
install(FILES org.kde.kstars.appdata.xml DESTINATION ${KDE_INSTALL_METAINFODIR})
|
||||
+ENDIF()
|
||||
|
||||
feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)
|
||||
|
||||
diff --git a/kstars/htmesh/SkipListElement.h b/kstars/htmesh/SkipListElement.h
|
||||
index f8187e4..a14cd7d 100644
|
||||
--- a/kstars/htmesh/SkipListElement.h
|
||||
+++ b/kstars/htmesh/SkipListElement.h
|
||||
@@ -20,7 +20,7 @@
|
||||
#define KEY_MAX _I64_MAX
|
||||
#else
|
||||
#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__) || \
|
||||
- (defined(__SUNPRO_CC) && defined(__sun)) || defined(__APPLE__)
|
||||
+ (defined(__SUNPRO_CC) && defined(__sun)) || defined(__APPLE__) || defined(__HAIKU__)
|
||||
#define KEY_MAX LLONG_MAX
|
||||
#else
|
||||
#define KEY_MAX LONG_LONG_MAX
|
||||
diff --git a/kstars/htmesh/SpatialGeneral.h b/kstars/htmesh/SpatialGeneral.h
|
||||
index 450119e..4c822d0 100644
|
||||
--- a/kstars/htmesh/SpatialGeneral.h
|
||||
+++ b/kstars/htmesh/SpatialGeneral.h
|
||||
@@ -101,7 +101,7 @@ const float64 gEpsilon = 1.0E-15;
|
||||
// standard explicit template instantiation, define.
|
||||
//
|
||||
|
||||
-#if defined(__APPLE__)
|
||||
+#if defined(__APPLE__) || defined(__HAIKU__)
|
||||
#define LINKAGE
|
||||
#endif
|
||||
|
||||
--
|
||||
2.15.0
|
||||
|
||||
167
kde-base/kstars/patches/kstars-2.9.4.patchset
Normal file
167
kde-base/kstars/patches/kstars-2.9.4.patchset
Normal file
@@ -0,0 +1,167 @@
|
||||
From 6e22b19ec334ed332da4809fc8ee9b164f47d4af Mon Sep 17 00:00:00 2001
|
||||
From: Gerasim Troeglazov <3dEyes@gmail.com>
|
||||
Date: Mon, 20 Nov 2017 22:44:37 +1000
|
||||
Subject: Fix build for Haiku
|
||||
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 7349373..c5d9066 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -247,6 +247,14 @@ if (UNIX)
|
||||
endif(UNIX)
|
||||
|
||||
# Add security (hardening flags)
|
||||
+IF (HAIKU)
|
||||
+ SET(SEC_COMP_FLAGS "-D_FORTIFY_SOURCE=2 -Wcast-align -fPIE -Wa,--noexecstack")
|
||||
+ SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${SEC_COMP_FLAGS}")
|
||||
+ SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${SEC_COMP_FLAGS}")
|
||||
+ SET(SEC_LINK_FLAGS "-Wl,-z,nodump -Wl,-z,noexecstack -Wl,-z,relro -Wl,-z,now -pie")
|
||||
+ SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${SEC_LINK_FLAGS}")
|
||||
+ SET(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${SEC_LINK_FLAGS}")
|
||||
+ELSE ()
|
||||
IF (UNIX OR APPLE OR ANDROID)
|
||||
SET(SEC_COMP_FLAGS "-D_FORTIFY_SOURCE=2 -fstack-protector-all -Wcast-align -fPIE")
|
||||
IF (NOT ANDROID AND NOT CMAKE_CXX_COMPILER_ID STREQUAL "Clang" AND NOT APPLE)
|
||||
@@ -264,6 +272,7 @@ IF (UNIX OR APPLE OR ANDROID)
|
||||
SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${SEC_LINK_FLAGS}")
|
||||
SET(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${SEC_LINK_FLAGS}")
|
||||
ENDIF ()
|
||||
+ENDIF ()
|
||||
|
||||
# Clang Format support
|
||||
IF (UNIX OR APPLE)
|
||||
@@ -374,7 +383,9 @@ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/kstars/version.h.cmake
|
||||
# let our config.h be found first in any case
|
||||
include_directories (BEFORE ${CMAKE_CURRENT_BINARY_DIR})
|
||||
|
||||
+IF (NOT HAIKU)
|
||||
add_subdirectory(doc)
|
||||
+ENDIF()
|
||||
add_subdirectory(kstars)
|
||||
add_subdirectory(datahandlers)
|
||||
|
||||
@@ -387,7 +398,9 @@ IF (NOT ANDROID)
|
||||
ki18n_install("${CMAKE_CURRENT_BINARY_DIR}/po")
|
||||
ENDIF ()
|
||||
|
||||
+IF (NOT HAIKU)
|
||||
install(FILES org.kde.kstars.appdata.xml DESTINATION ${KDE_INSTALL_METAINFODIR})
|
||||
+ENDIF()
|
||||
|
||||
feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)
|
||||
|
||||
diff --git a/kstars/htmesh/SkipListElement.h b/kstars/htmesh/SkipListElement.h
|
||||
index f8187e4..a14cd7d 100644
|
||||
--- a/kstars/htmesh/SkipListElement.h
|
||||
+++ b/kstars/htmesh/SkipListElement.h
|
||||
@@ -20,7 +20,7 @@
|
||||
#define KEY_MAX _I64_MAX
|
||||
#else
|
||||
#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__) || \
|
||||
- (defined(__SUNPRO_CC) && defined(__sun)) || defined(__APPLE__)
|
||||
+ (defined(__SUNPRO_CC) && defined(__sun)) || defined(__APPLE__) || defined(__HAIKU__)
|
||||
#define KEY_MAX LLONG_MAX
|
||||
#else
|
||||
#define KEY_MAX LONG_LONG_MAX
|
||||
diff --git a/kstars/htmesh/SpatialGeneral.h b/kstars/htmesh/SpatialGeneral.h
|
||||
index 450119e..4c822d0 100644
|
||||
--- a/kstars/htmesh/SpatialGeneral.h
|
||||
+++ b/kstars/htmesh/SpatialGeneral.h
|
||||
@@ -101,7 +101,7 @@ const float64 gEpsilon = 1.0E-15;
|
||||
// standard explicit template instantiation, define.
|
||||
//
|
||||
|
||||
-#if defined(__APPLE__)
|
||||
+#if defined(__APPLE__) || defined(__HAIKU__)
|
||||
#define LINKAGE
|
||||
#endif
|
||||
|
||||
--
|
||||
2.16.2
|
||||
|
||||
|
||||
From deab5c36302e44b24a95ecdeca7d362070d89e97 Mon Sep 17 00:00:00 2001
|
||||
From: Gerasim Troeglazov <3dEyes@gmail.com>
|
||||
Date: Sun, 22 Apr 2018 23:12:55 +1000
|
||||
Subject: Fix crash on start
|
||||
|
||||
|
||||
diff --git a/datahandlers/catalogdb.cpp b/datahandlers/catalogdb.cpp
|
||||
index 81c09cc..0b01238 100644
|
||||
--- a/datahandlers/catalogdb.cpp
|
||||
+++ b/datahandlers/catalogdb.cpp
|
||||
@@ -848,6 +848,9 @@ void CatalogDB::GetAllObjects(const QString &catalog, QList<SkyObject *> &sky_li
|
||||
// qWarning() << get_query.lastError();
|
||||
// qWarning() << FindCatalog(catalog);
|
||||
|
||||
+ if (FindCatalog(catalog) < 0)
|
||||
+ return;
|
||||
+
|
||||
if (!get_query.exec())
|
||||
{
|
||||
qWarning() << get_query.lastQuery();
|
||||
--
|
||||
2.16.2
|
||||
|
||||
|
||||
From 51649630e61e13f03ff621d3469ea6710e654e2b Mon Sep 17 00:00:00 2001
|
||||
From: Gerasim Troeglazov <3dEyes@gmail.com>
|
||||
Date: Sun, 22 Apr 2018 23:14:03 +1000
|
||||
Subject: Native Haiku style by default
|
||||
|
||||
|
||||
diff --git a/kstars/auxiliary/thememanager.cpp b/kstars/auxiliary/thememanager.cpp
|
||||
index ed9da21..8c5d8ed 100644
|
||||
--- a/kstars/auxiliary/thememanager.cpp
|
||||
+++ b/kstars/auxiliary/thememanager.cpp
|
||||
@@ -155,7 +155,10 @@ void ThemeManager::slotChangePalette()
|
||||
|
||||
if (theme == "Macintosh" || theme == "White Balance" || theme == "High Key" || (theme == "Default" && currentDesktopdefaultTheme().contains("Dark") == false))
|
||||
themeIconType = BREEZE_THEME;
|
||||
-
|
||||
+
|
||||
+ if (theme == "Default")
|
||||
+ themeIconType = SYSTEM_THEME;
|
||||
+
|
||||
setIconTheme(themeIconType);
|
||||
|
||||
QString filename = d->themeMap.value(theme);
|
||||
@@ -179,6 +182,8 @@ void ThemeManager::slotChangePalette()
|
||||
|
||||
if(theme == "Macintosh")
|
||||
qApp->setStyle(QStyleFactory::create("macintosh"));
|
||||
+ else if(theme == "Default")
|
||||
+ qApp->setStyle(QStyleFactory::create("haiku"));
|
||||
else
|
||||
qApp->setStyle(QStyleFactory::create("Fusion"));
|
||||
|
||||
@@ -404,6 +409,12 @@ void ThemeManager::setIconTheme(IconTheme theme)
|
||||
themeSearchPaths = themeSearchPaths << QStandardPaths::locate(QStandardPaths::GenericDataLocation, "icons", QStandardPaths::LocateDirectory);
|
||||
QString resourcePath = QStandardPaths::locate(QStandardPaths::GenericDataLocation, "icons", QStandardPaths::LocateDirectory) + QDir::separator() + iconTheme + QDir::separator() + rccFile;
|
||||
QResource::registerResource(resourcePath, "/icons/" + iconTheme);
|
||||
+ #elif defined(Q_OS_HAIKU)
|
||||
+ if (theme == SYSTEM_THEME)
|
||||
+ iconTheme = "haiku";
|
||||
+ themeSearchPaths = themeSearchPaths << QStandardPaths::locate(QStandardPaths::GenericDataLocation, "icons", QStandardPaths::LocateDirectory);
|
||||
+ QString resourcePath = QStandardPaths::locate(QStandardPaths::GenericDataLocation, "icons", QStandardPaths::LocateDirectory) + QDir::separator() + iconTheme + QDir::separator() + rccFile;
|
||||
+ QResource::registerResource(resourcePath, "/icons/" + iconTheme);
|
||||
#else
|
||||
//TODO On Linux on non-KDE Distros, find out if the themes are installed or not and perhaps warn the user
|
||||
#endif
|
||||
diff --git a/kstars/auxiliary/thememanager.h b/kstars/auxiliary/thememanager.h
|
||||
index 1eac5ad..2d4e909 100644
|
||||
--- a/kstars/auxiliary/thememanager.h
|
||||
+++ b/kstars/auxiliary/thememanager.h
|
||||
@@ -48,7 +48,7 @@ class ThemeManager : public QObject
|
||||
|
||||
public:
|
||||
|
||||
- typedef enum { BREEZE_THEME, BREEZE_DARK_THEME } IconTheme;
|
||||
+ typedef enum { BREEZE_THEME, BREEZE_DARK_THEME, SYSTEM_THEME } IconTheme;
|
||||
|
||||
~ThemeManager();
|
||||
static ThemeManager* instance();
|
||||
--
|
||||
2.16.2
|
||||
|
||||
Reference in New Issue
Block a user