Package Details: attica-qt4 0.4.2-7

Git Clone URL: https://aur.archlinux.org/attica-qt4.git (read-only, click to copy)
Package Base: attica-qt4
Description: A Qt4 library that implements the Open Collaboration Services API
Upstream URL: https://projects.kde.org/projects/frameworks/attica
Licenses: LGPL
Submitter: arojas
Maintainer: bidulock
Last Packager: bidulock
Votes: 18
Popularity: 0.000008
First Submitted: 2018-08-24 06:44 (UTC)
Last Updated: 2018-11-04 23:50 (UTC)

Dependencies (2)

Required by (1)

Sources (1)

Latest Comments

« First ‹ Previous 1 2 3

bidulock commented on 2018-11-03 17:06 (UTC)

Builds fine for me now in a clean chroot too, so I reverted the changes and made it a version 0.4.2-6.

snack commented on 2018-11-03 08:43 (UTC) (edited on 2018-11-03 08:49 (UTC) by snack)

Version 0.4.2-5 breaks my system since it produces a wrongly versioned library file: libattica.so.1.0.0 instead of libattica.so.0.4.2. I reverted to attica-qt4-0.4.2-4 (built from clean chroot) and it seems to fix the problems.

Rhinoceros commented on 2018-11-02 04:39 (UTC)

FWIW I had to downgrade attica-qt4 to the qt4-built version to get the stable qt4-version of Amarok to work.

Vrakfall commented on 2018-11-01 21:09 (UTC)

I don't understand the point to label this package "qt4" if we end up building it with qt5...

flaviut commented on 2018-10-19 17:30 (UTC)

And another patch to install it into the correct directory & fix namcap errors:

From c35433450a100e155024fa113d4128deac1adf7b Mon Sep 17 00:00:00 2001
From: Flaviu Tamas <tamasflaviu@gmail.com>
Date: Fri, 19 Oct 2018 13:20:17 -0400
Subject: [PATCH] Fix lib install path

---
 PKGBUILD | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/PKGBUILD b/PKGBUILD
index 27f6f97..3da53d7 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -9,7 +9,7 @@ pkgdesc='A Qt4 library that implements the Open Collaboration Services API'
 arch=('x86_64' 'i686')
 url='<https://projects.kde.org/projects/frameworks/attica>'
 license=('LGPL')
-depends=('qt4')
+depends=('qt5-base')
 makedepends=('cmake')
 source=("<http://download.kde.org/stable/attica/attica>-${pkgver}.tar.bz2"
         "FindQt5Transitional.cmake"
@@ -28,7 +28,8 @@ build() {
   cmake ../attica-${pkgver} \
     -DCMAKE_MODULE_PATH:PATH="$PWD/../attica-${pkgver}/lib/cmake" \
     -DCMAKE_BUILD_TYPE=Release \
-    -DCMAKE_INSTALL_PREFIX=/usr
+    -DCMAKE_INSTALL_PREFIX=/usr \
+    -DCMAKE_INSTALL_LIBDIR=lib
   make
 }

-- 
2.19.1

flaviut commented on 2018-10-19 17:14 (UTC) (edited on 2018-10-19 17:14 (UTC) by flaviut)

I had to apply this patch to get this to build:

commit f6321cc25aab156f8ad34c8e7e2c78b19b766369 (HEAD -> master)
Author: Flaviu Tamas <tamasflaviu@gmail.com>
Date:   Fri Oct 19 13:03:11 2018 -0400

    Fix build as of 2018-10-19

diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..b514be6
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,6 @@
+*
+!PKGBUILD
+!.SRCINFO
+!.gitignore
+!FindQt5Transitional.cmake
+!ECMQt4To5Porting.cmake
diff --git a/ECMQt4To5Porting.cmake b/ECMQt4To5Porting.cmake
new file mode 100644
index 0000000..02b0ef4
--- /dev/null
+++ b/ECMQt4To5Porting.cmake
@@ -0,0 +1,238 @@
+#=============================================================================
+# Copyright 2005-2011 Kitware, Inc.
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# * Redistributions of source code must retain the above copyright
+#   notice, this list of conditions and the following disclaimer.
+#
+# * Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in the
+#   documentation and/or other materials provided with the distribution.
+#
+# * Neither the name of Kitware, Inc. nor the names of its
+#   contributors may be used to endorse or promote products derived
+#   from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+# HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#=============================================================================
+
+# The automoc_qt4 macro is superceded by CMAKE_AUTOMOC from CMake 2.8.6
+# A Qt 5 version is not provided by CMake or Qt.
+
+include(MacroAddFileDependencies)
+
~/.c/y/attica-qt4 ❯❯❯ git show HEAD | cat                                                                     master ⬆
commit f6321cc25aab156f8ad34c8e7e2c78b19b766369
Author: Flaviu Tamas <tamasflaviu@gmail.com>
Date:   Fri Oct 19 13:03:11 2018 -0400

    Fix build as of 2018-10-19

diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..b514be6
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,6 @@
+*
+!PKGBUILD
+!.SRCINFO
+!.gitignore
+!FindQt5Transitional.cmake
+!ECMQt4To5Porting.cmake
diff --git a/ECMQt4To5Porting.cmake b/ECMQt4To5Porting.cmake
new file mode 100644
index 0000000..02b0ef4
--- /dev/null
+++ b/ECMQt4To5Porting.cmake
@@ -0,0 +1,238 @@
+#=============================================================================
+# Copyright 2005-2011 Kitware, Inc.
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# * Redistributions of source code must retain the above copyright
+#   notice, this list of conditions and the following disclaimer.
+#
+# * Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in the
+#   documentation and/or other materials provided with the distribution.
+#
+# * Neither the name of Kitware, Inc. nor the names of its
+#   contributors may be used to endorse or promote products derived
+#   from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+# HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#=============================================================================
+
+# The automoc_qt4 macro is superceded by CMAKE_AUTOMOC from CMake 2.8.6
+# A Qt 5 version is not provided by CMake or Qt.
+
+include(MacroAddFileDependencies)
+
+MACRO (QT4_GET_MOC_FLAGS _moc_flags)
+  SET(${_moc_flags})
+  GET_DIRECTORY_PROPERTY(_inc_DIRS INCLUDE_DIRECTORIES)
+
+  FOREACH(_current ${_inc_DIRS})
+    IF("${_current}" MATCHES "\\.framework/?$")
+      STRING(REGEX REPLACE "/[^/]+\\.framework" "" framework_path "${_current}")
+      SET(${_moc_flags} ${${_moc_flags}} "-F${framework_path}")
+    ELSE("${_current}" MATCHES "\\.framework/?$")
+      SET(${_moc_flags} ${${_moc_flags}} "-I${_current}")
+    ENDIF("${_current}" MATCHES "\\.framework/?$")
+  ENDFOREACH(_current ${_inc_DIRS})
+
+  GET_DIRECTORY_PROPERTY(_defines COMPILE_DEFINITIONS)
+  FOREACH(_current ${_defines})
+    SET(${_moc_flags} ${${_moc_flags}} "-D${_current}")
+  ENDFOREACH(_current ${_defines})
+
+  IF(Q_WS_WIN)
+    SET(${_moc_flags} ${${_moc_flags}} -DWIN32)
+  ENDIF(Q_WS_WIN)
+
+ENDMACRO(QT4_GET_MOC_FLAGS)
+
+# helper macro to set up a moc rule
+MACRO (QT4_CREATE_MOC_COMMAND infile outfile moc_flags moc_options)
+  # For Windows, create a parameters file to work around command line length limit
+  IF (WIN32)
+    # Pass the parameters in a file.  Set the working directory to
+    # be that containing the parameters file and reference it by
+    # just the file name.  This is necessary because the moc tool on
+    # MinGW builds does not seem to handle spaces in the path to the
+    # file given with the @ syntax.
+    GET_FILENAME_COMPONENT(_moc_outfile_name "${outfile}" NAME)
+    GET_FILENAME_COMPONENT(_moc_outfile_dir "${outfile}" PATH)
+    IF(_moc_outfile_dir)
+      SET(_moc_working_dir WORKING_DIRECTORY ${_moc_outfile_dir})
+    ENDIF(_moc_outfile_dir)
+    SET (_moc_parameters_file ${outfile}_parameters)
+    SET (_moc_parameters ${moc_flags} ${moc_options} -o "${outfile}" "${infile}")
+    STRING (REPLACE ";" "\n" _moc_parameters "${_moc_parameters}")
+    FILE (WRITE ${_moc_parameters_file} "${_moc_parameters}")
+    ADD_CUSTOM_COMMAND(OUTPUT ${outfile}
+                       COMMAND ${QT_MOC_EXECUTABLE} @${_moc_outfile_name}_parameters
+                       DEPENDS ${infile}
+                       ${_moc_working_dir}
+                       VERBATIM)
+  ELSE (WIN32)
+    ADD_CUSTOM_COMMAND(OUTPUT ${outfile}
+                       COMMAND ${QT_MOC_EXECUTABLE}
+                       ARGS ${moc_flags} ${moc_options} -o ${outfile} ${infile}
+                       DEPENDS ${infile} VERBATIM)
+  ENDIF (WIN32)
+ENDMACRO (QT4_CREATE_MOC_COMMAND)
+
+
+MACRO(QT4_AUTOMOC)
+  QT4_GET_MOC_FLAGS(_moc_INCS)
+
+  SET(_matching_FILES )
+  FOREACH (_current_FILE ${ARGN})
+
+    GET_FILENAME_COMPONENT(_abs_FILE ${_current_FILE} ABSOLUTE)
+    # if "SKIP_AUTOMOC" is set to true, we will not handle this file here.
+    # This is required to make uic work correctly:
+    # we need to add generated .cpp files to the sources (to compile them),
+    # but we cannot let automoc handle them, as the .cpp files don't exist yet when
+    # cmake is run for the very first time on them -> however the .cpp files might
+    # exist at a later run. at that time we need to skip them, so that we don't add two
+    # different rules for the same moc file
+    GET_SOURCE_FILE_PROPERTY(_skip ${_abs_FILE} SKIP_AUTOMOC)
+
+    IF ( NOT _skip AND EXISTS ${_abs_FILE} )
+
+      FILE(READ ${_abs_FILE} _contents)
+
+      GET_FILENAME_COMPONENT(_abs_PATH ${_abs_FILE} PATH)
+
+      STRING(REGEX MATCHALL "# *include +[^ ]+\\.moc[\">]" _match "${_contents}")
+      IF(_match)
+        FOREACH (_current_MOC_INC ${_match})
+          STRING(REGEX MATCH "[^ <\"]+\\.moc" _current_MOC "${_current_MOC_INC}")
+
+          GET_FILENAME_COMPONENT(_basename ${_current_MOC} NAME_WE)
+          IF(EXISTS ${_abs_PATH}/${_basename}.hpp)
+            SET(_header ${_abs_PATH}/${_basename}.hpp)
+          ELSE(EXISTS ${_abs_PATH}/${_basename}.hpp)
+            SET(_header ${_abs_PATH}/${_basename}.h)
+          ENDIF(EXISTS ${_abs_PATH}/${_basename}.hpp)
+          SET(_moc    ${CMAKE_CURRENT_BINARY_DIR}/${_current_MOC})
+          QT4_CREATE_MOC_COMMAND(${_header} ${_moc} "${_moc_INCS}" "")
+          MACRO_ADD_FILE_DEPENDENCIES(${_abs_FILE} ${_moc})
+        ENDFOREACH (_current_MOC_INC)
+      ENDIF(_match)
+    ENDIF ( NOT _skip AND EXISTS ${_abs_FILE} )
+  ENDFOREACH (_current_FILE)
+ENDMACRO(QT4_AUTOMOC)
+
+
+# Portability helpers.
+
+set(QT_QTGUI_LIBRARIES
+  ${Qt5Gui_LIBRARIES}
+  ${Qt5Widgets_LIBRARIES}
+  ${Qt5PrintSupport_LIBRARIES}
+  ${Qt5Svg_LIBRARIES}
+)
+
+set(QT_INCLUDES
+    ${Qt5Gui_INCLUDE_DIRS}
+    ${Qt5Widgets_INCLUDE_DIRS}
+    ${Qt5PrintSupport_INCLUDE_DIRS}
+    ${Qt5Svg_INCLUDE_DIRS}
+)
+set(QT_QTGUI_LIBRARY ${QT_QTGUI_LIBRARIES})
+
+set(_qt_modules
+  Core
+  Declarative
+  Widgets
+  Script
+  ScriptTools
+  DBus
+  Network
+  Test
+  Designer
+  Concurrent
+  Xml
+  UiTools
+  Qml
+  Quick1
+  WebKit
+  WebKitWidgets
+  Sql
+  OpenGL
+)
+
+foreach(_module ${_qt_modules})
+    string(TOUPPER ${_module} _module_upper)
+    set(QT_QT${_module_upper}_LIBRARIES ${Qt5${_module}_LIBRARIES})
+    set(QT_QT${_module_upper}_LIBRARY ${QT_QT${_module_upper}_LIBRARIES})
+    list(APPEND QT_INCLUDES ${Qt5${_module}_INCLUDE_DIRS})
+    set(QT_QT${_module_upper}_FOUND ${Qt5${_module}_FOUND})
+endforeach()
+
+list(APPEND QT_QTCORE_LIBRARIES ${Qt5Concurrent_LIBRARIES})
+list(APPEND QT_QTCORE_LIBRARY ${Qt5Concurrent_LIBRARIES})
+
+list(APPEND QT_QTWEBKIT_LIBRARIES ${Qt5WebKitWidgets_LIBRARIES})
+list(APPEND QT_QTWEBKIT_LIBRARY ${Qt5WebKitWidgets_LIBRARIES})
+
+set(QT_QTDECLARATIVE_LIBRARIES ${Qt5Quick1_LIBRARIES})
+set(QT_QTDECLARATIVE_LIBRARY ${Qt5Quick1_LIBRARIES})
+
+get_target_property(QT_QMAKE_EXECUTABLE Qt5::qmake LOCATION)
+get_target_property(QT_RCC_EXECUTABLE Qt5::rcc LOCATION)
+if (TARGET Qt5::uic)
+    get_target_property(QT_UIC_EXECUTABLE Qt5::uic LOCATION)
+endif()
+
+if (TARGET Qt5::qdbuscpp2xml)
+    get_target_property(QT_QDBUSCPP2XML_EXECUTABLE Qt5::qdbuscpp2xml LOCATION)
+endif()
+
+if (TARGET Qt5::qdbusxml2cpp)
+    get_target_property(QT_QDBUSXML2CPP_EXECUTABLE Qt5::qdbusxml2cpp LOCATION)
+endif()
+
+add_definitions(-DQT_DISABLE_DEPRECATED_BEFORE=0)
+
+macro(qt4_wrap_ui)
+  qt5_wrap_ui(${ARGN})
+endmacro()
+
+macro(qt4_wrap_cpp)
+  qt5_wrap_cpp(${ARGN})
+endmacro()
+
+macro(qt4_generate_moc)
+  qt5_generate_moc(${ARGN})
+endmacro()
+
+macro(qt4_add_dbus_adaptor)
+  qt5_add_dbus_adaptor(${ARGN})
+endmacro()
+
+macro(qt4_add_dbus_interfaces)
+  qt5_add_dbus_interfaces(${ARGN})
+endmacro()
+
+macro(qt4_add_dbus_interface)
+  qt5_add_dbus_interface(${ARGN})
+endmacro()
+
+macro(qt4_generate_dbus_interface)
+  qt5_generate_dbus_interface(${ARGN})
+endmacro()
+
+macro(qt4_add_resources)
+  qt5_add_resources(${ARGN})
+endmacro()
diff --git a/FindQt5Transitional.cmake b/FindQt5Transitional.cmake
new file mode 100644
index 0000000..1e9c31b
--- /dev/null
+++ b/FindQt5Transitional.cmake
@@ -0,0 +1,78 @@
+find_package(Qt5Core QUIET)
+
+if (Qt5Core_FOUND)
+  if (NOT Qt5Transitional_FIND_COMPONENTS)
+    foreach(_component
+          Core
+          Gui
+          DBus
+          Designer
+          Declarative
+          Script
+          ScriptTools
+          Network
+          Test
+          Xml
+          Svg
+          Sql
+          Widgets
+          PrintSupport
+          Concurrent
+          UiTools
+          WebKit
+          WebKitWidgets
+          OpenGL
+        )
+      find_package(Qt5${_component})
+      list(APPEND QT_LIBRARIES ${Qt5${_component}_LIBRARIES})
+    endforeach()
+  else()
+    foreach(_component ${Qt5Transitional_FIND_COMPONENTS})
+      find_package(Qt5${_component} REQUIRED)
+      if ("${_component}" STREQUAL "WebKit")
+        find_package(Qt5WebKitWidgets REQUIRED)
+        list(APPEND QT_LIBRARIES ${Qt5WebKitWidgets_LIBRARIES} )
+      endif()
+      if ("${_component}" STREQUAL "Gui")
+        find_package(Qt5Widgets REQUIRED)
+        find_package(Qt5PrintSupport REQUIRED)
+        find_package(Qt5Svg REQUIRED)
+        list(APPEND QT_LIBRARIES ${Qt5Widgets_LIBRARIES}
+                                 ${Qt5PrintSupport_LIBRARIES}
+                                 ${Qt5Svg_LIBRARIES} )
+      endif()
+      if ("${_component}" STREQUAL "Core")
+        find_package(Qt5Concurrent REQUIRED)
+        list(APPEND QT_LIBRARIES ${Qt5Concurrent_LIBRARIES} )
+      endif()
+    endforeach()
+  endif()
+
+  set(Qt5Transitional_FOUND TRUE)
+  set(QT5_BUILD TRUE)
+
+  get_filename_component(_modules_dir "${CMAKE_CURRENT_LIST_DIR}/../cmake" ABSOLUTE)
+  include("${_modules_dir}/ECMQt4To5Porting.cmake") # TODO: Port away from this.
+  include_directories(${QT_INCLUDES}) # TODO: Port away from this.
+
+  if (Qt5_POSITION_INDEPENDENT_CODE)
+    set(CMAKE_POSITION_INDEPENDENT_CODE ON)
+  endif()
+
+else()
+  foreach(_component ${Qt5Transitional_FIND_COMPONENTS})
+    if("${_component}" STREQUAL "Widgets")  # new in Qt5
+      set(_component Gui)
+    elseif("${_component}" STREQUAL "Concurrent")   # new in Qt5
+      set(_component Core)
+    endif()
+    list(APPEND _components Qt${_component})
+  endforeach()
+  find_package(Qt4 ${QT_MIN_VERSION} REQUIRED ${_components})
+  include_directories(${QT_INCLUDES})
+
+
+  if(QT4_FOUND)
+    set(Qt5Transitional_FOUND TRUE)
+  endif()
+endif()
diff --git a/PKGBUILD b/PKGBUILD
index [`e7b029f`](https://aur.archlinux.org/cgit/aur.git/commit/?h=attica-qt4&id=e7b029f)..27f6f97 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -11,16 +11,22 @@ url='<https://projects.kde.org/projects/frameworks/attica>'
 license=('LGPL')
 depends=('qt4')
 makedepends=('cmake')
-source=("<http://download.kde.org/stable/attica/attica>-${pkgver}.tar.bz2")
-md5sums=('d62c5c9489a68432e8d990dde7680c24')
+source=("<http://download.kde.org/stable/attica/attica>-${pkgver}.tar.bz2"
+        "FindQt5Transitional.cmake"
+        "ECMQt4To5Porting.cmake")
+sha256sums=('3b9c53770862c0b21b7af7ea15951c35831126022bb8d052760d9cf8bd7ee4f8'
+            '44ecad815b2ebbb81fa1f8eb7748fcdfb62cc1e3ecf36082cde9f2d04f364888'
+            'ff00d723c1c765d8a53870d073739e47b3ffb42c8f92e45c12b438785f65f0ec')

 prepare() {
-  mkdir build
+  mkdir -p build
+  cp *.cmake attica-${pkgver}/lib/cmake/
 }

 build() {
   cd build
   cmake ../attica-${pkgver} \
+    -DCMAKE_MODULE_PATH:PATH="$PWD/../attica-${pkgver}/lib/cmake" \
     -DCMAKE_BUILD_TYPE=Release \
     -DCMAKE_INSTALL_PREFIX=/usr
   make

edwinknox commented on 2018-10-10 10:15 (UTC) (edited on 2018-10-10 10:15 (UTC) by edwinknox)

It works fine however on my framework with the tarball (outside of a git repo), so far I can't recreate this blunder with any setup or variant, yet I don't see a motivation behind why it should work now for individuals that experienced this issue before.https://www.assignmentprofs.co.uk/

Sabre78 commented on 2018-09-15 19:09 (UTC)

cant install getting this error CMake Error at CMakeLists.txt:10 (find_package)

xuiqzy commented on 2018-09-09 17:56 (UTC)

Please change source URL to TLS encrypted https variant. Tested and works fine. Thanks! :)