Я пытаюсь скомпилировать c ++ - проект с Makefile.am
Я использую iot c sdk, особенно iot_hub_client.
Я запустил функцию, которая должна отправлять сообщенияна устройство x508 registert в iot_hub.Поэтому я реализовал таким образом, как iothub_ll_client_x509_sample.
Но если я скомпилирую с моим Makefile.am, я получу следующие ошибки
/var/opt/azure-iot-sdk-c/cmake/iothub_client/libiothub_client_mqtt_transport.a(iothub_client_authorization.c.o): In function `IoTHubClient_Auth_CreateFromDeviceAuth':
iothub_client_authorization.c:(.text+0x48f): undefined reference to `iothub_device_auth_create'
iothub_client_authorization.c:(.text+0x551): undefined reference to `iothub_device_auth_destroy'
iothub_client_authorization.c:(.text+0x5d7): undefined reference to `iothub_device_auth_destroy'
iothub_client_authorization.c:(.text+0x612): undefined reference to `iothub_device_auth_get_type'
/var/opt/azure-iot-sdk-c/cmake/iothub_client/libiothub_client_mqtt_transport.a(iothub_client_authorization.c.o): In function `IoTHubClient_Auth_Destroy':
iothub_client_authorization.c:(.text+0x669): undefined reference to `iothub_device_auth_destroy'
/var/opt/azure-iot-sdk-c/cmake/iothub_client/libiothub_client_mqtt_transport.a(iothub_client_authorization.c.o): In function `IoTHubClient_Auth_Set_xio_Certificate':
iothub_client_authorization.c:(.text+0x81f): undefined reference to `iothub_device_auth_generate_credentials'
/var/opt/azure-iot-sdk-c/cmake/iothub_client/libiothub_client_mqtt_transport.a(iothub_client_authorization.c.o): In function `IoTHubClient_Auth_Get_SasToken':
iothub_client_authorization.c:(.text+0xacc): undefined reference to `iothub_device_auth_generate_credentials'
collect2: error: ld returned 1 exit status
Makefile:608: recipe for target 'iotProcess' failed
make: *** [iotProcess] Error 1
Мой Makefile выглядит так
# cloud/Makefile.am
#
bin_PROGRAMS = iotProcess
.PHONY: doc dox
AM_CPPFLAGS = @THREADDEFINES@
AM_CXXFLAGS = @WARNING_CXXFLAGS@
iotProcess_SOURCES = iotProcess.cc \
TMPMsgIot.cc \
TMPMsgIot.hh \
IotCloudComm.cc \
IotCloudComm.hh \
MessageHandler.cc \
DeviceInformationContainer.hh \
CloudMessageRequests.h \
jsonUtil.hh \
jsonUtil.cc \
iotProcess_CPPFLAGS = -isystem/var/opt/azure-iot-sdk-c/provisioning_client/inc \
-isystem/var/opt/azure-iot-sdk-c/deps/uhttp/inc/azure_uhttp_c \
-isystem/var/opt/azure-iot-sdk-c/c-utility/inc \
-isystem/var/opt/azure-iot-sdk-c/iothub_client/inc \
-isystem/var/opt/azure-iot-sdk-c/umqtt/inc/azure_umqtt_c \
-I/usr/local/include/nlohmann \
@THREADDEFINES@
iotProcess_CXXFLAGS = @WARNING_CXXFLAGS@
iotProcess_LDADD = /var/opt/azure-iot-sdk-c/cmake/provisioning_client/libprov_auth_client.a \
/var/opt/azure-iot-sdk-c/cmake/provisioning_client/libhsm_security_client.a \
/var/opt/azure-iot-sdk-c/cmake/deps/uhttp/libuhttp.a \
/var/opt/azure-iot-sdk-c/cmake/iothub_client/libiothub_client.a \
/var/opt/azure-iot-sdk-c/cmake/iothub_client/libiothub_client_mqtt_transport.a \
/var/opt/azure-iot-sdk-c/cmake/umqtt/libumqtt.a \
/var/opt/azure-iot-sdk-c/cmake/c-utility/libaziotsharedutil.a \
-lpthread \
-lssl \
-lcrypto \
-lcurl \
-lxerces-c \
-luuid \
-lm
$(iotProcess_OBJECTS): Makefile
Я забыл что-то включить?