mirror of
https://github.com/platformio/platformio-core.git
synced 2025-07-31 10:37:13 +02:00
Rename "platformio" conflicted tool/module name to "piobuild"
This commit is contained in:
@ -55,7 +55,7 @@ DEFAULT_ENV_OPTIONS = dict(
|
|||||||
"link",
|
"link",
|
||||||
"piohooks",
|
"piohooks",
|
||||||
"pioasm",
|
"pioasm",
|
||||||
"platformio",
|
"piobuild",
|
||||||
"pioproject",
|
"pioproject",
|
||||||
"pioplatform",
|
"pioplatform",
|
||||||
"piotest",
|
"piotest",
|
||||||
|
@ -29,7 +29,7 @@ import os
|
|||||||
|
|
||||||
import SCons
|
import SCons
|
||||||
|
|
||||||
from platformio.builder.tools.platformio import SRC_ASM_EXT, SRC_C_EXT, SRC_CXX_EXT
|
from platformio.builder.tools.piobuild import SRC_ASM_EXT, SRC_C_EXT, SRC_CXX_EXT
|
||||||
from platformio.proc import where_is_program
|
from platformio.proc import where_is_program
|
||||||
|
|
||||||
# Implements the ability for SCons to emit a compilation database for the MongoDB project. See
|
# Implements the ability for SCons to emit a compilation database for the MongoDB project. See
|
||||||
|
@ -12,8 +12,6 @@
|
|||||||
# 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.
|
||||||
|
|
||||||
from __future__ import absolute_import
|
|
||||||
|
|
||||||
import fnmatch
|
import fnmatch
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
@ -27,7 +27,7 @@ from SCons.Script import ARGUMENTS # pylint: disable=import-error
|
|||||||
from SCons.Script import DefaultEnvironment # pylint: disable=import-error
|
from SCons.Script import DefaultEnvironment # pylint: disable=import-error
|
||||||
|
|
||||||
from platformio import exception, fs
|
from platformio import exception, fs
|
||||||
from platformio.builder.tools import platformio as piotool
|
from platformio.builder.tools import piobuild
|
||||||
from platformio.compat import IS_WINDOWS, hashlib_encode_data, string_types
|
from platformio.compat import IS_WINDOWS, hashlib_encode_data, string_types
|
||||||
from platformio.http import HTTPClientError, InternetIsOffline
|
from platformio.http import HTTPClientError, InternetIsOffline
|
||||||
from platformio.package.exception import (
|
from platformio.package.exception import (
|
||||||
@ -92,7 +92,7 @@ class LibBuilderFactory:
|
|||||||
return ["mbed"]
|
return ["mbed"]
|
||||||
for fname in files:
|
for fname in files:
|
||||||
if not fs.path_endswith_ext(
|
if not fs.path_endswith_ext(
|
||||||
fname, piotool.SRC_BUILD_EXT + piotool.SRC_HEADER_EXT
|
fname, piobuild.SRC_BUILD_EXT + piobuild.SRC_HEADER_EXT
|
||||||
):
|
):
|
||||||
continue
|
continue
|
||||||
with io.open(
|
with io.open(
|
||||||
@ -197,7 +197,7 @@ class LibBuilderBase:
|
|||||||
|
|
||||||
@property
|
@property
|
||||||
def src_filter(self):
|
def src_filter(self):
|
||||||
return piotool.SRC_FILTER_DEFAULT + [
|
return piobuild.SRC_FILTER_DEFAULT + [
|
||||||
"-<example%s>" % os.sep,
|
"-<example%s>" % os.sep,
|
||||||
"-<examples%s>" % os.sep,
|
"-<examples%s>" % os.sep,
|
||||||
"-<test%s>" % os.sep,
|
"-<test%s>" % os.sep,
|
||||||
@ -329,7 +329,7 @@ class LibBuilderBase:
|
|||||||
return [
|
return [
|
||||||
os.path.join(self.src_dir, item)
|
os.path.join(self.src_dir, item)
|
||||||
for item in self.env.MatchSourceFiles(
|
for item in self.env.MatchSourceFiles(
|
||||||
self.src_dir, self.src_filter, piotool.SRC_BUILD_EXT
|
self.src_dir, self.src_filter, piobuild.SRC_BUILD_EXT
|
||||||
)
|
)
|
||||||
]
|
]
|
||||||
|
|
||||||
@ -394,10 +394,10 @@ class LibBuilderBase:
|
|||||||
result.append(item)
|
result.append(item)
|
||||||
if not self.PARSE_SRC_BY_H_NAME:
|
if not self.PARSE_SRC_BY_H_NAME:
|
||||||
continue
|
continue
|
||||||
if not fs.path_endswith_ext(item_path, piotool.SRC_HEADER_EXT):
|
if not fs.path_endswith_ext(item_path, piobuild.SRC_HEADER_EXT):
|
||||||
continue
|
continue
|
||||||
item_fname = item_path[: item_path.rindex(".")]
|
item_fname = item_path[: item_path.rindex(".")]
|
||||||
for ext in piotool.SRC_C_EXT + piotool.SRC_CXX_EXT:
|
for ext in piobuild.SRC_C_EXT + piobuild.SRC_CXX_EXT:
|
||||||
if not os.path.isfile("%s.%s" % (item_fname, ext)):
|
if not os.path.isfile("%s.%s" % (item_fname, ext)):
|
||||||
continue
|
continue
|
||||||
item_c_node = self.env.File("%s.%s" % (item_fname, ext))
|
item_c_node = self.env.File("%s.%s" % (item_fname, ext))
|
||||||
@ -558,7 +558,7 @@ class ArduinoLibBuilder(LibBuilderBase):
|
|||||||
|
|
||||||
src_filter = []
|
src_filter = []
|
||||||
is_utility = os.path.isdir(os.path.join(self.path, "utility"))
|
is_utility = os.path.isdir(os.path.join(self.path, "utility"))
|
||||||
for ext in piotool.SRC_BUILD_EXT + piotool.SRC_HEADER_EXT:
|
for ext in piobuild.SRC_BUILD_EXT + piobuild.SRC_HEADER_EXT:
|
||||||
# arduino ide ignores files with .asm or .ASM extensions
|
# arduino ide ignores files with .asm or .ASM extensions
|
||||||
if ext.lower() == "asm":
|
if ext.lower() == "asm":
|
||||||
continue
|
continue
|
||||||
|
@ -14,7 +14,7 @@
|
|||||||
|
|
||||||
import os
|
import os
|
||||||
|
|
||||||
from platformio.builder.tools import platformio as piotool
|
from platformio.builder.tools import piobuild
|
||||||
from platformio.test.result import TestSuite
|
from platformio.test.result import TestSuite
|
||||||
from platformio.test.runners.factory import TestRunnerFactory
|
from platformio.test.runners.factory import TestRunnerFactory
|
||||||
|
|
||||||
@ -22,7 +22,7 @@ from platformio.test.runners.factory import TestRunnerFactory
|
|||||||
def ConfigureTestTarget(env):
|
def ConfigureTestTarget(env):
|
||||||
env.Append(
|
env.Append(
|
||||||
CPPDEFINES=["UNIT_TEST"], # deprecated, use PIO_UNIT_TESTING
|
CPPDEFINES=["UNIT_TEST"], # deprecated, use PIO_UNIT_TESTING
|
||||||
PIOTEST_SRC_FILTER=[f"+<*.{ext}>" for ext in piotool.SRC_BUILD_EXT],
|
PIOTEST_SRC_FILTER=[f"+<*.{ext}>" for ext in piobuild.SRC_BUILD_EXT],
|
||||||
)
|
)
|
||||||
env.Prepend(CPPPATH=["$PROJECT_TEST_DIR"])
|
env.Prepend(CPPPATH=["$PROJECT_TEST_DIR"])
|
||||||
|
|
||||||
@ -36,7 +36,7 @@ def ConfigureTestTarget(env):
|
|||||||
env.Prepend(
|
env.Prepend(
|
||||||
PIOTEST_SRC_FILTER=[
|
PIOTEST_SRC_FILTER=[
|
||||||
f"+<{test_name}{os.path.sep}*.{ext}>"
|
f"+<{test_name}{os.path.sep}*.{ext}>"
|
||||||
for ext in piotool.SRC_BUILD_EXT
|
for ext in piobuild.SRC_BUILD_EXT
|
||||||
],
|
],
|
||||||
CPPPATH=[os.path.join("$PROJECT_TEST_DIR", test_name)],
|
CPPPATH=[os.path.join("$PROJECT_TEST_DIR", test_name)],
|
||||||
)
|
)
|
||||||
|
Reference in New Issue
Block a user