Skip to content

Commit f10d47c

Browse files
authored
Merge pull request #4910 from martin-frbg/issue4908
fix placement of -fopenmp in the pkgconfig file
2 parents a1073f5 + fa77561 commit f10d47c

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

Makefile.install

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ endif
1414
ifeq ($(INTERFACE64),1)
1515
USE_64BITINT=1
1616
endif
17+
ifeq ($(USE_OPENMP),1)
18+
FOMP_OPT:= -fopenmp
19+
endif
1720

1821
PREFIX ?= /opt/OpenBLAS
1922

@@ -178,6 +181,7 @@ endif
178181
@echo 'libnamesuffix='$(LIBNAMESUFFIX) >> "$(PKGFILE)"
179182
@echo 'libsuffix='$(SYMBOLSUFFIX) >> "$(PKGFILE)"
180183
@echo 'includedir='$(OPENBLAS_INCLUDE_DIR) >> "$(PKGFILE)"
184+
@echo 'omp_opt='$(FOMP_OPT) >> "$(PKGFILE)"
181185
@echo 'openblas_config= USE_64BITINT='$(INTERFACE64) 'DYNAMIC_ARCH='$(DYNAMIC_ARCH) 'DYNAMIC_OLDER='$(DYNAMIC_OLDER) 'NO_CBLAS='$(NO_CBLAS) 'NO_LAPACK='$(NO_LAPACK) 'NO_LAPACKE='$(NO_LAPACKE) 'NO_AFFINITY='$(NO_AFFINITY) 'USE_OPENMP='$(USE_OPENMP) $(TARGET) 'MAX_THREADS='$(NUM_THREADS)>> "$(PKGFILE)"
182186
@echo 'version='$(VERSION) >> "$(PKGFILE)"
183187
@echo 'extralib='$(PKG_EXTRALIB) >> "$(PKGFILE)"

cmake/openblas.pc.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,5 @@ Name: OpenBLAS
99
Description: OpenBLAS is an optimized BLAS library based on GotoBLAS2 1.13 BSD version
1010
Version: @OpenBLAS_VERSION@
1111
URL: https://github.com/OpenMathLib/OpenBLAS
12-
Libs: @OpenMP_C_FLAGS@ -L${libdir} -l${libnameprefix}openblas${libnamesuffix}${libsuffix}
13-
Cflags: -I${includedir}
12+
Libs: -L${libdir} -l${libnameprefix}openblas${libnamesuffix}${libsuffix}
13+
Cflags: -I${includedir} @OpenMP_C_FLAGS@

openblas.pc.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ Version: ${version}
44
URL: https://github.com/xianyi/OpenBLAS
55
Libs: -L${libdir} -l${libprefix}openblas${libnamesuffix}
66
Libs.private: ${extralib}
7-
Cflags: -I${includedir}
7+
Cflags: -I${includedir} ${omp_opt}

0 commit comments

Comments
 (0)