From 2be00e761593bbc510a4f71b4a1d168887ecda30 Mon Sep 17 00:00:00 2001 From: Romuald Conty Date: Mon, 18 Mar 2013 23:53:01 +0100 Subject: [PATCH] Move log implementation for Windows in dedicated directory --- libnfc/log_win32.c => contrib/win32/libnfc/log-internal.c | 0 libnfc/CMakeLists.txt | 6 +++--- libnfc/Makefile.am | 7 ++----- libnfc/{log_posix.c => log-internal.c} | 0 4 files changed, 5 insertions(+), 8 deletions(-) rename libnfc/log_win32.c => contrib/win32/libnfc/log-internal.c (100%) rename libnfc/{log_posix.c => log-internal.c} (100%) diff --git a/libnfc/log_win32.c b/contrib/win32/libnfc/log-internal.c similarity index 100% rename from libnfc/log_win32.c rename to contrib/win32/libnfc/log-internal.c diff --git a/libnfc/CMakeLists.txt b/libnfc/CMakeLists.txt index c662f21..caae6df 100644 --- a/libnfc/CMakeLists.txt +++ b/libnfc/CMakeLists.txt @@ -48,15 +48,15 @@ IF(LIBUSB_FOUND) ENDIF(LIBUSB_FOUND) # Library -SET(LIBRARY_SOURCES nfc nfc-device nfc-emulation nfc-internal conf iso14443-subr mirror-subr target-subr log ${DRIVERS_SOURCES} ${BUSES_SOURCES} ${CHIPS_SOURCES} ${WINDOWS_SOURCES}) +SET(LIBRARY_SOURCES nfc nfc-device nfc-emulation nfc-internal conf iso14443-subr mirror-subr target-subr ${DRIVERS_SOURCES} ${BUSES_SOURCES} ${CHIPS_SOURCES} ${WINDOWS_SOURCES}) INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR}) IF(LIBNFC_LOG) IF(WIN32) SET(CMAKE_C_FLAGS "-fgnu89-inline ${CMAKE_C_FLAGS}") - LIST(APPEND LIBRARY_SOURCES log_win32) + LIST(APPEND LIBRARY_SOURCES log ../contrib/win32/libnfc/log-internal) ELSE(WIN32) - LIST(APPEND LIBRARY_SOURCES log_posix) + LIST(APPEND LIBRARY_SOURCES log log-internal) ENDIF(WIN32) ENDIF(LIBNFC_LOG) ADD_LIBRARY(nfc SHARED ${LIBRARY_SOURCES}) diff --git a/libnfc/Makefile.am b/libnfc/Makefile.am index 5d02b77..ba6b09a 100644 --- a/libnfc/Makefile.am +++ b/libnfc/Makefile.am @@ -7,7 +7,6 @@ lib_LTLIBRARIES = libnfc.la libnfc_la_SOURCES = \ conf.c \ iso14443-subr.c \ - log.c \ mirror-subr.c \ nfc.c \ nfc-device.c \ @@ -41,10 +40,8 @@ if LIBUSB_ENABLED endif if WITH_LOG - libnfc_la_SOURCES += log_posix.c + libnfc_la_SOURCES += log.c log-internal.c endif EXTRA_DIST = \ - CMakeLists.txt \ - log_posix.c \ - log_win32.c + CMakeLists.txt diff --git a/libnfc/log_posix.c b/libnfc/log-internal.c similarity index 100% rename from libnfc/log_posix.c rename to libnfc/log-internal.c