LP-101 - Use prebuilt firmware for RPM packaging.
[librepilot.git] / package / linux / rpmspec.in
blobbc1421a69e40b170b891f66e1875b35e776b9b4d
1 Name:           <NAME>
2 Summary:        Ground Control Station
3 Version:        <VERSION>
4 Release:        <RELEASE>%{?dist}
6 Group:          Applications/Scientific
7 License:        GPLv3+
8 URL:            http://forum.librepilot.org/
10 Source0:        <SOURCE0>
11 Source1:        <SOURCE1>
13 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
16 BuildRequires:  libusbx-devel
17 BuildRequires:  mesa-libGL-devel
18 BuildRequires:  qt5-qtbase-devel
19 BuildRequires:  qt5-qtdeclarative-devel
20 BuildRequires:  qt5-qtmultimedia-devel
21 BuildRequires:  qt5-qtquick1-devel
22 BuildRequires:  qt5-qtscript-devel
23 BuildRequires:  qt5-qtserialport-devel
24 BuildRequires:  qt5-qtsvg-devel
25 BuildRequires:  qt5-qttools-devel
26 BuildRequires:  qt5-qttranslations
27 BuildRequires:  dwz
28 BuildRequires:  pkgconfig
29 BuildRequires:  python
30 BuildRequires:  SDL-devel
31 BuildRequires:  systemd-devel
33 Requires:       libusbx
34 Requires:       SDL
35 Requires:       qt5-qtquickcontrols
36 Requires:       qt5-qtdeclarative
37 Requires:       qt5-qtmultimedia
38 Requires:       qt5-qtscript
39 Requires:       qt5-qtserialport
40 Requires:       qt5-qtsvg
43 %description
44 LibrePilot is a next-generation Open Source UAV autopilot created by the
45 LibrePilot Community. It is a highly capable platform for
46 multirotors, helicopters, fixed wing aircraft, and other vehicles.
47 It has been designed from the ground up by a community of passionate developers
48 from around the globe, with its core design principles being quality, safety,
49 and ease of use. 
52 %prep
53 %setup -q -T -a 1 -c -n <ARCHIVE_PREFIX>/build
54 %setup -q -D -n <ARCHIVE_PREFIX>
57 %build
58 make config_new                             \
59     enable-udev-rules=yes                   \
60     libbasename=%{_lib}                     \
61     prefix=%{_prefix}                       \
62     QMAKE=qmake-qt5                         \
63     udevrulesdir=%{_udevrulesdir}           \
64     WITH_PREBUILT_FW=$(pwd)/build/firmware
66 make %{?_smp_mflags} opfw_resource gcs
69 %install
70 rm -rf $RPM_BUILD_ROOT
71 make install DESTDIR=$RPM_BUILD_ROOT
74 %clean
75 rm -rf $RPM_BUILD_ROOT
78 %post -p /sbin/ldconfig
79 %postun -p /sbin/ldconfig
82 %files
83 %defattr(-,root,root)
84 %doc README.md CREDITS.txt WHATSNEW.txt
85 %doc GPLv3.txt
86 %{_bindir}/librepilot-gcs
87 %{_udevrulesdir}/45-librepilot.rules
88 %{_datadir}/applications/librepilot.desktop
89 %{_datadir}/librepilot-gcs/*
90 %{_datadir}/pixmaps/librepilot.png
91 %{_libdir}/librepilot-gcs/plugins/LibrePilot/*.pluginspec
92 %{_libdir}/librepilot-gcs/plugins/LibrePilot/*.so
94 %{_libdir}/librepilot-gcs/libAggregation.so.1*
95 %{_libdir}/librepilot-gcs/libExtensionSystem.so.1*
96 %{_libdir}/librepilot-gcs/libGLC_lib.so.1*
97 %{_libdir}/librepilot-gcs/libopmapwidget.so.1*
98 %{_libdir}/librepilot-gcs/libQScienceSpinBox.so.1*
99 %{_libdir}/librepilot-gcs/libQtConcurrent.so.1*
100 %{_libdir}/librepilot-gcs/libQwt.so.1*
101 %{_libdir}/librepilot-gcs/libsdlgamepad.so.1*
102 %{_libdir}/librepilot-gcs/libUtils.so.1*
103 %{_libdir}/librepilot-gcs/libVersionInfo.so.1*
105 %{_libdir}/librepilot-gcs/lib*.so
108 %changelog