public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Andreas Sturmlechner" <asturm@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: sci-libs/voro++/, sci-libs/voro++/files/
Date: Sat,  6 Mar 2021 11:10:05 +0000 (UTC)	[thread overview]
Message-ID: <1615028986.4cd1c13c41ae437acff1ee44811365d2b61f3b5c.asturm@gentoo> (raw)

commit:     4cd1c13c41ae437acff1ee44811365d2b61f3b5c
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Sat Mar  6 10:20:55 2021 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Sat Mar  6 11:09:46 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4cd1c13c

sci-libs/voro++: EAPI-7 bump, use cmake.eclass, use GNUInstallDirs

Raise cmake minimum to 3.0 for future compatibility.
Rename duplicate 'help' custom target to fix build with ninja.
Drop wholly unnecessary uninstall part from CMakeLists.txt.
Simplify ebuild.

...45 lines saved!

Package-Manager: Portage-3.0.16, Repoman-3.0.2
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 sci-libs/voro++/files/voro++-0.4.6-cmake.patch | 60 +++++---------------------
 sci-libs/voro++/voro++-0.4.6-r1.ebuild         | 15 ++-----
 2 files changed, 15 insertions(+), 60 deletions(-)

diff --git a/sci-libs/voro++/files/voro++-0.4.6-cmake.patch b/sci-libs/voro++/files/voro++-0.4.6-cmake.patch
index c848748c5cf..f8310097b76 100644
--- a/sci-libs/voro++/files/voro++-0.4.6-cmake.patch
+++ b/sci-libs/voro++/files/voro++-0.4.6-cmake.patch
@@ -1,9 +1,9 @@
 Index: CMakeLists.txt
 ===================================================================
---- a/CMakeLists.txt	(revision 0)
-+++ b/CMakeLists.txt	(working copy)
-@@ -0,0 +1,109 @@
-+cmake_minimum_required(VERSION 2.6)
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -0,0 +1,98 @@
++cmake_minimum_required(VERSION 2.8.12)
 +
 +project(voro++)
 +
@@ -28,18 +28,9 @@ Index: CMakeLists.txt
 +include(CheckCXXCompilerFlag)
 +
 +########################################################################
-+# User input options                                                   #
++# Standard install paths                                               #
 +########################################################################
-+option(BUILD_SHARED_LIBS "Build shared libs" ON)
-+if (NOT DEFINED LIB)
-+  set(LIB "lib")
-+endif(NOT DEFINED LIB)
-+if (NOT DEFINED MAN)
-+  set(MAN "share/man")
-+endif(NOT DEFINED MAN)
-+if (NOT DEFINED DATA)
-+  set(DATA "share/voro++")
-+endif(NOT DEFINED DATA)
++include(GNUInstallDirs)
 +
 +########################################################################
 +#Find external packages
@@ -78,14 +69,14 @@ Index: CMakeLists.txt
 +set_target_properties(voro++ PROPERTIES 
 +  LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/src"
 +  SOVERSION ${SOVERSION})
-+install(TARGETS voro++ LIBRARY DESTINATION ${LIB} ARCHIVE DESTINATION ${LIB})
++install(TARGETS voro++ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
 +
 +add_executable(cmd_line src/cmd_line.cc)
 +target_link_libraries(cmd_line voro++)
 +#cannot have two target with the same name
 +set_target_properties(cmd_line PROPERTIES OUTPUT_NAME voro++ 
 +  RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/src") 
-+install(TARGETS cmd_line RUNTIME DESTINATION bin)
++install(TARGETS cmd_line RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
 +
 +#for voto++.hh
 +include_directories(${CMAKE_SOURCE_DIR}/src)
@@ -102,40 +93,11 @@ Index: CMakeLists.txt
 +endforeach(SOURCE)
 +
 +file(GLOB_RECURSE VORO_HEADERS src/*.hh)
-+install(FILES ${VORO_HEADERS} DESTINATION include/voro++)
-+install(FILES ${CMAKE_SOURCE_DIR}/man/voro++.1 DESTINATION ${MAN}/man1)
++install(FILES ${VORO_HEADERS} DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/voro++)
++install(FILES ${CMAKE_SOURCE_DIR}/man/voro++.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
 +
 +if (DOXYGEN_FOUND)
-+  add_custom_target(help COMMAND ${DOXYGEN_EXECUTABLE} src/Doxyfile 
++  add_custom_target(doxygen COMMAND ${DOXYGEN_EXECUTABLE} src/Doxyfile
 +    COMMENT "Build doxygen documentation")
 +endif (DOXYGEN_FOUND)
 +
-+configure_file(${CMAKE_MODULE_PATH}/cmake_uninstall.cmake.in ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake IMMEDIATE @ONLY)
-+add_custom_target(uninstall COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)
-Index: CMakeModules/cmake_uninstall.cmake.in
-===================================================================
---- a/CMakeModules/cmake_uninstall.cmake.in	(revision 0)
-+++ b/CMakeModules/cmake_uninstall.cmake.in	(working copy)
-@@ -0,0 +1,22 @@
-+IF(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt")
-+  MESSAGE(FATAL_ERROR "Cannot find install manifest: \"@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt\"")
-+ENDIF(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt")
-+
-+FILE(READ "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt" files)
-+STRING(REGEX REPLACE "\n" ";" files "${files}")
-+FOREACH(file ${files})
-+  MESSAGE(STATUS "Uninstalling \"$ENV{DESTDIR}${file}\"")
-+  IF(EXISTS "$ENV{DESTDIR}${file}")
-+    EXEC_PROGRAM(
-+      "@CMAKE_COMMAND@" ARGS "-E remove \"$ENV{DESTDIR}${file}\""
-+      OUTPUT_VARIABLE rm_out
-+      RETURN_VALUE rm_retval
-+      )
-+    IF(NOT "${rm_retval}" STREQUAL 0)
-+      MESSAGE(FATAL_ERROR "Problem when removing \"$ENV{DESTDIR}${file}\"")
-+    ENDIF(NOT "${rm_retval}" STREQUAL 0)
-+  ELSE(EXISTS "$ENV{DESTDIR}${file}")
-+    MESSAGE(STATUS "File \"$ENV{DESTDIR}${file}\" does not exist.")
-+  ENDIF(EXISTS "$ENV{DESTDIR}${file}")
-+ENDFOREACH(file)
-+

diff --git a/sci-libs/voro++/voro++-0.4.6-r1.ebuild b/sci-libs/voro++/voro++-0.4.6-r1.ebuild
index b1fa7262375..a2ab69b03aa 100644
--- a/sci-libs/voro++/voro++-0.4.6-r1.ebuild
+++ b/sci-libs/voro++/voro++-0.4.6-r1.ebuild
@@ -1,11 +1,11 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=6
+EAPI=7
 
-inherit cmake-utils
+inherit cmake
 
-DESCRIPTION="A 3D Voronoi cell software library"
+DESCRIPTION="3D Voronoi cell software library"
 HOMEPAGE="http://math.lbl.gov/voro++/"
 SRC_URI="http://math.lbl.gov/voro++/download/dir/${P}.tar.gz"
 
@@ -15,10 +15,3 @@ KEYWORDS="amd64 x86"
 IUSE=""
 
 PATCHES=( "${FILESDIR}/${P}-cmake.patch" )
-
-src_configure() {
-	local mycmakeargs=(
-		-DLIB=$(get_libdir)
-	)
-	cmake-utils_src_configure
-}


             reply	other threads:[~2021-03-06 11:10 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-06 11:10 Andreas Sturmlechner [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-09-07 14:49 [gentoo-commits] repo/gentoo:master commit in: sci-libs/voro++/, sci-libs/voro++/files/ Guilherme Amadio
2018-10-14 13:35 Andreas Sturmlechner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1615028986.4cd1c13c41ae437acff1ee44811365d2b61f3b5c.asturm@gentoo \
    --to=asturm@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox