unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
blob 84f3487218822a6105e288fc20c0b9ffcf0d3f81 3952 bytes (raw)
name: gnu/packages/patches/openmolcas-pymolcas-openblas.patch 	 # note: path name is non-authoritative(*)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
 
By default, pymolcas is installed in the first writable directory in the
user's PATH.  This patch places it in the bin/ directory alongside the other
OpenMolcas binaries.

The default search for the OpenBLAS library is obviated and the directory name
is supplied as an argument to CMake.

diff --git OpenMolcas-v18.09/CMakeLists.txt OpenMolcas-v18.09/CMakeLists.txt
index a4071fd..53d8df5 100644
--- OpenMolcas-v18.09/CMakeLists.txt
+++ OpenMolcas-v18.09/CMakeLists.txt
@@ -1338,42 +1338,8 @@ if (LINALG STREQUAL "OpenBLAS")
         endif ()
 
         # search for the OpenBLAS library
-        find_library (LIBOPENBLAS
-                NAMES openblas
-                PATHS ${OPENBLASROOT}
-                PATH_SUFFIXES lib
-                NO_DEFAULT_PATH)
-
-        if (NOT LIBOPENBLAS)
-                message (FATAL_ERROR
-                        "OpenBLAS library not found, please check that "
-                        "the OPENBLASROOT variable is set and points to "
-                        "a valid OpenBLAS installation directory."
-                        )
-        endif ()
-
-        # here we check if LIBOPENBLAS has changed after it was processed
-        # succesfully, if not we do not need to rerun anything here.
-        if (NOT LIBOPENBLAS STREQUAL LIBOPENBLAS_LAST)
-                # check if the OpenBLAS library contains LAPACK functionality
-                message ("-- Checking OpenBLAS for LAPACK functionality...")
-                include(CheckFortranFunctionExists)
-                set (CMAKE_REQUIRED_LIBRARIES ${LIBOPENBLAS})
-                unset (OPENBLAS_WITH_LAPACK CACHE)
-                check_fortran_function_exists("dsyev" OPENBLAS_WITH_LAPACK)
-                if (NOT OPENBLAS_WITH_LAPACK)
-                        unset (LIBOPENBLAS CACHE)
-                        message (FATAL_ERROR
-                                "LAPACK functionality missing from OpenBLAS library, "
-                                "please build OpenBLAS with NO_LAPACK=0 defined."
-                                )
-                endif ()
-                # save the last location to check if it changed between configurations
-                set (LIBOPENBLAS_LAST ${LIBOPENBLAS} CACHE INTERNAL "last value." FORCE)
-        endif ()
-
         add_definitions (-D_OPENBLAS_)
-        set (LINALG_LIBRARIES ${LIBOPENBLAS})
+        set (LINALG_LIBRARIES ${LINALG_LIBRARIES})
 else ()
         mark_as_advanced(FORCE OPENBLASROOT)
 endif ()
@@ -3167,11 +3168,10 @@ install (PROGRAMS
 if (DEFINED PYMOLCAS_TARGET)
         install (PROGRAMS
                 ${PYMOLCAS_TARGET}
-                DESTINATION ${CMAKE_INSTALL_PREFIX}/sbin
+                DESTINATION ${CMAKE_INSTALL_PREFIX}/bin
                 RENAME pymolcas
                 )
 
-        install (CODE "execute_process(COMMAND ${OPENMOLCAS_DIR}/sbin/install_pymolcas.sh ${PYMOLCAS_TARGET})")
 endif ()
 
 if (DEFINED EXTRA_DIR)
@@ -3188,9 +3189,5 @@ if (DEFINED EXTRA_DIR)
                 DESTINATION ${CMAKE_INSTALL_PREFIX}/bin
                 )
 
-        install (CODE "execute_process(COMMAND ${OPENMOLCAS_DIR}/sbin/install_driver.sh ${MOLCAS_DRIVER})")
 endif ()
 
-if (IS_DIRECTORY "$ENV{HOME}/.Molcas")
-        install (CODE "execute_process(COMMAND sh \"-c\" \"cd ${CMAKE_INSTALL_PREFIX}; echo `pwd` > $HOME/.Molcas/molcas 2> /dev/null\")")
-endif ()
diff --git OpenMolcas-v18.09/Tools/pymolcas/CMakeLists.txt OpenMolcas-v18.09/Tools/pymolcas/CMakeLists.txt
index 0d576fa..f9ba6d7 100644
--- OpenMolcas-v18.09/Tools/pymolcas/CMakeLists.txt
+++ OpenMolcas-v18.09/Tools/pymolcas/CMakeLists.txt
@@ -52,9 +52,5 @@ if (PYTHONINTERP_FOUND)
                         DEPENDS ${PYMOLCAS_TARGET}
                         )
 
-                add_custom_command (TARGET pymolcas
-                        POST_BUILD
-                        COMMAND ${OPENMOLCAS_DIR}/sbin/install_pymolcas.sh ${PYMOLCAS_TARGET}
-                )
 
         endif ()

debug log:

solving 84f348721 ...
found 84f348721 in https://yhetil.org/guix-bugs/875zz36du9.fsf@gnu.org/

applying [1/1] https://yhetil.org/guix-bugs/875zz36du9.fsf@gnu.org/
diff --git a/gnu/packages/patches/openmolcas-pymolcas-openblas.patch b/gnu/packages/patches/openmolcas-pymolcas-openblas.patch
new file mode 100644
index 000000000..84f348721

1:20: trailing whitespace.
 
1:70: trailing whitespace.
 
1:73: trailing whitespace.
 
1:78: trailing whitespace.
 
1:81: trailing whitespace.
 
Checking patch gnu/packages/patches/openmolcas-pymolcas-openblas.patch...
Applied patch gnu/packages/patches/openmolcas-pymolcas-openblas.patch cleanly.
warning: squelched 2 whitespace errors
warning: 7 lines add whitespace errors.

index at:
100644 84f3487218822a6105e288fc20c0b9ffcf0d3f81	gnu/packages/patches/openmolcas-pymolcas-openblas.patch

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).