Hello all. I am trying to use WINE to make a windoze-only development environment (very rudimentar, command line cross-compiler and stuff) under Linux, because GNU make is far superior from the M$'s 'nmake'. Anyway, I have some trouble with expirating licenses and stuff, and the solution is to revert the system date back to some valid thing and then compile. Since I am now running it under WINE (yeah! it *almost* works great), I wonder if it is possible to hack wine so it tells the executed program some different date and time (changing systime in Linux tends to wreak havoc with makefiles and stuff) Can someone point out where the unix-to-windoze sysdate translation is done so I can hack it? TIA -- -- SNIP -- "The difference between genius and stupidity is that genius has limits" +--------------------------------------+ | Eduardo G. Andrade | | Ibiz Tecnologia | | eduardo@ibiz.com.br | | 5579-3178 r 224 | +--------------------------------------+
ops, nevermind, found it myself, pretty straightforwards... win32/time.c hacked it, works beautifully. but, itd be cool to make it a run-time option (like wine --sysdate='20000101') any hint on that? TIA. Eduardo G. Andrade wrote:> Hello all. > > I am trying to use WINE to make a windoze-only development environment > (very rudimentar, command line cross-compiler and stuff) > under Linux, because GNU make is far superior from the M$'s 'nmake'. > > Anyway, I have some trouble with expirating licenses and stuff, and the > solution is to revert the system date back to some > valid thing and then compile. > > Since I am now running it under WINE (yeah! it *almost* works great), I > wonder if it is possible to hack wine so it tells > the executed program some different date and time (changing systime in > Linux tends to wreak havoc with makefiles and stuff) > > Can someone point out where the unix-to-windoze sysdate translation is > done so I can hack it? > > TIA >-- -- SNIP -- "The difference between genius and stupidity is that genius has limits" +--------------------------------------+ | Eduardo G. Andrade | | Ibiz Tecnologia | | eduardo@ibiz.com.br | | 5579-3178 r 224 | +--------------------------------------+
Eduardo G. Andrade <eduardo@ibiz.com.br> wrote:> Hello all. > > I am trying to use WINE to make a windoze-only development environment (very rudimentar, command line cross-compiler and stuff) > under Linux, because GNU make is far superior from the M$'s 'nmake'. > > Anyway, I have some trouble with expirating licenses and stuff, and > the solution is to revert the system date back to some valid thing > and then compile.You cross-compile, but do not use i586-mingw32msvc-gcc? A shareware program?> Since I am now running it under WINE (yeah! it *almost* works great), > I wonder if it is possible to hack wine so it tells the executed program > some different date and time (changing systime in Linux tends to wreak > havoc with makefiles and stuff) > > Can someone point out where the unix-to-windoze sysdate translation is > done so I can hack it?gettimeofday() and time() - perhaps you could use a LD_PRELOAD library to fake them. -- 2.4.5 in kernel/signal.c(733): Let a parent know about a status change of a child. http://rebounce@durchnull.de
| Hello all. | | I am trying to use WINE to make a windoze-only development environment | (very rudimentar, command line cross-compiler and stuff) under Linux, | because GNU make is far superior from the M$'s 'nmake'. gcc is a better compiler, too. | ... | Since I am now running it under WINE (yeah! it *almost* works great), | I wonder if it is possible to hack wine so it tells the executed | program some different date and time (changing systime in Linux tends | to wreak havoc with makefiles and stuff) | | Can someone point out where the unix-to-windoze sysdate translation | is done so I can hack it? | Why would you think it would be in just one place? I don't know the API very well, but it is my impression that it is a mass of specialized hacks. There are probably 8192 date formats and 262144 functions to get some or all of them by. See for yourself: find <wine> -name '*.c' | xargs grep gettimeofday Lest you get discouraged, gettimeofday in the server is _probably_ for its own internal use, so this might be a morereasonable list: find <wine> -name '*.c' | xargs grep gettimeofday | grep -v server | TIA | | -- | | -- SNIP -- | | "The difference between genius and stupidity is that genius has limits" | | +--------------------------------------+ | Eduardo | G. Andrade | | Ibiz Tecnologia | | | eduardo@ibiz.com.br | | 5579-3178 r 224 | | +--------------------------------------+ | You could, of course, just LD_PRELOAD your own gettimeofday, but I bet it would play almost as much hob with file times as changing the system time would. Lawson Oh, what a tangled web we weave when first we practice to deceive.