I wanted to install GDC at my FreeBSD, but when I typed
the last line was such confusing, 'cause when I saw stdlib.d file with vi, it said:
as you see, it has FreeBSD support.
and I've also tried this:
then why it says "Unsupported platform"?
sudo gmake install
, those error occurred:
Code:
/usr/home/vmware/gdc/gcc-7.3.0/libphobos/libdruntime/core/stdc/stdlib.d:204:9: error: undefined identifier 'wchar_t'
int mbtowc(scope wchar_t* pwc, scope const char* s, size_t n);
^
/usr/home/vmware/gdc/gcc-7.3.0/libphobos/libdruntime/core/stdc/time.d:116:9: error: undefined identifier 'clock_t', did you mean function 'clock'?
clock_t clock();
^
/usr/home/vmware/gdc/gcc-7.3.0/libphobos/libdruntime/core/stdc/time.d:118:9: error: undefined identifier 'time_t', did you mean function 'time'?
double difftime(time_t time1, time_t time0);
^
/usr/home/vmware/gdc/gcc-7.3.0/libphobos/libdruntime/core/stdc/time.d:120:9: error: undefined identifier 'tm'
time_t mktime(tm* timeptr);
^
/usr/home/vmware/gdc/gcc-7.3.0/libphobos/libdruntime/core/stdc/wchar_.d:83:5: error: undefined identifier 'FILE'
int fwprintf(FILE* stream, in wchar_t* format, ...);
^
/usr/home/vmware/gdc/gcc-7.3.0/libphobos/libdruntime/core/stdc/stdio.d:1090:9: error: undefined identifier 'fpos_t'
int fgetpos(FILE* stream, scope fpos_t * pos);
^
../../../../gcc-7.3.0/libphobos/libdruntime/core/demangle.d:2622:16: error: module core.stdc.stdio import 'snprintf' not found, did you mean function 'sprintf'?
import core.stdc.stdio : snprintf;
^
/usr/home/vmware/gdc/gcc-7.3.0/libphobos/libdruntime/core/stdc/stdlib.d:82:6: error: static assert "Unsupported platform"
else static assert( false, "Unsupported platform" );
the last line was such confusing, 'cause when I saw stdlib.d file with vi, it said:
Code:
74 version(Windows) enum RAND_MAX = 0x7fff;
75 else version(CRuntime_Glibc) enum RAND_MAX = 0x7fffffff;
76 else version(Darwin) enum RAND_MAX = 0x7fffffff;
77 else version(FreeBSD) enum RAND_MAX = 0x7fffffff;
78 else version(NetBSD) enum RAND_MAX = 0x7fffffff;
79 else version(OpenBSD) enum RAND_MAX = 0x7fffffff;
80 else version(Solaris) enum RAND_MAX = 0x7fff;
81 else version(CRuntime_Bionic) enum RAND_MAX = 0x7fffffff;
82 else static assert( false, "Unsupported platform" );
as you see, it has FreeBSD support.
and I've also tried this:
Code:
vmware@localhost:~ % node -e 'console.log(os.platform())'
freebsd
then why it says "Unsupported platform"?