Porting to OS/2: Case #2 wildcards
When wildcards(*, ?) are provided as arguments, OS/2 accepts them as is, but Unix-like systems expand them to real entires. In fact, who do this is a shell. Fortunately, OS/2 shells such as CMD and 4OS2, do not this task. So this became the task of applications. You can do this by yourself. But kLIBC provides a function and a link flag for this. The function is _wildcard() and the flag is -Zargs-wild. If you add -Zargs-wild to your linker flag, then _wildcard() is called automatically on startup. Or do like this. Colored By Color Scripter ™ 1 2 3 4 5 6 7 8 9 10 int main( int argc, char *argv[]) { #ifdef __OS2__ _wildcard(&argc, &argv); #endif /* some codes */ return 0; } By this, you can expand wildcards in arguments to real file entries. For examples, if ...