NMAKE Build Error: Time is in future

Hi All,

I am trying to develop a driver build environment for both x86 as well as
AMD64 machines. As far as x86 is considered, I am able to build the drivers
using all DDKs and WDKs. When I try to build drivers for AMD64, then I am
getting following error.

– snip –

:

:

BUILD: Compile and Link for AMD64

BUILD: Start time: Thu Sep 13 15:10:42 2007

BUILD: Examining c:<source code dir>\ directory for files to compile.

c:<source code dir>

BUILD: Building generated files in c:<source code dir>\ directory

ERROR - “c:<source code dir>_Filename.mac” file time is in the future.

:

:

– snip ends –

I checked other machines on which drivers are getting built, with no
occurrences of such error. I have checked system clock and BIOS clock
difference for both the machines. It is 30 mins. But it is getting built
successfully on other and failing on other machine. So there must be
something wrong in the system on which this is failing.

Can anyone please let me know reason of this error?

ERROR - “c:<source code dir>_Filename.mac” file time is in the future.

Also, if anyone has encountered this before then please let me have the
direction to solve this.

Thanks in advance.
Yogi

Hi,

I would like to explain more about the problem with an example.

I have tried to build the driver located at: C:\winddk\6000\src\usb\bulkusb\sys. This is just a sample driver from WDK package.

First I tried to build with options: build -ceZ, then it built successfully with no errors or warnings.
Then I deleted generated files and again tried to build the same with options: build -ezE.

Then it gave following description into the log file:

– snip –
BUILD: Examining c:\winddk\6000\src\usb\bulkusb\sys directory for files to compile.
before AssemblyIdentity_AfterReadAllSources
after AssemblyIdentity_AfterReadAllSources
Building generated files in c:\winddk\6000\src\usb\bulkusb\sys *************
‘nmake.exe /nologo BUILDMSG=Stop. -i BUILD_PASS=PASS0 NOLINK=1 PASS0ONLY=1 MAKEDIR_RELATIVE_TO_BASEDIR=src\usb\bulkusb\sys MAKEDIR_LOWERCASE=c:\winddk\6000\src\usb\bulkusb\sys’

before second call to ScanSourceDirectories
ERROR - “c:\winddk\6000\src\usb\bulkusb\sys\objchk_wlh_amd64\amd64_objects.mac” file time is in the future.

after second call to ScanSourceDirectories

skipping post pass 0 command
ERROR - “c:\winddk\6000\src\usb\bulkusb\sys\objchk_wlh_amd64\amd64_objects.mac” file time is in the future.

– snip ends –

What is the problem with -ezE option? I also tried to sync OS Clock with BIOS clock.

Can anyone please help me for this problem?

Thanks,

Yogi

Have you tried doing a build -cZ?

-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Thursday, September 13, 2007 8:59 AM
To: Windows System Software Devs Interest List
Subject: RE:[ntdev] NMAKE Build Error: Time is in future

Hi,

I would like to explain more about the problem with an example.

I have tried to build the driver located at: C:\winddk\6000\src\usb\bulkusb\sys. This is just a sample driver from WDK package.

First I tried to build with options: build -ceZ, then it built successfully with no errors or warnings.
Then I deleted generated files and again tried to build the same with options: build -ezE.

Then it gave following description into the log file:

– snip –
BUILD: Examining c:\winddk\6000\src\usb\bulkusb\sys directory for files to compile.
before AssemblyIdentity_AfterReadAllSources
after AssemblyIdentity_AfterReadAllSources
Building generated files in c:\winddk\6000\src\usb\bulkusb\sys *************
‘nmake.exe /nologo BUILDMSG=Stop. -i BUILD_PASS=PASS0 NOLINK=1 PASS0ONLY=1 MAKEDIR_RELATIVE_TO_BASEDIR=src\usb\bulkusb\sys MAKEDIR_LOWERCASE=c:\winddk\6000\src\usb\bulkusb\sys’

before second call to ScanSourceDirectories
ERROR - “c:\winddk\6000\src\usb\bulkusb\sys\objchk_wlh_amd64\amd64_objects.mac” file time is in the future.

after second call to ScanSourceDirectories

skipping post pass 0 command
ERROR - “c:\winddk\6000\src\usb\bulkusb\sys\objchk_wlh_amd64\amd64_objects.mac” file time is in the future.

– snip ends –

What is the problem with -ezE option? I also tried to sync OS Clock with BIOS clock.

Can anyone please help me for this problem?

Thanks,

Yogi


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

Hi,

I have tried to build with this option as well. I am getting strange
results.

  1. Reached to this location “C:\winddk\6000\src\usb\bulkusb\sys”
  2. Tried to build this driver by “build -cZ”. Driver Built successfully.
  3. Deleted objchk_wlh_amd64 folder to build the driver again with same
    option
  4. With command line: build -cZ, I have got following error:

– snip –

C:\WINDDK\6000\src\usb\bulkusb>build -cZ
BUILD: Compile and Link for AMD64
BUILD: Start time: Fri Sep 14 11:56:51 2007
BUILD: Examining c:\winddk\6000\src\usb\bulkusb directory tree for files to
comp
ile.
BUILD: Building generated files in c:\winddk\6000\src\usb\bulkusb\sys
directory
ERROR -
“c:\winddk\6000\src\usb\bulkusb\sys\objchk_wlh_amd64\amd64_objects.mac”
file time is in the future.

ERROR -
“c:\winddk\6000\src\usb\bulkusb\exe\objchk_wlh_amd64\amd64_objects.mac”
file time is in the future.

BUILD: Compiling and Linking c:\winddk\6000\src\usb\bulkusb\exe directory
Compiling - exe\rwbulk.rc
Compiling - exe\rwbulk.c
Linking Executable - exe\objchk_wlh_amd64\amd64\rwbulk.exe
BUILD: Compiling and Linking c:\winddk\6000\src\usb\bulkusb\sys directory
Compiling - sys\bulkusb.rc
Compiling - sys\bulkusb.c
Compiling - sys\bulkpnp.c
Compiling - sys\bulkpwr.c
Compiling - sys\bulkdev.c
Compiling - sys\bulkwmi.c
Compiling - sys\bulkrwr.c
Linking Executable - sys\objchk_wlh_amd64\amd64\bulkusb.sys
BUILD: Finish time: Fri Sep 14 11:56:56 2007
BUILD: Done

13 files compiled - 2 Errors
2 executables built
– snip ends –

  1. I have checked difference between RTC of my machine and Operating System
    clock difference. It seems that I have 30 mins difference between these.
    Does this matter for driver build? How to sync both clocks? Why it is
    getting built successfully for the first time and failing on next instances?

Looking for help

Yogesh

On 9/13/07, Mark Rodriquez wrote:
>
> Have you tried doing a build -cZ?
>
> -----Original Message-----
> From: xxxxx@lists.osr.com [mailto:
> xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
> Sent: Thursday, September 13, 2007 8:59 AM
> To: Windows System Software Devs Interest List
> Subject: RE:[ntdev] NMAKE Build Error: Time is in future
>
> Hi,
>
> I would like to explain more about the problem with an example.
>
> I have tried to build the driver located at:
> C:\winddk\6000\src\usb\bulkusb\sys. This is just a sample driver from WDK
> package.
>
> First I tried to build with options: build -ceZ, then it built
> successfully with no errors or warnings.
> Then I deleted generated files and again tried to build the same with
> options: build -ezE.
>
> Then it gave following description into the log file:
>
> – snip –
> BUILD: Examining c:\winddk\6000\src\usb\bulkusb\sys directory for files to
> compile.
> before AssemblyIdentity_AfterReadAllSources
> after AssemblyIdentity_AfterReadAllSources
> Building generated files in c:\winddk\6000\src\usb\bulkusb\sys
> *************
> ‘nmake.exe /nologo BUILDMSG=Stop. -i BUILD_PASS=PASS0 NOLINK=1 PASS0ONLY=1
> MAKEDIR_RELATIVE_TO_BASEDIR=src\usb\bulkusb\sys
> MAKEDIR_LOWERCASE=c:\winddk\6000\src\usb\bulkusb\sys’
>
> before second call to ScanSourceDirectories
> ERROR -
> “c:\winddk\6000\src\usb\bulkusb\sys\objchk_wlh_amd64\amd64_objects.mac”
> file time is in the future.
>
> after second call to ScanSourceDirectories
>
> skipping post pass 0 command
> ERROR -
> “c:\winddk\6000\src\usb\bulkusb\sys\objchk_wlh_amd64\amd64_objects.mac”
> file time is in the future.
>
> – snip ends –
>
> What is the problem with -ezE option? I also tried to sync OS Clock with
> BIOS clock.
>
> Can anyone please help me for this problem?
>
> Thanks,
>
> Yogi
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

> ----------

From: xxxxx@lists.osr.com[SMTP:xxxxx@lists.osr.com] on behalf of Yogi[SMTP:xxxxx@gmail.com]
Reply To: Windows System Software Devs Interest List
Sent: Friday, September 14, 2007 8:02 AM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] NMAKE Build Error: Time is in future

BUILD: Start time: Fri Sep 14 11:56:51 2007
BUILD: Examining c:\winddk\6000\src\usb\bulkusb directory tree for files to comp
ile.
BUILD: Building generated files in c:\winddk\6000\src\usb\bulkusb\sys directory
ERROR - “c:\winddk\6000\src\usb\bulkusb\sys\objchk_wlh_amd64\amd64_objects.mac”
file time is in the future.

ERROR - “c:\winddk\6000\src\usb\bulkusb\exe\objchk_wlh_amd64\amd64_objects.mac”
file time is in the future.

Have you tried to compare above listed files’ times with system time? The error is generated by build.exe whose sources are available as part of some runtime. The error is generated from function which calls GetSystemTimeAsFileTime() to get system time and GetFileAttributesEx() to get checked file timestamps. Then it compares file last write time with system time. It tolerates if ftLastWriteTime is 2 sec in the future (because of FAT way to store timestamps) but nothing more. If newer, it returns above error.

So run build again and check affected files’ last write times. A good file manager should have a way to display it. Maybe even exploder has. Or write a simple tool for this purpose or use Google to find one.

  1. I have checked difference between RTC of my machine and Operating System clock difference. It seems that I have 30 mins difference between these. Does this matter for driver build?

Who knows. As you can see, your problem is very unusual so it is on you to find what matters.

How to sync both clocks?

It should work automatically. If it doesn’t, try to change OS time by hand, RTC should be updated accordingly (at least I believe so). You can change RTC manually in BIOS setup.

Why it is getting built successfully for the first time and failing on next instances?

Try to use System Internals, now Microsoft, Process Monitor to see what happens and where is a difference between both builds. Maybe you have installed some crazy antivirus or rootkit which plays games with your files timestamps. Anyway, you should start analysis yourself.

Best regards,

Michal Vodicka
UPEK, Inc.
[xxxxx@upek.com, http://www.upek.com]