]> git.ipfire.org Git - people/amarx/ipfire-3.x.git/blobdiff - hostapd/hostapd.nm
libidn: Update to version 1.30
[people/amarx/ipfire-3.x.git] / hostapd / hostapd.nm
index 9600139014b32ef32ac4b89d0b3635bafcf33043..216fe633a43fe29ecbc1993c7a08a7c5e003c5f1 100644 (file)
@@ -4,7 +4,7 @@
 ###############################################################################
 
 name       = hostapd
-version    = 0.7.3
+version    = 2.0
 release    = 1
 
 groups     = Networking/Tools
@@ -29,8 +29,15 @@ build
 
        prepare_cmds
                cd hostapd
-               cp -vf %{DIR_SOURCE}/config .config
-               sed -e "s@/usr/local@%{BUILDROOT}/usr@g" -i Makefile
+
+               # Create our custom configuration.
+               cat defconfig > .config
+               sed -i .config \
+                       -e '/^#CONFIG_DRIVER_NL80211=y/s/^#//' \
+                       -e '/^#CONFIG_DRIVER_NONE=y/s/^#//' \
+                       -e '/^#CONFIG_DRIVER_WIRED=y/s/^#//' \
+                       -e '/^#CONFIG_IEEE80211N=y/s/^#//' \
+                       -e '/^#CONFIG_RADIUS_SERVER=y/s/^#//'
        end
 
        build
@@ -39,12 +46,36 @@ build
        end
 
        install
-               mkdir -pv %{BUILDROOT}/usr/bin
-               cd hostapd && make install
+               cd hostapd
+
+               # Install binaries.
+               mkdir -pv %{BUILDROOT}%{bindir} %{BUILDROOT}%{sbindir}
+               install -m 755 hostapd %{BUILDROOT}%{sbindir}
+               install -m 755 hostapd_cli %{BUILDROOT}%{bindir}
+
+               # Install manpages.
+               mkdir -pv %{BUILDROOT}%{mandir}/man{1,8}
+               install -m 644 hostapd.8 %{BUILDROOT}%{mandir}/man8
+               install -m 644 hostapd_cli.1 %{BUILDROOT}%{mandir}/man1
        end
 end
 
 packages
        package %{name}
+               script postin
+                       systemctl daemon-reload >/dev/null 2>&1 || :
+               end
+
+               script postup
+                       systemctl daemon-reload >/dev/null 2>&1 || :
+               end
+
+               script postun
+                       systemctl daemon-reload >/dev/null 2>&1 || :
+               end
+       end
+
+       package %{name}-debuginfo
+               template DEBUGINFO
        end
 end