]> git.pld-linux.org Git - SPECS.git/blob - hostapd.spec
SPECS updated Wed 1 May 10:14:00 CEST 2024
[SPECS.git] / hostapd.spec
1 #
2 # Conditional build:
3 %bcond_without  systemd         # don't package systemd units
4
5 Summary:        HostAP - acts as an access point
6 Summary(es.UTF-8):      HostAP - actúa como un punto de acceso
7 Summary(pl.UTF-8):      HostAP - praca jako access point
8 Name:           hostapd
9 Version:        2.10
10 Release:        2
11 License:        BSD
12 Group:          Daemons
13 Source0:        https://w1.fi/releases/%{name}-%{version}.tar.gz
14 # Source0-md5:  0be43e9e09ab94a7ebf82de0d1c57761
15 Source1:        %{name}.init
16 Source2:        %{name}.service
17 Source3:        %{name}@.service
18 Patch0:         %{name}-config.patch
19 Patch1:         %{name}-build-time-config.patch
20 URL:            http://w1.fi/hostapd/
21 BuildRequires:  libnl-devel >= 1:3.2
22 BuildRequires:  openssl-devel >= 1.0.2
23 BuildRequires:  pkgconfig
24 BuildRequires:  rpmbuild(macros) >= 1.268
25 BuildRequires:  sed >= 4.0
26 BuildRequires:  sqlite3-devel >= 3
27 Requires(post,preun):   /sbin/chkconfig
28 Requires:       openssl >= 1.0.2
29 Requires:       rc-scripts
30 %{?with_systemd:Requires:       systemd-units >= 38}
31 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32
33 %description
34 This package contains utilities and userspace daemon for the Linux
35 driver for wireless LAN cards based on Intersil's Prism2/2.5/3,
36 Intersil/Conexant Prism GT/Duette/Indigo (Prism54), Atheros ar521x
37 (madwifi) chipsets. The driver supports a so called Host AP mode,
38 i.e., it takes care of IEEE 802.11 management functions in the host
39 computer and acts as an access point. This does not require any
40 special firmware for the wireless LAN card. In addition to this, it
41 has support for normal station operations in BSS and possible also in
42 IBSS.
43
44 %description -l es.UTF-8
45 Este paquete contiene unas herramientas y un servidor del espacio de
46 usuario para tarjetas LAN inalámbricas basadas en el chipset Intersil
47 Prism2/2.5/3, Intersil/Conexant Prism GT/Duette/Indigo (Prism54),
48 Atheros ar521x (madwifi). El driver soporta el llamado modo Host AP,
49 es decir, se encarga de las funciones administrativas el el host,
50 actuando como "access point". Ello no requiere ningún firmware
51 especial para la tarjeta LAN inalámbrica. Además, también hay soporte
52 para operaciones normales de estación en BSS y posiblemente también en
53 IBSS.
54
55 %description -l pl.UTF-8
56 Ten pakiet zawiera narzędzia oraz demona działającego w przestrzeni
57 użytkownika dla linuksowego sterownika kart sieci bezprzewodowych
58 opartych na układach Intersil Prism2/2.5/3, Intersil/Conexant Prism
59 GT/Duette/Indigo (Prism54), Atheros ar521x (madwifi). Sterownik
60 obsługuje tak zwany tryb Host AP, czyli dba o funkcje zarządzające
61 IEEE 802.11 na komputerze i działa jako access point. Nie wymaga to
62 żadnego specjalnego firmware dla karty sieci bezprzewodowej. Ponadto
63 ma obsługę normalnych operacji stacyjnych w BSS, a być może także
64 IBSS.
65
66 %prep
67 %setup -q
68 %patch0 -p1
69 %patch1 -p1
70
71 %build
72 CFLAGS="%{rpmcflags} %{rpmcppflags}" \
73 LDFLAGS="%{rpmldflags}" \
74 %{__make} -C hostapd all nt_password_hash hlr_auc_gw \
75         V=1 \
76         CC="%{__cc}" \
77
78 %install
79 rm -rf $RPM_BUILD_ROOT
80 install -d $RPM_BUILD_ROOT{/sbin,%{_sysconfdir}/{hostap,pcmcia},%{_mandir}/man{1,8}}
81 install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
82
83 # hostapd hostapd_cli nt_password_hash hlr_auc_gw
84 install -p %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/hostapd
85 %if %{with systemd}
86 install -pD %{SOURCE2} $RPM_BUILD_ROOT%{systemdunitdir}/%{name}.service
87 install -pD %{SOURCE3} $RPM_BUILD_ROOT%{systemdunitdir}/%{name}@.service
88 %endif
89 install -p hostapd/hostapd $RPM_BUILD_ROOT/sbin
90 install -p hostapd/hostapd_cli $RPM_BUILD_ROOT/sbin
91 install -p hostapd/nt_password_hash $RPM_BUILD_ROOT/sbin
92 install -p hostapd/hlr_auc_gw $RPM_BUILD_ROOT/sbin
93 cp -p hostapd/hostapd.8 $RPM_BUILD_ROOT%{_mandir}/man8
94 cp -p hostapd/hostapd_cli.1 $RPM_BUILD_ROOT%{_mandir}/man1
95
96 # hostapd configuration
97 cp -a hostapd/hostapd.accept $RPM_BUILD_ROOT%{_sysconfdir}/hostap
98 cp -a hostapd/hostapd.conf $RPM_BUILD_ROOT%{_sysconfdir}/hostap
99 cp -a hostapd/hostapd.deny $RPM_BUILD_ROOT%{_sysconfdir}/hostap
100
101 %clean
102 rm -rf $RPM_BUILD_ROOT
103
104 %post
105 /sbin/chkconfig --add hostapd
106 %service hostapd restart "HostAP Daemon"
107
108 %preun
109 if [ "$1" = "0" ]; then
110         %service hostapd stop
111         /sbin/chkconfig --del hostapd
112 fi
113
114 %files
115 %defattr(644,root,root,755)
116 %doc COPYING hostapd/{ChangeLog,README,README-WPS}
117 %dir %{_sysconfdir}/hostap
118 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/hostap/hostapd.accept
119 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/hostap/hostapd.conf
120 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/hostap/hostapd.deny
121 %attr(755,root,root) /sbin/hlr_auc_gw
122 %attr(755,root,root) /sbin/hostapd
123 %attr(755,root,root) /sbin/hostapd_cli
124 %attr(755,root,root) /sbin/nt_password_hash
125 %attr(754,root,root) /etc/rc.d/init.d/hostapd
126 %{_mandir}/man1/hostapd_cli.1*
127 %{_mandir}/man8/hostapd.8*
128 %if %{with systemd}
129 %{systemdunitdir}/%{name}.service
130 %{systemdunitdir}/%{name}@.service
131 %endif
This page took 0.759264 seconds and 4 git commands to generate.