vbnc(1)
π
vbnc β the Mono Visual Basic Compiler (yes bestie, vbnc(1), General Commands Manual, we're fancy like that)
β¨ NAME β¨
vbnc, vbnc2 β the Mono Visual Basic Compiler. two icons, one job. π
β¨ SYNOPSIS β¨
vbnc [option] [source-files]
like. that's it. that's the whole vibe. π¦
πΈ DESCRIPTION πΈ
vbnc is a CIL compiler for the VisualBasic.NET language. no cap. π
Apps you built on Windows with vbc can run on Mono, and apps you compiled with vbnc can run on the .NET runtime. cross-platform slay, honestly.
The Mono Visual Basic compiler accepts the exact same options as the Microsoft VB.NET compiler. and those options can start with a slash or a dash β /checked is the same thing as -checked. pick your fighter. π
Visual Basic.NET source files normally end with a .vb extension. To compile VB.NET source code you need to hand over all the files that make up a library, module or executable, right there on the command line. there is no support for partial compilation. nope. none. so if you want the benefits of partial compilation, you compile your programs into their own assemblies and then reference them later with the -r flag. that's the move. β¨
The Mono Basic compiler generates images (.exe files) that contain CIL byte code, and those can be executed by any system implementing a Common Language Infrastructure virtual machine β like the Microsoft .NET runtime engine on Windows, or the Mono runtime engine on Unix systems. Executables are not bound to a specific CPU or operating system. platform-independent queen behavior. π
By default the Mono Basic compiler only references these assemblies: mscorlib.dll, Microsoft.VisualBasic.dll, System.dll and System.Xml.dll. want extra libraries? you have to manually specify them yourself using the -r: command line option. the compiler is not a mind reader bestie π
The vbnc compiler is used to compile against the latest available profile (currently the 4.0 profile).
The vbnc2 compiler is used to compile against the 2.0 profile.
π OPTIONS π
-addmodule:MODULE1[,MODULE2]β includes the modules you list in the resulting assembly. come through, modules π«Ά-codepage:IDβ specifies the code page used to process the input files from the point it's specified onward. by default files get processed in the current code page. the compiler will also automatically detect Unicode/UTF8 files that have an embedded byte mark at the beginning. so it's got range. π- Other popular encodings are
28591(Latin1),1252(iso-8859-1) and65001(UTF-8). jot that down. π -define:SYMLIST,-d:SYMLISTβ defines the symbol listed by the semi-colon separated listSYMLISTSYMBOL. you can test it in the source code with the pre-processor, or it can be used by methods tagged with the Conditional attribute. β¨-debug:AMOUNTβ specify the amount of debugging information to emit. possible values for AMOUNT are"full"and"pdbonly". choose wisely π-imports:import-listβ declares globalImportsfor the listed namespaces.-ignorewarn:XXXXβ ignores warning numberXXXX. not me ignoring my problems... but make it warnings π-lib:PATHLIST,-libpath:PATHLISTβ each path specified in the comma-separated list directs the compiler to look for libraries in that specified path. go get your libraries bestie π-main:CLASSβ tells the compiler whichCLASSorMODULEcontains the entry point. super useful when you're compiling several classes that each have aMainmethod and you need to pick your main character. π-nologoβ suppress printing copyright information on startup. minimalism era. β¨-nostdlib,-nostdlib+β use this flag if you want to compile the core library. this makes the compiler load its internal types from the assembly being compiled. hardcore. π-noconfig,-noconfig+β disables the default compiler configuration from being loaded. by default the compiler has references to the system assemblies.-nowarnβ makes the compiler ignore warnings. blissful ignorance, but make it compiler-approved. π-optioncompare:binary,-optioncompare:textβ select between binary and text string comparisons. the default is binary string comparisons. βοΈ-optionexplicit[+|-]β require explicit declaration of variables.-optionstrict[+|-]β enforce strict language semantics. strict queen behavior, respect. π-out:FNAME,-o FNAMEβ names the output file to be generated.-q -quietβ commands the compiler to show only error messages for syntax-related errors and warnings. quiet luxury π-resource:RESOURCE[,ID]β embeds the given resource file. the optionalIDcan be used to give a different name to the resource. if not specified, the resource name will be the file name. π-linkresource:RESOURCE[,ID]β links to the specifiedRESOURCE. the optionalIDcan be used to give a name to the linked resource.-r:ASSEMBLY1[,ASSEMBLY2],-r ASSEMBLY1[,ASSEMBLY2]β reference the named assemblies. use this to use classes from the named assembly in your program. the assembly will be loaded from either the system directory where all the assemblies live, or from the path explicitly given with the-Loption. π- You can also use a semicolon to separate the assemblies instead of a comma. two ways to do the same thing, we love options π
-sdkpath:PATHβ sets the path to the required framework assemblies (mscorlib.dllandMicrosoft.VisualBasic.dll). to compile to a different profile than the default, use this option to point to the path of themscorlib.dllof the profile you want to compile to.-removeintchecks[+|-]β remove integer checks. default off.-rootnamespace:namespaceβ specifies the root namespace for all type declarations.-target:KIND,-t:KINDβ used to specify the desired target. the possible values are:exe(plain executable),winexe(Windows.Forms executable),library(component libraries) andmodule(partial library). pick your destiny β¨-utf8output[+|-]β emit compiler output in UTF8 character encoding. currently ignored. (it's giving "we'll get to it" π)--versionβ shows the compiler version.-warnaserror,-warnaserror+β treat warnings as errors. no warnings allowed, we're perfect here π
π STABILITY π
As of early 2011, the Mono Visual Basic compiler is still considered beta software. The compiler is feature-complete (targeting the Microsoft Visual Basic 8 compiler), however crashes are still occurring, most notably with incorrect code.
fr fr bestie β it's feature-complete but it can and will crash on bad code. treat it gently. π«Ά
π«Ά AUTHORS π«Ά
See the ChangeLog for authors.
π LICENSE π
The Mono Visual Basic compiler is released under the terms of the GNU LGPL. Alternative licenses are available from Novell.
π SEE ALSO π
mcs(1), mono(1), mint(1), sn(1)
π BUGS π
To report bugs in the compiler, you can file bug reports in our bug tracking system: http://bugzilla.ximian.com
π MAILING LIST π
The Mono Basic Mailing List is available at: mono-vb-list-request@ximian.com
and that's the whole page, bestie π this one's vbnc(1) from the General Commands Manual, dated 21 February 2006 β shoutout to whoever wrote it back then, hope they're thriving πΈ ok bye, go compile something cute β¨ππ¦
π¦ where this page comes from
- fedora 43: mono-basic 4.7-18.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 44: mono-basic 4.7-19.fc44 Β· LicenseRef-Callaway-LGPLv2+
- ubuntu jammy: mono-vbnc 4.0.1-3 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms