default platform + impl all functions
This commit is contained in:
parent
8ff3047aec
commit
f32bf63c98
10 changed files with 72 additions and 45 deletions
|
@ -136,15 +136,6 @@ struct GlobalConfig {
|
|||
};
|
||||
```
|
||||
|
||||
## OptionalFileType
|
||||
```
|
||||
enum OptionalFileType {
|
||||
OFileType_IsWin32,
|
||||
OFileType_IsUnix,
|
||||
OFileType_IsLinux
|
||||
};
|
||||
```
|
||||
|
||||
## Platform
|
||||
```c++
|
||||
struct Platform {
|
||||
|
@ -171,14 +162,4 @@ enum LanguageType {
|
|||
LanguageType_CPP,
|
||||
LanguageType_C
|
||||
};
|
||||
```
|
||||
|
||||
## Profile
|
||||
```c++
|
||||
struct Profile {
|
||||
string name;
|
||||
|
||||
Array<string> compiler_flags;
|
||||
Array<string> linker_flags;
|
||||
};
|
||||
```
|
|
@ -2,15 +2,14 @@
|
|||
Extensions can be loaded at runtime using grbc_ext(...), functions are then dumped into the runtime
|
||||
|
||||
## How extensions work
|
||||
Extensions are built into the grbc executable, or can be compiled as a shared library and put into ```/usr/local/share/grbc/extensions```, ```C:\GRBC\Extensions\```, or ```~/.local/share/grbc/extensions```
|
||||
Extensions are built into the grbc executable, and are loaded at runtime as needed
|
||||
|
||||
## Extension list
|
||||
* GRBC_EXT_pkg_config
|
||||
* GRBC_EXT_multi_file [NOSUPPORT]
|
||||
* GRBC_EXT_cmake [NOSUPPORT]
|
||||
|
||||
## GRBC_EXT_pkg_config
|
||||
Pkg config support. UNIX only
|
||||
|
||||
## GRBC_EXT_multi_file
|
||||
Multi file GRBC scripts, supported on all systems.
|
||||
## GRBC_EXT_cmake
|
||||
CMake interop support
|
|
@ -31,19 +31,19 @@ Create a new executable and add it to the build list
|
|||
## [X] grbc_library(library_config: LibraryConfig) -> TargetInfo
|
||||
Create a new library and add it to the build list
|
||||
|
||||
## grbc_pkg(package_name: String) -> Package
|
||||
## [X] grbc_pkg(package_name: String) -> Package
|
||||
Get a package with the given name and return its baked form
|
||||
|
||||
## [X] grbc_file(file_path: String) -> Path
|
||||
Used when listing source files, should perform pre-checks on the file and return its path
|
||||
|
||||
## grbc_file_optional(file_type: OptionalFileType, file_path: String) -> Path
|
||||
If file_type is true then file_path is returned, otherwise a blank string
|
||||
## [X] grbc_platform_file(platform: PlatformType, file_path: String) -> String
|
||||
If the current platform is equal to platform then return the file path, otherwise return an empty string
|
||||
|
||||
## grbc_has_ext(extension_name: String) -> Boolean
|
||||
## [X] grbc_has_ext(extension_name: String) -> Boolean
|
||||
Check if the given extension is supported
|
||||
|
||||
## grbc_ext(extension_name: String) -> Void
|
||||
## [X] grbc_ext(extension_name: String) -> Void
|
||||
Load the given extension into the script
|
||||
|
||||
## [X] grbc_exception(exception_string: String) -> Void
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue