|
100 | 100 | rm -f ../out/example_gfx_5_*.so |
101 | 101 | rm -f ../out/example_gfx_6.so |
102 | 102 | rm -f ../out/example_gfx_6_*.so |
| 103 | + rm -f ../out/example_basic_6.so |
| 104 | + rm -f ../out/example_basic_6_*.so |
103 | 105 |
|
104 | 106 |
|
105 | 107 | fi |
|
545 | 547 | echo ${CYAN}Results: ${NC} ${PL_RESULT} |
546 | 548 | echo ${CYAN}~~~~~~~~~~~~~~~~~~~~~~${NC} |
547 | 549 |
|
| 550 | +#~~~~~~~~~~~~~~~~~~~~~~~~~~~ example_basic_6 | debug ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 551 | + |
| 552 | +PL_RESULT=${BOLD}${GREEN}Successful.${NC} |
| 553 | +PL_DEFINES="-D_USE_MATH_DEFINES -DPL_PROFILING_ON -DPL_ALLOW_HOT_RELOAD -DPL_ENABLE_VALIDATION_LAYERS -DPL_CONFIG_DEBUG " |
| 554 | +PL_INCLUDE_DIRECTORIES="-I../examples -I../internal/sandbox -I../src -I../shaders -I../libs -I../extensions -I../out -I../internal/demo -I../thirdparty/stb -I../thirdparty/imgui " |
| 555 | +PL_LINK_DIRECTORIES="-L../out -Wl,-rpath,../out -L/usr/lib/x86_64-linux-gnu -Wl,-rpath,/usr/lib/x86_64-linux-gnu " |
| 556 | +PL_COMPILER_FLAGS="-std=c++14 -fPIC --debug -g " |
| 557 | +PL_LINKER_FLAGS="-ldl -lm " |
| 558 | +PL_STATIC_LINK_LIBRARIES="-ldearimguid " |
| 559 | +PL_DYNAMIC_LINK_LIBRARIES="" |
| 560 | +PL_SOURCES="example_basic_6.cpp " |
| 561 | + |
| 562 | +# run compiler (and linker) |
| 563 | +echo |
| 564 | +echo ${YELLOW}Step: example_basic_6${NC} |
| 565 | +echo ${YELLOW}~~~~~~~~~~~~~~~~~~~${NC} |
| 566 | +echo ${CYAN}Compiling and Linking...${NC} |
| 567 | +gcc -shared $PL_SOURCES $PL_INCLUDE_DIRECTORIES $PL_DEFINES $PL_COMPILER_FLAGS $PL_INCLUDE_DIRECTORIES $PL_LINK_DIRECTORIES $PL_STATIC_LINK_LIBRARIES $PL_DYNAMIC_LINK_LIBRARIES $PL_LINKER_FLAGS -o "./../out/libexample_basic_6.so" |
| 568 | + |
| 569 | +# check build status |
| 570 | +if [ $? -ne 0 ] |
| 571 | +then |
| 572 | + PL_RESULT=${BOLD}${RED}Failed.${NC} |
| 573 | + PL_BUILD_STATUS=1 |
| 574 | +echo ${CYAN}Results: ${NC} ${PL_RESULT} |
| 575 | +echo ${CYAN}~~~~~~~~~~~~~~~~~~~~~~${NC} |
| 576 | +popd >/dev/null |
| 577 | +exit 1 |
| 578 | +fi |
| 579 | + |
| 580 | +# print results |
| 581 | +echo ${CYAN}Results: ${NC} ${PL_RESULT} |
| 582 | +echo ${CYAN}~~~~~~~~~~~~~~~~~~~~~~${NC} |
| 583 | + |
548 | 584 | # delete lock file(s) |
549 | 585 | rm -f ../out/lock.tmp |
550 | 586 |
|
|
605 | 641 | rm -f ../out/example_gfx_5_*.so |
606 | 642 | rm -f ../out/example_gfx_6.so |
607 | 643 | rm -f ../out/example_gfx_6_*.so |
| 644 | + rm -f ../out/example_basic_6.so |
| 645 | + rm -f ../out/example_basic_6_*.so |
608 | 646 |
|
609 | 647 |
|
610 | 648 | fi |
@@ -1050,119 +1088,7 @@ fi |
1050 | 1088 | echo ${CYAN}Results: ${NC} ${PL_RESULT} |
1051 | 1089 | echo ${CYAN}~~~~~~~~~~~~~~~~~~~~~~${NC} |
1052 | 1090 |
|
1053 | | -# delete lock file(s) |
1054 | | -rm -f ../out/lock.tmp |
1055 | | - |
1056 | | -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
1057 | | -# end of release |
1058 | | -fi |
1059 | | - |
1060 | | -# ################################################################################ |
1061 | | -# # configuration | debug_experimental # |
1062 | | -# ################################################################################ |
1063 | | - |
1064 | | -if [[ "$PL_CONFIG" == "debug_experimental" ]]; then |
1065 | | - |
1066 | | -# create output directory(s) |
1067 | | -mkdir -p "../out" |
1068 | | - |
1069 | | -# create lock file(s) |
1070 | | -echo LOCKING > "../out/lock.tmp" |
1071 | | - |
1072 | | -PL_BUILD_STATUS=0 |
1073 | | - |
1074 | | -# check if this is a reload |
1075 | | -PL_HOT_RELOAD_STATUS=0 |
1076 | | - |
1077 | | -# # let user know if hot reloading |
1078 | | -if pidof -x "pilot_light" -o $$ >/dev/null;then |
1079 | | - PL_HOT_RELOAD_STATUS=1 |
1080 | | - echo |
1081 | | - echo ${BOLD}${WHITE}${RED_BG}--------${GREEN_BG} HOT RELOADING ${RED_BG}--------${NC} |
1082 | | - echo |
1083 | | -else |
1084 | | - # cleanup binaries if not hot reloading |
1085 | | - PL_HOT_RELOAD_STATUS=0 |
1086 | | - rm -r -f ../out-temp |
1087 | | - rm -f ../out/example_basic_6.so |
1088 | | - rm -f ../out/example_basic_6_*.so |
1089 | | - |
1090 | | - |
1091 | | -fi |
1092 | | -#~~~~~~~~~~~~~~~~~~~~~ example_basic_6 | debug_experimental ~~~~~~~~~~~~~~~~~~~~~ |
1093 | | - |
1094 | | -PL_RESULT=${BOLD}${GREEN}Successful.${NC} |
1095 | | -PL_DEFINES="-D_USE_MATH_DEFINES -DPL_PROFILING_ON -DPL_ALLOW_HOT_RELOAD -DPL_ENABLE_VALIDATION_LAYERS -DPL_CONFIG_DEBUG " |
1096 | | -PL_INCLUDE_DIRECTORIES="-I../examples -I../internal/sandbox -I../src -I../shaders -I../libs -I../extensions -I../out -I../internal/demo -I../thirdparty/stb -I../thirdparty/imgui " |
1097 | | -PL_LINK_DIRECTORIES="-L../out -Wl,-rpath,../out -L/usr/lib/x86_64-linux-gnu -Wl,-rpath,/usr/lib/x86_64-linux-gnu " |
1098 | | -PL_COMPILER_FLAGS="-std=c++14 -fPIC --debug -g " |
1099 | | -PL_LINKER_FLAGS="-ldl -lm " |
1100 | | -PL_STATIC_LINK_LIBRARIES="-ldearimguid " |
1101 | | -PL_DYNAMIC_LINK_LIBRARIES="" |
1102 | | -PL_SOURCES="example_basic_6.cpp " |
1103 | | - |
1104 | | -# run compiler (and linker) |
1105 | | -echo |
1106 | | -echo ${YELLOW}Step: example_basic_6${NC} |
1107 | | -echo ${YELLOW}~~~~~~~~~~~~~~~~~~~${NC} |
1108 | | -echo ${CYAN}Compiling and Linking...${NC} |
1109 | | -gcc -shared $PL_SOURCES $PL_INCLUDE_DIRECTORIES $PL_DEFINES $PL_COMPILER_FLAGS $PL_INCLUDE_DIRECTORIES $PL_LINK_DIRECTORIES $PL_STATIC_LINK_LIBRARIES $PL_DYNAMIC_LINK_LIBRARIES $PL_LINKER_FLAGS -o "./../out/libexample_basic_6.so" |
1110 | | - |
1111 | | -# check build status |
1112 | | -if [ $? -ne 0 ] |
1113 | | -then |
1114 | | - PL_RESULT=${BOLD}${RED}Failed.${NC} |
1115 | | - PL_BUILD_STATUS=1 |
1116 | | -echo ${CYAN}Results: ${NC} ${PL_RESULT} |
1117 | | -echo ${CYAN}~~~~~~~~~~~~~~~~~~~~~~${NC} |
1118 | | -popd >/dev/null |
1119 | | -exit 1 |
1120 | | -fi |
1121 | | - |
1122 | | -# print results |
1123 | | -echo ${CYAN}Results: ${NC} ${PL_RESULT} |
1124 | | -echo ${CYAN}~~~~~~~~~~~~~~~~~~~~~~${NC} |
1125 | | - |
1126 | | -# delete lock file(s) |
1127 | | -rm -f ../out/lock.tmp |
1128 | | - |
1129 | | -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
1130 | | -# end of debug_experimental |
1131 | | -fi |
1132 | | - |
1133 | | -# ################################################################################ |
1134 | | -# # configuration | release_experimental # |
1135 | | -# ################################################################################ |
1136 | | - |
1137 | | -if [[ "$PL_CONFIG" == "release_experimental" ]]; then |
1138 | | - |
1139 | | -# create output directory(s) |
1140 | | -mkdir -p "../out" |
1141 | | - |
1142 | | -# create lock file(s) |
1143 | | -echo LOCKING > "../out/lock.tmp" |
1144 | | - |
1145 | | -PL_BUILD_STATUS=0 |
1146 | | - |
1147 | | -# check if this is a reload |
1148 | | -PL_HOT_RELOAD_STATUS=0 |
1149 | | - |
1150 | | -# # let user know if hot reloading |
1151 | | -if pidof -x "pilot_light" -o $$ >/dev/null;then |
1152 | | - PL_HOT_RELOAD_STATUS=1 |
1153 | | - echo |
1154 | | - echo ${BOLD}${WHITE}${RED_BG}--------${GREEN_BG} HOT RELOADING ${RED_BG}--------${NC} |
1155 | | - echo |
1156 | | -else |
1157 | | - # cleanup binaries if not hot reloading |
1158 | | - PL_HOT_RELOAD_STATUS=0 |
1159 | | - rm -r -f ../out-temp |
1160 | | - rm -f ../out/example_basic_6.so |
1161 | | - rm -f ../out/example_basic_6_*.so |
1162 | | - |
1163 | | - |
1164 | | -fi |
1165 | | -#~~~~~~~~~~~~~~~~~~~~ example_basic_6 | release_experimental ~~~~~~~~~~~~~~~~~~~~ |
| 1091 | +#~~~~~~~~~~~~~~~~~~~~~~~~~~ example_basic_6 | release ~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
1166 | 1092 |
|
1167 | 1093 | PL_RESULT=${BOLD}${GREEN}Successful.${NC} |
1168 | 1094 | PL_DEFINES="-D_USE_MATH_DEFINES -DPL_PROFILING_ON -DPL_ALLOW_HOT_RELOAD -DPL_ENABLE_VALIDATION_LAYERS -DPL_CONFIG_DEBUG " |
@@ -1200,7 +1126,7 @@ echo ${CYAN}~~~~~~~~~~~~~~~~~~~~~~${NC} |
1200 | 1126 | rm -f ../out/lock.tmp |
1201 | 1127 |
|
1202 | 1128 | # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
1203 | | -# end of release_experimental |
| 1129 | +# end of release |
1204 | 1130 | fi |
1205 | 1131 |
|
1206 | 1132 |
|
|
0 commit comments