mirror of
https://github.com/ZDoom/Raze.git
synced 2025-06-02 10:11:04 +00:00
The great repository rearrangement of 2017.
Files moved but not modified. Changes to follow in a subsequent commit. You down with CPP? git-svn-id: https://svn.eduke32.com/eduke32@6055 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
05985da5a3
commit
1cc9d13ccf
916 changed files with 0 additions and 319 deletions
39
platform/Windows/src/compat-to-msvc/io_math.c
Normal file
39
platform/Windows/src/compat-to-msvc/io_math.c
Normal file
|
@ -0,0 +1,39 @@
|
|||
// Some libraries expect these functions, for which Visual Studio (pre-2013) falls down on the job.
|
||||
|
||||
#include <stdio.h>
|
||||
#include <math.h>
|
||||
|
||||
#ifndef _MSC_VER
|
||||
# include <stdint.h>
|
||||
int64_t _ftelli64(
|
||||
FILE *stream
|
||||
);
|
||||
int _fseeki64(
|
||||
FILE *stream,
|
||||
int64_t offset,
|
||||
int origin
|
||||
);
|
||||
#endif
|
||||
|
||||
int fseeko(FILE *fp, off_t offset, int whence)
|
||||
{
|
||||
return _fseeki64(fp, (int64_t)offset, whence);
|
||||
}
|
||||
int fseeko64(FILE *fp, off64_t offset, int whence)
|
||||
{
|
||||
return _fseeki64(fp, (int64_t)offset, whence);
|
||||
}
|
||||
|
||||
off_t ftello(FILE *stream)
|
||||
{
|
||||
return (off_t)_ftelli64(stream);
|
||||
}
|
||||
off64_t ftello64(FILE *stream)
|
||||
{
|
||||
return (off64_t)_ftelli64(stream);
|
||||
}
|
||||
|
||||
long lround(double d)
|
||||
{
|
||||
return (long)(d > 0 ? d + 0.5 : ceil(d - 0.5));
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue