User forums > General (but related to Code::Blocks)

Include regex.h

(1/2) > >>

Rossati:
Hi
I am using Code::Block 17.2 on windows 10 and I can't include <regex.h>.
I tried to add this search directory C:\Program Files (x86)\CodeBlocks\MinGW\lib\gcc\mingw32\5.1.0\include\c++ but this is not working.

Thanks

Miguel Gimenez:
You must include <regex>, not <regex.h>

Rossati:
Thanks Miguel
Unfortunately I have tried also
--- Quote ---#include <regex>
--- End quote ---
, but the result is always
--- Quote ---... fatal error: regex: No such file or directory|
--- End quote ---
best regards

Miguel Gimenez:
Then post a full rebuild log:

http://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F

Rossati:
I am running Code::Blocks version 17.12 on Windows 10

Build log:

--- Code: ---
-------------- Build file: "no target" in "no project" (compiler: unknown)---------------

mingw32-gcc.exe  -I"C:\Program Files (x86)\CodeBlocks\MinGW\lib\gcc\mingw32\5.1.0\include\c++\bits" -c C:\Sviluppo\fGenTK\C\re.c -o C:\Sviluppo\fGenTK\C\re.o
mingw32-g++.exe  -o C:\Sviluppo\fGenTK\C\re.exe C:\Sviluppo\fGenTK\C\re.o   
C:\Sviluppo\fGenTK\C\re.c:4:17: fatal error: regex: No such file or directory
compilation terminated.
Process terminated with status 1 (0 minute(s), 0 second(s))
1 error(s), 0 warning(s) (0 minute(s), 0 second(s))
 

--- End code ---

I have already tried ...
#include <bits/regex.h>
... but none of them worked.

Navigation

[0] Message Index

[#] Next page

Go to full version