| @@ -1,14 +1,14 @@ | | | @@ -1,14 +1,14 @@ |
1 | # $NetBSD: Makefile,v 1.21 2023/11/21 17:57:18 nros Exp $ | | 1 | # $NetBSD: Makefile,v 1.22 2023/11/21 18:26:30 nros Exp $ |
2 | | | 2 | |
3 | DISTNAME= abseil-20230802.1 | | 3 | DISTNAME= abseil-20230802.1 |
4 | CATEGORIES= devel | | 4 | CATEGORIES= devel |
5 | MASTER_SITES= ${MASTER_SITE_GITHUB:=abseil/} | | 5 | MASTER_SITES= ${MASTER_SITE_GITHUB:=abseil/} |
6 | GITHUB_PROJECT= abseil-cpp | | 6 | GITHUB_PROJECT= abseil-cpp |
7 | GITHUB_TAG= ${PKGVERSION_NOREV} | | 7 | GITHUB_TAG= ${PKGVERSION_NOREV} |
8 | | | 8 | |
9 | MAINTAINER= pkgsrc-users@NetBSD.org | | 9 | MAINTAINER= pkgsrc-users@NetBSD.org |
10 | HOMEPAGE= https://github.com/abseil/abseil-cpp | | 10 | HOMEPAGE= https://github.com/abseil/abseil-cpp |
11 | COMMENT= C++ Common Libraries | | 11 | COMMENT= C++ Common Libraries |
12 | LICENSE= apache-2.0 | | 12 | LICENSE= apache-2.0 |
13 | | | 13 | |
14 | USE_CXX_FEATURES= c++14 | | 14 | USE_CXX_FEATURES= c++14 |
| @@ -17,37 +17,19 @@ CMAKE_CONFIGURE_ARGS+= -DBUILD_SHARED_LI | | | @@ -17,37 +17,19 @@ CMAKE_CONFIGURE_ARGS+= -DBUILD_SHARED_LI |
17 | | | 17 | |
18 | # .buildlink/include/absl/base/policy_checks.h:57:2: error: | | 18 | # .buildlink/include/absl/base/policy_checks.h:57:2: error: |
19 | # #error "This package requires GCC 7 or higher." | | 19 | # #error "This package requires GCC 7 or higher." |
20 | GCC_REQD+= 7 | | 20 | GCC_REQD+= 7 |
21 | | | 21 | |
22 | .include "../../mk/bsd.prefs.mk" | | 22 | .include "../../mk/bsd.prefs.mk" |
23 | | | 23 | |
24 | .if ${OPSYS} == "Darwin" | | 24 | .if ${OPSYS} == "Darwin" |
25 | . if exists(${OSX_SDK_PATH}/usr/include/execinfo.h) | | 25 | . if exists(${OSX_SDK_PATH}/usr/include/execinfo.h) |
26 | BUILDLINK_TRANSFORM+= rm:-lexecinfo | | 26 | BUILDLINK_TRANSFORM+= rm:-lexecinfo |
27 | . endif | | 27 | . endif |
28 | .endif | | 28 | .endif |
29 | | | 29 | |
30 | ABSLPC_DIR= ${WRKSRC}/${CMAKE_BUILD_DIR}/lib/pkgconfig | | | |
31 | PKGCONFIG_OVERRIDE_STAGE= post-build | | 30 | PKGCONFIG_OVERRIDE_STAGE= post-build |
32 | | | 31 | PKGCONFIG_OVERRIDE= ${CMAKE_BUILD_DIR}/lib/pkgconfig/*.pc |
33 | .include "pkgconfig-overrides.mk" | | | |
34 | | | | |
35 | | | | |
36 | # abseil installs a lot of pkg-config files so maintaining a list of | | | |
37 | # pkgconfig overrides whould take a lot of time. Below is a target to | | | |
38 | # ease this work. | | | |
39 | # The target can be run when updating the package to update the list of | | | |
40 | # pkgconfig files that need an override. | | | |
41 | .PHONY: update-pkgconfig-overrides | | | |
42 | update-pkgconfig-overrides: all | | | |
43 | ${RUN} ${HEAD} -n 1 pkgconfig-overrides.mk > pkgconfig-overrides.mk.tmp | | | |
44 | ${RUN} ${MV} pkgconfig-overrides.mk.tmp pkgconfig-overrides.mk | | | |
45 | ${RUN} cd ${ABSLPC_DIR} && \ | | | |
46 | ${GREP} "\-l[ ]*absl" * | ${SED} 's/:[ ]*Libs:.*//g' | \ | | | |
47 | ${SED} 's,^,PKGCONFIG_OVERRIDE+=\ \$$\{ABSLPC_DIR\}/,g' \ | | | |
48 | >> ${.CURDIR}/pkgconfig-overrides.mk | | | |
49 | | | | |
50 | | | 32 | |
51 | .include "../../devel/cmake/build.mk" | | 33 | .include "../../devel/cmake/build.mk" |
52 | .include "../../mk/atomic64.mk" | | 34 | .include "../../mk/atomic64.mk" |
53 | .include "../../mk/bsd.pkg.mk" | | 35 | .include "../../mk/bsd.pkg.mk" |