莱姆无法建立html5目标,导致各种类型和导入错误的结果不符 [英] lime cannot build the html5 target, compliling results in various type and import errors

查看:72
本文介绍了莱姆无法建立html5目标,导致各种类型和导入错误的结果不符的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在恢复我的一个较旧的haxeflixel项目,并且无法使用石灰对其进行编译.

I am reviving an older haxeflixel project of mine and have been unable to get it to compile using lime.

为了确保我的代码没有问题,我使用 flixel tpl -n"HelloWorld" 创建了一个新的"hello world"项目.

To make sure it wasn't an issue with my code I created a new "hello world" project with flixel tpl -n "HelloWorld".

我确保已安装最新版本的haxe,并运行 haxelib更新以及 haxelib运行石灰安装程序

I made sure the most recent version of haxe was installed, ran haxelib update as well as haxelib run lime setup

我正在使用Windows10.

I'm using Windows 10.

所有软件包都说它们是最新的.堆栈溢出不会让我输入整个错误日志,它超过60,000个字符!我已经发布了代表性示例.

All packages say they are up to date. Stack Overflow will not let me enter the entire error log, it's over 60,000 characters! I've posted a representative sample.

C:/HaxeToolkit/haxe/lib/lime/7,7,0/src/lime/_internal/graphics/ImageDataUtil.hx:955: characters 32-67 : Class<lime._internal.backend.native.NativeCFFI> has no field lime_image_data_util_multiply_alpha
C:/HaxeToolkit/haxe/lib/lime/7,7,0/src/lime/_internal/graphics/ImageDataUtil.hx:1405: characters 32-69 : Class<lime._internal.backend.native.NativeCFFI> has no field lime_image_data_util_unmultiply_alpha
C:/HaxeToolkit/haxe/lib/lime/7,7,0/src/lime/_internal/graphics/ImageDataUtil.hx:1106: characters 32-63 : Class<lime._internal.backend.native.NativeCFFI> has no field lime_image_data_util_set_format
C:/HaxeToolkit/haxe/lib/lime/7,7,0/src/lime/graphics/cairo/Cairo.hx:747: characters 14-38 : Class<lime._internal.backend.native.NativeCFFI> has no field lime_cairo_set_tolerance
C:/HaxeToolkit/haxe/lib/lime/7,7,0/src/lime/graphics/cairo/Cairo.hx:738: characters 21-45 : Class<lime._internal.backend.native.NativeCFFI> has no field lime_cairo_get_tolerance
C:/HaxeToolkit/haxe/lib/lime/7,7,0/src/lime/graphics/cairo/Cairo.hx:729: characters 21-42 : Class<lime._internal.backend.native.NativeCFFI> has no field lime_cairo_get_target
C:/HaxeToolkit/haxe/lib/lime/7,7,0/src/lime/graphics/cairo/Cairo.hx:720: characters 14-35 : Class<lime._internal.backend.native.NativeCFFI> has no field lime_cairo_set_source
C:/HaxeToolkit/haxe/lib/lime/7,7,0/src/lime/graphics/cairo/Cairo.hx:711: characters 21-42 : Class<lime._internal.backend.native.NativeCFFI> has no field lime_cairo_get_source

etc. etc.

C:/HaxeToolkit/haxe/lib/openfl/8,9,6/src/openfl/_internal/renderer/cairo/CairoTextField.hx:246: characters 21-28 : Float has no field advance
C:/HaxeToolkit/haxe/lib/openfl/8,9,6/src/openfl/_internal/renderer/cairo/CairoTextField.hx:327: characters 63-78 : Float should be Int
C:/HaxeToolkit/haxe/lib/openfl/8,9,6/src/openfl/_internal/renderer/cairo/CairoTextField.hx:327: characters 63-78 : For function argument ''
C:/HaxeToolkit/haxe/lib/lime/7,7,0/src/lime/ui/Gamepad.hx:41: characters 14-39 : Class<lime._internal.backend.native.NativeCFFI> has no field lime_gamepad_add_mappings
C:/HaxeToolkit/haxe/lib/lime/7,7,0/src/lime/utils/Bytes.hx:133: characters 21-49 : Class<lime._internal.backend.native.NativeCFFI> has no field lime_bytes_from_data_pointer

任何帮助将不胜感激.

推荐答案

检查环境变量(您可以在终端中键入 set 来查看所有环境变量).如果定义了 hl ,Lime认为存在一个问题,即Lime认为它是为本机编译的,即使像HTML5上通常不使用任何业务,也会导致像 NativeCFFI 这样的类被包含在内.

Check your environment variables (you can just type set into a terminal to see all of them). There is an issue where Lime thinks it's compiling for native if hl is defined, resulting in classes like NativeCFFI being included, even though they normally have no business being used on HTML5.

如果未定义 hl ,则可能仍然存在另一个触发相同问题的环境变量.

If you don't have hl defined, there may still be another environment variable that triggers the same problem.

这篇关于莱姆无法建立html5目标,导致各种类型和导入错误的结果不符的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆