Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
BaiXuePrincess
rt-thread
提交
e1a01253
R
rt-thread
项目概览
BaiXuePrincess
/
rt-thread
与 Fork 源项目一致
Fork自
RT-Thread / rt-thread
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
rt-thread
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
e1a01253
编写于
11月 01, 2019
作者:
B
Bernard Xiong
提交者:
GitHub
11月 01, 2019
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #3168 from armink/fix_eclipse
Fix eclipse
上级
75ae3435
e32c7c98
变更
15
展开全部
显示空白变更内容
内联
并排
Showing
15 changed file
with
381 addition
and
117 deletion
+381
-117
bsp/stm32/stm32f103-dofly-M3S/.cproject
bsp/stm32/stm32f103-dofly-M3S/.cproject
+0
-1
bsp/stm32/stm32f103-yf-ufun/.cproject
bsp/stm32/stm32f103-yf-ufun/.cproject
+0
-1
bsp/stm32/stm32f401-st-nucleo/.cproject
bsp/stm32/stm32f401-st-nucleo/.cproject
+0
-1
bsp/stm32/stm32f405-smdz-breadfruit/.cproject
bsp/stm32/stm32f405-smdz-breadfruit/.cproject
+155
-0
bsp/stm32/stm32f405-smdz-breadfruit/.project
bsp/stm32/stm32f405-smdz-breadfruit/.project
+69
-0
bsp/stm32/stm32f405-smdz-breadfruit/.settings/language.settings.xml
...stm32f405-smdz-breadfruit/.settings/language.settings.xml
+14
-0
bsp/stm32/stm32f405-smdz-breadfruit/.settings/org.eclipse.core.runtime.prefs
...-smdz-breadfruit/.settings/org.eclipse.core.runtime.prefs
+3
-0
bsp/stm32/stm32f405-smdz-breadfruit/makefile.targets
bsp/stm32/stm32f405-smdz-breadfruit/makefile.targets
+4
-0
bsp/stm32/stm32f407-atk-explorer/.cproject
bsp/stm32/stm32f407-atk-explorer/.cproject
+0
-1
bsp/stm32/stm32f411-st-nucleo/.cproject
bsp/stm32/stm32f411-st-nucleo/.cproject
+0
-1
bsp/stm32/stm32f429-atk-apollo/.cproject
bsp/stm32/stm32f429-atk-apollo/.cproject
+0
-1
bsp/stm32/stm32f429-fire-challenger/.cproject
bsp/stm32/stm32f429-fire-challenger/.cproject
+0
-1
bsp/stm32/stm32f767-atk-apollo/.cproject
bsp/stm32/stm32f767-atk-apollo/.cproject
+0
-1
bsp/stm32/stm32l475-atk-pandora/.cproject
bsp/stm32/stm32l475-atk-pandora/.cproject
+0
-1
tools/eclipse.py
tools/eclipse.py
+136
-108
未找到文件。
bsp/stm32/stm32f103-dofly-M3S/.cproject
浏览文件 @
e1a01253
...
...
@@ -79,7 +79,6 @@
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.100549972"
name=
"Defined symbols (-D)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs"
useByScannerDiscovery=
"true"
valueType=
"definedSymbols"
>
<listOptionValue
builtIn=
"false"
value=
"DEBUG"
/>
<listOptionValue
builtIn=
"false"
value=
"_REENT_SMALL"
/>
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other.2133065240"
name=
"Other compiler flags"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other"
useByScannerDiscovery=
"true"
value=
""
valueType=
"string"
/>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files.714348818"
name=
"Include files (-include)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files"
useByScannerDiscovery=
"true"
valueType=
"includeFiles"
>
...
...
bsp/stm32/stm32f103-yf-ufun/.cproject
浏览文件 @
e1a01253
...
...
@@ -78,7 +78,6 @@
</option>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.100549972"
name=
"Defined symbols (-D)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs"
useByScannerDiscovery=
"true"
valueType=
"definedSymbols"
>
<listOptionValue
builtIn=
"false"
value=
"DEBUG"
/>
<listOptionValue
builtIn=
"false"
value=
"_REENT_SMALL"
/>
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other.2133065240"
name=
"Other compiler flags"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other"
useByScannerDiscovery=
"true"
value=
""
valueType=
"string"
/>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files.714348818"
name=
"Include files (-include)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files"
useByScannerDiscovery=
"true"
valueType=
"includeFiles"
>
...
...
bsp/stm32/stm32f401-st-nucleo/.cproject
浏览文件 @
e1a01253
...
...
@@ -80,7 +80,6 @@
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.100549972"
name=
"Defined symbols (-D)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs"
useByScannerDiscovery=
"true"
valueType=
"definedSymbols"
>
<listOptionValue
builtIn=
"false"
value=
"DEBUG"
/>
<listOptionValue
builtIn=
"false"
value=
"_REENT_SMALL"
/>
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other.2133065240"
name=
"Other compiler flags"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other"
useByScannerDiscovery=
"true"
value=
""
valueType=
"string"
/>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files.714348818"
name=
"Include files (-include)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files"
useByScannerDiscovery=
"true"
valueType=
"includeFiles"
>
...
...
bsp/stm32/stm32f405-smdz-breadfruit/.cproject
0 → 100644
浏览文件 @
e1a01253
此差异已折叠。
点击以展开。
bsp/stm32/stm32f405-smdz-breadfruit/.project
0 → 100644
浏览文件 @
e1a01253
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>
stm32f405-smdz-breadfruit
</name>
<comment
/>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>
org.eclipse.cdt.managedbuilder.core.genmakebuilder
</name>
<triggers>
clean,full,incremental,
</triggers>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>
org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder
</name>
<triggers>
full,incremental,
</triggers>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>
org.eclipse.cdt.core.cnature
</nature>
<nature>
org.rt-thread.studio.rttnature
</nature>
<nature>
org.eclipse.cdt.managedbuilder.core.managedBuildNature
</nature>
<nature>
org.eclipse.cdt.managedbuilder.core.ScannerConfigNature
</nature>
</natures>
<linkedResources>
<link>
<name>
rt-thread
</name>
<type>
2
</type>
<locationURI>
virtual:/virtual
</locationURI>
</link>
<link>
<name>
rt-thread/bsp
</name>
<type>
2
</type>
<locationURI>
virtual:/virtual
</locationURI>
</link>
<link>
<name>
rt-thread/components
</name>
<type>
2
</type>
<locationURI>
$%7BPARENT-3-PROJECT_LOC%7D/components
</locationURI>
</link>
<link>
<name>
rt-thread/include
</name>
<type>
2
</type>
<locationURI>
$%7BPARENT-3-PROJECT_LOC%7D/include
</locationURI>
</link>
<link>
<name>
rt-thread/libcpu
</name>
<type>
2
</type>
<locationURI>
$%7BPARENT-3-PROJECT_LOC%7D/libcpu
</locationURI>
</link>
<link>
<name>
rt-thread/src
</name>
<type>
2
</type>
<locationURI>
$%7BPARENT-3-PROJECT_LOC%7D/src
</locationURI>
</link>
<link>
<name>
rt-thread/bsp/stm32
</name>
<type>
2
</type>
<locationURI>
virtual:/virtual
</locationURI>
</link>
<link>
<name>
rt-thread/bsp/stm32/libraries
</name>
<type>
2
</type>
<locationURI>
$%7BPARENT-1-PROJECT_LOC%7D/libraries
</locationURI>
</link>
</linkedResources>
</projectDescription>
bsp/stm32/stm32f405-smdz-breadfruit/.settings/language.settings.xml
0 → 100644
浏览文件 @
e1a01253
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project>
<configuration
id=
"ilg.gnuarmeclipse.managedbuild.cross.config.elf.debug.553091094"
name=
"Debug"
>
<extension
point=
"org.eclipse.cdt.core.LanguageSettingsProvider"
>
<provider
copy-of=
"extension"
id=
"org.eclipse.cdt.ui.UserLanguageSettingsProvider"
/>
<provider-reference
id=
"org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider"
ref=
"shared-provider"
/>
<provider-reference
id=
"org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider"
ref=
"shared-provider"
/>
<provider
class=
"org.eclipse.cdt.managedbuilder.language.settings.providers.GCCBuiltinSpecsDetector"
console=
"false"
env-hash=
"-1576159572023439102"
id=
"ilg.gnuarmeclipse.managedbuild.cross.GCCBuiltinSpecsDetector"
keep-relative-paths=
"false"
name=
"CDT ARM Cross GCC Built-in Compiler Settings "
parameter=
"${COMMAND} ${FLAGS} ${cross_toolchain_flags} -E -P -v -dD "${INPUTS}""
prefer-non-shared=
"true"
>
<language-scope
id=
"org.eclipse.cdt.core.gcc"
/>
<language-scope
id=
"org.eclipse.cdt.core.g++"
/>
</provider>
</extension>
</configuration>
</project>
bsp/stm32/stm32f405-smdz-breadfruit/.settings/org.eclipse.core.runtime.prefs
0 → 100644
浏览文件 @
e1a01253
content-types/enabled=true
content-types/org.eclipse.cdt.core.asmSource/file-extensions=s
eclipse.preferences.version=1
bsp/stm32/stm32f405-smdz-breadfruit/makefile.targets
0 → 100644
浏览文件 @
e1a01253
clean2
:
-
$(RM)
$(CC_DEPS)
$
(
C++_DEPS
)
$(C_UPPER_DEPS)$(CXX_DEPS)$(SECONDARY_FLASH)$(SECONDARY_SIZE)$(ASM_DEPS)$(S_UPPER_DEPS)$(C_DEPS)$(CPP_DEPS)
-
$(RM)
$(OBJS)
*
.elf
-
@echo
' '
\ No newline at end of file
bsp/stm32/stm32f407-atk-explorer/.cproject
浏览文件 @
e1a01253
...
...
@@ -81,7 +81,6 @@
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.100549972"
name=
"Defined symbols (-D)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs"
useByScannerDiscovery=
"true"
valueType=
"definedSymbols"
>
<listOptionValue
builtIn=
"false"
value=
"DEBUG"
/>
<listOptionValue
builtIn=
"false"
value=
"_REENT_SMALL"
/>
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other.2133065240"
name=
"Other compiler flags"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other"
useByScannerDiscovery=
"true"
value=
""
valueType=
"string"
/>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files.714348818"
name=
"Include files (-include)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files"
useByScannerDiscovery=
"true"
valueType=
"includeFiles"
>
...
...
bsp/stm32/stm32f411-st-nucleo/.cproject
浏览文件 @
e1a01253
...
...
@@ -80,7 +80,6 @@
</option>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.100549972"
name=
"Defined symbols (-D)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs"
useByScannerDiscovery=
"true"
valueType=
"definedSymbols"
>
<listOptionValue
builtIn=
"false"
value=
"DEBUG"
/>
<listOptionValue
builtIn=
"false"
value=
"_REENT_SMALL"
/>
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other.2133065240"
name=
"Other compiler flags"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other"
useByScannerDiscovery=
"true"
value=
""
valueType=
"string"
/>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files.714348818"
name=
"Include files (-include)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files"
useByScannerDiscovery=
"true"
valueType=
"includeFiles"
>
...
...
bsp/stm32/stm32f429-atk-apollo/.cproject
浏览文件 @
e1a01253
...
...
@@ -81,7 +81,6 @@
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.100549972"
name=
"Defined symbols (-D)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs"
useByScannerDiscovery=
"true"
valueType=
"definedSymbols"
>
<listOptionValue
builtIn=
"false"
value=
"DEBUG"
/>
<listOptionValue
builtIn=
"false"
value=
"_REENT_SMALL"
/>
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other.2133065240"
name=
"Other compiler flags"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other"
useByScannerDiscovery=
"true"
value=
""
valueType=
"string"
/>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files.714348818"
name=
"Include files (-include)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files"
useByScannerDiscovery=
"true"
valueType=
"includeFiles"
>
...
...
bsp/stm32/stm32f429-fire-challenger/.cproject
浏览文件 @
e1a01253
...
...
@@ -81,7 +81,6 @@
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.100549972"
name=
"Defined symbols (-D)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs"
useByScannerDiscovery=
"true"
valueType=
"definedSymbols"
>
<listOptionValue
builtIn=
"false"
value=
"DEBUG"
/>
<listOptionValue
builtIn=
"false"
value=
"_REENT_SMALL"
/>
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other.2133065240"
name=
"Other compiler flags"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other"
useByScannerDiscovery=
"true"
value=
""
valueType=
"string"
/>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files.714348818"
name=
"Include files (-include)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files"
useByScannerDiscovery=
"true"
valueType=
"includeFiles"
>
...
...
bsp/stm32/stm32f767-atk-apollo/.cproject
浏览文件 @
e1a01253
...
...
@@ -81,7 +81,6 @@
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.100549972"
name=
"Defined symbols (-D)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs"
useByScannerDiscovery=
"true"
valueType=
"definedSymbols"
>
<listOptionValue
builtIn=
"false"
value=
"DEBUG"
/>
<listOptionValue
builtIn=
"false"
value=
"_REENT_SMALL"
/>
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other.2133065240"
name=
"Other compiler flags"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other"
useByScannerDiscovery=
"true"
value=
""
valueType=
"string"
/>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files.714348818"
name=
"Include files (-include)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files"
useByScannerDiscovery=
"true"
valueType=
"includeFiles"
>
...
...
bsp/stm32/stm32l475-atk-pandora/.cproject
浏览文件 @
e1a01253
...
...
@@ -80,7 +80,6 @@
</option>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.100549972"
name=
"Defined symbols (-D)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs"
useByScannerDiscovery=
"true"
valueType=
"definedSymbols"
>
<listOptionValue
builtIn=
"false"
value=
"DEBUG"
/>
<listOptionValue
builtIn=
"false"
value=
"_REENT_SMALL"
/>
</option>
<option
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other.2133065240"
name=
"Other compiler flags"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.other"
useByScannerDiscovery=
"true"
value=
""
valueType=
"string"
/>
<option
IS_BUILTIN_EMPTY=
"false"
IS_VALUE_EMPTY=
"false"
id=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files.714348818"
name=
"Include files (-include)"
superClass=
"ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.files"
useByScannerDiscovery=
"true"
valueType=
"includeFiles"
>
...
...
tools/eclipse.py
浏览文件 @
e1a01253
...
...
@@ -142,23 +142,49 @@ def HandleToolOption(tools, env, project, reset):
CPPDEFINES
=
project
[
'CPPDEFINES'
]
paths
=
[
ConverToRttEclipsePathFormat
(
RelativeProjectPath
(
env
,
os
.
path
.
normpath
(
i
)).
replace
(
'
\\
'
,
'/'
))
for
i
in
project
[
'CPPPATH'
]]
compile_include_paths_option
=
None
compile_include_files_option
=
None
compile_defs_option
=
None
linker_scriptfile_option
=
None
linker_script_option
=
None
linker_nostart_option
=
None
linker_libs_option
=
None
linker_paths_option
=
None
linker_newlib_nano_option
=
None
for
tool
in
tools
:
if
tool
.
get
(
'id'
).
find
(
'c.compile'
)
!=
1
:
options
=
tool
.
findall
(
'option'
)
include_paths_option
=
None
include_files_option
=
None
defs_option
=
None
# find all compile options
for
option
in
options
:
if
option
.
get
(
'id'
).
find
(
'c.compiler.include.paths'
)
!=
-
1
or
option
.
get
(
'id'
).
find
(
'c.compiler.option.includepaths'
)
!=
-
1
:
include_paths_option
=
option
compile_
include_paths_option
=
option
elif
option
.
get
(
'id'
).
find
(
'c.compiler.include.files'
)
!=
-
1
or
option
.
get
(
'id'
).
find
(
'c.compiler.option.includefiles'
)
!=
-
1
:
include_files_option
=
option
compile_
include_files_option
=
option
elif
option
.
get
(
'id'
).
find
(
'c.compiler.defs'
)
!=
-
1
or
option
.
get
(
'id'
).
find
(
'c.compiler.option.definedsymbols'
)
!=
-
1
:
defs_option
=
option
compile_defs_option
=
option
if
tool
.
get
(
'id'
).
find
(
'c.linker'
)
!=
-
1
:
options
=
tool
.
findall
(
'option'
)
# find all linker options
for
option
in
options
:
if
option
.
get
(
'id'
).
find
(
'c.linker.scriptfile'
)
!=
-
1
:
linker_scriptfile_option
=
option
elif
option
.
get
(
'id'
).
find
(
'c.linker.option.script'
)
!=
-
1
:
linker_script_option
=
option
elif
option
.
get
(
'id'
).
find
(
'c.linker.nostart'
)
!=
-
1
:
linker_nostart_option
=
option
elif
option
.
get
(
'id'
).
find
(
'c.linker.libs'
)
!=
-
1
and
env
.
has_key
(
'LIBS'
):
linker_libs_option
=
option
elif
option
.
get
(
'id'
).
find
(
'c.linker.paths'
)
!=
-
1
and
env
.
has_key
(
'LIBPATH'
):
linker_paths_option
=
option
elif
option
.
get
(
'id'
).
find
(
'c.linker.usenewlibnano'
)
!=
-
1
:
linker_newlib_nano_option
=
option
# change the inclue path
if
include_paths_option
is
not
None
:
option
=
include_paths_option
if
compile_
include_paths_option
is
not
None
:
option
=
compile_
include_paths_option
# find all of paths in this project
include_paths
=
option
.
findall
(
'listOptionValue'
)
for
item
in
include_paths
:
...
...
@@ -170,8 +196,12 @@ def HandleToolOption(tools, env, project, reset):
for
item
in
paths
:
SubElement
(
option
,
'listOptionValue'
,
{
'builtIn'
:
'false'
,
'value'
:
item
})
# change the inclue files (default) or definitions
if
include_files_option
is
not
None
:
option
=
include_files_option
if
compile_include_files_option
is
not
None
:
option
=
compile_include_files_option
# add '_REENT_SMALL' to CPPDEFINES when --specs=nano.specs has select
if
linker_newlib_nano_option
is
not
None
and
linker_newlib_nano_option
.
get
(
'value'
)
==
'true'
and
'_REENT_SMALL'
not
in
CPPDEFINES
:
CPPDEFINES
+=
[
'_REENT_SMALL'
]
file_header
=
'''
#ifndef RTCONFIG_PREINC_H__
#define RTCONFIG_PREINC_H__
...
...
@@ -197,8 +227,8 @@ def HandleToolOption(tools, env, project, reset):
break
if
find_ok
is
False
:
SubElement
(
option
,
'listOptionValue'
,
{
'builtIn'
:
'false'
,
'value'
:
rtt_pre_inc_item
})
elif
defs_option
is
not
None
:
option
=
defs_option
elif
compile_
defs_option
is
not
None
:
option
=
compile_
defs_option
defs
=
option
.
findall
(
'listOptionValue'
)
project_defs
=
[]
for
item
in
defs
:
...
...
@@ -217,11 +247,9 @@ def HandleToolOption(tools, env, project, reset):
for
item
in
cproject_defs
:
SubElement
(
option
,
'listOptionValue'
,
{
'builtIn'
:
'false'
,
'value'
:
item
})
if
tool
.
get
(
'id'
).
find
(
'c.linker'
)
!=
-
1
:
options
=
tool
.
findall
(
'option'
)
for
option
in
options
:
# update linker script config
if
option
.
get
(
'id'
).
find
(
'c.linker.scriptfile'
)
!=
-
1
:
if
linker_scriptfile_option
is
not
None
:
option
=
linker_scriptfile_option
linker_script
=
'link.lds'
items
=
env
[
'LINKFLAGS'
].
split
(
' '
)
if
'-T'
in
items
:
...
...
@@ -233,32 +261,32 @@ def HandleToolOption(tools, env, project, reset):
listOptionValue
.
set
(
'value'
,
linker_script
)
else
:
SubElement
(
option
,
'listOptionValue'
,
{
'builtIn'
:
'false'
,
'value'
:
linker_script
})
# scriptfile in stm32cubeIDE
if
option
.
get
(
'id'
).
find
(
'c.linker.option.script'
)
!=
-
1
:
if
linker_script_option
is
not
None
:
option
=
linker_script_option
items
=
env
[
'LINKFLAGS'
].
split
(
' '
)
if
'-T'
in
items
:
linker_script
=
ConverToRttEclipsePathFormat
(
items
[
items
.
index
(
'-T'
)
+
1
]).
strip
(
'"'
)
option
.
set
(
'value'
,
linker_script
)
option
.
set
(
'value'
,
linker_script
)
# update nostartfiles config
if
option
.
get
(
'id'
).
find
(
'c.linker.nostart'
)
!=
-
1
:
if
linker_nostart_option
is
not
None
:
option
=
linker_nostart_option
if
env
[
'LINKFLAGS'
].
find
(
'-nostartfiles'
)
!=
-
1
:
option
.
set
(
'value'
,
'true'
)
else
:
option
.
set
(
'value'
,
'false'
)
# update libs
if
option
.
get
(
'id'
).
find
(
'c.linker.libs'
)
!=
-
1
and
env
.
has_key
(
'LIBS'
):
if
linker_libs_option
is
not
None
:
option
=
linker_libs_option
# remove old libs
for
item
in
option
.
findall
(
'listOptionValue'
):
option
.
remove
(
item
)
# add new libs
for
lib
in
env
[
'LIBS'
]:
SubElement
(
option
,
'listOptionValue'
,
{
'builtIn'
:
'false'
,
'value'
:
lib
})
# update lib paths
if
option
.
get
(
'id'
).
find
(
'c.linker.paths'
)
!=
-
1
and
env
.
has_key
(
'LIBPATH'
):
if
linker_paths_option
is
not
None
:
option
=
linker_paths_option
# remove old lib paths
for
item
in
option
.
findall
(
'listOptionValue'
):
option
.
remove
(
item
)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录