Skip to content

Commit

Permalink
m_throttleDelay inherited (#80)
Browse files Browse the repository at this point in the history
* m_throttleDelay inherited, m_lossless edited out
* V2.2.3 bf fixes (#81)
* BF: CanModule object libray only required
* BF: quoted include not angle bracket: quoted include searches local directory first, which is the code intention here (NB: quasar, wienerHAL etc also all come with files named version.h, therefore MSVC build fails - windows, case insensitive, picks up wrong version.h file
* BF: fix windows build - requires implementations of utility functions in build, otherwise dll link step fails

---------
Co-authored-by: Ben Farnham <[email protected]> BF
  • Loading branch information
meeludwig authored Jan 29, 2024
1 parent 2b58b3b commit 64128e3
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 30 deletions.
20 changes: 3 additions & 17 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -85,23 +85,9 @@ endfunction()
#
# -- FUNCTION SECTTION END --

# use env var for static-as-possible or shared linking for linux (only shared for windows)
IF ( $ENV{CANMODULE_AS_STATIC_AS_POSSIBLE} MATCHES "true" )
SET ( CANMODULE_AS_STATIC_AS_POSSIBLE TRUE )
ELSE()
SET ( CANMODULE_AS_STATIC_AS_POSSIBLE FALSE )
ENDIF()

IF ( ${CANMODULE_AS_STATIC_AS_POSSIBLE} )
SET ( CANMODULE_LIB_NAME CanModule-static ) # expands to libCanModule-static.a
SET ( LINK_OPTION STATIC )
SET ( BUILD_SHARED_LIBS OFF )
ELSE()
SET ( CANMODULE_LIB_NAME CanModule ) # expands to libCanModule.so
SET ( LINK_OPTION SHARED )
SET ( BUILD_SHARED_LIBS ON )
ENDIF()

SET ( CANMODULE_LIB_NAME CanModule )
SET ( LINK_OPTION STATIC )
SET ( BUILD_SHARED_LIBS OFF )


# LogIt pull-in
Expand Down
2 changes: 1 addition & 1 deletion CanInterface/include/CCanAccess.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
#include <CanStatistics.h>
#include <CanModuleUtils.h>

#include <VERSION.h>
#include "VERSION.h"



Expand Down
3 changes: 1 addition & 2 deletions CanInterfaceImplementations/anagate/AnaCanScan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,7 @@ AnaCanScan::AnaCanScan():
m_UcanHandle(0),
m_timeout ( 6000 ),
m_busStopped( false ),
m_gsig( NULL ),
m_sendThrottleDelay(-1)
m_gsig( NULL )
{
m_statistics.setTimeSinceOpened();
m_statistics.beginNewRun();
Expand Down
3 changes: 1 addition & 2 deletions CanInterfaceImplementations/anagate2/AnaCanScan2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,7 @@ AnaCanScan2::AnaCanScan2():
m_UcanHandle(0),
m_timeout ( 6000 ),
m_busStopped( false ),
m_gsig( NULL ),
m_sendThrottleDelay(-1)
m_gsig( NULL )
{
m_statistics.setTimeSinceOpened();
m_statistics.beginNewRun();
Expand Down
4 changes: 1 addition & 3 deletions CanInterfaceImplementations/pkcan/pkcan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,7 @@ PKCanScan::PKCanScan():
m_CanScanThreadRunEnableFlag(false),
m_logItHandlePk(0),
m_pkCanHandle(0),
m_gsig( NULL ),
m_sendThrottleDelay(-1)

m_gsig( NULL )
{
m_statistics.setTimeSinceOpened();
m_statistics.beginNewRun();
Expand Down
3 changes: 1 addition & 2 deletions CanInterfaceImplementations/sockcan/SockCanScan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,7 @@ CSockCanScan::CSockCanScan() :
m_hCanScanThread( NULL ),
m_busName("nobus"),
m_logItHandleSock(0),
m_gsig( NULL ),
m_sendThrottleDelay(-1)
m_gsig( NULL )
{
m_statistics.setTimeSinceOpened();
m_statistics.beginNewRun();
Expand Down
3 changes: 1 addition & 2 deletions CanInterfaceImplementations/systec/STCanScan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,7 @@ STCanScan::STCanScan():
m_baudRate(0),
m_idCanScanThread(0),
m_logItHandleSt(0),
m_gsig ( NULL ),
m_sendThrottleDelay(-1)
m_gsig ( NULL )
{
m_statistics.setTimeSinceOpened();
m_statistics.beginNewRun();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@ set(MOCK_SOURCES
MockCanAccess.cpp
MockCanAccess.h
../../CanInterface/src/CanStatistics.cpp
../../CanInterface/include/CanStatistics.h
../../CanInterface/include/CanStatistics.h
../../CanInterface/src/CCanAccess.cpp
../../CanInterface/src/CanModuleUtils.cpp
)

IF ( DEFINED CANMODULE_AS_STATIC_AS_POSSIBLE )
Expand Down

0 comments on commit 64128e3

Please sign in to comment.