summaryrefslogtreecommitdiffstats
path: root/package/nvram/src/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'package/nvram/src/Makefile')
-rw-r--r--package/nvram/src/Makefile22
1 files changed, 22 insertions, 0 deletions
diff --git a/package/nvram/src/Makefile b/package/nvram/src/Makefile
new file mode 100644
index 000000000..376c2b7de
--- /dev/null
+++ b/package/nvram/src/Makefile
@@ -0,0 +1,22 @@
+# $Id$
+
+EXTRA_CFLAGS := -c -I. -I../include
+LIBSHARED_OBJS := shutils.o wl.o wl_linux.o defaults.o linux_timer.o
+LIBNVRAM_OBJS := nvram_linux.o nvram_convert.o
+
+all: libshared.so libnvram.so nvram
+
+%.o: %.c
+ $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -o $@ $^
+
+libshared.so: $(LIBSHARED_OBJS)
+ $(CC) -shared -o $@ $^
+
+libnvram.so: $(LIBNVRAM_OBJS)
+ $(CC) -shared -o $@ $^
+
+nvram: main.o
+ $(CC) -o $@ $^ -L. -lnvram
+
+clean:
+ rm -f *.o *.so nvram