Skip to content

Commit ebb2aa6

Browse files
committed
distro UPDATE use cmake abstraction for build commands in RPM
1 parent 0c98eb5 commit ebb2aa6

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

distro/pkg/rpm/libyang.spec

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -66,12 +66,11 @@ written (and providing API) in C.
6666
-DCMAKE_C_FLAGS="${RPM_OPT_FLAGS}" \
6767
-DCMAKE_CXX_FLAGS="${RPM_OPT_FLAGS}" \
6868
..
69-
make
7069
%else
7170
%cmake -DCMAKE_BUILD_TYPE=RELWITHDEBINFO
72-
%cmake_build
7371
%endif
74-
%cmake_build --target doc
72+
cmake --build .
73+
cmake --build . --target doc
7574

7675
%check
7776
%if ( 0%{?rhel} == 0 ) || 0%{?rhel} > 7
@@ -85,7 +84,7 @@ ctest --output-on-failure -V %{?_smp_mflags}
8584
mkdir -m0755 -p %{buildroot}/%{_docdir}/libyang
8685
%if 0%{?rhel} && 0%{?rhel} < 8
8786
cd build
88-
make DESTDIR=%{buildroot} install
87+
DESTDIR=%{buildroot} cmake --build . --target install
8988
%else
9089
%cmake_install
9190
cp -a doc/html %{buildroot}/%{_docdir}/libyang/html

0 commit comments

Comments
 (0)