diff --git a/Makefile b/Makefile
index 6924341936ac4c777579aeebbb41398267436b1e..4e9173dbe06acf2c47b5f8b166cc0a37e9dbc597 100644
--- a/Makefile
+++ b/Makefile
@@ -64,12 +64,14 @@ endif
 #                    #
 ######################
 
-VFILES:=$(wildcard *.v) $(wildcard lib/ModuRes/*.v)
+LIBVFILES:=$(wildcard lib/*/*.v)
+VFILES:=$(wildcard *.v) $(LIBVFILES)
 
 -include $(addsuffix .d,$(VFILES))
 .SECONDARY: $(addsuffix .d,$(VFILES))
 
 VOFILES:=$(VFILES:.v=.vo)
+LIBVOFILES:=$(LIBVFILES:.v=.vo)
 VOFILESINC=$(filter $(wildcard ./*),$(VOFILES)) 
 GLOBFILES:=$(VFILES:.v=.glob)
 VIFILES:=$(VFILES:.v=.vi)
@@ -90,6 +92,8 @@ endif
 
 all: $(VOFILES)
 
+lib: $(LIBVOFILES)
+
 spec: $(VIFILES)
 
 gallina: $(GFILES)
@@ -122,7 +126,7 @@ beautify: $(VFILES:=.beautified)
 	@echo 'Do not do "make clean" until you are sure that everything went well!'
 	@echo 'If there were a problem, execute "for file in $$(find . -name \*.v.old -print); do mv $${file} $${file%.old}; done" in your shell/'
 
-.PHONY: all opt byte archclean clean install userinstall depend html validate
+.PHONY: all lib opt byte archclean clean install userinstall depend html validate
 
 ####################
 #                  #