i have gotten down to this error now my issue is it is working in arduino directly
Linking it all together ...
# Coping cached core C:\Users\Home\AppData\Local\Temp\VMBCore\arduino16x\85035866b9b756aae135cc0b7da7261c\core.a to C:\Users\Home\AppData\Local\Temp\VMBuilds\MainMod0\esp32_d32_pro\Release\core.a
"C:\Users\Home\AppData\Local\arduino15\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-80-g6c4433a-5.2.0/bin/xtensa-esp32-elf-gcc" -nostdlib "-LC:\Users\Home\AppData\Local\arduino15\packages\esp32\hardware\esp32\1.0.4/tools/sdk/lib" "-LC:\Users\Home\AppData\Local\arduino15\packages\esp32\hardware\esp32\1.0.4/tools/sdk/ld" -T esp32_out.ld -T esp32.common.ld -T esp32.rom.ld -T esp32.peripherals.ld -T esp32.rom.libgcc.ld -T esp32.rom.spiram_incompatible_fns.ld -u ld_include_panic_highint_hdl -u call_user_start_cpu0 -Wl,--gc-sections -Wl,-static -Wl,--undefined=uxTopUsedPriority -u __cxa_guard_dummy -u __cxx_fatal_exception -Wl,--start-group "MainMod0.cpp.o" "ADC.cpp.o" "BME680P.cpp.o" "i2c.cpp.o" "power.cpp.o" "variable.cpp.o" "Wire\Wire.cpp.o" "SPI\SPI.cpp.o" "EEPROM\EEPROM.cpp.o" "bsec\bsec.cpp.o" "bsec\bme680\bme680.c.o" "C:\Users\Home\AppData\Local\Temp\VMBuilds\MainMod0\esp32_d32_pro\Release\core.a" -lgcc -lesp32 -lphy -lesp_http_client -lmbedtls -lrtc -lesp_http_server -lbtdm_app -lspiffs -lbootloader_support -lmdns -lnvs_flash -lfatfs -lpp -lnet80211 -ljsmn -lface_detection -llibsodium -lvfs -ldl_lib -llog -lfreertos -lcxx -lsmartconfig_ack -lxtensa-debug-module -lheap -ltcpip_adapter -lmqtt -lulp -lfd -lfb_gfx -lnghttp -lprotocomm -lsmartconfig -lm -lethernet -limage_util -lc_nano -lsoc -ltcp_transport -lc -lmicro-ecc -lface_recognition -ljson -lwpa_supplicant -lmesh -lesp_https_ota -lwpa2 -lexpat -llwip -lwear_levelling -lapp_update -ldriver -lbt -lespnow -lcoap -lasio -lnewlib -lconsole -lapp_trace -lesp32-camera -lhal -lprotobuf-c -lsdmmc -lcore -lpthread -lcoexist -lfreemodbus -lspi_flash -lesp-tls -lwpa -lwifi_provisioning -lwps -lesp_adc_cal -lesp_event -lopenssl -lesp_ringbuf -lfr -lstdc++ -Wl,--end-group -Wl,-EL -o "C:\Users\Home\AppData\Local\Temp\VMBuilds\MainMod0\esp32_d32_pro\Release/MainMod0.ino.elf"
bsec.cpp.o: (.literal._ZN4Bsec11beginCommonEv+0x0): undefined reference to bsec_init
bsec.cpp.o: (.literal._ZN4Bsec11beginCommonEv+0x4): undefined reference to bsec_get_version
bsec.cpp.o: (.literal._ZN4Bsec18updateSubscriptionEP21bsec_virtual_sensor_thf+0x0): undefined reference to bsec_update_subscription
bsec.cpp.o: (.literal._ZN4Bsec8getStateEPh+0x0): undefined reference to bsec_get_state
Error linking for board LOLIN D32 PRO
bsec.cpp.o: (.literal._ZN4Bsec8setStateEPh+0x0): undefined reference to bsec_set_state
Build failed for project 'MainMod0'
bsec.cpp.o: (.literal._ZN4Bsec9setConfigEPKh+0x0): undefined reference to bsec_set_configuration
bsec.cpp.o: (.literal._ZN4Bsec15readProcessDataEx19bsec_bme_settings_t+0x4): undefined reference to bsec_do_steps
bsec.cpp.o: (.literal._ZN4Bsec3runEv+0x0): undefined reference to bsec_sensor_control
bsec.cpp.o: In function Bsec::beginCommon()
bsec.cpp:375: undefined reference to bsec_init
bsec.cpp.o: In function Bsec::getVersion()
bsec.cpp:375: undefined reference to bsec_get_version
bsec.cpp.o: In function Bsec::updateSubscription(bsec_virtual_sensor_t*, unsigned char, float)
bsec.cpp:375: undefined reference to bsec_update_subscription
bsec.cpp.o: In function Bsec::getState(unsigned char*)
bsec.cpp:375: undefined reference to bsec_get_state
bsec.cpp.o: In function Bsec::setState(unsigned char*)
bsec.cpp:375: undefined reference to bsec_set_state
bsec.cpp.o: In function Bsec::setConfig(unsigned char const*)
bsec.cpp:375: undefined reference to bsec_set_configuration
bsec.cpp.o: In function Bsec::readProcessData(long long, bsec_bme_settings_t)
bsec.cpp:291: undefined reference to bsec_do_steps
bsec.cpp.o: In function Bsec::run()
bsec.cpp:174: undefined reference to bsec_sensor_control
collect2.exe*: error: ld returned 1 exit status