summaryrefslogtreecommitdiffstats
path: root/perl-install/help.pm
Commit message (Expand)AuthorAgeFilesLines
* s/Mandrivalinux/Mandriva Linux/Pablo Saratxaga2005-04-231-27/+27
* switch from MandrakeSoft to MandrivaThierry Vignaud2005-04-211-26/+26
* better english (writing style rather than spoken one)Thierry Vignaud2004-12-131-30/+30
* fix bad %%Pascal Rigaux2004-08-121-2/+2
* update from doc (/cooker/doc/manualB)Pascal Rigaux2004-08-121-482/+346
* spell Mandrakelinux in one wordThierry Vignaud2004-03-101-24/+24
* Changed Newt/Previous strings to remove arrowsPablo Saratxaga2004-02-061-6/+6
* update from xmlPascal Rigaux2004-02-061-106/+146
* remove arrows from previous/next buttons according to interface teamThierry Vignaud2004-01-161-5/+5
* reverted to previous version, to avoid huge strings break at this stagePablo Saratxaga2003-09-151-108/+65
* update from xml helpPascal Rigaux2003-09-091-65/+108
* new version from XML docPascal Rigaux2003-08-191-2/+2
* Fixed typosPablo Saratxaga2003-08-191-2/+2
* changed "Country" . " / Region" to "Country / Region" and fixed Chinese po'sPablo Saratxaga2003-07-121-2/+2
* "Country" -> "Country" . " / Region" in a few places still missing that changePablo Saratxaga2003-06-061-2/+2
* add prototypesPascal Rigaux2003-04-231-41/+41
* fix typo (help.pm must return a true value)Pascal Rigaux2003-04-221-0/+2
* per Pablo's request:Pascal Rigaux2003-04-221-509/+490
* update from xmlPascal Rigaux2003-03-031-109/+74
* fixed a typoPablo Saratxaga2003-02-211-1/+1
* fix typosPascal Rigaux2003-02-201-2/+2
* fixed small typoPablo Saratxaga2003-02-181-1/+1
* some more fixes (thanks to Edward Cherlin and Reinout van Schouwen)Pascal Rigaux2003-02-171-3/+3
* fix typos (thanks to Reinout van Schouwen)Pascal Rigaux2003-02-171-2/+2
* fix typo (thanks to Christophe Combelles)Pascal Rigaux2003-02-161-1/+1
* minor changes (update from xml)Pascal Rigaux2003-02-131-4/+4
* no need for "empty" id anymorePascal Rigaux2003-02-131-1/+0
* fix typo (from xml)Pascal Rigaux2003-02-131-3/+0
* new help from xmlPascal Rigaux2003-02-131-491/+610
* "license" is now step "acceptLicense"Pascal Rigaux2003-01-211-1/+1
* perl_checker adaptationsPascal Rigaux2002-11-271-1/+1
* one can now alter settings thereThierry Vignaud2002-11-191-2/+2
* replace "_" with "N" and "__" with "N_"Pascal Rigaux2002-11-061-37/+37
* update help from xmlPascal Rigaux2002-09-131-155/+150
* Fixed typoPablo Saratxaga2002-09-021-1/+1
* update help from xmlPascal Rigaux2002-08-291-103/+105
* s/enter a disk/insert a disk/ (Arpad Biro)Thierry Vignaud2002-08-201-1/+1
* - update help.pm based on the xml manualPascal Rigaux2002-07-221-70/+73
* updated help filePablo Saratxaga2002-03-111-254/+258
* updated help filePablo Saratxaga2002-02-211-14/+21
* updated help filePablo Saratxaga2002-02-181-47/+45
* new version for 8.2Stefan Siegel2002-02-171-109/+134
* updated help.pm filePablo Saratxaga2002-02-091-12/+23
* updated pot file with help messages from manualPablo Saratxaga2002-01-291-5/+24
* updated help filePablo Saratxaga2001-11-141-23/+23
* updated help filePablo Saratxaga2001-09-211-2/+2
* updated help filePablo Saratxaga2001-09-191-17/+57
* updated help filePablo Saratxaga2001-09-171-0/+34
* updated help.pm filePablo Saratxaga2001-09-161-28/+0
* Added a dialog in English for users selecting a printing system since no otherMichael Glenn Moore2001-09-151-0/+28
kwa">return file; } /* If path looks like: A/B/C/D/whatever, it returns A/B/C/D as a malloced * string. */ char *SLpath_dirname (char *file) { char *b; if (file == NULL) return NULL; b = file + strlen (file); while (b != file) { b--; if (IS_PATH_SEP(*b)) { if (b == file) b++; break; } #ifdef DRIVE_SPECIFIER if (*b == DRIVE_SPECIFIER) { b++; break; } #endif } if (b == file) return SLmake_string (THIS_DIR_STRING); return SLmake_nstring (file, (unsigned int) (b - file)); } /* Note: VMS filenames also contain version numbers. The caller will have * to deal with that. * * The extension includes the '.'. If no extension is present, "" is returned. */ char *SLpath_extname (char *file) { char *b; if (NULL == (file = SLpath_basename (file))) return NULL; b = file + strlen (file); while (b != file) { b--; if (*b == '.') return b; } if (*b == '.') return b; /* Do not return a literal "" */ return file + strlen (file); } #ifdef IBMPC_SYSTEM static void convert_slashes (char *f) { while (*f) { if (*f == '/') *f = PATH_SEP; f++; } } #endif int SLpath_is_absolute_path (char *name) { #ifdef UNIX_PATHNAMES_OK return (*name == '/'); #else if (IS_PATH_SEP (*name)) return 1; # ifdef DRIVE_SPECIFIER /* Look for a drive specifier */ while (*name) { if (*name == DRIVE_SPECIFIER) return 1; name++; } # endif return 0; #endif } /* This returns a MALLOCED string */ char *SLpath_dircat (char *dir, char *name) { unsigned int len, dirlen; char *file; #ifndef VMS int requires_fixup; #endif if (name == NULL) name = ""; if ((dir == NULL) || (SLpath_is_absolute_path (name))) dir = ""; /* Both VMS and MSDOS have default directories associated with each drive. * That is, the meaning of something like C:X depends upon more than just * the syntax of the string. Since this concept has more power under VMS * it will be honored here. However, I am going to treat C:X as C:\X * under MSDOS. * * Note!!! * VMS has problems of its own regarding path names, so I am simply * going to strcat. Hopefully the VMS RTL is smart enough to deal with * the result. */ dirlen = strlen (dir); #ifndef VMS requires_fixup = (dirlen && (0 == IS_PATH_SEP(dir[dirlen - 1]))); #endif len = dirlen + strlen (name) + 2; if (NULL == (file = SLmalloc (len))) return NULL; strcpy (file, dir); #ifndef VMS if (requires_fixup) file[dirlen++] = PATH_SEP; #endif strcpy (file + dirlen, name); #if defined(IBMPC_SYSTEM) convert_slashes (file); #endif return file; } int SLpath_file_exists (char *file) { struct stat st; int m; #if defined(__os2__) && !defined(S_IFMT) /* IBM VA3 doesn't declare S_IFMT */ # define S_IFMT (S_IFDIR | S_IFCHR | S_IFREG) #endif #ifdef _S_IFDIR # ifndef S_IFDIR # define S_IFDIR _S_IFDIR # endif #endif #ifndef S_ISDIR # ifdef S_IFDIR # define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR) # else # define S_ISDIR(m) 0 # endif #endif if (file == NULL) return -1; if (stat(file, &st) < 0) return 0; m = st.st_mode; if (S_ISDIR(m)) return (2); return 1; } char *SLpath_find_file_in_path (char *path, char *name) { unsigned int max_path_len; unsigned int this_path_len; char *file, *dir; char *p; unsigned int nth; if ((path == NULL) || (*path == 0) || (name == NULL) || (*name == 0)) return NULL; max_path_len = 0; this_path_len = 0; p = path; while (*p != 0) { if (*p++ == SEARCH_PATH_DELIMITER) { if (this_path_len > max_path_len) max_path_len = this_path_len; this_path_len = 0; } else this_path_len++; } if (this_path_len > max_path_len) max_path_len = this_path_len; max_path_len++; if (NULL == (dir = SLmalloc (max_path_len))) return NULL; nth = 0; while (-1 != SLextract_list_element (path, nth, SEARCH_PATH_DELIMITER, dir, max_path_len)) { nth++; if (*dir == 0) continue; if (NULL == (file = SLpath_dircat (dir, name))) { SLfree (dir); return NULL; } if (1 == SLpath_file_exists (file)) { SLfree (dir); return file; } SLfree (file); } SLfree (dir); return NULL; }