r409 - x86/trunk/packages/bash

jhuntwork at linuxfromscratch.org jhuntwork at linuxfromscratch.org
Mon Jul 25 16:44:57 PDT 2005


Author: jhuntwork
Date: 2005-07-25 17:44:56 -0600 (Mon, 25 Jul 2005)
New Revision: 409

Modified:
   x86/trunk/packages/bash/Makefile
Log:
Updated bash Makefile

Modified: x86/trunk/packages/bash/Makefile
===================================================================
--- x86/trunk/packages/bash/Makefile	2005-07-25 01:39:57 UTC (rev 408)
+++ x86/trunk/packages/bash/Makefile	2005-07-25 23:44:56 UTC (rev 409)
@@ -1,53 +1,104 @@
 # Bash Makefile
+#==============================================================================
 
-# Package versions
 NM= bash
 VRS= 3.0
 DIR= $(NM)-$(VRS)
+
 FILE= $(DIR).tar.bz2
+URL-$(FILE)= $(HTTP)/$(NM)/$(FILE)
+SHA-$(FILE)= 6093c4e37c114b465510fb2f74b3bd39ef20eed7
+
 PATCH1= $(DIR)-avoid_WCONTINUED-1.patch
+URL-$(PATCH1)= $(HTTP)/$(NM)/$(PATCH1)
+SHA-$(PATCH1)= 3ea7cf640d5bcf5e442654986e53e6a796ba996e
+
 PATCH2= $(DIR)-fixes-3.patch
-URL= $(HTTP)/$(NM)/$(FILE)
-URL1= $(HTTP)/$(NM)/$(PATCH1)
-URL2= $(HTTP)/$(NM)/$(PATCH2)
+URL-$(PATCH2)= $(HTTP)/$(NM)/$(PATCH2)
+SHA-$(PATCH2)= f5dc122edaac230856d208a5787a3b346959a034
 
-# RULES
+# Targets
+# =============================================================================
 
-.PHONY: stage1 clean chroot stage2
+include $(ROOT)/scripts/functions
 
-stage1:
-	@echo ""
-	@echo "=====> Building $(NM)"
-	@echo ""
-	@if [ ! -f $(SRC)/$(FILE) ] ; then $(WGET) $(URL) && \
-	 mv $(FILE) $(SRC) ; fi
-	@if [ ! -f $(SRC)/$(PATCH1) ] ; then $(WGET) $(URL1) && \
-	 mv $(PATCH1) $(SRC) ; fi
-	@if [ ! -f $(WD)/bin/bash ] ; then unpack $(SRC)/$(FILE) && cd $(DIR) && \
-	 patch -Np1 -i $(SRC)/$(PATCH1) && \
-	 ./configure --prefix=$(WD) --without-bash-malloc && make && make install && \
-	 ln -s bash $(WD)/bin/sh ; fi
-	@make clean
+stage1: $(FILE) $(PATCH1)
+	@$(std_build)
+	@cp $(SRC)/{$(FILE),$(PATCH1)} $(LFSSRC)
 
+compile-stage1:
+	@$(call echo_message, Configuring)
+#==============================================================================
+# Configure commands below \/
+#==============================================================================
+	@patch -Np1 -i ../$(PATCH1)
+	@./configure --prefix=$(WD) --without-bash-malloc \
+	 >../$(DIR)-$@.log 2>&1
+#
+#==Status Messages==========================================
+#
+	@$(OK)
+	@$(call echo_message, Making)
+#==============================================================================
+# Make commands below \/
+#==============================================================================
+	@make >>../$(DIR)-$@.log 2>&1
+#
+#==Status Messages==========================================
+#
+	@$(OK)
+	@$(call echo_message, Installing)
+#==============================================================================
+# Install commands below \/
+#==============================================================================
+	@make install >>../$(DIR)-$@.log 2>&1
+	@ln -s bash $(WD)/bin/sh
+#
+#==Status Messages==========================================
+#
+	@$(OK)
+
 chroot:
-	@chroot "$(MP)" $(chenv-pre-bash) 'cd $(ROOT) && make ch-$(NM) $(chbash-pre-bash)'
+	@chroot "$(MP)" $(chenv-pre-bash) \
+	'cd $(ROOT) && make ch-$(NM) $(chbash-pre-bash)'
 
-stage2:
-	@echo ""
-	@echo "=====> Building $(NM) in chroot"
-	@echo ""
-	@if [ ! -f $(SRC)/$(FILE) ] ; then $(WGET) $(URL) && \
-	 mv $(FILE) $(SRC) ; fi
-	@if [ ! -f $(SRC)/$(PATCH1) ] ; then $(WGET) $(URL1) && \
-	 mv $(PATCH1) $(SRC) ; fi
-	@if [ ! -f $(SRC)/$(PATCH2) ] ; then $(WGET) $(URL2) && \
-	 mv $(PATCH2) $(SRC) ; fi
-	@if [ ! -f /bin/bashbug ] ; then unpack $(SRC)/$(FILE) && cd $(DIR) && \
-	 patch -Np1 -i $(SRC)/$(PATCH2) && patch -Np1 -i $(SRC)/$(PATCH1) && \
-	 ./configure --prefix=/usr --bindir=/bin --without-bash-malloc --with-installed-readline && \
-	 make && rm /bin/bash && make install ; fi
-	@make clean
-	
+stage2: Makefile $(FILE) $(PATCH1) $(PATCH2)
+	@$(std_build)
+	@cp $(SRC)/$(PATCH2) $(LFSSRC)/
 
+compile-stage2:
+	@$(call echo_message, Configuring)
+#==============================================================================
+# Configure commands below \/
+#==============================================================================
+	@patch -Np1 -i ../$(PATCH1)
+	@patch -Np1 -i ../$(PATCH2)
+	@./configure --prefix=/usr --bindir=/bin --without-bash-malloc \
+	 --with-installed-readline >../$(DIR)-$@.log 2>&1
+#
+#==Status Messages==========================================
+#
+	@$(OK)
+	@$(call echo_message, Making)
+#==============================================================================
+# Make commands below \/
+#==============================================================================
+	@make $(PM) >>../$(DIR)-$@.log 2>&1
+#
+#==Status Messages===========================================
+#
+	@$(OK)
+	@$(call echo_message, Installing)
+#==============================================================================
+# Install commands below \/
+#==============================================================================
+	@make install >>../$(DIR)-$@.log 2>&1
+#
+#==Status Messages===========================================
+#
+	@$(OK)
+
 clean:
 	@-rm -rf $(DIR)
+
+.PHONY: compile-stage1 clean chroot compile-stage2




More information about the livecd mailing list