set(WIRINGPI wiringPi) include_directories(${CMAKE_CURRENT_SOURCE_DIR}) add_library(${WIRINGPI}Obj OBJECT wiringPi.c wiringSerial.c wiringShift.c piHiPri.c piThread.c wiringPiSPI.c wiringPiI2C.c softPwm.c softTone.c mcp23008.c mcp23016.c mcp23017.c mcp23s08.c mcp23s17.c sr595.c pcf8574.c pcf8591.c mcp3002.c mcp3004.c mcp4802.c mcp3422.c max31855.c max5322.c ads1115.c sn3218.c bmp180.c htu21d.c ds18b20.c rht03.c drcSerial.c drcNet.c pseudoPins.c wpiExtensions.c w25q64.c oled.c OrangePi.c) add_library(${WIRINGPI} STATIC $) add_library(${WIRINGPI}shared SHARED $) set_target_properties(${WIRINGPI}shared PROPERTIES OUTPUT_NAME ${WIRINGPI}) install(TARGETS ${WIRINGPI} ${WIRINGPI}shared RUNTIME DESTINATION bin LIBRARY DESTINATION lib ARCHIVE DESTINATION lib)