Update Makefile
This commit is contained in:
		
							parent
							
								
									c062a954f7
								
							
						
					
					
						commit
						9c533a517f
					
				
							
								
								
									
										30
									
								
								Makefile
									
									
									
									
									
								
							
							
						
						
									
										30
									
								
								Makefile
									
									
									
									
									
								
							| @ -1,17 +1,35 @@ | |||||||
| PYTHON ?= /usr/bin/env python | PYTHON ?= /usr/bin/env python | ||||||
| 
 | 
 | ||||||
|  | PKGNAME = lorax | ||||||
|  | VERSION = $(shell awk '/Version:/ { print $$2 }' $(PKGNAME).spec) | ||||||
|  | RELEASE = $(shell awk '/Release:/ { print $$2 }' $(PKGNAME).spec | sed -e 's|%.*$$||g') | ||||||
|  | TAG = r$(VERSION)-$(RELEASE) | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | default: all | ||||||
| 
 | 
 | ||||||
| all: | all: | ||||||
| 	$(PYTHON) setup.py build | 	$(PYTHON) setup.py build | ||||||
| 
 | 
 | ||||||
| install: | install: all | ||||||
| 	$(PYTHON) setup.py install | 	$(PYTHON) setup.py install --root=$(DESTDIR) | ||||||
| 
 | 
 | ||||||
| clean: | clean: | ||||||
| 	-rm -rf build | 	-rm -rf build | ||||||
| 
 | 
 | ||||||
| testlocal: | tag: | ||||||
| 	/usr/bin/lorax -p FEDORA -v RAWHIDE -r 2010 -s /rawrepo /root/rawhide | 	git tag -f $(TAG) | ||||||
| 
 | 
 | ||||||
| test: | archive: tag | ||||||
| 	/usr/bin/lorax -p FEDORA -v RAWHIDE -r 2010 -s http://download.englab.brq.redhat.com/pub/fedora/linux/development/rawhide/x86_64/os/ /root/rawhide | 	@git archive --format=tar --prefix=$(PKGNAME)-$(VERSION)/ $(TAG) > $(PKGNAME)-$(VERSION).tar | ||||||
|  | 	@bzip2 $(PKGNAME)-$(VERSION).tar | ||||||
|  | 	@echo "The archive is in $(PKGNAME)-$(VERSION).tar.bz2" | ||||||
|  | 
 | ||||||
|  | local: | ||||||
|  | 	@rm -rf $(PKGNAME)-$(VERSION).tar.bz2 | ||||||
|  | 	@rm -rf /tmp/$(PKGNAME)-$(VERSION) /tmp/$(PKGNAME) | ||||||
|  | 	@dir=$$PWD; cp -a $$dir /tmp/$(PKGNAME)-$(VERSION) | ||||||
|  | 	@rm -rf /tmp/$(PKGNAME)-$(VERSION)/.git | ||||||
|  | 	@dir=$$PWD; cd /tmp; tar --bzip2 -cSpf $$dir/$(PKGNAME)-$(VERSION).tar.bz2 $(PKGNAME)-$(VERSION) | ||||||
|  | 	@rm -rf /tmp/$(PKGNAME)-$(VERSION) | ||||||
|  | 	@echo "The archive is in $(PKGNAME)-$(VERSION).tar.bz2" | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user