Commit Graph

9910 Commits

Author SHA1 Message Date
Andrew Johnson
bdbada28a8 makeBaseApp: Remove bad characters from user names
Also warns about some bad characters in record names, but only
the ones that are known to cause known bad behaviour.
2012-07-31 13:47:23 -05:00
Janet Anderson
4133b666a0 Added die if no target file argument 2012-07-31 10:44:33 -05:00
Andrew Johnson
1864ac41fb Add support for native linux-arm builds. 2012-07-30 17:50:30 -05:00
Janet Anderson
1649ce6f79 Replaced makeDbDepends with mkmf 2012-07-30 17:10:57 -05:00
Andrew Johnson
32f556637d libCom/osi: Fixed all epicsThreadSleep() implementations
All are now robust against overflow, NAN or negative argument.
Passing seconds=0 calls the OS scheduler, offering to yield.
Passing seconds>0 delays at least the requested time, up to a
limit which usually depends on the OS tick rate.
2012-06-18 14:52:03 -05:00
Andrew Johnson
146520d035 dbStatic: Fix dbReportDeviceConfig() overflow.
Reported by Hinko Kocevar.
2012-05-21 15:43:03 -05:00
Kate Feng
ea8d19e727 RTEMS: Make nfsMount() globally visible. 2012-05-16 12:25:27 -05:00
Andrew Johnson
c1cebc89bf rsrv: Add epicsShareFunc to casStatsFetch()
Fixes lp:999167
2012-05-14 11:16:33 -05:00
Andrew Johnson
4982a6308b db: Don't call epicsPrintf() from callbackRequest()
The callbackRequest() routine can be called from an ISR,
so use epicsInterruptContextMessage() to print errors.
2012-05-04 17:34:48 -05:00
Andrew Johnson
243baddbf6 Add an Init stat to all thread control variables
This makes the uninitilized value not the Run state.
2012-05-04 13:38:59 -05:00
Andrew Johnson
dde8c61ad8 registry: Cleanup
Delete spurious global symbols
Remove unnecessary casts
Fix (c) headers
Added missing #include guard
Remove unnecessary #includes
Prettified.
2012-04-30 17:40:43 -05:00
Andrew Johnson
8ed86967d1 Don't build command-line programs for iOS targets. 2012-03-30 15:52:19 -05:00
Andrew Johnson
dffe203856 db: Another modification to fix lp:907761
From Dirk Zimoch.
2012-03-19 12:31:11 -05:00
Andrew Johnson
e48ca8a688 rec: Fix timestamps from calcout and seq records
Update record timestamp before calling db_post_events()
2012-03-08 09:47:38 -06:00
Andrew Johnson
7435a9831b db: Reject trailing space in numeric => enum/menu/device conversion
This is really a workaround for a Win32/MinGW bug in sscanf, which
will only set the %n argument for the format "%u %n" when there is
a space following the unsigned number.

This changes the IOC's behavior very slightly.
2012-03-06 14:14:39 -06:00
Andrew Johnson
10e7bced84 libCom/test: epicsTimeTest reworked a bit
Report throw from first call to epicsTime::getCurrent().
Reorganized test order so a bad time provider doesn't stop
all tests from being run.  Also cleaned up a few extraneous
variables.
2012-03-06 12:54:54 -06:00
Andrew Johnson
df7fa22a15 libCom/test: Add more tests of the CALC engine
Some of the isnan(Inf) tests were failing on mingw.
This change doesn't fix them, it adds related examples.
2012-02-29 17:11:08 -06:00
Andrew Johnson
6f9f5498b4 libCom/test: Add diagnostic to epicsStdioTest on vxWorks
This test fails if the cwd is not writable, but on vxWorks the
fault appears at the fclose() not the fopen() line. The code
now detects this and tells the user what's probably wrong.
2012-02-03 16:12:06 -06:00
Andrew Johnson
f5bc02393e libCom: Increase stack sizes for Windows and Posix
Windows stack sizes were the same as vxWorks - tiny.
The stack sizes are now multiples of sizeof(void*).
On 32-bit systems they give 256KB, 512KB and 1MB;
64-bit systems get twice those numbers.

Fixes lp:903448
2012-02-02 18:14:01 -06:00
Andrew Johnson
f86cf730e9 db: fix dbpf to enum from integer bug 2012-01-27 09:41:37 -06:00
Andrew Johnson
adfa1257f5 makeBaseApp: caMonitor example should use ca_create_subscription()
It was calling ca_add_event(), which is a deprecated API.
2012-01-16 16:40:37 -06:00
Andrew Johnson
7cc8a552a3 db: Allow single-char accesses as long strings
Clients try to use long string support to fetch DBF_STRING
fields use DBF_CTRL_CHAR with a 1-element array, but the IOC
was rejecting that.  This permits it, and also ensures that
the resulting strings are zero-terminated.

Fixes lp:907761
2012-01-11 16:47:37 -06:00
Andrew Johnson
afaebfbeb1 libCom: Fix iocsh comment recognition
Merged J. Lewis Muir's fix for comments introduced by macro.
Added fixes to allow comments to be indented too, which used
to work if the '#' was followed by white-space or any argument
separator character.
2012-01-11 15:12:15 -06:00
J. Lewis Muir
ee2a2dfffc libCom/iocsh: Ignore comment lines after macro expansion
The handling of comment lines is only performed before macro
expansion, thus lines with macros that expand to comment lines will
not be correctly handled as comment lines.

By chance this kind of worked sometimes because a "#" command that
does nothing is internally added to the command registry to make it
show up in the help output.  Relying on this is broken.  Furthermore,
if the line starts with '#' followed by a non-separator character
(e.g. "##", "#whatever", etc.) it will not work (i.e. it will produce
a command-not-found error).

This fix checks to see if the first character of the line after macro
expansion is '#'.  If it is, it considers the line to be a comment.
2012-01-11 11:40:30 -06:00
Andrew Johnson
c32997ffa1 tools: Fix dependency file problem.
Reported by Eric.
2011-12-20 16:30:41 -06:00
Jeff Hill
d8f7c3731d fixed various archaic sun pro build failures repoted by Dirk 2011-12-12 16:10:24 -07:00
Andrew Johnson
4a5b8a37df cap5: Load libCap5.so from lib/perl/<perl-version>/<perl-archname>
This allows the same version of Base to be used from both RHEL5 and RHEL6
for example; they use different Perl versions which are not compatible at
the ABI level.
2011-12-10 23:11:33 -06:00
Andrew Johnson
8cb8ad081b softIoc: Strip single-quote chars from arg
Most shells strip the single-quote chars from arguments, but on
win32-x86 this is not happening so we need to do it ourselves.
The single quotes are important to prevent un-escaping of things
that shouldn't be unescaped.
2011-12-05 12:43:26 -06:00
Andrew Johnson
3fc6a77fb0 libCom/posix: Define finite() for uClibc
The finite() function is provided in glibc but not in uClibc.
C99 requires isfinite() to be a macro, so we can test for it
and define our own finite() macro in osi/os/posix/epicsMath.h
2011-12-02 11:07:04 -06:00
Andrew Johnson
3b268475d3 Fix some warnings reported by Clang. 2011-11-29 16:14:19 -06:00
Andrew Johnson
2010e58c61 libCom/win32: Conditionally define MINLONGLONG
Some version of Visual Studio define MAXLONGLONG but not
MINLONGLONG, so they need separate checks.
2011-11-29 14:07:29 -06:00
Andrew Johnson
b791a3692b libCom: Clean up win32 build warning
Delete CFLAG added for the Borland compiler (no longer supported).
2011-11-28 15:54:49 -06:00
Benjamin Franksen
0e41c03ff2 dbStatic: Fix windows build issue
fixes: lp:894276
2011-11-28 12:55:55 -06:00
Andrew Johnson
b5ec6e2448 catools: Edited camonitor help text. 2011-11-21 12:30:02 -06:00
unknown
d077c8b0ff dbStatic: Added -b option to dbExpand
-b turns off monotonic checking of breakpoint tables.
2011-11-21 11:33:26 -06:00
Andrew Johnson
b27e22d75e Makefile cleanup
Various minor changes to comments and build variable names.
2011-11-14 12:33:07 -06:00
Jeff Hill
6ef52b5d03 fixed launchpad bug 697509, Thread synchronization issue in libCom/osi/os/WIN32/osdTime.cpp 2011-11-10 17:34:47 -07:00
Jeff Hill
652235ef13 fixed LP Bug #697517, WIN32 osdtime should handle the system time change properly 2011-11-10 17:22:22 -07:00
Jeff Hill
5b46eebe1a fixed LP bug 697516, PLL time adjustments fail if user sets system time before EPICS epoch 2011-11-10 14:52:22 -07:00
Jeff Hill
a252218e69 fixed launchpad bug 697519 (rollover time diff calc off by two ticks) 2011-11-10 14:03:01 -07:00
Andrew Johnson
fae5bbcf86 cap5: Don't try to process POD on Win32 2011-11-10 13:29:33 -06:00
Andrew Johnson
a0c1c0fb15 makeBaseApp: Remove local duplicates of library functions
Replace the buggy local copies of the functions UnixPath(),
LocalPath(), readRelease() and expandRelease() with the
library versions from our EPICS::Path and EPICS::Release
perl modules.
2011-11-08 17:51:19 -06:00
Andrew Johnson
bb14c6594b Win32: Fix for lp:861214 2011-11-08 15:57:15 -06:00
Andrew Johnson
b36b07db9e Clean up some compiler warnings reported by J. Lewis Muir. 2011-11-07 11:58:09 -06:00
Andrew Johnson
ee95f0c4b7 catools: Fix array handling in caget and camonitor.
Fixes lp:794749
2011-11-02 11:26:29 -05:00
Andrew Johnson
d72b4a3c1e Fix install problems when using parallel builds.
If two targets using the same OS are built in parallel,
they can both try to install the same include/os/* file
at the same time, causing the installEpics.pl script to
die.  We fix this by making all installations atomic:
First copy the file to the installation directory using
a unique name, then rename it to the target name.  The
target name is in the same directory and filesystem as
the temporary name, so the rename should be atomic.
2011-10-28 13:19:08 -05:00
Andrew Johnson
21b4acfa86 ca: Remove anonymous namespace from acctstRegister.cpp
The 3.14 branch still supports vxWorks 5.4.2 whose compiler
doesn't contain any namespace support.
2011-10-19 17:36:21 -05:00
Jeff Hill johill@lanl.gov
96cad82a2a o fixed launchpad epics base bug 878372
o fixed launchpad epics base bug 878387
o added regression test for bug 878372
o build the optional test and diagnostic codes  for all (not just vxWorks) IOCs
o added acctstRegister optional IOC shell registration for regression tests
2011-10-19 12:07:00 -06:00
Andrew Johnson
6cb9a3f7c1 iocInit: Added some database sanity checks to iocIInit
Two menus can get modified by users; these checks make sure they
haven't been damaged too much:

* menuConvert is checked to flag problems with IOCs converted from
  3.13.x, where the SLOPE choice didn't exist.
* menuScan is checked to ensure the three initial choices are still
  present and that there is at least one periodic scan rate.
2011-09-26 16:42:15 -05:00
Till Straumann
6c4164d953 libCom: Second fix for RT thread priority
The previous fix prevented epicsThreads from working properly when
the RT scheduler is *not* used.

fixes lp:835138
2011-09-21 09:55:52 -05:00