- Timestamp:
- 04/17/03 15:47:28 (22 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/setup.py
r920 r938 23 23 # 24 24 # $Log$ 25 # Revision 1.9 2003/04/17 13:47:28 jalet 26 # Help added during installation. 27 # 25 28 # Revision 1.8 2003/04/15 17:49:29 jalet 26 29 # Installation script now checks the presence of Netatalk … … 84 87 return result 85 88 86 def checkWithPrompt(prompt, module=None, command=None ) :89 def checkWithPrompt(prompt, module=None, command=None, help=None) : 87 90 """Tells the user what will be checked, and asks him what to do if something is absent.""" 88 91 sys.stdout.write("Checking for %s availability : " % prompt) … … 98 101 sys.stdout.write("NO.\n") 99 102 sys.stderr.write("ERROR : %s not available !\n" % prompt) 103 if help is not None : 104 sys.stout.write("%s\n" % help) 100 105 answer = raw_input("%s is missing. Do you want to continue anyway (y/N) ? " % prompt) 101 106 if answer[0:1].upper() == 'Y' : … … 143 148 # checks if some needed Python modules are there or not. 144 149 modulestocheck = [("PygreSQL", "pg"), ("mxDateTime", "mx.DateTime")] 145 commandstocheck = [("SNMP Tools", "snmpget" ), ("Netatalk", "pap")]150 commandstocheck = [("SNMP Tools", "snmpget", "SNMP Tools are needed if you want to use SNMP enabled printers."), ("Netatalk", "pap", "Netatalk is needed if you want to use AppleTalk enabled printers.")] 146 151 for (name, module) in modulestocheck : 147 152 action = checkWithPrompt(name, module=module) … … 151 156 152 157 # checks if some software are there or not. 153 for (name, command ) in commandstocheck :154 action = checkWithPrompt(name, command=command )158 for (name, command, help) in commandstocheck : 159 action = checkWithPrompt(name, command=command, help=help) 155 160 if action == ACTION_ABORT : 156 161 sys.stderr.write("Aborted !\n")