Skip to content

Commit 9d4cdcb

Browse files
committed
WL#16310: RPM/DEB: Remove version number from include path
1 parent f1c9ad8 commit 9d4cdcb

File tree

3 files changed

+12
-15
lines changed

3 files changed

+12
-15
lines changed

mysql-concpp-config.cmake.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ macro(main)
182182

183183
# System-wide install, DEB or RPM layout.
184184

185-
set(INCLUDE_PATH "/usr/include/mysql-cppconn-@CONCPP_VERSION_MAJOR@")
185+
set(INCLUDE_PATH "/usr/include/mysql-cppconn")
186186
get_filename_component(LIB_PATH "${CMAKE_CURRENT_LIST_DIR}/../.." ABSOLUTE)
187187

188188
file(GLOB found "${LIB_PATH}/*libmysqlcppconn*")

packaging/deb-in/libmysqlcppconn-dev.install.in

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@ usr/lib/*/libmysqlcppconnx-static.a
2828
usr/lib/*/cmake/mysql-concpp/mysql-concpp-config.cmake
2929
usr/lib/*/cmake/mysql-concpp/mysql-concpp-config-version.cmake
3030

31-
usr/include/mysqlx/*.h usr/include/mysql-cppconn-8/mysqlx
32-
usr/include/mysqlx/devapi/*.h usr/include/mysql-cppconn-9/mysqlx/devapi
33-
usr/include/mysqlx/devapi/detail/*.h usr/include/mysql-cppconn-9/mysqlx/devapi/detail
34-
usr/include/mysqlx/common/*.h usr/include/mysql-cppconn-9/mysqlx/common
35-
usr/include/mysql/*.h usr/include/mysql-cppconn-9/mysql
36-
usr/include/jdbc/*.h usr/include/mysql-cppconn-9/jdbc
37-
usr/include/jdbc/cppconn/*.h usr/include/mysql-cppconn-9/jdbc/cppconn
31+
usr/include/mysqlx/*.h usr/include/mysql-cppconn/mysqlx
32+
usr/include/mysqlx/devapi/*.h usr/include/mysql-cppconn/mysqlx/devapi
33+
usr/include/mysqlx/devapi/detail/*.h usr/include/mysql-cppconn/mysqlx/devapi/detail
34+
usr/include/mysqlx/common/*.h usr/include/mysql-cppconn/mysqlx/common
35+
usr/include/mysql/*.h usr/include/mysql-cppconn/mysql
36+
usr/include/jdbc/*.h usr/include/mysql-cppconn/jdbc
37+
usr/include/jdbc/cppconn/*.h usr/include/mysql-cppconn/jdbc/cppconn
3838

3939
# Build info
4040
/usr/INFO_SRC /usr/share/doc/libmysqlcppconn-dev

packaging/mysql-connector-c++.spec.in

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ to develop MySQL client applications in C++.
112112
%global __cmake_test_opts %{nil}
113113
%endif
114114
%global __cmake_explicit_opts -DCMAKE_INSTALL_PREFIX="%_prefix" -DCMAKE_C_FLAGS:STRING="%optflags" -DCMAKE_CXX_FLAGS:STRING="%optflags"
115-
%global __cmake_common_opts -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_INCLUDEDIR=%{_includedir}/mysql-cppconn-9 -DWITH_JDBC=ON -DMYSQLCLIENT_STATIC_LINKING=1 -DWITH_SSL=system %{__cmake_test_opts} %{?mysql_opt} -DDEBUG_PREFIX_MAP=OFF
115+
%global __cmake_common_opts -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_INCLUDEDIR=%{_includedir}/mysql-cppconn -DWITH_JDBC=ON -DMYSQLCLIENT_STATIC_LINKING=1 -DWITH_SSL=system %{__cmake_test_opts} %{?mysql_opt} -DDEBUG_PREFIX_MAP=OFF
116116
%global __cmake_cmd cmake%{?el6:3}%{?el7:3} %{__cmake_common_opts} %{__cmake_explicit_opts} ..
117117
mkdir build-dynamic && pushd build-dynamic
118118
pwd
@@ -134,8 +134,8 @@ popd
134134
pushd build-static
135135
make DESTDIR=%{buildroot} install
136136
popd
137-
# Add compat dir and remove unwanted file
138-
ln -s mysql-cppconn-9 %{buildroot}%{_includedir}/mysql-cppconn
137+
138+
# Remove unwanted files
139139
rm %{buildroot}/usr/{INFO_SRC,INFO_BIN}
140140

141141
# Add CMake files to the right location, and remove the incorrect ones
@@ -167,10 +167,7 @@ rm %{buildroot}/usr/*.cmake
167167
%{_libdir}/libmysqlcppconnx-static.a
168168
%{_libdir}/cmake/mysql-concpp/mysql-concpp-config-version.cmake
169169
%{_libdir}/cmake/mysql-concpp/mysql-concpp-config.cmake
170-
%dir %{_includedir}/mysql-cppconn-9
171-
%{_includedir}/mysql-cppconn-9/mysqlx
172-
%{_includedir}/mysql-cppconn-9/mysql
173-
%{_includedir}/mysql-cppconn-9/jdbc
170+
%{_includedir}/mysql-cppconn
174171

175172
%changelog
176173
* Mon May 12 2024 Gipson Pulla <[email protected]> - 9.0.0-1

0 commit comments

Comments
 (0)