Open GoogleCodeExporter opened 9 years ago
Same trouble under wine-1.1.38/MinGW-4.4.0
Original comment by zl29ah@gmail.com
on 2 Mar 2010 at 5:23
I believe this is because ./configure creates a utilities.h file that should
include windows/port.h instead of just port.h; however, fixing this simply
leads to issue 15
Original comment by warrensi...@gmail.com
on 10 Oct 2010 at 11:16
I don't think that last solution is correct - though I do not have a Windows
machine to test. (To third parties, I'm implicated in this because Warren and
I are working on a project and he's on the Windows side...)
Let's actually look at the files in the directory.
src/
config.h
# other stuff.
glog/
log_severity.h
logging.h
# other
windows/
config.h
port.h
glog/
log_severity.h
logging.h
# other stuff.
You can see that the windows/ subdirectory contains "amended" copies of files
in the main directory.
So it seems to me that including windows/port.h is not the right thing - in
fact, the writers of the code are intending to shadow window's "port.h" with
their own.
It seems to me that the solution is that that src/windows subdirectory needs to
be in the include path of your compilation before the src/ subdirectory.
I have to say that I'm not sure how the include path really gets set inside config, but I'm pretty sure that this is the correct diagnosis of the issue.
Original comment by tom.ritc...@gmail.com
on 12 Oct 2010 at 3:44
I did a hack on Makefile to inlcude 'src/windows' with -I option. With this the
src/windows/port.h is included automatically.
But the below problem remains:
src/windows/port.h: In function 'tm* localtime_r(const time_t*, tm*)':
src/windows/port.h:133:28: error: 'localtime_s' was not declared in this scope
src/windows/port.h: In function 'char* strerror_r(int, char*, size_t)':
src/windows/port.h:138:33: error: 'strerror_s' was not declared in this scope
So i opened the time.h and string.h from C:\MinGW\include to see whether the
files have the functions localtime_s and strerror_s but there are no such
definitions.
I have attached the files for reference!
Please advise on how to modify glog source for MINGW!
Original comment by kdkoms...@live.in
on 2 Oct 2012 at 5:39
Attachments:
Hi,
Please dont use MSYS/MINGW for compiling GLOG builds. I fixed the errors with
src/windows/port.h . But the errors related to src/logging.cc cant be solved as
MSYS/MINGW does not have 'syslink' (symbolic link) in unistd.h
(http://mingw.org/wiki/MSYS_1_0_12_Features)
So for WINDOWS environment better use Visual Studio or Cygwin environment!
Thanks
KDK
Original comment by kdkoms...@live.in
on 2 Oct 2012 at 8:16
Original issue reported on code.google.com by
AndrewMc...@gmail.com
on 14 Jan 2010 at 6:41