Skip to content

Commit

Permalink
Build static or shared libraries depending on the platform/default se…
Browse files Browse the repository at this point in the history
…ttings
  • Loading branch information
wravery committed Oct 3, 2018
1 parent 3a7edcd commit e4dbc06
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ CTestCostData.txt
CTestTestfile.cmake
install_manifest.txt
LastTest.log
lib*.a
lib*.so
Makefile
schemagen
Expand Down
5 changes: 3 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ if(WIN32)
SET(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS TRUE)
endif()

add_library(graphqlservice SHARED GraphQLService.cpp Introspection.cpp IntrospectionSchema.cpp)
add_library(graphqlservice GraphQLService.cpp Introspection.cpp IntrospectionSchema.cpp)
add_executable(schemagen SchemaGenerator.cpp)

find_library(GRAPHQLPARSER graphqlparser)
Expand Down Expand Up @@ -50,7 +50,7 @@ if(BUILD_TESTS OR UPDATE_SAMPLES)
)

if(BUILD_TESTS)
add_library(todaygraphql SHARED
add_library(todaygraphql
TodaySchema.cpp
Today.cpp)

Expand Down Expand Up @@ -99,6 +99,7 @@ endif()
install(TARGETS graphqlservice schemagen
EXPORT cppgraphqlgen-config
RUNTIME DESTINATION bin
ARCHIVE DESTINATION lib
LIBRARY DESTINATION lib)

install(FILES GraphQLService.h Introspection.h IntrospectionSchema.h
Expand Down

0 comments on commit e4dbc06

Please sign in to comment.