Fixing for windows + bumping version.
This commit is contained in:
@ -12,7 +12,7 @@
|
|||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
VERSION=7.0.6.12
|
VERSION=7.0.6.13
|
||||||
STABLE_VERSION=7.0.5.4
|
STABLE_VERSION=7.0.5.4
|
||||||
REVISION=$(shell git rev-parse HEAD | head -c 20)
|
REVISION=$(shell git rev-parse HEAD | head -c 20)
|
||||||
REVSHORT=$(shell echo $(REVISION) | head -c 7)
|
REVSHORT=$(shell echo $(REVISION) | head -c 7)
|
||||||
@ -26,7 +26,7 @@ WINDOWS = $(OUT)/windows
|
|||||||
ESP32 = $(OUT)/esp32
|
ESP32 = $(OUT)/esp32
|
||||||
DEPLOY = $(OUT)/deploy
|
DEPLOY = $(OUT)/deploy
|
||||||
|
|
||||||
CFLAGS_COMMON = -std=c++11 -O2 -I ./ -I $(OUT)
|
CFLAGS_COMMON = -O2 -I ./ -I $(OUT)
|
||||||
|
|
||||||
CFLAGS_MINIMIZE = \
|
CFLAGS_MINIMIZE = \
|
||||||
-s \
|
-s \
|
||||||
@ -43,6 +43,7 @@ CFLAGS_MINIMIZE = \
|
|||||||
-fmerge-all-constants
|
-fmerge-all-constants
|
||||||
CFLAGS = $(CFLAGS_COMMON) \
|
CFLAGS = $(CFLAGS_COMMON) \
|
||||||
$(CFLAGS_MINIMIZE) \
|
$(CFLAGS_MINIMIZE) \
|
||||||
|
-std=c++11 \
|
||||||
-Wall \
|
-Wall \
|
||||||
-Werror \
|
-Werror \
|
||||||
-no-pie \
|
-no-pie \
|
||||||
@ -170,7 +171,7 @@ WINDOWS_BOOT = common/boot.fs common/conditionals.fs common/vocabulary.fs \
|
|||||||
common/blocks.fs common/locals.fs \
|
common/blocks.fs common/locals.fs \
|
||||||
common/fini.fs
|
common/fini.fs
|
||||||
$(GEN)/windows_boot.h: common/source_to_string.js $(WINDOWS_BOOT) | $(GEN)
|
$(GEN)/windows_boot.h: common/source_to_string.js $(WINDOWS_BOOT) | $(GEN)
|
||||||
$< boot $(VERSION) $(REVISION) $(WINDOWS_BOOT) >$@
|
$< -win boot $(VERSION) $(REVISION) $(WINDOWS_BOOT) >$@
|
||||||
|
|
||||||
ESP32_BOOT = common/boot.fs common/conditionals.fs common/vocabulary.fs \
|
ESP32_BOOT = common/boot.fs common/conditionals.fs common/vocabulary.fs \
|
||||||
common/tasks.fs esp32/platform.fs esp32/highlevel.fs \
|
common/tasks.fs esp32/platform.fs esp32/highlevel.fs \
|
||||||
|
|||||||
@ -30,17 +30,33 @@ function DropCopyright(source) {
|
|||||||
return cleaned.join('\n');
|
return cleaned.join('\n');
|
||||||
}
|
}
|
||||||
|
|
||||||
var name = process.argv[2];
|
var is_windows = false;
|
||||||
var version = process.argv[3];
|
|
||||||
var revision = process.argv[4];
|
var args = process.argv.slice(2);
|
||||||
|
if (args.length > 0 && args[0] == '-win') {
|
||||||
|
is_windows = true;
|
||||||
|
args.shift();
|
||||||
|
}
|
||||||
|
var name = args.shift();
|
||||||
|
var version = args.shift();
|
||||||
|
var revision = args.shift();
|
||||||
var source = '';
|
var source = '';
|
||||||
for (var i = 5; i < process.argv.length; i++) {
|
while (args.length > 0) {
|
||||||
source += DropCopyright(fs.readFileSync(process.argv[i]).toString());
|
source += DropCopyright(fs.readFileSync(args.shift()).toString());
|
||||||
}
|
}
|
||||||
|
|
||||||
source = source.replace('{{VERSION}}', version);
|
source = source.replace('{{VERSION}}', version);
|
||||||
source = source.replace('{{REVISION}}', revision);
|
source = source.replace('{{REVISION}}', revision);
|
||||||
|
|
||||||
source = 'const char ' + name + '[] = R"""(\n' + source + ')""";\n';
|
if (is_windows) {
|
||||||
|
source = source.replace(/\\/g, '\\\\');
|
||||||
|
source = source.replace(/["]/g, '\\"');
|
||||||
|
source = '"' + source.split('\n').join('\\n"\n"') + '\\n"';
|
||||||
|
source = source.replace(/["] ["]/g, '');
|
||||||
|
source = source.replace(/["] [(] ([^)]*)[)] ["]/g, '// $1');
|
||||||
|
source = 'const char ' + name + '[] =\n' + source + ';\n';
|
||||||
|
} else {
|
||||||
|
source = 'const char ' + name + '[] = R"""(\n' + source + ')""";\n';
|
||||||
|
}
|
||||||
|
|
||||||
process.stdout.write(source);
|
process.stdout.write(source);
|
||||||
|
|||||||
@ -95,6 +95,8 @@
|
|||||||
# define USER_WORDS
|
# define USER_WORDS
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
static cell_t ResizeFile(cell_t fd, cell_t size);
|
||||||
|
|
||||||
#define PLATFORM_OPCODE_LIST \
|
#define PLATFORM_OPCODE_LIST \
|
||||||
FLOATING_POINT_LIST \
|
FLOATING_POINT_LIST \
|
||||||
REQUIRED_MEMORY_SUPPORT \
|
REQUIRED_MEMORY_SUPPORT \
|
||||||
@ -297,6 +299,9 @@
|
|||||||
# include "esp_intr_alloc.h"
|
# include "esp_intr_alloc.h"
|
||||||
# include "driver/timer.h"
|
# include "driver/timer.h"
|
||||||
# include "driver/gpio.h"
|
# include "driver/gpio.h"
|
||||||
|
static cell_t EspIntrAlloc(cell_t source, cell_t flags, cell_t xt, cell_t arg, void *ret);
|
||||||
|
static cell_t GpioIsrHandlerAdd(cell_t pin, cell_t xt, cell_t arg);
|
||||||
|
static cell_t TimerIsrRegister(cell_t group, cell_t timer, cell_t xt, cell_t arg, cell_t flags, void *ret);
|
||||||
# define OPTIONAL_INTERRUPTS_SUPPORT \
|
# define OPTIONAL_INTERRUPTS_SUPPORT \
|
||||||
Y(gpio_config, n0 = gpio_config((const gpio_config_t *) a0)) \
|
Y(gpio_config, n0 = gpio_config((const gpio_config_t *) a0)) \
|
||||||
Y(gpio_reset_pin, n0 = gpio_reset_pin((gpio_num_t) n0)) \
|
Y(gpio_reset_pin, n0 = gpio_reset_pin((gpio_num_t) n0)) \
|
||||||
@ -546,6 +551,7 @@ static cell_t FromIP(IPAddress ip) {
|
|||||||
# define OPTIONAL_WEBSERVER_SUPPORT
|
# define OPTIONAL_WEBSERVER_SUPPORT
|
||||||
#else
|
#else
|
||||||
# include <WebServer.h>
|
# include <WebServer.h>
|
||||||
|
static void InvokeWebServerOn(WebServer *ws, const char *url, cell_t xt);
|
||||||
# define ws0 ((WebServer *) a0)
|
# define ws0 ((WebServer *) a0)
|
||||||
# define OPTIONAL_WEBSERVER_SUPPORT \
|
# define OPTIONAL_WEBSERVER_SUPPORT \
|
||||||
/* WebServer */ \
|
/* WebServer */ \
|
||||||
@ -614,12 +620,6 @@ static char filename[PATH_MAX];
|
|||||||
static String string_value;
|
static String string_value;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef ENABLE_INTERRUPTS_SUPPORT
|
|
||||||
static cell_t EspIntrAlloc(cell_t source, cell_t flags, cell_t xt, cell_t arg, cell_t *ret);
|
|
||||||
static cell_t GpioIsrHandlerAdd(cell_t pin, cell_t xt, cell_t arg);
|
|
||||||
static cell_t TimerIsrRegister(cell_t group, cell_t timer, cell_t xt, cell_t arg, void *ret);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
{{core}}
|
{{core}}
|
||||||
{{interp}}
|
{{interp}}
|
||||||
{{boot}}
|
{{boot}}
|
||||||
|
|||||||
Reference in New Issue
Block a user