Date: Sunday, July 15, 2018 @ 02:49:02 Author: kkeen Revision: 359518
upgpkg: kicad 5.0.0-1 Modified: kicad/trunk/PKGBUILD Deleted: kicad/trunk/boost-1.61.patch kicad/trunk/remove-internal-CheckCXXSymbolExists.patch --------------------------------------------+ PKGBUILD | 43 +-- boost-1.61.patch | 347 --------------------------- remove-internal-CheckCXXSymbolExists.patch | 59 ---- 3 files changed, 20 insertions(+), 429 deletions(-) Modified: PKGBUILD =================================================================== --- PKGBUILD 2018-07-15 01:31:19 UTC (rev 359517) +++ PKGBUILD 2018-07-15 02:49:02 UTC (rev 359518) @@ -3,33 +3,30 @@ # Contributor: Marq Schneider <[email protected]> pkgname=kicad -pkgver=4.0.7 -pkgrel=5 +pkgver=5.0.0 +pkgrel=1 pkgdesc="Electronic schematic and printed circuit board (PCB) design tools" arch=('x86_64') #url="http://iut-tice.ujf-grenoble.fr/kicad/" url="http://kicad-pcb.org/" license=('GPL') -#wxgtk3 is not supported yet (FS#54839) -depends=('wxgtk2' 'hicolor-icon-theme' 'desktop-file-utils' 'libsm' 'boost-libs' 'glew' 'python2' 'curl') +#wxgtk3 is still not supported yet (FS#54839) +depends=('wxgtk2' 'python2' 'boost-libs' 'glew' 'curl' 'glm' 'ngspice') +# the AUR git package uses python3 but this release does not support it +# can ngspice be an optdep? +# aur deps? oce makedepends=('cmake' 'zlib' 'mesa' 'boost' 'swig') optdepends=('kicad-library: for footprints and symbols' 'kicad-library-3d: for 3d models of components') -source=("https://launchpad.net/kicad/4.0/$pkgver/+download/kicad-$pkgver.tar.xz" - "kicad-i18n.$pkgver.tar.gz::https://github.com/KiCad/kicad-i18n/archive/$pkgver.tar.gz" - "remove-internal-CheckCXXSymbolExists.patch" - "boost-1.61.patch") -sha512sums=('7b2acd9efadf5d48565f71bd0df2474ecc8fc04145953c13ac27363d48dbe6b0de091e311713635f603aed89ce0759a1d623abb37a139e2c87184ca4e717145b' - '4880705fd7e95c939b7f5e2b7730fd37c426be10596f4cfa80d7df102d9e67232621900395d45f4e735986054f74fb215ae2002a2818faae32b1c75e3cb7e10a' - 'adeb28c59b7b8d9b1383df8eed4e6dcb7cf91c116be3faa29c9c475def3eaf7147bfa11e1a755616be672ad7e730fb71b17399abed80c1af8b600edf71691b78' - 'a960117a4c08144de5111e76a33f208a9b3fe702d10ec2546afc57faf3de3fccfe19b5a5c62b527953d55687e644ed67c9b560cd3baf8b678d127977f3f30cee') +source=("https://launchpad.net/kicad/5.0/$pkgver/+download/kicad-$pkgver.tar.xz" + #"kicad-i18n.$pkgver.tar.gz::https://github.com/KiCad/kicad-i18n/archive/$pkgver.tar.gz" + "kicad-i18n.$pkgver-rc3.tar.gz::https://github.com/KiCad/kicad-i18n/archive/$pkgver-rc3.tar.gz") +sha512sums=('79d4d34e8eaa5b6e4c7baac39a76f86af89adbaf3f9181b8cd846ed3a8db1b4c6dd7a36efefda3394d33ef828917909ad3bd8bb22435af9c6f671efbff125b42' + '8183545d636f64ee2cd6780acb7fec6491c580e6abea8acc1967881644acc79472569b2c21f494d1a6bde5d98b6736655baebb103d646319725edad9c82626f7') prepare() { cd "$srcdir/kicad-$pkgver" - # https://bugs.debian.org/897100 - patch -Np1 -i ../remove-internal-CheckCXXSymbolExists.patch - # Remove on 4.0.5? Or whenever they finally merge it. - patch -Np1 --binary -i ../boost-1.61.patch + find -name '*.py' -exec sed -i '1s/python$/&2/' {} + } build() { @@ -37,18 +34,18 @@ mkdir -p build/Release cd build/Release - cmake ../.. -DKICAD_STABLE_VERSION=ON \ - -DKICAD_REPO_NAME=stable \ - -DKICAD_BUILD_VERSION=$pkgver \ - -DCMAKE_BUILD_TYPE=Release \ + cmake ../.. -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_INSTALL_PREFIX=/usr \ - -DKICAD_SKIP_BOOST=ON \ + -DCMAKE_INSTALL_LIBDIR=lib \ + -DKICAD_USE_OCE=OFF \ -DKICAD_SCRIPTING=ON \ -DKICAD_SCRIPTING_MODULES=ON \ + -DKICAD_SCRIPTING_WXPYTHON=OFF \ + -DKICAD_SCRIPTING_ACTION_MENU=ON \ -DBUILD_GITHUB_PLUGIN=ON make - cd "$srcdir/kicad-i18n-$pkgver" + cd "$srcdir/kicad-i18n-$pkgver-rc3" mkdir -p build/Release cd build/Release cmake ../.. -DCMAKE_INSTALL_PREFIX=/usr @@ -63,6 +60,6 @@ # copy updated linux icons #cp -r -n "$srcdir/$pkgname-icons/resources/linux/mime/icons" "$pkgdir/usr/share/" - cd "$srcdir/kicad-i18n-$pkgver/build/Release" + cd "$srcdir/kicad-i18n-$pkgver-rc3/build/Release" make DESTDIR="$pkgdir" install } Deleted: boost-1.61.patch =================================================================== --- boost-1.61.patch 2018-07-15 01:31:19 UTC (rev 359517) +++ boost-1.61.patch 2018-07-15 02:49:02 UTC (rev 359518) @@ -1,347 +0,0 @@ ---- a/common/tool/tool_manager.cpp -+++ b/common/tool/tool_manager.cpp -@@ -532,11 +532,11 @@ - if( st->cofunc ) - st->Push(); - -+ st->cofunc = new COROUTINE<int, const TOOL_EVENT&>( tr.second ); -+ - // as the state changes, the transition table has to be set up again - st->transitions.clear(); - -- st->cofunc = new COROUTINE<int, const TOOL_EVENT&>( tr.second ); -- - // got match? Run the handler. - st->cofunc->Call( aEvent ); - ---- a/include/tool/coroutine.h -+++ b/include/tool/coroutine.h -@@ -27,10 +28,15 @@ - - #include <cstdlib> - --#include <boost/context/fcontext.hpp> - #include <boost/version.hpp> -+#include <type_traits> - --#include "delegate.h" -+#if BOOST_VERSION <= 106000 -+#include <boost/context/fcontext.hpp> -+#else -+#include <boost/context/execution_context.hpp> -+#include <boost/context/protected_fixedsize_stack.hpp> -+#endif - - /** - * Class COROUNTINE. -@@ -53,13 +59,12 @@ - * See coroutine_example.cpp for sample code. - */ - --template <class ReturnType, class ArgType> -+template <typename ReturnType, typename ArgType> - class COROUTINE - { - public: - COROUTINE() : -- m_saved( NULL ), m_self( NULL ), m_stack( NULL ), m_stackSize( c_defaultStackSize ), -- m_running( false ) -+ COROUTINE( nullptr ) - { - } - -@@ -69,8 +74,7 @@ - */ - template <class T> - COROUTINE( T* object, ReturnType(T::* ptr)( ArgType ) ) : -- m_func( object, ptr ), m_self( NULL ), m_saved( NULL ), m_stack( NULL ), -- m_stackSize( c_defaultStackSize ), m_running( false ) -+ COROUTINE( std::bind( ptr, object, std::placeholders::_1 ) ) - { - } - -@@ -78,9 +82,15 @@ - * Constructor - * Creates a coroutine from a delegate object - */ -- COROUTINE( DELEGATE<ReturnType, ArgType> aEntry ) : -- m_func( aEntry ), m_saved( NULL ), m_self( NULL ), m_stack( NULL ), -- m_stackSize( c_defaultStackSize ), m_running( false ) -+ COROUTINE( std::function<ReturnType(ArgType)> aEntry ) : -+ m_func( std::move( aEntry ) ), -+ m_running( false ), -+#if BOOST_VERSION <= 106000 -+ m_stack( nullptr ), -+ m_stackSize( c_defaultStackSize ), -+#endif -+ m_caller( nullptr ), -+ m_callee( nullptr ) - { - // Avoid not initialized members, and make static analysers quiet - m_args = 0; -@@ -89,18 +99,26 @@ - - ~COROUTINE() - { -- if( m_saved ) -- delete m_saved; -- - #if BOOST_VERSION >= 105600 -- if( m_self ) -- delete m_self; -+ delete m_callee; - #endif - -+#if BOOST_VERSION <= 106000 -+ delete m_caller; -+ - if( m_stack ) - free( m_stack ); -+#endif - } - -+private: -+#if BOOST_VERSION <= 106000 -+ using context_type = boost::context::fcontext_t; -+#else -+ using context_type = boost::context::execution_context<COROUTINE*>; -+#endif -+ -+public: - /** - * Function Yield() - * -@@ -110,7 +128,12 @@ - */ - void Yield() - { -- jump( m_self, m_saved, 0 ); -+#if BOOST_VERSION <= 106000 -+ jump( m_callee, m_caller, false ); -+#else -+ auto result = (*m_caller)( this ); -+ *m_caller = std::move( std::get<0>( result ) ); -+#endif - } - - /** -@@ -122,7 +145,11 @@ - void Yield( ReturnType& aRetVal ) - { - m_retVal = aRetVal; -- jump( m_self, m_saved, 0 ); -+#if BOOST_VERSION <= 106000 -+ jump( m_callee, m_caller, false ); -+#else -+ m_caller( this ); -+#endif - } - - /** -@@ -130,9 +157,9 @@ - * - * Defines the entry point for the coroutine, if not set in the constructor. - */ -- void SetEntry( DELEGATE<ReturnType, ArgType> aEntry ) -+ void SetEntry( std::function<ReturnType(ArgType)> aEntry ) - { -- m_func = aEntry; -+ m_func = std::move( aEntry ); - } - - /* Function Call() -@@ -143,6 +170,10 @@ - */ - bool Call( ArgType aArgs ) - { -+ assert( m_callee == NULL ); -+ assert( m_caller == NULL ); -+ -+#if BOOST_VERSION <= 106000 - // fixme: Clean up stack stuff. Add a guard - m_stack = malloc( c_defaultStackSize ); - -@@ -151,22 +182,32 @@ - - // correct the stack size - m_stackSize -= ( (size_t) m_stack + m_stackSize - (size_t) sp ); -- -- assert( m_self == NULL ); -- assert( m_saved == NULL ); -+#endif - - m_args = &aArgs; --#if BOOST_VERSION >= 105600 -- m_self = new boost::context::fcontext_t(); -- *m_self = boost::context::make_fcontext( sp, m_stackSize, callerStub ); -+ -+#if BOOST_VERSION < 105600 -+ m_callee = boost::context::make_fcontext( sp, m_stackSize, callerStub ); -+#elif BOOST_VERSION <= 106000 -+ m_callee = new context_type( boost::context::make_fcontext( sp, m_stackSize, callerStub ) ); - #else -- m_self = boost::context::make_fcontext( sp, m_stackSize, callerStub ); -+ m_callee = new context_type( std::allocator_arg_t(), -+ boost::context::protected_fixedsize_stack( c_defaultStackSize ), &COROUTINE::callerStub ); -+#endif -+ -+#if BOOST_VERSION <= 106000 -+ m_caller = new context_type(); - #endif -- m_saved = new boost::context::fcontext_t(); - - m_running = true; -+ - // off we go! -- jump( m_saved, m_self, reinterpret_cast<intptr_t>( this ) ); -+#if BOOST_VERSION <= 106000 -+ jump( m_caller, m_callee, reinterpret_cast<intptr_t>( this ) ); -+#else -+ auto result = (*m_callee)( this ); -+ *m_callee = std::move( std::get<0>( result ) ); -+#endif - return m_running; - } - -@@ -179,7 +220,12 @@ - */ - bool Resume() - { -- jump( m_saved, m_self, 0 ); -+#if BOOST_VERSION <= 106000 -+ jump( m_caller, m_callee, false ); -+#else -+ auto result = (*m_callee)( this ); -+ *m_callee = std::move( std::get<0>( result ) ); -+#endif - - return m_running; - } -@@ -208,61 +254,66 @@ - static const int c_defaultStackSize = 2000000; // fixme: make configurable - - /* real entry point of the coroutine */ -+#if BOOST_VERSION <= 106000 - static void callerStub( intptr_t aData ) -+#else -+ static context_type callerStub( context_type caller, COROUTINE* cor ) -+#endif - { - // get pointer to self -+#if BOOST_VERSION <= 106000 - COROUTINE<ReturnType, ArgType>* cor = reinterpret_cast<COROUTINE<ReturnType, ArgType>*>( aData ); -+#else -+ cor->m_caller = &caller; -+#endif - - // call the coroutine method -- cor->m_retVal = cor->m_func( *cor->m_args ); -+ cor->m_retVal = cor->m_func( *( cor->m_args ) ); - cor->m_running = false; - - // go back to wherever we came from. -- jump( cor->m_self, cor->m_saved, 0 ); // reinterpret_cast<intptr_t>( this )); -+#if BOOST_VERSION <= 106000 -+ jump( cor->m_callee, cor->m_caller, 0 ); -+#else -+ return caller; -+#endif - } - - ///> Wrapper for jump_fcontext to assure compatibility between different boost versions -- static inline intptr_t jump(boost::context::fcontext_t* aOld, boost::context::fcontext_t* aNew, -+#if BOOST_VERSION <= 106000 -+ static inline intptr_t jump( context_type* aOld, context_type* aNew, - intptr_t aP, bool aPreserveFPU = true ) - { --#if BOOST_VERSION >= 105600 -- return boost::context::jump_fcontext( aOld, *aNew, aP, aPreserveFPU ); --#else -+#if BOOST_VERSION < 105600 - return boost::context::jump_fcontext( aOld, aNew, aP, aPreserveFPU ); -+#else -+ return boost::context::jump_fcontext( aOld, *aNew, aP, aPreserveFPU ); - #endif - } -+#endif - -- template <typename T> -- struct strip_ref -- { -- typedef T result; -- }; -+ std::function<ReturnType(ArgType)> m_func; - -- template <typename T> -- struct strip_ref<T&> -- { -- typedef T result; -- }; -+ bool m_running; - -- DELEGATE<ReturnType, ArgType> m_func; -+#if BOOST_VERSION <= 106000 -+ ///< coroutine stack -+ void* m_stack; -+ -+ size_t m_stackSize; -+#endif - - ///< pointer to coroutine entry arguments. Stripped of references - ///< to avoid compiler errors. -- typename strip_ref<ArgType>::result* m_args; -+ typename std::remove_reference<ArgType>::type* m_args; -+ - ReturnType m_retVal; - - ///< saved caller context -- boost::context::fcontext_t* m_saved; -+ context_type* m_caller; - - ///< saved coroutine context -- boost::context::fcontext_t* m_self; -- -- ///< coroutine stack -- void* m_stack; -- -- size_t m_stackSize; -- -- bool m_running; -+ context_type* m_callee; - }; - - #endif ---- a/include/tool/tool_base.h -+++ b/include/tool/tool_base.h -@@ -31,7 +32,7 @@ - #include <tool/tool_event.h> - #include <tool/tool_settings.h> - --#include <tool/delegate.h> -+#include <functional> - - class EDA_ITEM; - class TOOL_MANAGER; -@@ -53,7 +54,9 @@ - - /// Unique identifier for tools - typedef int TOOL_ID; --typedef DELEGATE<int, const TOOL_EVENT&> TOOL_STATE_FUNC; -+ -+using TOOL_STATE_FUNC = std::function<int(const TOOL_EVENT&)>; -+ - - /** - * Class TOOL_BASE ---- a/include/tool/tool_interactive.h -+++ b/include/tool/tool_interactive.h -@@ -113,7 +114,7 @@ - void TOOL_INTERACTIVE::Go( int (T::* aStateFunc)( const TOOL_EVENT& ), - const TOOL_EVENT_LIST& aConditions ) - { -- TOOL_STATE_FUNC sptr( static_cast<T*>( this ), aStateFunc ); -+ TOOL_STATE_FUNC sptr = std::bind( aStateFunc, static_cast<T*>( this ), std::placeholders::_1 ); - - goInternal( sptr, aConditions ); - } - Deleted: remove-internal-CheckCXXSymbolExists.patch =================================================================== --- remove-internal-CheckCXXSymbolExists.patch 2018-07-15 01:31:19 UTC (rev 359517) +++ remove-internal-CheckCXXSymbolExists.patch 2018-07-15 02:49:02 UTC (rev 359518) @@ -1,59 +0,0 @@ -From 2e0b75c058d676f427328506bbf3bc10079da117 Mon Sep 17 00:00:00 2001 -From: Seth Hillbrand <[email protected]> -Date: Fri, 30 Mar 2018 14:47:16 -0700 -Subject: Remove internal CheckCXXSymbolExists - -Since Cmake 2.8.6, Cmake provides this macro. Our use references -internal Cmake variables that have changes in Cmake 3.11. - -diff --git a/CMakeModules/CheckCXXSymbolExists.cmake b/CMakeModules/CheckCXXSymbolExists.cmake -deleted file mode 100644 -index 2100973..0000000 ---- a/CMakeModules/CheckCXXSymbolExists.cmake -+++ /dev/null -@@ -1,42 +0,0 @@ --# - Check if a symbol exists as a function, variable, or macro in C++ --# CHECK_CXX_SYMBOL_EXISTS(<symbol> <files> <variable>) --# --# Check that the <symbol> is available after including given header --# <files> and store the result in a <variable>. Specify the list --# of files in one argument as a semicolon-separated list. --# CHECK_CXX_SYMBOL_EXISTS() can be used to check in C++ files, as opposed --# to CHECK_SYMBOL_EXISTS(), which works only for C. --# --# If the header files define the symbol as a macro it is considered --# available and assumed to work. If the header files declare the --# symbol as a function or variable then the symbol must also be --# available for linking. If the symbol is a type or enum value --# it will not be recognized (consider using CheckTypeSize or --# CheckCSourceCompiles). --# --# The following variables may be set before calling this macro to --# modify the way the check is run: --# --# CMAKE_REQUIRED_FLAGS = string of compile command line flags --# CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar) --# CMAKE_REQUIRED_INCLUDES = list of include directories --# CMAKE_REQUIRED_LIBRARIES = list of libraries to link -- --#============================================================================= --# Copyright 2003-2011 Kitware, Inc. --# --# Distributed under the OSI-approved BSD License (the "License"); --# see accompanying file Copyright.txt for details. --# --# This software is distributed WITHOUT ANY WARRANTY; without even the --# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. --# See the License for more information. --#============================================================================= --# (To distribute this file outside of CMake, substitute the full --# License text for the above reference.) -- --include(CheckSymbolExists) -- --macro(CHECK_CXX_SYMBOL_EXISTS SYMBOL FILES VARIABLE) -- _CHECK_SYMBOL_EXISTS("${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/CheckSymbolExists.cxx" "${SYMBOL}" "${FILES}" "${VARIABLE}" ) --endmacro() --- -cgit v0.10.2 -
