rebranding 'code' targets as 'meta'

This commit is contained in:
Eric Froemling 2021-06-09 13:43:05 -05:00
parent 2b6d627b6a
commit 634ae77b7e
No known key found for this signature in database
GPG Key ID: 89C93F0F8D6D5A98
10 changed files with 33 additions and 32 deletions

View File

@ -186,6 +186,7 @@
<w>basn</w> <w>basn</w>
<w>bastd</w> <w>bastd</w>
<w>batools</w> <w>batools</w>
<w>batoolsinternal</w>
<w>bbbb</w> <w>bbbb</w>
<w>bblk</w> <w>bblk</w>
<w>bblu</w> <w>bblu</w>

View File

@ -1,3 +1,3 @@
<component name="DependencyValidationManager"> <component name="DependencyValidationManager">
<scope name="UncheckedPython" pattern="file:assets/src/ba_data/python/_ba.py||file:src/generated_src/ballistica/binding.py||file:src/generated_src/ballistica/vis_cleanup.py" /> <scope name="UncheckedPython" pattern="file:assets/src/ba_data/python/_ba.py||file:src/meta/ballistica/binding.py" />
</component> </component>

View File

@ -50,35 +50,35 @@ prereqs-clean:
@rm -rf ${PREREQS} @rm -rf ${PREREQS}
# Build all assets for all platforms. # Build all assets for all platforms.
assets: prereqs assets: prereqs meta
cd assets && $(MAKE) -j$(CPUS) cd assets && $(MAKE) -j$(CPUS)
# Build assets required for cmake builds (linux, mac) # Build assets required for cmake builds (linux, mac)
assets-cmake: prereqs assets-cmake: prereqs meta
cd assets && $(MAKE) -j$(CPUS) cmake cd assets && $(MAKE) -j$(CPUS) cmake
# Build assets required for WINDOWS_PLATFORM windows builds. # Build assets required for WINDOWS_PLATFORM windows builds.
assets-windows: prereqs assets-windows: prereqs meta
cd assets && $(MAKE) -j$(CPUS) win-${WINDOWS_PLATFORM} cd assets && $(MAKE) -j$(CPUS) win-${WINDOWS_PLATFORM}
# Build assets required for Win32 windows builds. # Build assets required for Win32 windows builds.
assets-windows-Win32: prereqs assets-windows-Win32: prereqs meta
cd assets && $(MAKE) -j$(CPUS) win-Win32 cd assets && $(MAKE) -j$(CPUS) win-Win32
# Build assets required for x64 windows builds. # Build assets required for x64 windows builds.
assets-windows-x64: prereqs assets-windows-x64: prereqs meta
cd assets && $(MAKE) -j$(CPUS) win-x64 cd assets && $(MAKE) -j$(CPUS) win-x64
# Build assets required for mac xcode builds # Build assets required for mac xcode builds
assets-mac: prereqs assets-mac: prereqs meta
cd assets && $(MAKE) -j$(CPUS) mac cd assets && $(MAKE) -j$(CPUS) mac
# Build assets required for ios. # Build assets required for ios.
assets-ios: prereqs assets-ios: prereqs meta
cd assets && $(MAKE) -j$(CPUS) ios cd assets && $(MAKE) -j$(CPUS) ios
# Build assets required for android. # Build assets required for android.
assets-android: prereqs assets-android: prereqs meta
cd assets && $(MAKE) -j$(CPUS) android cd assets && $(MAKE) -j$(CPUS) android
# Clean all assets. # Clean all assets.
@ -86,7 +86,7 @@ assets-clean:
cd assets && $(MAKE) clean cd assets && $(MAKE) clean
# Build resources. # Build resources.
resources: prereqs resources: prereqs meta
tools/pcommand lazybuild resources_src ${LAZYBUILDDIR}/resources \ tools/pcommand lazybuild resources_src ${LAZYBUILDDIR}/resources \
cd resources \&\& $(MAKE) -j$(CPUS) resources cd resources \&\& $(MAKE) -j$(CPUS) resources
@ -96,17 +96,16 @@ resources-clean:
rm -f ${LAZYBUILDDIR}/resources rm -f ${LAZYBUILDDIR}/resources
# Build our generated sources. # Build our generated sources.
# TODO: should perhaps make this a more standard component, including it # Meta builds can affect sources used by asset builds, resource builds, and
# in other standard targets such as checks and tests (at least once we're # compiles, so it should be listed as a dependency of any of those.
# generating things that can affect the outcome of said checks/tests). meta: prereqs
code: prereqs tools/pcommand lazybuild meta_src ${LAZYBUILDDIR}/meta \
tools/pcommand lazybuild code_gen_src ${LAZYBUILDDIR}/code \ cd src/meta \&\& $(MAKE) -j$(CPUS)
cd src/generated_src \&\& $(MAKE) -j$(CPUS) generated_code
# Clean our generated sources. # Clean our generated sources.
code-clean: meta-clean:
cd src/generated_src && $(MAKE) clean cd src/meta && $(MAKE) clean
rm -f ${LAZYBUILDDIR}/code rm -f ${LAZYBUILDDIR}/meta
# Remove ALL files and directories that aren't managed by git # Remove ALL files and directories that aren't managed by git
# (except for a few things such as localconfig.json). # (except for a few things such as localconfig.json).
@ -123,7 +122,7 @@ clean-list:
.PHONY: help prereqs prereqs-clean assets assets-cmake assets-windows \ .PHONY: help prereqs prereqs-clean assets assets-cmake assets-windows \
assets-windows-Win32 assets-windows-x64 \ assets-windows-Win32 assets-windows-x64 \
assets-mac assets-ios assets-android assets-clean \ assets-mac assets-ios assets-android assets-clean \
resources resources-clean code code-clean \ resources resources-clean meta meta-clean \
clean clean-list clean clean-list
@ -767,7 +766,7 @@ WINDOWS_PLATFORM ?= Win32
WINDOWS_CONFIGURATION ?= Debug WINDOWS_CONFIGURATION ?= Debug
# Stage assets and other files so a built binary will run. # Stage assets and other files so a built binary will run.
windows-staging: assets-windows resources code windows-staging: assets-windows resources meta
${STAGE_ASSETS} -win-${WINPLT}-${WINCFG} \ ${STAGE_ASSETS} -win-${WINPLT}-${WINCFG} \
build/windows/$(WINCFG)_$(WINPLT) build/windows/$(WINCFG)_$(WINPLT)
@ -857,7 +856,7 @@ cmake: cmake-build
@cd build/cmake/$(CM_BT_LC) && ./ballisticacore @cd build/cmake/$(CM_BT_LC) && ./ballisticacore
# Build but don't run it. # Build but don't run it.
cmake-build: assets-cmake resources code cmake-build: assets-cmake resources meta
@tools/pcommand cmake_prep_dir build/cmake/$(CM_BT_LC) @tools/pcommand cmake_prep_dir build/cmake/$(CM_BT_LC)
@tools/pcommand update_cmake_prefab_lib standard ${CM_BT_LC} build/cmake/${CM_BT_LC} @tools/pcommand update_cmake_prefab_lib standard ${CM_BT_LC} build/cmake/${CM_BT_LC}
@${STAGE_ASSETS} -cmake build/cmake/$(CM_BT_LC) @${STAGE_ASSETS} -cmake build/cmake/$(CM_BT_LC)
@ -872,7 +871,7 @@ cmake-clean:
cmake-server: cmake-server-build cmake-server: cmake-server-build
@cd build/cmake/server-$(CM_BT_LC) && ./ballisticacore_server @cd build/cmake/server-$(CM_BT_LC) && ./ballisticacore_server
cmake-server-build: assets-cmake resources code cmake-server-build: assets-cmake resources meta
@tools/pcommand cmake_prep_dir build/cmake/server-$(CM_BT_LC)/dist @tools/pcommand cmake_prep_dir build/cmake/server-$(CM_BT_LC)/dist
@tools/pcommand update_cmake_prefab_lib server ${CM_BT_LC} build/cmake/server-${CM_BT_LC}/dist @tools/pcommand update_cmake_prefab_lib server ${CM_BT_LC} build/cmake/server-${CM_BT_LC}/dist
@${STAGE_ASSETS} -cmakeserver -${CM_BT_LC} build/cmake/server-$(CM_BT_LC) @${STAGE_ASSETS} -cmakeserver -${CM_BT_LC} build/cmake/server-$(CM_BT_LC)
@ -975,7 +974,7 @@ ballisticacore-cmake/.clang-format: .clang-format
# Simple target for CI to build a binary but not download/assemble assets/etc. # Simple target for CI to build a binary but not download/assemble assets/etc.
_cmake-simple-ci-server-build: _cmake-simple-ci-server-build:
SKIP_ENV_CHECKS=1 $(MAKE) code SKIP_ENV_CHECKS=1 $(MAKE) meta
rm -rf build/cmake_simple_ci_server_build rm -rf build/cmake_simple_ci_server_build
mkdir -p build/cmake_simple_ci_server_build mkdir -p build/cmake_simple_ci_server_build
tools/pcommand update_cmake_prefab_lib \ tools/pcommand update_cmake_prefab_lib \

View File

@ -79,6 +79,7 @@
<w>basicsize</w> <w>basicsize</w>
<w>basn</w> <w>basn</w>
<w>bastd</w> <w>bastd</w>
<w>batoolsinternal</w>
<w>bbbb</w> <w>bbbb</w>
<w>bbbbb</w> <w>bbbbb</w>
<w>bbbbbb</w> <w>bbbbbb</w>

View File

@ -41,7 +41,7 @@
"python_source_dirs": [ "python_source_dirs": [
"assets/src/ba_data/python", "assets/src/ba_data/python",
"assets/src/server", "assets/src/server",
"src/generated_src", "src/meta",
"tools", "tools",
"tests" "tests"
] ]

View File

@ -74,7 +74,7 @@ DO_SPARSE_TEST_BUILDS = 'ballistica' + 'core' == 'ballisticacore'
class SourceCategory(Enum): class SourceCategory(Enum):
"""Types of sources.""" """Types of sources."""
RESOURCES = 'resources_src' RESOURCES = 'resources_src'
CODE_GEN = 'code_gen_src' META = 'meta_src'
ASSETS = 'assets_src' ASSETS = 'assets_src'
CMAKE = 'cmake_src' CMAKE = 'cmake_src'
WIN = 'win_src' WIN = 'win_src'
@ -117,9 +117,9 @@ def _lazybuild_check_paths(inpaths: List[str], category: SourceCategory,
continue continue
for root, _dnames, fnames in os.walk(inpath): for root, _dnames, fnames in os.walk(inpath):
# Only gen category uses gen src. # Only gen category uses generated src.
if (root.startswith('src/generated_src') if (root.startswith('src/meta')
and category is not SourceCategory.CODE_GEN): and category is not SourceCategory.META):
continue continue
# None of our targets use tools-src. # None of our targets use tools-src.
@ -172,11 +172,11 @@ def lazybuild(target: str, category: SourceCategory, command: str) -> None:
""" """
paths: List[str] paths: List[str]
# Everything possibly affecting generated code. # Everything possibly affecting generated sources.
if category is SourceCategory.CODE_GEN: if category is SourceCategory.META:
paths = [ paths = [
'Makefile', 'tools/generate_code', 'tools/batools/codegen.py', 'Makefile', 'tools/generate_code', 'tools/batools/codegen.py',
'src/generated_src' 'src/meta'
] ]
# Everything possibly affecting asset builds. # Everything possibly affecting asset builds.