Skip to content

Commit b891145

Browse files
committed
Add extended API with _64 suffix to LAPACK with lapack_64.h
1 parent 9077255 commit b891145

File tree

2,049 files changed

+4334
-6
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,049 files changed

+4334
-6
lines changed

INSTALL/dlamch.f

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#include "../SRC/lapack_64.h"
12
*> \brief \b DLAMCH
23
*
34
* =========== DOCUMENTATION ===========

INSTALL/droundup_lwork.f

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#include "../SRC/lapack_64.h"
12
*> \brief \b DROUNDUP_LWORK
23
*
34
* =========== DOCUMENTATION ===========

INSTALL/ilaver.f

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#include "../SRC/lapack_64.h"
12
*> \brief \b ILAVER returns the LAPACK version.
23
**
34
* =========== DOCUMENTATION ===========

INSTALL/lsame.f

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#include "../SRC/lapack_64.h"
12
*> \brief \b LSAME
23
*
34
* =========== DOCUMENTATION ===========

INSTALL/slamch.f

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#include "../SRC/lapack_64.h"
12
*> \brief \b SLAMCH
23
*
34
* =========== DOCUMENTATION ===========

INSTALL/sroundup_lwork.f

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#include "../SRC/lapack_64.h"
12
*> \brief \b SROUNDUP_LWORK
23
*
34
* =========== DOCUMENTATION ===========

SRC/CMakeLists.txt

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -516,7 +516,31 @@ if(BUILD_COMPLEX16)
516516
endif()
517517
list(REMOVE_DUPLICATES SOURCES)
518518

519-
add_library(${LAPACKLIB} ${SOURCES})
519+
add_library(${LAPACKLIB}_obj OBJECT ${SOURCES})
520+
set_target_properties(
521+
${LAPACKLIB}_obj PROPERTIES
522+
POSITION_INDEPENDENT_CODE ON
523+
Fortran_PREPROCESS ON
524+
)
525+
526+
if(BUILD_INDEX64_EXT_API)
527+
set(SOURCES_64)
528+
list(APPEND SOURCES_64 ${SOURCES})
529+
list(REMOVE_ITEM SOURCES_64 la_xisnan.F90)
530+
list(REMOVE_ITEM SOURCES_64 ${SECOND_SRC})
531+
list(REMOVE_ITEM SOURCES_64 ${DSECOND_SRC})
532+
add_library(${LAPACKLIB}_64_obj OBJECT ${SOURCES_64})
533+
target_compile_options(${LAPACKLIB}_64_obj PRIVATE ${FOPT_ILP64} -DLAPACK_64)
534+
set_target_properties(
535+
${LAPACKLIB}_64_obj PROPERTIES
536+
POSITION_INDEPENDENT_CODE ON
537+
Fortran_PREPROCESS ON
538+
)
539+
endif()
540+
541+
add_library(${LAPACKLIB}
542+
$<TARGET_OBJECTS:${LAPACKLIB}_obj>
543+
$<$<BOOL:${BUILD_INDEX64_EXT_API}>: $<TARGET_OBJECTS:${LAPACKLIB}_64_obj>>)
520544
set_target_properties(
521545
${LAPACKLIB} PROPERTIES
522546
VERSION ${LAPACK_VERSION}
@@ -534,7 +558,7 @@ target_link_libraries(${LAPACKLIB} PRIVATE ${BLAS_LIBRARIES})
534558

535559
if(_is_coverage_build)
536560
target_link_libraries(${LAPACKLIB} PRIVATE gcov)
537-
add_coverage(${LAPACKLIB})
561+
add_coverage(${LAPACKLIB}_obj)
538562
endif()
539563

540564
lapack_install_library(${LAPACKLIB})

SRC/cbbcsd.f

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#include "lapack_64.h"
12
*> \brief \b CBBCSD
23
*
34
* =========== DOCUMENTATION ===========

SRC/cbdsqr.f

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#include "lapack_64.h"
12
*> \brief \b CBDSQR
23
*
34
* =========== DOCUMENTATION ===========

SRC/cgbbrd.f

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#include "lapack_64.h"
12
*> \brief \b CGBBRD
23
*
34
* =========== DOCUMENTATION ===========

0 commit comments

Comments
 (0)