Create RPM package with runtime libraries and executable file
I have created a C++ application under redhat linux environment. Beside this application, I have also created many *.so libraries required by the application. The created application uses some Boost C++ libraries, e.g. -lboost_system, -lboost_thread and etc
I wish to deploy this application and its required runtime libraries onto the production machine without exposing/recompiling the source codes and without having Boost C++ full installation on the production machine. Is it possible?
The application directories structure in development machine as follows:
~/SysA/debug/main/main (executable binary file)
~/SysA/debug/main/config (configuration text file)
~/SysA/debug/lib1/libA.so
~/SysA/debug/lib2/libB.so
~/SysA/debug/lib3/libC.so
:
:
I have attempted to make my first following RPM SPEC file as follows, but stucked:
Name: SYSTEM
Version: 0.1
Release: 1.0
BuildRoot: %{_topdir}BUILD/%{name}-%{version}-%{release}
AutoReqProv: no
%description
System testing开发者_StackOverflow
%prep
rm -rf $RPM_BUILD_ROOT
%clean
rm -rf %RPM_BUILD_ROOT
%files
%defattr(644, root, root)
%changelog
Wish someone can help me out...
You should either create a 2nd RPM for Boost libraries (to be installed together with your RPM) or link Boost libraries statically into your application.
精彩评论