Share common routines into a reg lib, other objects will later reuse.
authorLuis R. Rodriguez <lrodriguez@atheros.com>
Tue, 28 Oct 2008 22:15:36 +0000 (15:15 -0700)
committerLuis R. Rodriguez <lrodriguez@atheros.com>
Tue, 28 Oct 2008 22:15:36 +0000 (15:15 -0700)
renamed:    regdb.c -> reglib.c
renamed:    crda.h -> reglib.h

Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Makefile
crda.c
dump.c
reglib.c [moved from regdb.c with 100% similarity]
reglib.h [moved from crda.h with 100% similarity]

index 8ea132b..969c263 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -41,9 +41,9 @@ keys-%.c: key2pub.py $(wildcard *.pem)
        $(NQ) '  CC  ' $@
        $(Q)$(CC) -c $(CPPFLAGS) $(CFLAGS) -o $@ $<
 
-crda: keys-ssl.c keys-gcrypt.c regdb.o crda.o
+crda: keys-ssl.c keys-gcrypt.c reglib.o crda.o
        $(NQ) '  LD  ' $@
-       $(Q)$(CC) $(CFLAGS) $(LDFLAGS) `pkg-config --libs libnl-1` -o $@ regdb.o crda.o
+       $(Q)$(CC) $(CFLAGS) $(LDFLAGS) `pkg-config --libs libnl-1` -o $@ reglib.o crda.o
 
 warn:
        @if test ! -f key.priv.pem || diff -qNs test-key key.priv.pem >/dev/null ; then \
@@ -59,9 +59,9 @@ key.priv.pem:
 generate_key:
        $(Q)openssl genrsa -out key.priv.pem 2048
 
-dump: keys-ssl.c keys-gcrypt.c regdb.o dump.o
+dump: keys-ssl.c keys-gcrypt.c reglib.o dump.o
        $(NQ) '  LD  ' $@
-       $(Q)$(CC) $(CFLAGS) $(LDFLAGS) -o $@ regdb.o dump.o
+       $(Q)$(CC) $(CFLAGS) $(LDFLAGS) -o $@ reglib.o dump.o
 
 verify: regulatory.bin dump
        $(NQ) '  CHK  regulatory.bin'
diff --git a/crda.c b/crda.c
index 0930c69..1ea866d 100644 (file)
--- a/crda.c
+++ b/crda.c
@@ -19,7 +19,7 @@
 #include <linux/nl80211.h>
 
 #include "regdb.h"
-#include "crda.h"
+#include "reglib.h"
 
 struct nl80211_state {
        struct nl_handle *nl_handle;
diff --git a/dump.c b/dump.c
index 2bd9bc8..36fbe0e 100644 (file)
--- a/dump.c
+++ b/dump.c
@@ -7,7 +7,7 @@
 #include <arpa/inet.h> /* ntohl */
 
 #include "regdb.h"
-#include "crda.h"
+#include "reglib.h"
 
 static void print_reg_rule(__u8 *db, int dblen, __be32 ruleptr)
 {
similarity index 100%
rename from regdb.c
rename to reglib.c
diff --git a/crda.h b/reglib.h
similarity index 100%
rename from crda.h
rename to reglib.h