Skip to content

Commit de8c07a

Browse files
committed
fixes for clang++
1 parent e2e8191 commit de8c07a

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

.github/workflows/macos.yml

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,15 +52,13 @@ jobs:
5252
run: brew install berkeley-db
5353

5454
- name: Build
55-
run: |
56-
flags=$( perl -MConfig -e 'print $Config::Config{ccflags}' )
57-
perl Makefile.PL CCFLAGS="$flags -Werror" && make
55+
run: perl Makefile.PL && make
5856

5957
- name: Test
6058
run: make test
6159

6260

63-
c-plus-plus:
61+
werror:
6462

6563
runs-on: ubuntu-latest
6664

@@ -69,6 +67,12 @@ jobs:
6967
perl:
7068
- latest
7169

70+
compiler:
71+
- name: clang
72+
werror: -Werror -Wno-error=deprecated
73+
74+
- name: clang++
75+
werror: -Werror -Wno-error=deprecated
7276

7377
name: Perl ${{ matrix.perl }}
7478
steps:
@@ -88,10 +92,14 @@ jobs:
8892
- name: Install Perl dependencies
8993
run: cpanm --quiet --installdeps --notest .
9094

95+
# Need the -Wno-error=deprecated below to stop this terminating the workflow
96+
#
97+
# clang: error: treating 'c' input as 'c++' when in C++ mode, this behavior is deprecated [-Werror,-Wdeprecated]
98+
9199
- name: Build
92100
run: |
93101
flags=$( perl -MConfig -e 'print $Config::Config{ccflags}' )
94-
perl Makefile.PL CCFLAGS="$flags -Werror" CC=clang++ && make
102+
perl Makefile.PL CCFLAGS="$flags ${{ matrix.compiler.wname }}" CC=${{ matrix.compiler.name }} && make
95103
96104
- name: Test
97105
run: make test

0 commit comments

Comments
 (0)