build system revision
[vg.git] / labs / build.c
1 #include "vg/vg_build.h"
2 #include "vg/vg_build_utils_shader.h"
3
4 void s_lab_physics(void){
5 vg_info( "running script: s_lab_physics(void)\n" );
6
7 struct vg_project project;
8 struct vg_env env = vg_test_env;
9
10 vg_project_init( &project, &vg_test_env, "labs" );
11 vg_project_new_target( &project, "physics", k_obj_type_exe );
12 vg_add_engine( &project, NULL );
13 vg_add_source( &project, "physics.c" );
14 vg_compile_project( &project );
15 vg_success( "Completed 1/1\n" );
16 }
17
18 int main( int argc, char *argv[] ){
19 char *arg;
20 while( vg_argp( argc, argv ) ){
21 if( vg_long_opt( "physics" ) )
22 s_lab_physics();
23
24 if( vg_opt('r') )
25 vg_test_env.optimization = 3;
26 }
27
28 vg_success( "All scripts ran successfully\n" );
29 }