fpillet / NSLogger

A modern, flexible logging tool
Other
5k stars 573 forks source link

Definition of 'tm' must be imported from module 'Darwin.C.time' before it is required #271

Open twoputt opened 5 years ago

twoputt commented 5 years ago

Hi,

In LoggerClient.m I'm receiving an error in the routine LoggerLogToConsole: Definition of 'tm' must be imported from module 'Darwin.C.time' before it is required I found similar issues from a couple of years ago to #import <sys/time.h> would solve it, however, you already do that and the problem persists.

Any thoughts?

fpillet commented 5 years ago

Hi Red,

Sorry about this issue. It's weird as I'm not seeing this issue at all -- which Xcode / SDK / target OS are you compiling for ?

twoputt commented 5 years ago

Thanks for your response. To answer your question, I'm using Xcode 10.1 and I tried targeting iOS 9.x, iOS 10.x, and iOS 12.x. All to no avail.

I did circumvent this issue by using Foundation / NSDate operations, as I only need this to work for MacOS and iOS. Frankly, I think this is an Xcode issue given sys/time.h is an Apple Darwin header. I could also be wrong ;-)

fpillet commented 5 years ago

Wicked! I'll definitely check this out soon. Compilation should never be an issue.

BTW hit me up on my private email (fpillet at gmail), I remember your name from when you were at Dataviz (I'm the author of Powerglot) :)