Skip to content

Commit 8fa4e00

Browse files
agattidpgeorge
authored andcommitted
unix/mpconfigport: Report the correct sys.platform name on FreeBSD.
This commit lets the "sys" module report the correct value of "sys.platform" on FreeBSD systems. The only two platforms known to the module were Darwin and Linux, with the latter used as a fallback. Now FreeBSD is also recognised as such, with the appropriate string being set. Signed-off-by: Alessandro Gatti <[email protected]>
1 parent b516d39 commit 8fa4e00

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

‎ports/unix/mpconfigport.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,8 @@
4545
#ifndef MICROPY_PY_SYS_PLATFORM
4646
#if defined(__APPLE__) && defined(__MACH__)
4747
#define MICROPY_PY_SYS_PLATFORM "darwin"
48+
#elif defined(__FreeBSD__)
49+
#define MICROPY_PY_SYS_PLATFORM "freebsd"
4850
#else
4951
#define MICROPY_PY_SYS_PLATFORM "linux"
5052
#endif

0 commit comments

Comments
 (0)