summaryrefslogtreecommitdiff
path: root/windows
AgeCommit message (Collapse)Author
2015-12-13unix: Move modmachine into unix directoryDave Hylands
This leaves behind the common functionality in extmod/machine_mem.c which can be used by all ports.
2015-12-12unix: Rename "_os" module to "uos" for consistency with baremetal ports.Paul Sokolovsky
2015-12-11msvc: Use different output directories depending on build typestijn
This allows multiple versions (e.g. Debug/Release, x86/x64) of micropython.exe to co-exist instead and also solves potential problems where msbuild does not completely rebuild the output and/or pdb files when switching between builds, which in turn can cause linker errors in dependent projects. By default exe/map/... files go in windows/build/$(Configuration)$(Platform) After each build micropython.exe is still copied from the above directory to the windows directory though, as that is consistent with the other ports and the test runner by default uses that location as well. Also rename env.props -> path.props which is a clearer name, and add ample documentation in the affected build files. (also see discussion in #1538)
2015-11-24windows/py: Support 64bit mingw-w64 buildsstijn
- add mp_int_t/mp_uint_t typedefs in mpconfigport.h - fix integer suffixes/formatting in mpconfig.h and mpz.h - use MICROPY_NLR_SETJMP=1 in Makefile since the current nlrx64.S implementation causes segfaults in gc_free() - update README
2015-11-24windows: Cleanup makefilestijn
The BSD stuff is a copy from the unix makefile but at least there it makes some sense, a windows makefile on BSD doesn't. The -lmman flag is probably for mmap functions but there is no other build support for it on windows so just that flag won't cut it anyway.
2015-11-14windows: Define ssize_t and use renamed mphal headerstijn
This fixes the build after changes in [66fd3e4] and [3a6b3d2]
2015-11-10windows: Allow specifying the python executable to use for msvc buildsstijn
This defaults to 'python' but can be now overridden if needed
2015-11-10Fix project file for Visual Studio 2015omtinez
2015-11-02windows: Update build instructions in the READMEstijn
- use correct 'mingw-w64' package name - small grammar fixes - modify Cygwin build instructions to use that same compiler as well: the original mingw is stuck at gcc v4.7 and does not seem to be updated anymore - make it clear thet uPy also builds using Visual Studio versions > 2013
2015-11-01windows/README: Deprecate mingw32, suggest using mingw64.Paul Sokolovsky
Ubuntu's mingw32 has gcc 4.2.1, which is rather old and has incorrect non-initialized variable analysis which produces warnings, which per MicroPython default settings get turned into errors.
2015-10-31all: Add py/mphal.h and use it in all ports.Damien George
py/mphal.h contains declarations for generic mp_hal_XXX functions, such as stdio and delay/ticks, which ports should provide definitions for. A port will also provide mphalport.h with further HAL declarations.
2015-10-31windows: Use write() instead of fwrite() to avoid out-of-order output.stijn
This fixes the basics/exception_chain.py test, also see #1500 for more info and [4300c7d] where the same change was done for the other ports.
2015-10-30windows: Call _set_output_format() only on Visual Studio versions 2013 or lower.omtinez
Since VS2015, float formatting is C standard compliant by default: https://msdn.microsoft.com/en-us/library/bb531344(v=vs.140).aspx
2015-10-26windows: Rename "time" module to "utime" for consistency with others.stijn
2015-10-26windows: Erase pre-calc'd number of chars instead of clearing whole line.stijn
2015-10-25windows: Add usleep() implementation for msvc portstijn
Also make sleep.c self-contained by moving initialization code, instead of having part of the code in init.c, and add a header file to accomodate this. msec_sleep() now uses the usleep() implementation as well.
2015-10-25windows: Do not use wildcards when looking for sources in directories ↵stijn
containing optional features Fixes issues like #1532
2015-10-20lib/mp-readline: Add n_chars argument to mp_hal_erase_line_from_cursor.Damien George
If VT100 support is not available then a given implementation of mp_hal_erase_line_from_cursor might need to know the number of characters to erase. This patch does not change generated code when VT100 is supported, since compiler can optimise away the argument.
2015-10-19all: Make netutils.h available to all ports by default.Paul Sokolovsky
Generally, ports should inherit INC from py.mk, append to it, not overwrite it. TODO: Likely should do the same for other vars too.
2015-09-23windows: Make mpconfigport.h up-to-date with the unix portstijn
2015-09-22windows/msvc: Exclude modjni from build.stijn
2015-08-14windows: Make unistd.h more posix compatiblestijn
- add SEEK_XXX definitions, this fixes missing definition in py/stream.c - move R_OK from realpath.c and add W_OK/F_OK defintions - move STDXXX_FILENO definitions from mpconfigport for consistency
2015-06-04windows/README: Add notes on running under Wine.Paul Sokolovsky
After enabling line editing support on Windows console, this is no longer trivial.
2015-06-04windows: Implement the mp_hal_xxx functions and enable mp-readlinestijn
2015-05-27unix: Factor out stdio and ctrl-C code to unix_mphal.c file.Damien George
2015-05-17py: Implement mp_format_float for doubles and use where appropriatestijn
This allows using (almost) the same code for printing floats everywhere, removes the dependency on sprintf and uses just snprintf and applies an msvc-specific fix for snprintf in a single place so nan/inf are now printed correctly.
2015-05-13windows: Enable some recently added features in mpconfigport.hstijn
2015-04-30msvc: Allow overriding of build options with custom filestijn
- by default look for a user.props in the msvc directory, which is more convenient than the built-in way of looking for such file in the user's home directory - make git ignore the file
2015-04-28py: Replace py-version.sh with makeversionhdr.py, written in Python.Damien George
Also rename py-version.h to mpversion.h for consistency with mpconfig.h.
2015-04-22msvc: Update genhdr script to emit MicroPython version numbersstijn
2015-04-16Add .gitattributes file to force text line endings to LF.Damien George
Some files are excluded, otherwise a whole lot of files need converting.
2015-04-16py: Overhaul and simplify printf/pfenv mechanism.Damien George
Previous to this patch the printing mechanism was a bit of a tangled mess. This patch attempts to consolidate printing into one interface. All (non-debug) printing now uses the mp_print* family of functions, mainly mp_printf. All these functions take an mp_print_t structure as their first argument, and this structure defines the printing backend through the "print_strn" function of said structure. Printing from the uPy core can reach the platform-defined print code via two paths: either through mp_sys_stdout_obj (defined pert port) in conjunction with mp_stream_write; or through the mp_plat_print structure which uses the MP_PLAT_PRINT_STRN macro to define how string are printed on the platform. The former is only used when MICROPY_PY_IO is defined. With this new scheme printing is generally more efficient (less layers to go through, less arguments to pass), and, given an mp_print_t* structure, one can call mp_print_str for efficiency instead of mp_printf("%s", ...). Code size is also reduced by around 200 bytes on Thumb2 archs.
2015-03-26py: Add optional support for descriptors' __get__ and __set__ methods.stijn
Disabled by default. Enabled on unix and windows ports.
2015-03-14py: Add MICROPY_COMP_{DOUBLE,TRIPLE}_TUPLE_ASSIGN config options.Damien George
These allow to fine-tune the compiler to select whether it optimises tuple assignments of the form a, b = c, d and a, b, c = d, e, f. Sensible defaults are provided.
2015-03-03py: Add MICROPY_MALLOC_USES_ALLOCATED_SIZE to allow simpler malloc API.Damien George
2015-01-12windows: Enable MICROPY_STACK_CHECK.Damien George
2015-01-10py: Add config option MICROPY_COMP_MODULE_CONST for module consts.Damien George
Compiler optimises lookup of module.CONST when enabled (an existing feature). Disabled by default; enabled for unix, windows, stmhal. Costs about 100 bytes ROM on stmhal.
2015-01-09windows: Enable MICROPY_PY_MICROPYTHON_MEM_INFO.Damien George
2015-01-08Remove obsolete bss-related code/build featuresstijn
GC for unix/windows builds doesn't make use of the bss section anymore, so we do not need the (sometimes complicated) build features and code related to it
2015-01-04msvc: Define no-op MP_LIKELY/UNLIKELY since there's no __builtin_expectstijn
2015-01-02msvc: Use single build target for dealing with generated filesstijn
Remove some duplication in the code for generating qstrdefs.generated.h and py-version.h
2015-01-02msvc: Define main build/include directories in a single locationstijn
- Use a single file env.props for defining the main directories used when building. env.props resolves the base directory and defines overridable output directories, and is used by all other build files. - Fix the build currently failing, basically because the preprocessing command for generating qstrdefs uses different include directories than the build itself does. (specifically, qstrdefs.h uses #include "py/mpconfig.h" since the fixes for #1022 in 51dfcb4, so we need to use the base directory as include directory, not the py dir itself). So define a single variable containing the include directories instead and use it where needed.
2015-01-01windows: Prefix includes with py/; remove need for -I../py.Damien George
2015-01-01msvc: Support py/*.h includes per #1022stijn
2014-12-27Makefiles: Support py/*.h includes per #1022.Paul Sokolovsky
2014-12-20windows: Correctly interpret skipped tests, enable uhashlib and ubinasciistijn
2014-12-09py: Allow builtins to be overridden.Damien George
This patch adds a configuration option (MICROPY_CAN_OVERRIDE_BUILTINS) which, when enabled, allows to override all names within the builtins module. A builtins override dict is created the first time the user assigns to a name in the builtins model, and then that dict is searched first on subsequent lookups. Note that this implementation doesn't allow deleting of names. This patch also does some refactoring of builtins code, creating the modbuiltins.c file. Addresses issue #959.
2014-12-06windows: define __USE_MINGW_ANSI_STDIO for all Windows compilers.Damien George
2014-11-21windows: Update config with latest featuresstijn
- update mpconfigport.h to reflect latest unix version - fix compilation error in modure due to msvc not allowing dynamic arrays
2014-11-17ports: Define mp_off_t.Paul Sokolovsky