Changeset 45 for trunk/src/kmk/main.c
- Timestamp:
- Apr 3, 2003, 4:23:37 AM (22 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/kmk/main.c
r40 r45 79 79 */ 80 80 81 #if defined(USE_KLIB) || defined(KMK)81 #if defined(USE_KLIB) //|| defined(KMK) 82 82 #define KLIB_INSTRICT 83 83 #include <kLib/kLib.h> … … 533 533 char *cp = NULL, *start; 534 534 /* avoid faults on read-only strings */ 535 #ifndef KMK 535 536 static char syspath[] = _PATH_DEFSYSPATH; 537 #endif 536 538 537 539 #ifdef RLIMIT_NOFILE … … 634 636 } 635 637 638 #ifdef KMK 639 /* @todo figure out how to set object directory! */ 640 #else 636 641 /* 637 642 * The object directory location is determined using the … … 675 680 objdir = curdir; 676 681 } 682 #endif 677 683 678 684 #ifdef WANT_ENV_PWD … … 794 800 795 801 802 #ifdef KMK 803 /* 804 * Add current directory tree to system include path all levels up to the root. 805 * ASSUMES that curdir is absolute. 806 */ 807 { 808 char * psz = estrdup(curdir); 809 char * pszEnd = psz + strlen(psz); 810 while (psz < pszEnd) 811 { 812 Dir_AddDir(sysIncPath, psz); 813 814 /* Trim of the last directory component. */ 815 while (pszEnd-- > psz) 816 if (*pszEnd == '/' || *pszEnd == ':') 817 { 818 if (*pszEnd == ':') /*Drive letter means end of story */ 819 pszEnd = psz; 820 *pszEnd = '\0'; 821 break; 822 } 823 } 824 efree(psz); 825 } 826 827 #else 796 828 /* 797 829 * If no user-supplied system path was given (through the -m option) … … 811 843 } 812 844 } 845 #endif 813 846 814 847 /*
Note:
See TracChangeset
for help on using the changeset viewer.