Install both libraries. Force IfcGeom to static on Windows. Correct IfcParse linkage. Update IfcMax

This commit is contained in:
Thomas Krijnen
2016-06-22 14:54:55 +02:00
parent ea6fbc77dd
commit 478bda30bc
2 changed files with 12 additions and 7 deletions
+10 -6
View File
@@ -452,7 +452,7 @@ endforeach()
set(IFCPARSE_FILES ${IFCPARSE_CPP_FILES} ${IFCPARSE_H_FILES})
add_library(IfcParse STATIC ${IFCPARSE_FILES})
add_library(IfcParse ${IFCPARSE_FILES})
set_target_properties(IfcParse PROPERTIES COMPILE_FLAGS -DIfcParse_EXPORTS)
IF(UNICODE_SUPPORT)
@@ -463,13 +463,17 @@ ENDIF()
file(GLOB IFCGEOM_H_FILES ../src/ifcgeom/*.h)
file(GLOB IFCGEOM_CPP_FILES ../src/ifcgeom/*.cpp)
set(IFCGEOM_FILES ${IFCGEOM_CPP_FILES} ${IFCGEOM_H_FILES})
IF(BUILD_SHARED_LIBS)
message(WARNING "Building IfcGeom as shared library not currently supported")
add_library(IfcGeom SHARED ${IFCGEOM_FILES})
ELSE()
add_library(IfcGeom ${IFCGEOM_FILES})
message(WARNING "Building IfcGeom as shared library currently not supported depending on platform and compiler options")
ENDIF()
if(WIN32)
add_library(IfcGeom STATIC ${IFCGEOM_FILES})
else()
add_library(IfcGeom ${IFCGEOM_FILES})
endif()
TARGET_LINK_LIBRARIES(IfcGeom IfcParse)
# IfcConvert
@@ -528,7 +532,7 @@ INSTALL(FILES ${IFCGEOM_H_FILES}
DESTINATION ${INCLUDEDIR}/ifcgeom
)
INSTALL(TARGETS ${IFCOPENSHELL_LIBRARIES} IfcConvert IfcGeomServer
INSTALL(TARGETS IfcParse IfcGeom IfcConvert IfcGeomServer
ARCHIVE DESTINATION ${LIBDIR}
LIBRARY DESTINATION ${LIBDIR}
RUNTIME DESTINATION ${BINDIR}
+2 -1
View File
@@ -28,7 +28,8 @@ LINK_DIRECTORIES(${LINK_DIRECTORIES} ${IfcOpenShell_BINARY_DIR} ${OCC_LIBRARY_DI
ADD_LIBRARY(IfcMax SHARED IfcMax.h IfcMax.cpp)
TARGET_LINK_LIBRARIES(IfcMax ${IFCLIBS} Comctl32.lib zlibdll.lib bmm.lib core.lib CustDlg.lib edmodel.lib expr.lib
# TODO: find the minimal subset of 3dsmax libraries to reference
TARGET_LINK_LIBRARIES(IfcMax ${IFCOPENSHELL_LIBRARIES} Comctl32.lib zlibdll.lib bmm.lib core.lib CustDlg.lib edmodel.lib expr.lib
flt.lib geom.lib gfx.lib gup.lib imageViewers.lib ManipSys.lib maxnet.lib Maxscrpt.lib
maxutil.lib MenuMan.lib menus.lib mesh.lib MNMath.lib Paramblk2.lib particle.lib Poly.lib RenderUtil.lib
tessint.lib viewfile.lib ${OPENCASCADE_LIBRARIES}