From d706ef38719c3874c6dde78b3421a7dc8326791e6c4580522135c44548c14c13 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20Br=C3=BCns?= Date: Thu, 25 Oct 2018 21:34:24 +0000 Subject: [PATCH] Accepting request 644324 from home:StefanBruens:branches:electronics - Update to bugfix release 5.0.1 This version contains critical bugfixes and minor improvements. See http://kicad-pcb.org/blog/2018/10/KiCad-5.0.1-Release/ for details. - Do proper fix for 3d plugindir, use absolute LIBDIR instead of deriving it from BINDIR: Add 0001-Use-absolute-path-CMAKE_INSTALL_FULL_LIBDIR-for-3d-v.patch - Drop upstream kicad-fix-boost168-build.patch. - Add Recommends: for new kicad-templates package OBS-URL: https://build.opensuse.org/request/show/644324 OBS-URL: https://build.opensuse.org/package/show/electronics/kicad?expand=0&rev=50 --- ...h-CMAKE_INSTALL_FULL_LIBDIR-for-3d-v.patch | 54 +++++++++++++++++++ kicad-5.0.0.tar.xz | 3 -- kicad-5.0.1.tar.xz | 3 ++ kicad-fix-boost168-build.patch | 36 ------------- kicad.changes | 12 +++++ kicad.spec | 21 +++++--- 6 files changed, 82 insertions(+), 47 deletions(-) create mode 100644 0001-Use-absolute-path-CMAKE_INSTALL_FULL_LIBDIR-for-3d-v.patch delete mode 100644 kicad-5.0.0.tar.xz create mode 100644 kicad-5.0.1.tar.xz delete mode 100644 kicad-fix-boost168-build.patch diff --git a/0001-Use-absolute-path-CMAKE_INSTALL_FULL_LIBDIR-for-3d-v.patch b/0001-Use-absolute-path-CMAKE_INSTALL_FULL_LIBDIR-for-3d-v.patch new file mode 100644 index 0000000..5630c0f --- /dev/null +++ b/0001-Use-absolute-path-CMAKE_INSTALL_FULL_LIBDIR-for-3d-v.patch @@ -0,0 +1,54 @@ +From 3f1f474f8ceab75acda7c1d0a36cc9c33c6124b3 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Stefan=20Br=C3=BCns?= +Date: Tue, 9 Oct 2018 17:35:55 +0200 +Subject: [PATCH] Use absolute path CMAKE_INSTALL_FULL_LIBDIR for 3d viewer + PLUGINDIR + +Currently, the plugindir in the plugin manager is constructed as +{CMAKE_INSTALL_PREFIX}/bin/../{CMAKE_INSTALL_LIBDIR}/kicad/..., while +CMakes install uses {CMAKE_INSTALL_LIBDIR}/kicad/... + +In case CMAKE_INSTALL_LIBDIR is a relative path "install" prefixes it +with CMAKE_INSTALL_PREFIX and both paths happen to match, otherwise +the constructed path ends up as e.g. "/usr/bin/../usr/lib/kicad/...". + +For these cases where an absolute path is wanted CMake provides the +CMAKE_INSTALL_FULL_ variants which works the same as +CMAKE_INSTALL_ when used as DIRECTORY for install. +--- + 3d-viewer/3d_cache/3d_plugin_manager.cpp | 10 +++------- + 3d-viewer/3d_plugin_dir.h.in | 2 +- + 2 files changed, 4 insertions(+), 8 deletions(-) + +diff --git a/3d-viewer/3d_cache/3d_plugin_manager.cpp b/3d-viewer/3d_cache/3d_plugin_manager.cpp +index 52f2cef..fc561e7 100644 +--- a/3d-viewer/3d_cache/3d_plugin_manager.cpp ++++ b/3d-viewer/3d_cache/3d_plugin_manager.cpp +@@ -149,14 +149,10 @@ void S3D_PLUGIN_MANAGER::loadPlugins( void ) + #endif + + #ifndef _WIN32 +- // multiarch friendly determination of the plugin directory: the executable dir +- // is first determined via wxStandardPaths::Get().GetExecutablePath() and then +- // the CMAKE_INSTALL_LIBDIR path is appended relative to the executable dir. ++ // PLUGINDIR = CMAKE_INSTALL_FULL_LIBDIR path is the absolute path ++ // corresponding to the install path used for constructing KICAD_USER_PLUGIN + +- fn.Assign( wxStandardPaths::Get().GetExecutablePath() ); +- fn.RemoveLastDir(); +- wxString tfname = fn.GetPathWithSep(); +- tfname.Append( wxString::FromUTF8Unchecked( PLUGINDIR ) ); ++ wxString tfname = wxString::FromUTF8Unchecked( PLUGINDIR ); + fn.Assign( tfname, ""); + fn.AppendDir( "kicad" ); + #else +diff --git a/3d-viewer/3d_plugin_dir.h.in b/3d-viewer/3d_plugin_dir.h.in +index 6cf6de2..fb923ec 100644 +--- a/3d-viewer/3d_plugin_dir.h.in ++++ b/3d-viewer/3d_plugin_dir.h.in +@@ -1 +1 @@ +-#define PLUGINDIR "@CMAKE_INSTALL_LIBDIR@" ++#define PLUGINDIR "@CMAKE_INSTALL_FULL_LIBDIR@" +-- +2.19.0 + diff --git a/kicad-5.0.0.tar.xz b/kicad-5.0.0.tar.xz deleted file mode 100644 index b85ef5c..0000000 --- a/kicad-5.0.0.tar.xz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:377582e4287146186593d42a5a7fe761590a79404982524ce445b4edbf96d89e -size 14284708 diff --git a/kicad-5.0.1.tar.xz b/kicad-5.0.1.tar.xz new file mode 100644 index 0000000..b41a74b --- /dev/null +++ b/kicad-5.0.1.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5fe4f63318522cb0a1c89ecd6a71c470def1720f152954cf3182f5deb878716a +size 14241544 diff --git a/kicad-fix-boost168-build.patch b/kicad-fix-boost168-build.patch deleted file mode 100644 index d05a4ef..0000000 --- a/kicad-fix-boost168-build.patch +++ /dev/null @@ -1,36 +0,0 @@ -From: Dave Plater -Date: 2018-11-18 10:52 -Subject: Fix build against boost-1.68 -Upstream: from upstream - -In boost-1.68 "boost/uuid/sha1.hpp" is moved to -"boost/uuid/detail/sha1.hpp" -Patch copied from git #8bb0fabcba3b9344105b11d762b2360de9889fc0 -The comit also includes a large number of debug fixes that are -not necessary and would make the patch very large. - -Index: 3d-viewer/3d_cache/3d_cache.cpp -=================================================================== ---- 3d-viewer/3d_cache/3d_cache.cpp.orig 2018-07-13 21:53:52.000000000 +0200 -+++ 3d-viewer/3d_cache/3d_cache.cpp 2018-09-18 11:02:07.410240387 +0200 -@@ -2,6 +2,7 @@ - * This program source code file is part of KiCad, a free EDA CAD application. - * - * Copyright (C) 2015-2016 Cirilo Bernardo -+ * Copyright (C) 2018 KiCad Developers, see AUTHORS.txt for contributors. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License -@@ -34,7 +35,12 @@ - #include - #include - -+#include -+#if BOOST_VERSION >= 106800 -+#include -+#else - #include -+#endif - - #include - #include diff --git a/kicad.changes b/kicad.changes index d995504..c02f51d 100644 --- a/kicad.changes +++ b/kicad.changes @@ -1,3 +1,15 @@ +------------------------------------------------------------------- +Thu Oct 18 19:03:17 UTC 2018 - Stefan Brüns + +- Update to bugfix release 5.0.1 + This version contains critical bugfixes and minor improvements. + See http://kicad-pcb.org/blog/2018/10/KiCad-5.0.1-Release/ for details. +- Do proper fix for 3d plugindir, use absolute LIBDIR instead of + deriving it from BINDIR: + Add 0001-Use-absolute-path-CMAKE_INSTALL_FULL_LIBDIR-for-3d-v.patch +- Drop upstream kicad-fix-boost168-build.patch. +- Add Recommends: for new kicad-templates package + ------------------------------------------------------------------- Wed Oct 10 11:52:55 UTC 2018 - Stefan Brüns diff --git a/kicad.spec b/kicad.spec index a2f594e..d197c39 100644 --- a/kicad.spec +++ b/kicad.spec @@ -12,15 +12,18 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # +# According to upstream, kicad 5.0.x can be used with the footprint and +# symbol libraries from version 5.0.0 +%define compatversion 5.0.0 Name: kicad -Version: 5.0.0 +Version: 5.0.1 Release: 0 Summary: EDA software suite for the creation of schematics and PCB -License: GPL-3.0-or-later AND AGPL-3.0-or-later +License: GPL-3.0-or-later AND AGPL-3.0-or-later Group: Productivity/Scientific/Electronics Url: http://kicad-pcb.org Source: https://launchpad.net/kicad/5.0/%{version}/+download/kicad-%{version}.tar.xz @@ -36,7 +39,8 @@ Patch2: kicad-library-repos-install.patch # PATCH-FIX-OPENSUSE davejplater@gmail.com -kicad-suse-help-path.patch - kicad looks in /usr/share/doc/kicad for help files and doesn't find them. # this patch adds packges/ befor kicad and enables help to function. Patch3: kicad-suse-help-path.patch -Patch4: kicad-fix-boost168-build.patch +# PATCH-FIX-UPSTREAM 0001-Use-absolute-path-CMAKE_INSTALL_FULL_LIBDIR-for-3d-v.patch +Patch4: 0001-Use-absolute-path-CMAKE_INSTALL_FULL_LIBDIR-for-3d-v.patch %if 0%{?suse_version} > 1325 BuildRequires: libboost_system-devel @@ -73,13 +77,15 @@ Requires: python-wxWidgets-3_0 >= 3 # The help function gives an error without the doc package Requires: %{name}-doc = %{version} # You cannot build a schematic without symbols -Requires: %{name}-symbols = %{version} +Requires: %{name}-symbols = %{compatversion} # You cannot create a pcb layout without footprints -Requires: %{name}-footprints = %{version} +Requires: %{name}-footprints = %{compatversion} # Kicad functions without these packages Recommends: %{name}-library-install = %{version} Recommends: %{name}-packages3D +Recommends: %{name}-templates Obsoletes: kicad = 20140120 +Provides: kicad = %{compatversion} %description Kicad is an open source (GPL) software for the creation of electronic schematic @@ -110,7 +116,7 @@ This package contains script for KiCad libraries downloading. %patch1 -p0 %patch2 -p1 %patch3 -%patch4 +%patch4 -p1 cp %{SOURCE2} ./LICENSE.GPLv3 cp %{SOURCE3} ./LICENSE.AGPLv3 @@ -129,7 +135,6 @@ cp %{SOURCE3} ./LICENSE.AGPLv3 -DKICAD_SCRIPTING=ON \ -DKICAD_SCRIPTING_MODULES=ON \ -DKICAD_SCRIPTING_WXPYTHON=ON \ - -DCMAKE_INSTALL_LIBDIR:PATH=%{_lib} \ -DCMAKE_EXE_LINKER_FLAGS="-Wl,--as-needed -Wl,--no-undefined -Wl,-z,now -pie" \ -DPYTHON_SITE_PACKAGE_PATH=%{python_sitearch} \ -DKICAD_SPICE=ON