Commits
Takeshi Enomoto authored 64b938d01ec
86 86 | if {$build_arch eq "x86_64"} { |
87 87 | patchfiles-append patch-config-ymake.diff |
88 88 | } |
89 89 | if {[variant_isset accelerate]} { |
90 90 | patchfiles-append patch-config-Project-accelerate.diff \ |
91 91 | patch-external-yMakefile.diff |
92 92 | } else { |
93 93 | patchfiles-append patch-config-Project.diff |
94 94 | } |
95 95 | |
96 + | if {${configure.sdkroot} ne ""} { |
97 + | configure.cflags-append -isysroot ${configure.sdkroot} |
98 + | configure.fflags-append -isysroot ${configure.sdkroot} |
99 + | } |
96 100 | pre-configure { |
97 101 | if {[file exists ${prefix}/bin/h5pcc]} { |
98 102 | configure.cc ${prefix}/bin/h5pcc |
99 103 | } else { |
100 104 | configure.cc ${prefix}/bin/h5cc |
101 105 | } |
102 106 | # build modified g2clib |
103 107 | if {$build_arch eq "x86_64" || $build_arch eq "ppc64"} { |
104 108 | set defs "-DUSE_JPEG2000 -DUSE_PNG -D__64BIT__" |
105 109 | } else { |
121 125 | } |
122 126 | set fvar [fortran_variant_name] |
123 127 | if {[variant_isset g95]} { |
124 128 | reinplace "s|-lgfortran|-L${prefix}/lib/${fvar} -lf95|" ${worksrcpath}/config/${f} |
125 129 | } else { |
126 130 | reinplace "s|-lgfortran|-L${prefix}/lib/${fvar} -lgfortran -lgomp|" ${worksrcpath}/config/${f} |
127 131 | } |
128 132 | reinplace "s| gfortran$| ${configure.fc}|" ${worksrcpath}/config/${f} |
129 133 | reinplace "s|gcc$|${configure.cc}|" ${worksrcpath}/config/${f} |
130 134 | reinplace "/CcOptions/d" ${worksrcpath}/config/${f} |
135 + | reinplace "/FcOptions/d" ${worksrcpath}/config/${f} |
131 136 | reinplace "/ArchRecLibSearch/d" ${worksrcpath}/config/${f} |
132 137 | reinplace "/ArchRecIncSearch/d" ${worksrcpath}/config/${f} |
133 138 | reinplace "s|-lXext$|-lXext\\ |
134 139 | #define ArchRecLibSearch ${configure.ldflags} \\ |
135 140 | #define ArchRecIncSearch ${configure.cppflags} \\ |
136 - | #define CcOptions -fPIC -D_DARWIN_C_SOURCE \\ |
137 - | #define COptimizeFlag ${configure.cflags}\\ |
138 - | #define FOptimizeFlag ${configure.fflags}\\ |
141 + | #define CcOptions -fPIC -D_DARWIN_C_SOURCE ${configure.cflags}\\ |
142 + | #define FcOptions -fPIC -fno-range-check -m64 -Wall ${configure.fflags}\\ |
139 143 | #define ManRoot ${destroot}${prefix}/share/man\\ |
140 144 | #define NetCDFlib -lnetcdf\\ |
141 145 | #define HDFEOS5lib -lhe5_hdfeos -lGctp|" ${worksrcpath}/config/${f} |
142 146 | # A workaround for XQuartz 2.7.3 on Mountain Lion known as ncl.xq.fix |
143 147 | if {${os.version}>=12} { |
144 148 | reinplace "s|-D_XOPEN_SOURCE|-D_XOPEN_SOURCE -D__JIRA1530__|" ${worksrcpath}/config/${f} |
145 149 | } |
146 150 | } |
147 151 | if {[variant_isset g95]} { |
148 152 | reinplace "s|-fno-range-check||" ${worksrcpath}/config/Darwin_Intel |