Changeset 7770cc5dee8fe34e69492da723b75e024d9c3e90

Show
Ignore:
Timestamp:
11/04/09 01:51:33 (3 years ago)
Author:
Pierre-Alexandre Meyer <pierre@…>
Children:
494fa55b2fe19660464b008af12694f2448512f1
Parents:
4c87c3409e1788191541cc1e4897bc38f5fe02c6, 291f0542a26110868069d9f92d7d71c9974e28ff
git-committer:
Pierre-Alexandre Meyer <pierre@mouraf.org> / 2009-11-03T17:51:33Z-0800
Message:

Merge commit 'hdt-0.3.5-pre2' into hdt-0.3.5

Location:
com32
Files:
10 modified

Legend:

Unmodified
Added
Removed
  • com32/hdt/hdt-cli-hdt.c

    rad501c r7770cc  
    194194{ 
    195195        char version_string[256]; 
    196         snprintf(version_string, sizeof version_string, "%s %s", 
    197                  PRODUCT_NAME, VERSION); 
     196        snprintf(version_string, sizeof version_string, "%s %s (%s)", 
     197                 PRODUCT_NAME, VERSION, CODENAME); 
    198198        start_menu_mode(hardware, version_string); 
    199199        return; 
     
    242242    reset_more_printf(); 
    243243        more_printf("HDT\n"); 
    244         more_printf(" Product     : %s\n", PRODUCT_NAME); 
    245         more_printf(" Version     : %s\n", VERSION); 
    246         more_printf(" Author      : %s\n", AUTHOR); 
    247         more_printf(" Contact     : %s\n", CONTACT); 
     244        more_printf(" Product        : %s\n", PRODUCT_NAME); 
     245        more_printf(" Version        : %s (%s)\n", VERSION, CODENAME); 
     246        more_printf(" Project Leader : %s\n", AUTHOR); 
     247        more_printf(" Contact        : %s\n", CONTACT); 
     248        more_printf(" Core Developer : %s\n", CORE_DEVELOPER); 
    248249        char *contributors[NB_CONTRIBUTORS] = CONTRIBUTORS; 
    249250        for (int c = 0; c < NB_CONTRIBUTORS; c++) { 
    250                 more_printf(" Contributor : %s\n", contributors[c]); 
     251                more_printf(" Contributor    : %s\n", contributors[c]); 
    251252        } 
    252253} 
  • com32/hdt/hdt-cli.h

    rf8ac66 rad501c  
    4949#define CLI_EXIT "exit" 
    5050#define CLI_HELP "help" 
     51#define CLI_REBOOT "reboot" 
    5152#define CLI_SHOW "show" 
    5253#define CLI_SET "set" 
  • com32/hdt/hdt-common.c

    r47ac91 rd98e62  
    7373        sizeof(hardware->memtest_label)); 
    7474      convert_isolinux_filename(hardware->memtest_label,hardware); 
     75    } else if (!strncmp(argv[i], "reboot=", 7)) { 
     76      strncpy(hardware->reboot_label, argv[i] + 7, 
     77        sizeof(hardware->reboot_label)); 
     78      convert_isolinux_filename(hardware->reboot_label,hardware); 
    7579    } 
    7680  } 
     
    134138         sizeof hardware->modules_alias_path); 
    135139  memset(hardware->memtest_label, 0, sizeof hardware->memtest_label); 
     140  memset(hardware->reboot_label, 0, sizeof hardware->reboot_label); 
    136141  strcat(hardware->pciids_path, "pci.ids"); 
    137142  strcat(hardware->modules_pcimap_path, "modules.pcimap"); 
    138143  strcat(hardware->modules_alias_path, "modules.alias"); 
    139144  strcat(hardware->memtest_label, "memtest"); 
     145  strcat(hardware->reboot_label, "reboot.c32"); 
    140146} 
    141147 
  • com32/hdt/hdt-common.h

    r079f92 rd98e62  
    163163  char pciids_path[255]; 
    164164  char memtest_label[255]; 
     165  char reboot_label[255]; 
    165166}; 
    166167 
  • com32/hdt/hdt-menu-about.c

    r51148f r291f05  
    4040  set_menu_pos(SUBMENU_Y, SUBMENU_X); 
    4141 
    42   snprintf(buffer, sizeof buffer, "Product     : %s", PRODUCT_NAME); 
     42  snprintf(buffer, sizeof buffer, "Product        : %s", PRODUCT_NAME); 
    4343  snprintf(statbuffer, sizeof statbuffer, "Product : %s", PRODUCT_NAME); 
    4444  add_item(buffer, statbuffer, OPT_INACTIVE, NULL, 0); 
    4545  menu->items_count++; 
    4646 
    47   snprintf(buffer, sizeof buffer, "Version     : %s", VERSION); 
    48   snprintf(statbuffer, sizeof statbuffer, "Version : %s", VERSION); 
     47  snprintf(buffer, sizeof buffer, "Version        : %s (%s)", VERSION, CODENAME); 
     48  snprintf(statbuffer, sizeof statbuffer, "Version : %s (%s)", VERSION,CODENAME); 
    4949  add_item(buffer, statbuffer, OPT_INACTIVE, NULL, 0); 
    5050  menu->items_count++; 
    5151 
    52   snprintf(buffer, sizeof buffer, "Author      : %s", AUTHOR); 
    53   snprintf(statbuffer, sizeof statbuffer, "Author  : %s", AUTHOR); 
     52  snprintf(buffer, sizeof buffer, "Project Leader : %s", AUTHOR); 
     53  snprintf(statbuffer, sizeof statbuffer, "Project Leader  : %s", AUTHOR); 
    5454  add_item(buffer, statbuffer, OPT_INACTIVE, NULL, 0); 
    5555  menu->items_count++; 
    5656 
    57   snprintf(buffer, sizeof buffer, "Contact     : %s", CONTACT); 
     57  snprintf(buffer, sizeof buffer, "Contact        : %s", CONTACT); 
    5858  snprintf(statbuffer, sizeof statbuffer, "Contact : %s", CONTACT); 
     59  add_item(buffer, statbuffer, OPT_INACTIVE, NULL, 0); 
     60  menu->items_count++; 
     61 
     62  snprintf(buffer, sizeof buffer, "Core Developer : %s", CORE_DEVELOPER); 
     63  snprintf(statbuffer, sizeof statbuffer, "Core Developer  : %s", CORE_DEVELOPER); 
    5964  add_item(buffer, statbuffer, OPT_INACTIVE, NULL, 0); 
    6065  menu->items_count++; 
     
    6267  char *contributors[NB_CONTRIBUTORS] = CONTRIBUTORS; 
    6368  for (int c=0; c<NB_CONTRIBUTORS; c++) { 
    64    snprintf(buffer, sizeof buffer, "Contributor : %s", contributors[c]); 
     69   snprintf(buffer, sizeof buffer, "Contributor    : %s", contributors[c]); 
    6570   snprintf(statbuffer, sizeof statbuffer, "Contributor : %s", contributors[c]); 
    6671   add_item(buffer, statbuffer, OPT_INACTIVE, NULL, 0); 
  • com32/hdt/hdt-menu.c

    ra4dfd1 rd98e62  
    293293  add_item("<A>bout", "About Menu", OPT_SUBMENU, NULL, 
    294294     hdt_menu->about_menu.menu); 
     295  add_item("<R>eboot", "Reboot", OPT_RUN, hardware->reboot_label, 0); 
    295296  add_item("E<x>it","Exit", OPT_EXITMENU,NULL,0); 
    296297  hdt_menu->main_menu.items_count++; 
  • com32/hdt/hdt.c

    r821b54 r291f05  
    4949  struct s_hardware hardware; 
    5050 
    51   snprintf(version_string, sizeof version_string, "%s %s", 
    52            PRODUCT_NAME,VERSION); 
     51  snprintf(version_string, sizeof version_string, "%s %s (%s)", 
     52           PRODUCT_NAME,VERSION, CODENAME); 
    5353 
    5454  /* Opening the Syslinux console */ 
  • com32/hdt/hdt.h

    r4dc540 r291f05  
    3232#define PRODUCT_NAME "Hardware Detection Tool" 
    3333#define AUTHOR "Erwan Velu" 
     34#define CORE_DEVELOPER "Pierre-Alexandre Meyer" 
    3435#define CONTACT "hdt@zytor.com" 
    35 #define VERSION "0.3.5-pre1" 
    36 #define NB_CONTRIBUTORS 3 
    37 #define CONTRIBUTORS {"Pierre-Alexandre Meyer", "Sebastien Gonzalve", "Gert Hulselmans"} 
     36#define VERSION "0.3.5-pre2" 
     37#define CODENAME "mojito" 
     38#define NB_CONTRIBUTORS 2  
     39#define CONTRIBUTORS {"Sebastien Gonzalve", "Gert Hulselmans"} 
    3840 
    3941#define ATTR_PACKED __attribute__((packed)) 
  • com32/include/libansi.h

    r3e9ec4 r4c87c3  
    7272} 
    7373 
    74 /* 
    75  * cls - clear and initialize the entire screen 
    76  * 
    77  * Note: when initializing xterm, one has to specify that 
    78  * G1 points to the alternate character set (this is not true 
    79  * by default). Without the initial printf "\033)0", line drawing 
    80  * characters won't be displayed. 
    81  */ 
    82 static inline void cls(void) 
    83 { 
    84         fputs("\033e\033%@\033)0\033(B\1#0\033[?25l\033[2J", stdout); 
    85 } 
     74void cls(void); 
    8675 
    8776static inline void cursoroff(void) 
  • com32/lib/sys/libansi.c

    r71fb86 r4c87c3  
    114114 * Convert the VGA attribute @attr to an ANSI escape sequence and 
    115115 * print it. 
     116 * For performance, SGR parameters are cached. To reset them, 
     117 * call cprint_vga2ansi('0', '0'). 
    116118 **/ 
    117119static void cprint_vga2ansi(const char chr, const char attr) 
     
    120122        static uint16_t last_attr = 0x300; 
    121123        char buf[16], *p; 
     124 
     125    if (chr == '0' && attr == '0') { 
     126        last_attr = 0x300; 
     127        return; 
     128    } 
    122129 
    123130        if (attr != last_attr) { 
     
    164171} 
    165172 
     173/* 
     174 * cls - clear and initialize the entire screen 
     175 * 
     176 * Note: when initializing xterm, one has to specify that 
     177 * G1 points to the alternate character set (this is not true 
     178 * by default). Without the initial printf "\033)0", line drawing 
     179 * characters won't be displayed. 
     180 */ 
     181void cls(void) 
     182{ 
     183        fputs("\033e\033%@\033)0\033(B\1#0\033[?25l\033[2J", stdout); 
     184 
     185    /* Reset SGR parameters cache */ 
     186    cprint_vga2ansi('0', '0'); 
     187} 
     188 
    166189void reset_colors() 
    167190{