Merge pull request #112 from turboencabulator/cleanup
[platform/upstream/lapack.git] / TESTING / MATGEN / CMakeLists.txt
1 #######################################################################
2 #  This is the makefile to create a library of the test matrix
3 #  generators used in LAPACK.  The files are organized as follows:
4 #
5 #     SCATGEN  -- Auxiliary routines called from both REAL and COMPLEX
6 #     DZATGEN  -- Auxiliary routines called from both DOUBLE PRECISION
7 #                 and COMPLEX*16
8 #     SMATGEN  -- Single precision real matrix generation routines
9 #     CMATGEN  -- Single precision complex matrix generation routines
10 #     DMATGEN  -- Double precision real matrix generation routines
11 #     ZMATGEN  -- Double precision complex matrix generation routines
12 #
13 #  The library can be set up to include routines for any combination
14 #  of the four precisions.  To create or add to the library, enter make
15 #  followed by one or more of the precisions desired.  Some examples:
16 #       make single
17 #       make single complex
18 #       make single double complex complex16
19 #  Alternatively, the command
20 #       make
21 #  without any arguments creates a library of all four precisions.
22 #  The library is called
23 #       tmglib.a
24 #  and is created at the LAPACK directory level.
25 #
26 #  To remove the object files after the library is created, enter
27 #       make clean
28 #  On some systems, you can force the source files to be recompiled by
29 #  entering (for example)
30 #       make single FRC=FRC
31 #
32 #######################################################################
33
34 set(SCATGEN slatm1.f slatm7.f slaran.f slarnd.f)
35
36 set(SMATGEN slatms.f slatme.f slatmr.f slatmt.f
37    slagge.f slagsy.f slakf2.f slarge.f slaror.f slarot.f slatm2.f
38    slatm3.f slatm5.f slatm6.f slahilb.f)
39
40 set(CMATGEN clatms.f clatme.f clatmr.f clatmt.f
41    clagge.f claghe.f clagsy.f clakf2.f clarge.f claror.f clarot.f
42    clatm1.f clarnd.f clatm2.f clatm3.f clatm5.f clatm6.f clahilb.f)
43
44 set(DZATGEN dlatm1.f dlatm7.f dlaran.f dlarnd.f)
45
46 set(DMATGEN dlatms.f dlatme.f dlatmr.f dlatmt.f
47    dlagge.f dlagsy.f dlakf2.f dlarge.f dlaror.f dlarot.f dlatm2.f
48    dlatm3.f dlatm5.f dlatm6.f dlahilb.f)
49
50 set(ZMATGEN zlatms.f zlatme.f zlatmr.f zlatmt.f
51   zlagge.f zlaghe.f zlagsy.f zlakf2.f zlarge.f zlaror.f zlarot.f
52   zlatm1.f zlarnd.f zlatm2.f zlatm3.f zlatm5.f zlatm6.f zlahilb.f)
53
54 if(BUILD_SINGLE)
55   set(ALLOBJ ${SMATGEN} ${SCATGEN})
56 endif()
57 if(BUILD_DOUBLE)
58   set(ALLOBJ ${ALLOBJ} ${DMATGEN} ${DZATGEN})
59 endif()
60 if(BUILD_COMPLEX)
61   set(ALLOBJ ${ALLOBJ} ${CMATGEN} ${SCATGEN})
62 endif()
63 if(BUILD_COMPLEX16)
64   set(ALLOBJ ${ALLOBJ} ${ZMATGEN} ${DZATGEN})
65 endif()
66
67 if(NOT ALLOBJ)
68   set(ALLOBJ ${SMATGEN} ${CMATGEN} ${SCATGEN} ${DMATGEN} ${ZMATGEN}
69     ${DZATGEN})
70 else()
71   list(REMOVE_DUPLICATES ALLOBJ)
72 endif()
73 add_library(tmglib ${ALLOBJ})
74 target_link_libraries(tmglib ${LAPACK_LIBRARIES})
75 lapack_install_library(tmglib)