1 |
commit: 743c2d9bf3e68329bb350f08d212fe0ebd9a6aa0 |
2 |
Author: Christoph Junghans <junghans <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Jun 1 00:19:03 2018 +0000 |
4 |
Commit: Christoph Junghans <junghans <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Jun 1 00:19:03 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/sci.git/commit/?id=743c2d9b |
7 |
|
8 |
sci-libs/lmfit: version bump |
9 |
|
10 |
Package-Manager: Portage-2.3.24, Repoman-2.3.6 |
11 |
|
12 |
sci-libs/lmfit/files/lmfit-7.0-cmake.patch | 66 ++++++++++++++++++++++++++++++ |
13 |
sci-libs/lmfit/lmfit-7.0.ebuild | 25 +++++++++++ |
14 |
2 files changed, 91 insertions(+) |
15 |
|
16 |
diff --git a/sci-libs/lmfit/files/lmfit-7.0-cmake.patch b/sci-libs/lmfit/files/lmfit-7.0-cmake.patch |
17 |
new file mode 100644 |
18 |
index 000000000..9ca4efb24 |
19 |
--- /dev/null |
20 |
+++ b/sci-libs/lmfit/files/lmfit-7.0-cmake.patch |
21 |
@@ -0,0 +1,66 @@ |
22 |
+From 4e66272e1f5ebb220af517ca4d8804936f7f465c Mon Sep 17 00:00:00 2001 |
23 |
+From: Christoph Junghans <junghans@×××××.org> |
24 |
+Date: Thu, 31 May 2018 18:11:26 -0600 |
25 |
+Subject: [PATCH] cmake: minor distribution tweaks |
26 |
+ |
27 |
+- Use GNUInstallDirs to allow to configure install dirs |
28 |
+- Allow to disable injecting c flags |
29 |
+ |
30 |
+Signed-off-by: Christoph Junghans <junghans@×××××.org> |
31 |
+--- |
32 |
+ CMakeLists.txt | 7 +++++-- |
33 |
+ lib/CMakeLists.txt | 4 ++-- |
34 |
+ man/CMakeLists.txt | 2 +- |
35 |
+ 3 files changed, 8 insertions(+), 5 deletions(-) |
36 |
+ |
37 |
+diff --git a/CMakeLists.txt b/CMakeLists.txt |
38 |
+index f2d0bdf..75753d3 100644 |
39 |
+--- a/CMakeLists.txt |
40 |
++++ b/CMakeLists.txt |
41 |
+@@ -13,9 +13,12 @@ set(lmfit_VERSION ${lmfit_SOVERSION}.0) # lib version |
42 |
+ # --- Declare project-wide user flags, and set default values --- |
43 |
+ option(FITTEST "Build with FitTest" OFF) |
44 |
+ |
45 |
+-set(destination ${CMAKE_INSTALL_PREFIX}) |
46 |
++include(GNUInstallDirs) |
47 |
+ |
48 |
+-set(CMAKE_C_FLAGS "${CMAKE_CXX_FLAGS} -g -O2 -pedantic -Wall -Wno-sign-compare -Wno-unused-result -Wno-parentheses -Wno-unknown-pragmas -Werror") |
49 |
++option(INJECT_C_FLAGS "Inject a bunch of useful c flags" ON) |
50 |
++if (INJECT_C_FLAGS) |
51 |
++ set(CMAKE_C_FLAGS "${CMAKE_CXX_FLAGS} -g -O2 -pedantic -Wall -Wno-sign-compare -Wno-unused-result -Wno-parentheses -Wno-unknown-pragmas -Werror") |
52 |
++endif() |
53 |
+ |
54 |
+ add_subdirectory(lib) |
55 |
+ add_subdirectory(demo) |
56 |
+diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt |
57 |
+index 51b79bb..754f60f 100644 |
58 |
+--- a/lib/CMakeLists.txt |
59 |
++++ b/lib/CMakeLists.txt |
60 |
+@@ -17,9 +17,9 @@ target_link_libraries(${library_name} m) |
61 |
+ |
62 |
+ install( |
63 |
+ TARGETS ${library_name} LIBRARY |
64 |
+- DESTINATION ${destination}/lib |
65 |
++ DESTINATION ${CMAKE_INSTALL_LIBDIR} |
66 |
+ COMPONENT Libraries) |
67 |
+ install( |
68 |
+ FILES ${inc_files} |
69 |
+- DESTINATION ${destination}/include |
70 |
++ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} |
71 |
+ COMPONENT Headers) |
72 |
+diff --git a/man/CMakeLists.txt b/man/CMakeLists.txt |
73 |
+index a718d3d..4a15597 100644 |
74 |
+--- a/man/CMakeLists.txt |
75 |
++++ b/man/CMakeLists.txt |
76 |
+@@ -15,7 +15,7 @@ function(one_page pname section) |
77 |
+ ) |
78 |
+ install( |
79 |
+ FILES ${CMAKE_CURRENT_BINARY_DIR}/${pname}.${section} |
80 |
+- DESTINATION "${CMAKE_INSTALL_PREFIX}/man/man${section}" |
81 |
++ DESTINATION "${CMAKE_INSTALL_MANDIR}/man${section}" |
82 |
+ ) |
83 |
+ endfunction() |
84 |
+ |
85 |
+-- |
86 |
+2.16.4 |
87 |
+ |
88 |
|
89 |
diff --git a/sci-libs/lmfit/lmfit-7.0.ebuild b/sci-libs/lmfit/lmfit-7.0.ebuild |
90 |
new file mode 100644 |
91 |
index 000000000..e895f1f06 |
92 |
--- /dev/null |
93 |
+++ b/sci-libs/lmfit/lmfit-7.0.ebuild |
94 |
@@ -0,0 +1,25 @@ |
95 |
+# Copyright 1999-2018 Gentoo Foundation |
96 |
+# Distributed under the terms of the GNU General Public License v2 |
97 |
+ |
98 |
+EAPI=6 |
99 |
+ |
100 |
+inherit cmake-utils |
101 |
+ |
102 |
+DESCRIPTION="library for Levenberg-Marquardt least-squares minimization and curve fitting" |
103 |
+HOMEPAGE="http://apps.jcns.fz-juelich.de/doku/sc/lmfit" |
104 |
+SRC_URI="http://apps.jcns.fz-juelich.de/src/lmfit/${P}.tgz" |
105 |
+ |
106 |
+LICENSE="BSD-2" |
107 |
+SLOT="0" |
108 |
+KEYWORDS="~amd64" |
109 |
+IUSE="" |
110 |
+ |
111 |
+PATCHES=( "${FILESDIR}/${P}-cmake.patch" ) |
112 |
+ |
113 |
+src_configure() { |
114 |
+ local mycmakeargs=( |
115 |
+ -DINJECT_C_FLAGS=OFF |
116 |
+ ) |
117 |
+ |
118 |
+ cmake-utils_src_configure |
119 |
+} |