Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
U
uniset2
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
UniSet project repositories
uniset2
Commits
b3029c67
Commit
b3029c67
authored
Sep 08, 2016
by
Pavel Vainerman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Добавил "грубое" определение версии libpoco, для возможности
компилировать в ubuntu со старой версией libpoco (<1.7.4). (Нужно для компиляции в travis-ci.org)
parent
46a4232c
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
0 deletions
+16
-0
libuniset2.spec
conf/libuniset2.spec
+1
-0
configure.ac
configure.ac
+5
-0
PassiveTimer.cc
src/Timers/PassiveTimer.cc
+10
-0
No files found.
conf/libuniset2.spec
View file @
b3029c67
...
@@ -489,6 +489,7 @@ mv -f %buildroot%python_sitelibdir_noarch/* %buildroot%python_sitelibdir/%oname
...
@@ -489,6 +489,7 @@ mv -f %buildroot%python_sitelibdir_noarch/* %buildroot%python_sitelibdir/%oname
* Thu Sep 08 2016 Pavel Vainerman <pv@altlinux.ru> 2.5-alt11
* Thu Sep 08 2016 Pavel Vainerman <pv@altlinux.ru> 2.5-alt11
- DebugStream: added support format: level1,level2,-level3
- DebugStream: added support format: level1,level2,-level3
for set or delete debug levels.
for set or delete debug levels.
- add support old version of libpoco (version < 1.7.4)
* Wed Sep 07 2016 Pavel Vainerman <pv@altlinux.ru> 2.5-alt10
* Wed Sep 07 2016 Pavel Vainerman <pv@altlinux.ru> 2.5-alt10
- fixed bug in millisecToPoco() function
- fixed bug in millisecToPoco() function
...
...
configure.ac
View file @
b3029c67
...
@@ -63,6 +63,11 @@ POCO_LIBS="-lPocoFoundation -lPocoNet"
...
@@ -63,6 +63,11 @@ POCO_LIBS="-lPocoFoundation -lPocoNet"
POCO_CFLAGS="-IPoco"
POCO_CFLAGS="-IPoco"
AC_SUBST(POCO_LIBS)
AC_SUBST(POCO_LIBS)
AC_SUBST(POCO_CFLAGS)
AC_SUBST(POCO_CFLAGS)
poco_old=
AC_CHECK_HEADERS([Poco/Version.h],,poco_old=1)
if test -n "$poco_old"; then
POCO_CFLAGS="${POCO_CFLAGS} -DPOCO_OLD_VERSION"
fi
#check sqlite support
#check sqlite support
AC_MSG_CHECKING([sqlite support])
AC_MSG_CHECKING([sqlite support])
...
...
src/Timers/PassiveTimer.cc
View file @
b3029c67
...
@@ -113,8 +113,13 @@ void UniSetTimer::stop()
...
@@ -113,8 +113,13 @@ void UniSetTimer::stop()
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
const
Poco
::
Timespan
UniSetTimer
::
millisecToPoco
(
const
timeout_t
msec
)
const
Poco
::
Timespan
UniSetTimer
::
millisecToPoco
(
const
timeout_t
msec
)
{
{
#ifdef POCO_OLD_VERSION
if
(
msec
==
WaitUpTime
)
return
Poco
::
Timespan
(
std
::
numeric_limits
<
long
>::
max
(),
0
);
#else
if
(
msec
==
WaitUpTime
)
if
(
msec
==
WaitUpTime
)
return
Poco
::
Timespan
(
Poco
::
Timestamp
::
TIMEVAL_MAX
,
0
);
return
Poco
::
Timespan
(
Poco
::
Timestamp
::
TIMEVAL_MAX
,
0
);
#endif
// msec --> usec
// msec --> usec
return
Poco
::
Timespan
(
long
(
msec
/
1000
),
long
((
msec
*
1000
)
%
1000000
)
);
return
Poco
::
Timespan
(
long
(
msec
/
1000
),
long
((
msec
*
1000
)
%
1000000
)
);
...
@@ -122,8 +127,13 @@ const Poco::Timespan UniSetTimer::millisecToPoco( const timeout_t msec )
...
@@ -122,8 +127,13 @@ const Poco::Timespan UniSetTimer::millisecToPoco( const timeout_t msec )
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
const
Poco
::
Timespan
UniSetTimer
::
microsecToPoco
(
const
timeout_t
usec
)
const
Poco
::
Timespan
UniSetTimer
::
microsecToPoco
(
const
timeout_t
usec
)
{
{
#ifdef POCO_OLD_VERSION
if
(
usec
==
WaitUpTime
)
return
Poco
::
Timespan
(
std
::
numeric_limits
<
long
>::
max
(),
0
);
#else
if
(
usec
==
WaitUpTime
)
if
(
usec
==
WaitUpTime
)
return
Poco
::
Timespan
(
Poco
::
Timestamp
::
TIMEVAL_MAX
,
0
);
return
Poco
::
Timespan
(
Poco
::
Timestamp
::
TIMEVAL_MAX
,
0
);
#endif
return
Poco
::
Timespan
(
long
(
usec
/
1000000
),
long
(
usec
%
1000000
)
);
return
Poco
::
Timespan
(
long
(
usec
/
1000000
),
long
(
usec
%
1000000
)
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment