Main Content

빌드 구성

출력 파일 이름, 위치, 유형, 언어와 같은 빌드 설정 구성

이진 코드 생성을 위한 빌드 프로세스를 제어하고 구성하기 위한 많은 파라미터와 설정이 있습니다. 이러한 설정은 출력 빌드 유형(MEX, lib, dll 또는 exe)과 C 및 C++ 언어와 같은 특성을 제어합니다. 다른 빌드 설정을 사용하면 가독성, 성능, 외부 코드 통합 등의 특정 요구 사항에 따라 빌드 출력을 사용자 지정할 수 있습니다. 앱이나 명령줄에서 코드 생성 구성 객체의 빌드 옵션을 수정할 수 있습니다. coder.config를 사용하여 구성 객체를 생성할 수 있습니다. open을 사용하여 편집 앱에서 객체를 엽니다. 함수 코드 내부에서 추가 빌드 파일과 플래그를 지정하려면 coder.updateBuildInfo를 사용하십시오.

함수

모두 확장

coder.configCreate MATLAB Coder code generation configuration objects
coder.updateBuildInfoUpdate build information object RTW.BuildInfo
target.addAdd target object to internal database
target.clearClear all target objects from internal database (R2023a 이후)
target.createCreate target object
target.exportExport target object data (R2019b 이후)
target.getRetrieve target objects from internal database
target.removeRemove target object from internal database
target.updateUpdate target objects in internal database (R2023a 이후)
target.upgradeUpgrade existing definitions of hardware devices (R2019b 이후)
addCompileFlagsAdd compiler options to build information
addDefinesAdd preprocessor macro definitions to build information
addIncludeFilesAdd include files to build information
addIncludePathsAdd include paths to build information
addLinkFlagsAdd link options to build information
addLinkObjectsAdd link objects to build information
addNonBuildFilesAdd nonbuild-related files to build information
addPreincludeFilesAdd preinclude files to build information (R2024a 이후)
addSourceFilesAdd source files to build information
addSourcePathsAdd source paths to build information
addTMFTokensAdd template makefile (TMF) tokens to build information
addUndefinesAdd undefine preprocessor directives to build information (R2024a 이후)
removeIncludePathsRemove include paths from build information (R2023b 이후)
removeSourceFilesRemove source files from build information object (R2021b 이후)
removeUndefinesRemove undefine preprocessor macros from build information (R2024a 이후)
findBuildArgFind a specific build argument in build information
findIncludeFilesFind and add include (header) files to build information
getBuildArgsGet build arguments from build information
getCompileFlagsGet compiler options from build information
getDefinesGet preprocessor macro definitions from build information
getFullFileListGet list of files from build information
getIncludeFilesGet include files from build information
getIncludePathsGet include paths from build information
getLinkFlagsGet link options from build information
getNonBuildFilesGet nonbuild-related files from build information
getPreincludeFilesGet preinclude files from build information (R2024a 이후)
getSourceFilesGet source files from build information
getSourcePathsGet source paths from build information
getUndefinesFrom build information, get preprocessor macros to undefine (R2024a 이후)
setTargetProvidesMainDisable inclusion of code generator provided (generated or static) main.c source file during build
updateFilePathsAndExtensionsUpdate files in build information with missing paths and file extensions
updateFileSeparatorUpdate file separator character for file lists in build information

객체

coder.MexCodeConfigConfiguration parameters for MEX function generation from MATLAB code
coder.CodeConfigConfiguration parameters for C/C++ code generation from MATLAB code
coder.EmbeddedCodeConfigConfiguration parameters for C/C++ code generation from MATLAB code with Embedded Coder
coder.HardwareImplementationHardware-specific configuration parameters for C/C++ code generation from MATLAB code
coder.hardwareCreate hardware board configuration object for C/C++ code generation from MATLAB code
coder.ReplacementTypesConfiguration parameter to specify custom names for MATLAB built-in data types in C/C++ code generation (R2019b 이후)
RTW.BuildInfoProvide information for compiling and linking generated code

클래스

coder.ExternalDependencyInterface to external code
target.AliasCreate alternative identifier for target object
target.CMakeSpecify CMake installation for building generated code (R2022b 이후)
target.CMakeBuilder Configure how CMake builds generated code (R2022b 이후)
target.CMakeBuildTypeDescribe CMake build type or build configuration (R2022b 이후)
target.CMakeCacheEntryConfigure a CMake cache entry (R2022b 이후)
target.EnvironmentConfigurationConfigure system environment for toolchain (R2022b 이후)
target.HardwareComponentSupportDescribe support for a hardware component (R2022b 이후)
target.LanguageImplementationProvide C and C++ compiler implementation details
target.ObjectBase class for target types (R2019b 이후)
target.ProcessorProvide target processor information
target.ToolchainCapture high-level information about toolchain (R2022b 이후)

네임스페이스

target타깃 하드웨어 및 빌드 툴 정보 관리

도움말 항목

빌드 구성 기본 사항

특정 빌드 옵션

문제 해결하기