← Back to team overview

team4alfanous team mailing list archive

[Branch ~team4alfanous/alfanous/alfanous-git] Rev 332: Makefile self documentation , issue #71

 

------------------------------------------------------------
revno: 332
committer: Assem Chelli <assem.ch@xxxxxxxxx>
timestamp: Fri 2012-09-07 07:40:36 +0100
message:
  Makefile self documentation , issue #71
modified:
  Makefile


--
lp:alfanous
https://code.launchpad.net/~team4alfanous/alfanous/alfanous-git

Your team Alfanous team is subscribed to branch lp:alfanous.
To unsubscribe from this branch go to https://code.launchpad.net/~team4alfanous/alfanous/alfanous-git/+edit-subscription
=== modified file 'Makefile'
--- Makefile	2012-09-07 06:37:25 +0000
+++ Makefile	2012-09-07 06:40:36 +0000
@@ -6,28 +6,49 @@
 #
 ##  TODO: Must follow the standards!
 ##  TODO: Check installation scripts
-
-
-
-## Global Version of the project , must be updated in each significant change in the API
-# 0.7.00 is the initial version 
+##  TODO: make a self-documentations for Makefile using comments
+
+
+
+
+## Global Version of the project, must be updated in each significant change in 
+## the API & Desktop Gui
 VERSION="0.7.00"
 
+## API path, API contains all python packages 
 API_PATH="./src/"
-QIMPORT=$(API_PATH)"alfanous-import/main.py"
+
+## Importer package path, the importer is the responsible of downloading quranic
+## resources, updating them , indexing them.
+QIMPORT=$(API_PATH)"alfanous-import/main.py" 
+	
+## Dynamic resources, are some auto-generated python modules that contain some 
+## linguistic resources on the form of python dictionaries		
 DYNAMIC_RESOURCES_PATH=$(API_PATH)"alfanous/dynamic_resources/"
 
+## Alfanous Desktop Gui configuration files, generated by "configobj" module 
 CONFIG_PATH="./resources/configs/"
+
+## Databases file, the databases mainly store the Quranic data in a middle 
+## structure before indexing it  
 DB_PATH="./resources/databases/"
-QT_UI_PATH="./resources/UI/"
 
+## Store is the place where we're storing the Quranic data in its original 
+## structure (raw data)
 STORE_PATH="./store/"
+
+## Index path, is where we put the generated indexes
 INDEX_PATH=$(API_PATH)"alfanous/indexes/"
 
+## Desktop Gui interface path
 DESKTOP_INTERFACE_PATH=$(API_PATH)"alfanous-desktop/"
+## Path of Web User Interface for mobiles 
 MOBILE_WUI_PATH=./interfaces/web/mobile_wui/
+## Web User interface path
 WUI_PATH=./interfaces/web/wui/
 
+
+##  Installation Paths:
 PREFIX?=/usr
 CONFIG_INSTALL_PATH="$(DESTDIR)$(PREFIX)/share/alfanous-config/"
 INDEX_INSTALL_PATH="$(DESTDIR)$(PREFIX)/share/alfanous-indexes/"
@@ -35,19 +56,43 @@
 WEB_CGI_INSTALL_PATH=$(WEB_INSTALL_PATH)cgi/
 
 
+## default target, it's what to do if you typed "make" without target
 default: 
-	@echo "choose a target!"
+	@echo "choose a target:"
+	@echo "download_all \n\t to download all Quranic resources that we can't \n\t include in Git or tarball because of license or huge size" 
+	@echo "build \n\t to build all indexes, update all resources, qt files, \n\t localization files, help files"
+	@echo "tarball_data \n\t to make a tarball that contains all downloaded \n\t and generated data"
+	@echo "dist_all \n\t to generate all distribution files for the API and \n\t the Desktop interface"
+	@echo "install_all \n\t install all interfaces on your system. don't use \n\t it unless you know what you are doing!! (deprecated)"
+	 
 	
+
+## This target englob all the targets on this makefile
+## it may help when you are going to make a release
+## it will do every thing:
+# 1. download all Quranic resources that we can't include in Git or tarball because of license or huge size
+# 2. build all indexes, update all resources, qt files,  localization files, help files
+# 3. make a tarball that contains all downloaded and generated data
+# 4. generate all possible distribution files for all interfaces: API, Desktop interface
 ## Kaboom! @TODO: must test this well
-all:  download_all   build   tarball_data  dist_all  clean  #tarball_minimal #install_all	 
-
-
-##
+all:  download_all   build   tarball_data  dist_all  clean  #install_all	 
+
+
+## this target is to build all what have to be built:
+# 1. Update Quranic resources needed for indexing phase, see update_pre_build
+# 2. Generate all Indexes, see  index_all
+# 3. Generate all spelling dictionaries, see speller_all
+# 4. Update all resources that must be updated after indexing phase or independently, see  update_post_build
+# 5. Build qt resource files, see qt_all
+# 6. Generate localization files, see local_pot_all
+# 7. Generate help files, see help_all
 build:  update_pre_build index_all speller_all update_post_build qt_all local_pot_all help_all
 
-	
+
+## clean temporary files after a building operation
+# TODO	add all what has to be cleaned!
 clean:
-	@echo "Cleaning" 
+	@echo "Cleaning..." 
 	rm -rf `find . -type f -name Thumbs.db`
 	#rm -rf `find . -name *~`
 	rm -rf `find . -name *.pyc`