feat: validate values from Cargo manifest automatically
This PR parses the manifest using the tomlj library and automatically calculates some values from the Cargo manifest as follows:
-
crateName
andlibraryName
crateName
andlibraryName
inBindingsGeneration
need to be set by the user, but they can be determined from the Cargo manifest. From the parsed manifest, this PR automatically sets these values. -
crateType
lib.crate-type
needs to be verified sincestaticlib
andcdylib
are required crate types, but users can indirectly know that after they encounter no file found errors pointing.dylib
,.so
, or.a
files.
For these, this PR adds the class CargoPackage
which contains the parsed TOML and CargoMetadata
.
Edited by Chanjung Kim