Azure / azure-iot-sdk-c

A C99 SDK for connecting devices to Microsoft Azure IoT services
https://azure.github.io/azure-iot-sdk-c
Other
580 stars 738 forks source link

Fix xcodenative build (set LD path to latest curl version installed) #2581

Closed ewertons closed 4 months ago

ewertons commented 4 months ago
# Checklist - [x] I have read the [contribution guidelines] (https://github.com/Azure/azure-iot-sdk-c/blob/main/.github/CONTRIBUTING.md). - [ ] I added or modified the existing tests to cover the change (we do not allow our test coverage to go down). - If this is a modification that impacts the behavior of a public API - [ ] I edited the corresponding document in the `devdoc` folder and added or modified requirements. - I submitted this PR against the correct branch: - [x] This pull-request is submitted against the `main` branch. - [x] I have merged the latest `main` branch prior to submission and re-merged as needed after I took any feedback. - [x] I have squashed my changes into one with a clear description of the change. # Reference/Link to the issue solved with this PR (if any) # Description of the problem xcodenative tests are failing on the gate (e2e tests): ```shell 8: Info: If using SecureTransport with the C SDK, please confirm cURL is also configured to use SecureTransport. 8: Error: Time:Sat Feb 17 04:38:40 2024 File:/Users/runner/work/1/s/c-utility/adapters/httpapi_curl.c Func:HTTPAPI_ExecuteRequest Line:770 curl_easy_perform() failed: SSL connect error 8: 8: Error: Time:Sat Feb 17 04:38:40 2024 File:/Users/runner/work/1/s/c-utility/adapters/httpapi_curl.c Func:HTTPAPI_ExecuteRequest Line:772 (result = HTTPAPI_OPEN_REQUEST_FAILED (4)) 8: Error: Time:Sat Feb 17 04:38:40 2024 File:/Users/runner/work/1/s/c-utility/src/httpapiex.c Func:HTTPAPIEX_ExecuteRequest Line:547 unable to recover sending to a working state 8: Error: Time:Sat Feb 17 04:38:40 2024 File:/Users/runner/work/1/s/iothub_service_client/src/iothub_registrymanager.c Func:sendHttpRequestCRUD Line:1228 HTTPAPIEX_SAS_ExecuteRequest failed. Host:iotsdk-c-production.azure-devices.net 8: Error: Time:Sat Feb 17 04:38:40 2024 File:/Users/runner/work/1/s/testtools/iothub_test/src/iothub_account.c Func:IoTHubAccount_deinit Line:863 IoTHubRegistryManager_DeleteDevice failed (8) for SAS Based Device "csdk_e2eDevice_sas_j_please_delete_033F103F-D163-48D0-87B7-619ED5E56E9F" 8: ``` # Description of the solution Figured out that curl is not able to load shared libs, since we were passing a path to an old curl version (not present in the OSX image). Fixed by setting DYLD_LIBRARY_PATH to whatever version is installed in the system.