Changeset 2986

Show
Ignore:
Timestamp:
06/12/08 01:15:45 (5 years ago)
Author:
boltrix
Message:

Fixed some things to make Umit run under Windows XP. The modifications of some paths was not properly fixed on BasePaths? and other installation scripts. From now, Umit is compiling and running ok, despite the fact I'm having problems to run Nmap on Windows.

Location:
trunk
Files:
7 modified

Legend:

Unmodified
Added
Removed
  • trunk/install_scripts/windows/setup.nsi

    r1282 r2986  
    11!define py2exeOutputDir 'dist' 
    22!define exe             'Umit.exe' 
    3 !define icon            'C:\Umit\share\icons\umit_48.ico' 
     3!define icon            'C:\Umit\share\icons\umit\umit_48.ico' 
    44!define compressor      'lzma'  ;one of 'zlib', 'bzip2', 'lzma' 
    55!define onlyOneInstance 
  • trunk/install_scripts/windows/setup.py

    r2980 r2986  
    3939# Ex: python setup.py install --prefix=/tmp/umit 
    4040# Will create the directory /tmp/umit with the following directories 
    41 pixmaps_dir = os.path.join('share', 'pixmaps') 
    42 icons_dir = os.path.join('share', 'icons') 
    43 locale_dir = os.path.join('share', 'umit', 'locale') 
     41pixmaps_dir = os.path.join('share', 'pixmaps', 'umit') 
     42icons_dir = os.path.join('share', 'icons', 'umit') 
     43locale_dir = os.path.join('share', 'locale') 
    4444config_dir = os.path.join('share', 'umit', 'config') 
    45 docs_dir = os.path.join('share', 'umit', 'docs') 
     45docs_dir = os.path.join('share', 'doc', 'umits') 
    4646misc_dir = os.path.join('share', 'umit', 'misc') 
    4747 
     
    143143      cmdclass = {"py2exe":umit_py2exe}, 
    144144      windows = [{"script" : "umit", 
    145                   "icon_resources" : [(1, os.path.join("share", "icons", "umit_48.ico"))]}], 
     145                  "icon_resources" : [(1, os.path.join(icons_dir, 
     146                                                       "umit_48.ico"))]}], 
    146147      options = {"py2exe":{"compressed":1, 
    147148                           "optimize":2, 
  • trunk/install_scripts/windows/umit_compiled.nsi

    r2975 r2986  
    55;!define MUI_UNICON "share\icons\trash_32.ico" # Uninstaller icon 
    66!define MUI_HEADERIMAGE 
    7 !define MUI_HEADERIMAGE_BITMAP "share\pixmaps\splash.bmp" 
    8 !define MUI_HEADERIMAGE_UNBITMAP "share\pixmaps\splash.bmp" 
     7!define MUI_HEADERIMAGE_BITMAP "share\pixmaps\umit\splash.bmp" 
     8!define MUI_HEADERIMAGE_UNBITMAP "share\pixmaps\umit\splash.bmp" 
    99!define MUI_ABORTWARNING 
    1010!define MUI_UNABORTWARNING 
    1111 
    1212!define APPLICATION_NAME "Umit" 
    13 !define APPLICATION_VERSION "0.9.5RC1" 
     13!define APPLICATION_VERSION "0.9.5RC2" 
    1414!define WINPCAP "winpcap-nmap-4.01.exe" 
    1515 
     
    5454  File COPYING_WINPCAP 
    5555  File README 
    56   File share\icons\umit_*.ico 
     56  File share\icons\umit\umit_*.ico 
    5757 
    5858  File /r dist\*.* 
  • trunk/umitCore/BasePaths.py

    r2977 r2986  
    3737main_dir = os.path.abspath(os.path.dirname(sys.argv[0])) 
    3838if hasattr(sys, "frozen"): 
    39     main_dir = dirname(sys.executable) 
     39    main_dir = os.path.dirname(sys.executable) 
    4040 
    4141CONFIG_DIR = os.path.join(main_dir, "share", "umit", "config") 
     
    5757                  umit_opf = 'umit.opf', 
    5858                  umit_opt = 'umit.opt', 
    59                   pixmaps_dir = os.path.join('share', 'pixmaps'), 
    60                   i18n_dir = os.path.join('share','locale'), 
     59                  pixmaps_dir = PIXMAPS_DIR, 
     60                  i18n_dir = LOCALE_DIR, 
    6161                  i18n_message_file = 'umit.mo', 
    6262                  scan_results_extension = 'usr',  # comes from umit scan result 
     
    6565                  basic_search_sequence = [HOME, CURRENT_DIR], 
    6666                  config_search_sequence = [HOME, CURRENT_DIR], 
    67                   pixmaps_search_sequence = [os.path.join(CURRENT_DIR, 'share', 'pixmaps'), 
     67                  pixmaps_search_sequence = [os.path.join(CURRENT_DIR, PIXMAPS_DIR), 
    6868                                             HOME], 
    69                   i18n_search_sequence = [os.path.join(CURRENT_DIR, 'share', 'locale'), HOME], 
     69                  i18n_search_sequence = [os.path.join(CURRENT_DIR, LOCALE_DIR), HOME], 
    7070                  umitdb = "umit.db", 
    7171                  services = "nmap-services", 
     
    8484                           config_search_sequence = [os.path.join(HOME, base_paths['config_dir']), 
    8585                                                     CURRENT_DIR, '/etc'], 
    86                            pixmaps_search_sequence = [os.path.join(CURRENT_DIR, 
    87                                                                    'share', 
    88                                                                    'pixmaps'), 
    89                                                       '/usr/share/pixmaps', 
     86                           pixmaps_search_sequence = [os.path.join(CURRENT_DIR, PIXMAPS_DIR), 
     87                                                      '/usr/share/pixmaps/umit', 
    9088                                                      '/opt/umit', HOME], 
    91                            i18n_search_sequence = [os.path.join(CURRENT_DIR, 'share', 'locale'), 
     89                           i18n_search_sequence = [os.path.join(CURRENT_DIR, LOCALE_DIR), 
    9290                                                   '/usr/share/locale', 
    9391                                                   HOME, CURRENT_DIR])) 
     
    9593    PROGRAM_FILES = os.environ.get("PROGRAMFILES", "\\") 
    9694    UMIT_DIR = os.path.join(PROGRAM_FILES, "Umit") 
    97     PIXMAPS_DIR = os.path.join(UMIT_DIR, 'share', 'pixmaps') 
     95    PIXMAPS_DIR = os.path.join(UMIT_DIR, PIXMAPS_DIR) 
    9896     
    9997    base_paths.update(dict(\ 
     
    10199        config_search_sequence = [UMIT_DIR, PROGRAM_FILES, HOME, CURRENT_DIR], 
    102100        pixmaps_search_sequence = [PIXMAPS_DIR, PROGRAM_FILES, 
    103                                    os.path.join(CURRENT_DIR, 'share', 'pixmaps'), 
     101                                   os.path.join(CURRENT_DIR, PIXMAPS_DIR), 
    104102                                   HOME], 
    105103        i18n_search_sequence = [UMIT_DIR, PROGRAM_FILES, 
    106                                 os.path.join(CURRENT_DIR, 'share', 'locale'), HOME],)) 
     104                                os.path.join(CURRENT_DIR, LOCALE_DIR), HOME],)) 
    107105 
    108106elif PLATFORM == 'darwin': 
  • trunk/umitCore/NmapCommand.py

    r2975 r2986  
    2222 
    2323import sys 
     24sys.path.append(".") 
    2425import os 
    2526import re 
     
    432433                                  loadTestsFromTestCase(SplitQuotedTest)) 
    433434 
    434     scan = NmapCommand('%s -T4 -iL "/home/adriano/umit/test/targets\ teste"' % \ 
     435    scan = NmapCommand('%s -T4 192.168.0.101"' % \ 
    435436                       nmap_command_path) 
    436437    scan.run_scan() 
  • trunk/umitCore/Paths.py

    r2975 r2986  
    107107            config_dir = base_paths['user_dir'] 
    108108            config_file = supposed_file 
    109             log.debug(">>> Using config files in user home \ 
    110 directory: %s" % config_file) 
     109            log.debug(">>> Using config files in user home directory: %s" \ 
     110                      % config_file) 
    111111 
    112112        elif not exists(supposed_file)\ 
     
    156156 
    157157        log.debug(">>> Config file: %s" % config_file) 
     158        log.debug(">>> Locale: %s" % self.locale_dir) 
     159        log.debug(">>> Pixmaps: %s" % self.pixmaps_dir) 
     160        log.debug(">>> Icons: %s" % self.icons_dir) 
     161        log.debug(">>> Misc: %s" % self.misc_dir) 
     162        log.debug(">>> Docs: %s" % self.docs_dir) 
    158163 
    159164    def update_config_dir(self, config_dir): 
  • trunk/umitGUI/App.py

    r2975 r2986  
    117117        import gobject 
    118118        from umitGUI.Splash import Splash 
     119        log.info(">>> Pixmaps path: %s" % Path.pixmaps_dir) 
    119120 
    120121        if not is_maemo():