Willus.com Home   |   Archive   |   About  

Willus.com's MinGW/Gnu C Tips

MinGW Tips
Overview
Install Notes
Benchmark
Starter Links
Compile Flags
Fast Math Funcs
DLLs
Globbing
Console
Binary Stdout
Predefined Macros
Linker Map
Show All Tips
 
  No Globbing
By default compile, if you run a MinGW compiled command-line utility and pass it a wildcard argument such as *.c, it acts exactly as a unix utility and looks for every file ending in .c in your current file directory, replacing the *.c argument with the name of every one of those files so that your program never actually sees the *.c. (In unix/linux, it's actually the shell that does this work.) To prevent MinGW C programs from mimicking this "globbing," (e.g. to actually see "*.c" as the command argument) put CRT_noglob.o (in the MinGW library directory) at the beginning of your link list when linking.

Or, put this into your C code to turn on or off from inside your program:

extern int _CRT_glob = 0; /* 0 turns off globbing; 1 turns it on */


 
MinGW Links
MinGW64 Home
MinGW Home
Users Mail Archive
MinGW Bug List
Gnu C Home

Willus.com Links
Willus.com Home
Win32/64 Compilers
Win32/64 Software
Compiler Benchmark

This page last modified
Saturday, 13-Jun-2020 11:54:52 MDT