If you heard a loud, thumping sound earlier that was me banging my head on my 
desk.  Using H5_BUILT_AS_DYNAMIC worked.  Is there a similar define needed for 
using the static libraries?  I missed this in the documentation.

Thanks,
Jeff
________________________________________
From: Hdf-forum <[email protected]> on behalf of Dana 
Robinson <[email protected]>
Sent: Tuesday, April 26, 2016 9:16:40 PM
To: HDF Users Discussion List
Subject: Re: [Hdf-forum] Unresolved Symbols?

You defined H5_BUILD_AS_DYNAMIC, not BUILT.

Dana Robinson
Software Engineer
The HDF Group

-----Original Message-----
From: Hdf-forum [mailto:[email protected]] On Behalf Of jeff 
womble
Sent: Tuesday, April 26, 2016 10:08 PM
To: HDF Users Discussion List <[email protected]>
Subject: Re: [Hdf-forum] Unresolved Symbols?


I didn't have that defined, but it didn't help.  Below is the compiler output.  
Any other thoughts?

Thanks!
Jeff

20:57:13: Running steps for project test...
20:57:13: Starting: "C:\Qt5x86\Tools\QtCreator\bin\jom.exe" clean
        C:\Qt5x86\Tools\QtCreator\bin\jom.exe -f Makefile.Debug clean
        del debug\moc_mainwindow.cpp debug\moc_hdffile.cpp
        del ui_mainwindow.h
Could Not Find 
C:\Users\Jake\Documents\build-test-Desktop_Qt_5_6_0_MSVC2015_32bit-Debug\ui_mainwindow.h
        del debug\main.obj debug\mainwindow.obj debug\hdffile.obj 
debug\moc_mainwindow.obj debug\moc_hdffile.obj
        del debug\test.exp debug\test.ilk debug\test.idb Could Not Find 
C:\Users\Jake\Documents\build-test-Desktop_Qt_5_6_0_MSVC2015_32bit-Debug\debug\test.exp
        C:\Qt5x86\Tools\QtCreator\bin\jom.exe -f Makefile.Release clean Could 
Not Find 
C:\Users\Jake\Documents\build-test-Desktop_Qt_5_6_0_MSVC2015_32bit-Debug\release\moc_mainwindow.cpp
        del release\moc_mainwindow.cpp release\moc_hdffile.cpp
        del ui_mainwindow.h
        del release\main.obj release\mainwindow.obj release\hdffile.obj 
release\moc_mainwindow.obj release\moc_hdffile.obj
        del release\test.exp
Could Not Find 
C:\Users\Jake\Documents\build-test-Desktop_Qt_5_6_0_MSVC2015_32bit-Debug\release\main.obj
Could Not Find 
C:\Users\Jake\Documents\build-test-Desktop_Qt_5_6_0_MSVC2015_32bit-Debug\release\test.exp
        del test.exp
Could Not Find 
C:\Users\Jake\Documents\build-test-Desktop_Qt_5_6_0_MSVC2015_32bit-Debug\test.exp
        del test.ilk
Could Not Find 
C:\Users\Jake\Documents\build-test-Desktop_Qt_5_6_0_MSVC2015_32bit-Debug\test.ilk
        del test.idb
Could Not Find 
C:\Users\Jake\Documents\build-test-Desktop_Qt_5_6_0_MSVC2015_32bit-Debug\test.idb
20:57:13: The process "C:\Qt5x86\Tools\QtCreator\bin\jom.exe" exited normally.
20:57:13: Configuration unchanged, skipping qmake step.
20:57:13: Starting: "C:\Qt5x86\Tools\QtCreator\bin\jom.exe"
        C:\Qt5x86\Tools\QtCreator\bin\jom.exe -f Makefile.Debug
        C:\Qt5x86\5.6\msvc2015\bin\uic.exe ..\test\mainwindow.ui -o 
ui_mainwindow.h
        cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -Zi 
-MDd -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc 
/Fddebug\test.pdb -DUNICODE -DWIN32 -DQT_QML_DEBUG -DQT_WIDGETS_LIB 
-DQT_GUI_LIB -DQT_CORE_LIB -DH5_BUILD_AS_DYNAMIC_LIB -I..\test -I. 
-I..\..\..\..\hdf5_x86\include -I..\..\..\..\Qt5x86\5.6\msvc2015\include 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtWidgets 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtGui 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtANGLE 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtCore -Idebug -I. 
-I..\..\..\..\Qt5x86\5.6\msvc2015\mkspecs\win32-msvc2015 -Fodebug\ 
@C:\Users\Jake\AppData\Local\Temp\main.obj.6648.15.jom
        cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -Zi 
-MDd -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc 
/Fddebug\test.pdb -DUNICODE -DWIN32 -DQT_QML_DEBUG -DQT_WIDGETS_LIB 
-DQT_GUI_LIB -DQT_CORE_LIB -DH5_BUILD_AS_DYNAMIC_LIB -I..\test -I. 
-I..\..\..\..\hdf5_x86\include -I..\..\..\..\Qt5x86\5.6\msvc2015\include 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtWidgets 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtGui 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtANGLE 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtCore -Idebug -I. 
-I..\..\..\..\Qt5x86\5.6\msvc2015\mkspecs\win32-msvc2015 -Fodebug\ 
@C:\Users\Jake\AppData\Local\Temp\hdffile.obj.6648.15.jom
        C:\Qt5x86\5.6\msvc2015\bin\moc.exe -DUNICODE -DWIN32 -DQT_QML_DEBUG 
-DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -DH5_BUILD_AS_DYNAMIC_LIB 
-D_MSC_VER=1900 -D_WIN32 -IC:/Qt5x86/5.6/msvc2015/mkspecs/win32-msvc2015 
-IC:/Users/Jake/Documents/test -IC:/hdf5_x86/include 
-IC:/Qt5x86/5.6/msvc2015/include -IC:/Qt5x86/5.6/msvc2015/include/QtWidgets 
-IC:/Qt5x86/5.6/msvc2015/include/QtGui -IC:/Qt5x86/5.6/msvc2015/include/QtANGLE 
-IC:/Qt5x86/5.6/msvc2015/include/QtCore -I. ..\test\mainwindow.h -o 
debug\moc_mainwindow.cpp hdffile.cpp main.cpp
        C:\Qt5x86\5.6\msvc2015\bin\moc.exe -DUNICODE -DWIN32 -DQT_QML_DEBUG 
-DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -DH5_BUILD_AS_DYNAMIC_LIB 
-D_MSC_VER=1900 -D_WIN32 -IC:/Qt5x86/5.6/msvc2015/mkspecs/win32-msvc2015 
-IC:/Users/Jake/Documents/test -IC:/hdf5_x86/include 
-IC:/Qt5x86/5.6/msvc2015/include -IC:/Qt5x86/5.6/msvc2015/include/QtWidgets 
-IC:/Qt5x86/5.6/msvc2015/include/QtGui -IC:/Qt5x86/5.6/msvc2015/include/QtANGLE 
-IC:/Qt5x86/5.6/msvc2015/include/QtCore -I. ..\test\hdffile.h -o 
debug\moc_hdffile.cpp
        cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -Zi 
-MDd -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc 
/Fddebug\test.pdb -DUNICODE -DWIN32 -DQT_QML_DEBUG -DQT_WIDGETS_LIB 
-DQT_GUI_LIB -DQT_CORE_LIB -DH5_BUILD_AS_DYNAMIC_LIB -I..\test -I. 
-I..\..\..\..\hdf5_x86\include -I..\..\..\..\Qt5x86\5.6\msvc2015\include 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtWidgets 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtGui 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtANGLE 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtCore -Idebug -I. 
-I..\..\..\..\Qt5x86\5.6\msvc2015\mkspecs\win32-msvc2015 -Fodebug\ 
@C:\Users\Jake\AppData\Local\Temp\mainwindow.obj.6648.234.jom
mainwindow.cpp
        cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -Zi 
-MDd -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc 
/Fddebug\test.pdb -DUNICODE -DWIN32 -DQT_QML_DEBUG -DQT_WIDGETS_LIB 
-DQT_GUI_LIB -DQT_CORE_LIB -DH5_BUILD_AS_DYNAMIC_LIB -I..\test -I. 
-I..\..\..\..\hdf5_x86\include -I..\..\..\..\Qt5x86\5.6\msvc2015\include 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtWidgets 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtGui 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtANGLE 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtCore -Idebug -I. 
-I..\..\..\..\Qt5x86\5.6\msvc2015\mkspecs\win32-msvc2015 -Fodebug\ 
@C:\Users\Jake\AppData\Local\Temp\moc_hdffile.obj.6648.343.jom
moc_hdffile.cpp
        cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -Zi 
-MDd -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc 
/Fddebug\test.pdb -DUNICODE -DWIN32 -DQT_QML_DEBUG -DQT_WIDGETS_LIB 
-DQT_GUI_LIB -DQT_CORE_LIB -DH5_BUILD_AS_DYNAMIC_LIB -I..\test -I. 
-I..\..\..\..\hdf5_x86\include -I..\..\..\..\Qt5x86\5.6\msvc2015\include 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtWidgets 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtGui 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtANGLE 
-I..\..\..\..\Qt5x86\5.6\msvc2015\include\QtCore -Idebug -I. 
-I..\..\..\..\Qt5x86\5.6\msvc2015\mkspecs\win32-msvc2015 -Fodebug\ 
@C:\Users\Jake\AppData\Local\Temp\moc_mainwindow.obj.6648.2140.jom
moc_mainwindow.cpp
..\test\mainwindow.cpp(21): warning C4189: 'hdf': local variable is initialized 
but not referenced
        link /NOLOGO /DYNAMICBASE /NXCOMPAT /DEBUG /SUBSYSTEM:WINDOWS 
"/MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls' 
version='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*' 
processorArchitecture='*'" /MANIFEST:embed /OUT:debug\test.exe 
@C:\Users\Jake\AppData\Local\Temp\test.exe.6648.3796.jom
hdffile.obj : error LNK2001: unresolved external symbol _H5T_NATIVE_FLOAT_g 
hdffile.obj : error LNK2001: unresolved external symbol _H5T_NATIVE_DOUBLE_g 
debug\test.exe : fatal error LNK1120: 2 unresolved externals
jom: 
C:\Users\Jake\Documents\build-test-Desktop_Qt_5_6_0_MSVC2015_32bit-Debug\Makefile.Debug
 [debug\test.exe] Error 1120
jom: 
C:\Users\Jake\Documents\build-test-Desktop_Qt_5_6_0_MSVC2015_32bit-Debug\Makefile
 [debug] Error 2
20:57:17: The process "C:\Qt5x86\Tools\QtCreator\bin\jom.exe" exited with code 
2.
Error while building/deploying project test (kit: Desktop Qt 5.6.0 MSVC2015 
32bit) When executing step "Make"
20:57:17: Elapsed time: 00:04.
________________________________________
From: Hdf-forum <[email protected]> on behalf of Gerd Heber 
<[email protected]>
Sent: Monday, April 25, 2016 7:54:35 AM
To: HDF Users Discussion List
Subject: Re: [Hdf-forum] Unresolved Symbols?

Jeff, did you specify the H5_BUILT_AS_DYNAMIC_LIB preprocessor definition 
(/D...) when building your application?

Best, G.

From: Hdf-forum [mailto:[email protected]] On Behalf Of jeff 
womble
Sent: Sunday, April 24, 2016 8:41 PM
To: [email protected]
Subject: [Hdf-forum] Unresolved Symbols?

I am trying to build a project on Windows 8 using QT5, and VS2015 community 
tools.  I installed HDF5 1.8.16 using the precompiled binaries.

When I try to build my project I get errors:
error LNK2001: unresolved external symbol _H5T_NATIVE_FLOAT_g

I'm linking in  zlib, szip, hdf5, and hdf5_cpp (in that order).

Can anyone help me out?

Thanks,
Jeff

_______________________________________________
Hdf-forum is for HDF software users discussion.
[email protected]
http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org
Twitter: https://twitter.com/hdf5

_______________________________________________
Hdf-forum is for HDF software users discussion.
[email protected]
http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org
Twitter: https://twitter.com/hdf5

_______________________________________________
Hdf-forum is for HDF software users discussion.
[email protected]
http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org
Twitter: https://twitter.com/hdf5

_______________________________________________
Hdf-forum is for HDF software users discussion.
[email protected]
http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org
Twitter: https://twitter.com/hdf5

Reply via email to