@@ -10,48 +10,51 @@ jobs:
10
10
matrix :
11
11
compiler : [gcc, clang]
12
12
python-ruby-version :
13
- - {python: 3.9 , ruby: 2.7 }
14
- - {python: 3.9 , ruby: 2.7 , other: test-flags-override}
15
- - {python: 3.9 , ruby: 2.7 , other: test-debug}
16
- - {python: 3.9 , ruby: 2.7 , other: linker-bfd}
17
- - {python: 3.9 , ruby: 2.7 , other: linker-gold}
13
+ - {python: '3.10' , ruby: '3.1' }
14
+ - {python: '3.10' , ruby: '3.1' , other: test-flags-override}
15
+ - {python: '3.10' , ruby: '3.1' , other: test-debug}
16
+ - {python: '3.10' , ruby: '3.1' , other: linker-bfd}
17
+ - {python: '3.10' , ruby: '3.1' , other: linker-gold}
18
18
# Test several Python versions with the latest Ruby version
19
- - {python: 3.8, ruby: 2.7}
20
- - {python: 3.7, ruby: 2.7}
21
- - {python: 3.6, ruby: 2.7}
22
- - {python: 3.5, ruby: 2.7}
23
- - {python: pypy3, ruby: 2.7}
19
+ - {python: '3.9', ruby: '3.1'}
20
+ - {python: '3.8', ruby: '3.1'}
21
+ - {python: '3.7', ruby: '3.1'}
22
+ - {python: '3.6', ruby: '3.1'}
23
+ - {python: '3.5', ruby: '3.1'}
24
+ - {python: 'pypy3.7', ruby: '3.1'}
24
25
# Test several Ruby versions with the latest Python version
25
- - {python: 3.9, ruby: 2.6}
26
- - {python: 3.9, ruby: 2.5}
26
+ - {python: '3.10', ruby: '3.0'}
27
+ - {python: '3.10', ruby: '2.7'}
28
+ - {python: '3.10', ruby: '2.6'}
29
+ - {python: '3.10', ruby: '2.5'}
27
30
exclude :
28
31
- compiler : clang
29
- python-ruby-version : {python: 3.9 , ruby: 2.7 , other: linker-bfd}
32
+ python-ruby-version : {python: '3.10' , ruby: '3.1' , other: linker-bfd}
30
33
- compiler : clang
31
- python-ruby-version : {python: 3.9 , ruby: 2.7 , other: linker-gold}
34
+ python-ruby-version : {python: '3.10' , ruby: '3.1' , other: linker-gold}
32
35
include :
33
36
- compiler : gcc
34
- python-ruby-version : {python: 3.9 , ruby: 2.7 , other: sanitizers}
37
+ python-ruby-version : {python: '3.10' , ruby: '3.1' , other: sanitizers}
35
38
36
39
steps :
37
- - uses : actions/checkout@v2
40
+ - uses : actions/checkout@v3
38
41
39
42
- name : Set up Python ${{ matrix.python-ruby-version.python }}
40
- uses : actions/setup-python@v2
43
+ uses : actions/setup-python@v4
41
44
with :
42
45
python-version : ${{ matrix.python-ruby-version.python }}
43
46
44
47
- name : Set up Ruby ${{ matrix.python-ruby-version.ruby }}
45
- uses : actions /setup-ruby@v1
48
+ uses : ruby /setup-ruby@v1
46
49
with :
47
50
ruby-version : ${{ matrix.python-ruby-version.ruby }}
51
+ bundler-cache : true
48
52
49
53
- name : Install dependencies
50
54
run : |
51
- sudo apt-get update -qq
52
- sudo apt-get install -qqy \
55
+ sudo apt-get update -q
56
+ sudo apt-get install -qy --no-install-recommends \
53
57
bison \
54
- clang \
55
58
flex \
56
59
gawk \
57
60
gettext \
@@ -61,14 +64,16 @@ jobs:
61
64
libcunit1-dev \
62
65
libdbus-glib-1-dev \
63
66
libpcre2-dev \
64
- python3-dev \
65
- python-dev \
66
67
ruby-dev \
67
68
swig \
68
69
xmlto
69
70
70
71
pip install flake8
71
72
73
+ - name : Install Clang
74
+ if : ${{ matrix.compiler == 'clang' }}
75
+ run : sudo apt-get install -qqy clang
76
+
72
77
- name : Configure the environment
73
78
run : |
74
79
DESTDIR=/tmp/destdir
82
87
elif [ "${{ matrix.python-ruby-version.other }}" = "linker-gold" ] ; then
83
88
CC="$CC -fuse-ld=gold"
84
89
fi
90
+ # https://bugs.ruby-lang.org/issues/18616
91
+ # https://github.com/llvm/llvm-project/issues/49958
92
+ if [ "${{ matrix.compiler }}" = "clang" ] && [[ "${{ matrix.python-ruby-version.ruby }}" = 3* ]] ; then
93
+ CC="$CC -fdeclspec"
94
+ fi
85
95
echo "CC=$CC" >> $GITHUB_ENV
86
96
87
97
EXPLICIT_MAKE_VARS=
@@ -110,7 +120,7 @@ jobs:
110
120
PYTHON_SYS_PREFIX="$(python -c 'import sys;print(sys.prefix)')"
111
121
echo "PKG_CONFIG_PATH=${PYTHON_SYS_PREFIX}/lib/pkgconfig" >> $GITHUB_ENV
112
122
113
- if [ "${{ matrix.python-ruby-version.python }}" = "pypy3" ] ; then
123
+ if [[ "${{ matrix.python-ruby-version.python }}" = pypy* ] ] ; then
114
124
# PyPy does not provide a config file for pkg-config
115
125
# libpypy-c.so is provided in bin/libpypy-c.so for PyPy and bin/libpypy3-c.so for PyPy3
116
126
echo "PYINC=-I${PYTHON_SYS_PREFIX}/include" >> $GITHUB_ENV
@@ -122,10 +132,10 @@ jobs:
122
132
123
133
- name : Download and install refpolicy headers for sepolgen tests
124
134
run : |
125
- curl --location --retry 10 -o refpolicy.tar.bz2 https://github.com/SELinuxProject/refpolicy/releases/download/RELEASE_2_20180701 /refpolicy-2.20180701 .tar.bz2
135
+ curl --location --retry 10 -o refpolicy.tar.bz2 https://github.com/SELinuxProject/refpolicy/releases/download/RELEASE_2_20220520 /refpolicy-2.20220520 .tar.bz2
126
136
tar -xvjf refpolicy.tar.bz2
127
137
sed -e "s,^PREFIX :=.*,PREFIX := $DESTDIR/usr," -i refpolicy/support/Makefile.devel
128
- sudo make -C refpolicy install-headers clean
138
+ sudo make -C refpolicy install-headers bare
129
139
sudo mkdir -p /etc/selinux
130
140
echo 'SELINUXTYPE=refpolicy' | sudo tee /etc/selinux/config
131
141
echo 'SELINUX_DEVEL_PATH = /usr/share/selinux/refpolicy' | sudo tee /etc/selinux/sepolgen.conf
0 commit comments