Compare commits

..

45 Commits

Author SHA1 Message Date
157b0867fa removed unused vxWorks version defaults 2019-08-14 14:06:05 +02:00
56529964f3 always use -g for non-vxWorks gnu compiler 2019-08-14 13:55:07 +02:00
c28e240fce clear whitespace 2019-08-14 11:39:30 +02:00
b04b2dab22 fix astac crash 2019-08-13 15:13:54 +02:00
8edcd7b07f use READLINE as default for all Linux systems 2019-08-09 16:21:08 +02:00
ca78451122 move PSI specifics out to CONFIG_SITE. files 2019-08-09 13:33:41 +02:00
4cc44e3dce cleanup spaces 2019-08-09 13:32:49 +02:00
e81d3a1d7d remove strict-aliasing warnings in RHEL7 2019-08-09 11:34:50 +02:00
53dd61b80a merged with R7.0.3 2019-08-09 11:31:43 +02:00
5b754d320f fix posix epicsThreadSleepQuantum() implementation not to return 0.01 on Linux 2019-07-24 14:17:25 +02:00
2be2658cfc added modules/pcas 2019-07-22 17:12:22 +02:00
2b157096e6 merge branch '7.0' into 'PSI-7.0' 2019-07-22 15:44:08 +02:00
71eaddfd84 Merge branch 'refs/heads/PSI-7.0.1' into PSI-7.0 2019-07-22 15:36:33 +02:00
5589deb3ad make sure softIoc for vxWorks contains all functions 2019-07-22 15:17:18 +02:00
0bb80e373b add simple calculations to macros 2019-05-10 14:44:17 +02:00
4acdd83984 also build pcas 2019-05-10 11:13:23 +02:00
d12d38f970 re-enable -fno-strict-aliasing for vxWorks 2019-05-10 11:08:48 +02:00
74d9749255 fix install location 2019-05-10 11:07:50 +02:00
3276ada78a build for DeltaTau with ELDK-5.3 for newer C++ compiler 2019-05-08 17:32:50 +02:00
de378eec34 also build pcas 2019-04-03 15:14:34 +02:00
dbb2d875fb undo commit 2206934 which introduces a MKDIR rule that conflicts with driver/makefile 2019-04-03 15:13:00 +02:00
c7f966a1f5 fix install location 2019-04-03 15:10:28 +02:00
7889dda6f8 merged with upstream 2019-02-20 10:51:02 +01:00
a2ccf3b631 add raspberryPi and skip unused vxWorks archs 2018-10-31 15:23:05 +01:00
57db34b303 Merge branch 'FixShellCommands' into PSI-7.0 2018-10-24 09:25:44 +02:00
4f790758af no PVA for mvl40-xscale_be 2018-10-23 10:01:13 +02:00
ce9dfc6bb4 need some .o files, but there aren't many any more 2018-10-18 16:20:45 +02:00
4f40ad1927 build for mvl40-xscale_be (without PVA)configure/os/CONFIG.Common.mvl40-xscale_be 2018-10-18 16:20:13 +02:00
a42a4010d6 skip building with clang on old SL6 to avoid problems with cross build from RHEL7 2018-10-11 13:20:59 +02:00
a2aa17fafc some drivers complain about strict-aliasing 2018-10-11 08:36:35 +02:00
5bf2784db2 add -fno-strict-aliasing for those archs which complain about anyscalar.h 2018-10-05 10:43:08 +02:00
7a4e7b7600 add tar and copysrc make rules 2018-10-03 17:13:13 +02:00
70aa23513f use -isystem option to find correct headers for cross compiling for old Linux host versions 2018-10-03 16:47:57 +02:00
71ded2f25f install dbCaPvt.h needed by devIocStats/ioccar 2018-10-03 16:43:32 +02:00
11103351b2 add build year-month to version string 2018-10-03 16:38:53 +02:00
146a413977 add -isystem to avoid system headers in .d files (does not work for vxWorks 5) 2018-10-03 13:48:09 +02:00
4e44550f62 Merge branch 'FixShellCommands' into PSI-7.0 2018-09-28 11:41:52 +02:00
9952470486 Merge branch 'FixShellCommands' into PSI-7.0 2018-09-27 13:58:23 +02:00
02d30dedbc install server.h for misc module 2018-09-26 16:10:30 +02:00
5ed0fe52a0 Merge branch '7.0' into PSI-7.0 2018-09-26 11:45:19 +02:00
42b1f774da add PSI configuration 2018-09-25 11:13:08 +02:00
7738b68320 fix missing template instances for old vxWorks (uses -fno-implicit-templates) 2018-09-24 18:00:53 +02:00
1199fabe90 Fix strange compiler errors with gcc 2.96:
using <namespace::function>; seems not to work but
using namespace <namespace>; works
Also 'add' only works with explicit namespace. Why?
2018-09-21 16:21:13 +02:00
1aefc5f2f0 re-enable building vxWorks 5 2018-09-21 16:20:17 +02:00
6f666c6c22 Add mechanism to skip modules for selected architectures 2018-09-21 15:50:06 +02:00
1499 changed files with 46947 additions and 76298 deletions

View File

@@ -1,18 +1,11 @@
# Appveyor configuration file for EPICS Base 7 builds
# (see also https://github.com/epics-base/ci-scripts)
# AppVeyor configuration for EPICS Base
# Ralph Lange <ralph.lange@gmx.de>
# Copyright (c) 2016-2017 ITER Organization
# Version format
version: base-{branch}-{build}
#---------------------------------#
# build cache #
#---------------------------------#
# The AppVeyor cache allowance is way too small (1GB per account across all projects, branches and jobs)
# to be used for the dependency builds.
cache:
- C:\Users\appveyor\.tools
#---------------------------------#
# repository cloning #
#---------------------------------#
@@ -23,14 +16,20 @@ init:
- git config --global core.autocrlf true
# Set clone depth (do not fetch complete history)
clone_depth: 5
clone_depth: 50
# Skipping commits affecting only specific files
skip_commits:
files:
- 'documentation/*'
- 'templates/*'
- '**/*.html'
- '**/*.md'
#---------------------------------#
# build matrix configuration #
#---------------------------------#
image: Visual Studio 2015
# Build Configurations: dll/static, regular/debug
configuration:
- dynamic
@@ -38,51 +37,34 @@ configuration:
- dynamic-debug
- static-debug
# Environment variables: compiler toolchain, base version, setup file, ...
# Environment variables: compiler toolchain
environment:
# common / default variables for all jobs
SETUP_PATH: .ci-local:.ci
BASE: SELF
EPICS_TEST_IMPRECISE_TIMING: YES
matrix:
- CMP: vs2019
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
- CMP: vs2017
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
- CMP: vs2015
- CMP: vs2013
- CMP: vs2012
- CMP: vs2010
- CMP: gcc
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
# TODO: static linking w/ readline isn't working. Bypass auto-detect
COMMANDLINE_LIBRARY: EPICS
- TOOLCHAIN: 10.0
- TOOLCHAIN: 11.0
- TOOLCHAIN: 12.0
- TOOLCHAIN: 14.0
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
TOOLCHAIN: 2017
- TOOLCHAIN: cygwin
- TOOLCHAIN: mingw
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
# Platform: processor architecture
# Platform: architecture
platform:
- x86
- x64
# Matrix configuration: exclude sets of jobs
# Matrix configuration: allow specific failing jobs
matrix:
exclude:
# VS2012 and older installs don't have the 64 bit compiler
# VS Express installs don't have the 64 bit compiler
- platform: x64
CMP: vs2012
- platform: x64
CMP: vs2010
# Exclude more jobs to reduce build time
# Skip 32-bit for "middle-aged" compilers
- platform: x86
CMP: vs2017
- platform: x86
CMP: vs2015
# MinGW debug builds use the same libraries, unlike VS
- configuration: dynamic-debug
CMP: gcc
TOOLCHAIN: 10.0
# Cygwin static-debug has compiler problems
- configuration: static-debug
CMP: gcc
TOOLCHAIN: cygwin
#---------------------------------#
# building & testing #
@@ -90,38 +72,13 @@ matrix:
install:
- cmd: git submodule update --init --recursive
- cmd: pip install git+https://github.com/mdavidsaver/ci-core-dumper#egg=ci-core-dumper
- cmd: python .ci/cue.py prepare
- cmd: .ci/appveyor-prepare.bat
build_script:
- cmd: python .ci/cue.py build
- cmd: .ci/appveyor-make.bat
test_script:
- cmd: python -m ci_core_dumper install
- cmd: python .ci/cue.py -T 20M test
on_finish:
- ps: Get-ChildItem *.tap -Recurse -Force | % { Push-AppveyorArtifact $_.FullName -FileName $_.Name }
- cmd: python .ci/cue.py -T 5M test-results
on_failure:
- cmd: python -m ci_core_dumper report
#---------------------------------#
# debugging #
#---------------------------------#
## if you want to connect by remote desktop to a failed build, uncomment these lines
## note that you will need to connect within the usual build timeout limit (60 minutes)
## so you may want to adjust the build matrix above to just build the one of interest
# print the connection info
#init:
# - ps: iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
# block a failed build (until the watchdog barks)
#on_failure:
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
- cmd: .ci/appveyor-make.bat runtests
#---------------------------------#
# notifications #

View File

@@ -1,144 +0,0 @@
# Appveyor configuration file for EPICS Base 7 builds
# (see also https://github.com/epics-base/ci-scripts)
# branches to build
branches:
# whitelist
only:
- 7.0
- /R7\.0\.\d+.*/
# Version format
version: base-{branch}-{build}
#---------------------------------#
# build cache #
#---------------------------------#
# The AppVeyor cache allowance is way too small (1GB per account across all projects, branches and jobs)
# to be used for the dependency builds.
cache:
- C:\Users\appveyor\.tools
#---------------------------------#
# repository cloning #
#---------------------------------#
# Called at very beginning, before repo cloning
init:
# Set autocrlf to make batch files work
- git config --global core.autocrlf true
# Set clone depth (do not fetch complete history)
clone_depth: 5
#---------------------------------#
# build matrix configuration #
#---------------------------------#
image: Visual Studio 2015
# Build Configurations: dll/static, regular/debug
configuration:
- dynamic
- static
- dynamic-debug
- static-debug
# Environment variables: compiler toolchain, base version, setup file, ...
environment:
# common / default variables for all jobs
SETUP_PATH: .ci-local:.ci
BASE: SELF
EPICS_TEST_IMPRECISE_TIMING: YES
matrix:
- CMP: vs2019
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
- CMP: vs2017
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
- CMP: vs2015
- CMP: vs2013
- CMP: vs2012
- CMP: vs2010
- CMP: gcc
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
# TODO: static linking w/ readline isn't working. Bypass auto-detect
COMMANDLINE_LIBRARY: EPICS
# Platform: processor architecture
platform:
- x86
- x64
# Matrix configuration: exclude sets of jobs
matrix:
exclude:
# VS2012 and older installs don't have the 64 bit compiler
- platform: x64
CMP: vs2012
- platform: x64
CMP: vs2010
# Exclude more jobs to reduce build time
# Skip 32-bit for "middle-aged" compilers
- platform: x86
CMP: vs2017
- platform: x86
CMP: vs2015
# MinGW debug builds use the same libraries, unlike VS
- configuration: dynamic-debug
CMP: gcc
- configuration: static-debug
CMP: gcc
#---------------------------------#
# building & testing #
#---------------------------------#
install:
- cmd: git submodule update --init --recursive
- cmd: pip install git+https://github.com/mdavidsaver/ci-core-dumper#egg=ci-core-dumper
- cmd: python .ci/cue.py prepare
build_script:
- cmd: python .ci/cue.py build
test_script:
- cmd: python -m ci_core_dumper install
- cmd: python .ci/cue.py -T 20M test
on_finish:
- ps: Get-ChildItem *.tap -Recurse -Force | % { Push-AppveyorArtifact $_.FullName -FileName $_.Name }
- cmd: python .ci/cue.py -T 5M test-results
on_failure:
- cmd: python -m ci_core_dumper report
#---------------------------------#
# debugging #
#---------------------------------#
## if you want to connect by remote desktop to a failed build, uncomment these lines
## note that you will need to connect within the usual build timeout limit (60 minutes)
## so you may want to adjust the build matrix above to just build the one of interest
# print the connection info
#init:
# - ps: iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
# block a failed build (until the watchdog barks)
#on_failure:
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
#---------------------------------#
# notifications #
#---------------------------------#
notifications:
- provider: Email
to:
- core-talk@aps.anl.gov
on_build_success: false
- provider: GitHubPullRequest

1
.ci

Submodule .ci deleted from 130e88b709

137
.ci/appveyor-make.bat Normal file
View File

@@ -0,0 +1,137 @@
:: Universal build script for AppVeyor (https://ci.appveyor.com/)
:: Environment:
:: TOOLCHAIN - toolchain version [10.0/11.0/12.0/14.0/2017/cygwin/mingw]
:: CONFIGURATION - determines EPICS build [dynamic/static]
:: PLATFORM - architecture [x86/x64]
::
:: All command line args are passed to make
Setlocal EnableDelayedExpansion
set "ST="
if /i "%CONFIGURATION%"=="static" set ST=-static
set OS=64BIT
if "%PLATFORM%"=="x86" set OS=32BIT
echo [INFO] Platform: %OS%
:: Use parallel make, except for 3.14
set "MAKEARGS=-j2 -Otarget"
if "%APPVEYOR_REPO_BRANCH%"=="3.14" set MAKEARGS=
if "%TOOLCHAIN%"=="cygwin" (
set "MAKE=make"
if "%OS%"=="64BIT" (
set "EPICS_HOST_ARCH=cygwin-x86_64"
set "INCLUDE=C:\cygwin64\include;%INCLUDE%"
set "PATH=C:\cygwin64\bin;%PATH%"
echo [INFO] Cygwin Toolchain 64bit
) else (
set "EPICS_HOST_ARCH=cygwin-x86"
set "INCLUDE=C:\cygwin\include;%INCLUDE%"
set "PATH=C:\cygwin\bin;%PATH%"
echo [INFO] Cygwin Toolchain 32bit
)
echo [INFO] Compiler Version
gcc -v
goto Finish
)
if "%TOOLCHAIN%"=="mingw" (
set "MAKE=mingw32-make"
if "%OS%"=="64BIT" (
set "EPICS_HOST_ARCH=windows-x64-mingw"
set "INCLUDE=C:\mingw-w64\x86_64-8.1.0-posix-seh-rt_v6-rev0\mingw64\include;%INCLUDE%"
set "PATH=C:\mingw-w64\x86_64-8.1.0-posix-seh-rt_v6-rev0\mingw64\bin;%PATH%"
echo [INFO] MinGW Toolchain 64bit
) else (
set "EPICS_HOST_ARCH=win32-x86-mingw"
set "INCLUDE=C:\mingw-w64\i686-6.3.0-posix-dwarf-rt_v5-rev1\mingw32\include;%INCLUDE%"
set "PATH=C:\mingw-w64\i686-6.3.0-posix-dwarf-rt_v5-rev1\mingw32\bin;%PATH%"
echo [INFO] MinGW Toolchain 32bit
)
echo [INFO] Compiler Version
gcc -v
goto Finish
)
set "VSINSTALL=C:\Program Files (x86)\Microsoft Visual Studio %TOOLCHAIN%"
if not exist "%VSINSTALL%\" set "VSINSTALL=C:\Program Files (x86)\Microsoft Visual Studio\%TOOLCHAIN%\Community"
if not exist "%VSINSTALL%\" goto MSMissing
set "MAKE=C:\tools\make"
echo [INFO] APPVEYOR_BUILD_WORKER_IMAGE=%APPVEYOR_BUILD_WORKER_IMAGE%
if "%OS%"=="64BIT" (
set EPICS_HOST_ARCH=windows-x64%ST%
:: VS 2017
if exist "%VSINSTALL%\VC\Auxiliary\Build\vcvars64.bat" (
call "%VSINSTALL%\VC\Auxiliary\Build\vcvars64.bat"
where cl
if !ERRORLEVEL! NEQ 0 goto MSMissing
goto MSFound
)
if exist "%VSINSTALL%\VC\vcvarsall.bat" (
call "%VSINSTALL%\VC\vcvarsall.bat" amd64
where cl
if !ERRORLEVEL! NEQ 0 (
call "%VSINSTALL%\VC\vcvarsall.bat" x86_amd64
where cl
if !ERRORLEVEL! NEQ 0 goto MSMissing
)
goto MSFound
)
if exist "%VSINSTALL%\VC\bin\amd64\vcvars64.bat" (
call "%VSINSTALL%\VC\bin\amd64\vcvars64.bat"
where cl
if !ERRORLEVEL! NEQ 0 goto MSMissing
goto MSFound
)
) else (
set EPICS_HOST_ARCH=win32-x86%ST%
:: VS 2017
if exist "%VSINSTALL%\VC\Auxiliary\Build\vcvars32.bat" (
call "%VSINSTALL%\VC\Auxiliary\Build\vcvars32.bat"
where cl
if !ERRORLEVEL! NEQ 0 goto MSMissing
goto MSFound
)
if exist "%VSINSTALL%\VC\vcvarsall.bat" (
call "%VSINSTALL%\VC\vcvarsall.bat" x86
where cl
if !ERRORLEVEL! NEQ 0 goto MSMissing
goto MSFound
)
if exist "%VSINSTALL%\VC\bin\vcvars32.bat" (
call "%VSINSTALL%\VC\bin\vcvars32.bat"
where cl
if !ERRORLEVEL! NEQ 0 goto MSMissing
goto MSFound
)
if exist "%VSINSTALL%\Common7\Tools\vsvars32.bat" (
call "%VSINSTALL%\Common7\Tools\vsvars32.bat"
where cl
if !ERRORLEVEL! NEQ 0 goto MSMissing
goto MSFound
)
)
:MSMissing
echo [INFO] Installation for MSVC Toolchain %TOOLCHAIN% / %OS% seems to be missing
exit 1
:MSFound
echo [INFO] Microsoft Visual Studio Toolchain %TOOLCHAIN%
echo [INFO] Compiler Version
cl
:Finish
echo [INFO] EPICS_HOST_ARCH: %EPICS_HOST_ARCH%
echo [INFO] Make version
%MAKE% --version
echo [INFO] Perl version
perl --version
%MAKE% %MAKEARGS% %*

63
.ci/appveyor-prepare.bat Normal file
View File

@@ -0,0 +1,63 @@
:: Build script for AppVeyor (https://ci.appveyor.com/)
:: Environment:
:: TOOLCHAIN - Toolchain Version [9.0/10.0/11.0/12.0/14.0/cygwin/mingw]
:: CONFIGURATION - determines EPICS build [dynamic/static, -debug]
:: PLATFORM - "x86" -> use 32bit architecture
::
:: Prepares an Appveyor build by excuting the following steps
:: - Set up configure\CONFIG_SITE for static vs. dynamic build
:: - Install Cygwin / Mingw (TOOLCHAIN setting) in the in the appropriate flavor
:: - Download and install Make-4.1 from EPICS download page
Setlocal EnableDelayedExpansion
set OS=64BIT
if "%PLATFORM%"=="x86" set OS=32BIT
echo [INFO] Platform: %OS%
if "%TOOLCHAIN%"=="cygwin" (
echo.%CONFIGURATION% | findstr /C:"static">nul && (
echo SHARED_LIBRARIES=NO>> configure\CONFIG_SITE
echo STATIC_BUILD=YES>> configure\CONFIG_SITE
echo [INFO] EPICS set up for static build
) || (
echo [INFO] EPICS set up for dynamic build
)
echo.%CONFIGURATION% | findstr /C:"debug">nul && (
echo HOST_OPT=NO>> configure\CONFIG_SITE
echo [INFO] EPICS set up for debug build
) || (
echo [INFO] EPICS set up for optimized build
)
if "%OS%"=="64BIT" (
echo [INFO] Installing Cygwin 64bit and dependencies
@powershell -Command "(new-object net.webclient).DownloadFile('http://www.cygwin.com/setup-x86_64.exe', 'C:\cygwin64\setup-x86_64.exe')"
C:\cygwin64\setup-x86_64.exe -q -P "libreadline-devel,libncursesw-devel"
) else (
echo [INFO] Installing Cygwin 32bit and dependencies
@powershell -Command "(new-object net.webclient).DownloadFile('http://www.cygwin.com/setup-x86.exe', 'C:\cygwin\setup-x86.exe')"
C:\cygwin\setup-x86.exe -q -P "libreadline-devel,libncursesw-devel"
)
)
if "%TOOLCHAIN%"=="mingw" (
echo.%CONFIGURATION% | findstr /C:"static">nul && (
echo SHARED_LIBRARIES=NO>> configure\CONFIG_SITE
echo STATIC_BUILD=YES>> configure\CONFIG_SITE
echo [INFO] EPICS set up for static build
) || (
echo [INFO] EPICS set up for dynamic build
)
echo.%CONFIGURATION% | findstr /C:"debug">nul && (
echo HOST_OPT=NO>> configure\CONFIG_SITE
echo [INFO] EPICS set up for debug build
) || (
echo [INFO] EPICS set up for optimized build
)
)
echo [INFO] Installing Make 4.2.1 from ANL web site
curl -fsS --retry 3 -o C:\tools\make-4.2.1.zip https://epics.anl.gov/download/tools/make-4.2.1-win64.zip
cd \tools
"C:\Program Files\7-Zip\7z" e make-4.2.1.zip

8
.ci/checkout-modules.sh Executable file
View File

@@ -0,0 +1,8 @@
#!/bin/sh
#
# Checkout submodules on their appropriate branches
#
git submodule foreach '\
git checkout `git config -f $toplevel/.gitmodules submodule.$name.branch` && \
git pull '

77
.ci/travis-build.sh Executable file
View File

@@ -0,0 +1,77 @@
#!/bin/sh
set -e -x
die() {
echo "$1" >&2
exit 1
}
CACHEKEY=1
export EPICS_HOST_ARCH=`perl src/tools/EpicsHostArch.pl`
[ -e configure/os/CONFIG_SITE.Common.linux-x86 ] || die "Wrong location: $PWD"
case "$CMPLR" in
clang)
echo "Host compiler is clang"
cat << EOF >> configure/os/CONFIG_SITE.Common.$EPICS_HOST_ARCH
GNU = NO
CMPLR_CLASS = clang
CC = clang
CCC = clang++
EOF
;;
*) echo "Host compiler is default";;
esac
if [ "$STATIC" = "YES" ]
then
echo "Build static libraries/executables"
cat << EOF >> configure/CONFIG_SITE
SHARED_LIBRARIES=NO
STATIC_BUILD=YES
EOF
fi
# requires wine and g++-mingw-w64-i686
if [ "$WINE" = "32" ]
then
echo "Cross mingw32"
sed -i -e '/CMPLR_PREFIX/d' configure/os/CONFIG_SITE.linux-x86.win32-x86-mingw
cat << EOF >> configure/os/CONFIG_SITE.linux-x86.win32-x86-mingw
CMPLR_PREFIX=i686-w64-mingw32-
EOF
cat << EOF >> configure/CONFIG_SITE
CROSS_COMPILER_TARGET_ARCHS+=win32-x86-mingw
EOF
fi
# set RTEMS to eg. "4.9" or "4.10"
if [ -n "$RTEMS" ]
then
echo "Cross RTEMS${RTEMS} for pc386"
curl -L "https://github.com/mdavidsaver/rsb/releases/download/20171203-${RTEMS}/i386-rtems${RTEMS}-trusty-20171203-${RTEMS}.tar.bz2" \
| tar -C / -xmj
sed -i -e '/^RTEMS_VERSION/d' -e '/^RTEMS_BASE/d' configure/os/CONFIG_SITE.Common.RTEMS
cat << EOF >> configure/os/CONFIG_SITE.Common.RTEMS
RTEMS_VERSION=$RTEMS
RTEMS_BASE=$HOME/.rtems
EOF
cat << EOF >> configure/CONFIG_SITE
CROSS_COMPILER_TARGET_ARCHS += RTEMS-pc386-qemu
EOF
# find local qemu-system-i386
echo -n "Using QEMU: "
type qemu-system-i386 || echo "Missing qemu"
fi
make -j2 $EXTRA
if [ "$TEST" != "NO" ]
then
make -j2 tapfiles
make -s test-results
fi

View File

@@ -1,8 +0,0 @@
# Documentation for this file: https://EditorConfig.org
root = true
# Unix-style newlines ending every file,
# as some compilers complain about files not ending in newline
[*]
insert_final_newline = true

22
.gitattributes vendored
View File

@@ -1,25 +1,5 @@
.ci/ export-ignore
.tools/ export-ignore
.github/ export-ignore
.appveyor/ export-ignore
.appveyor.yml export-ignore
.travis.yml export-ignore
README export-subst
#Which files need CRLF handling
# default to automatic
* text=auto
# batch script parser on windows requires CRLF
*.bat text eol=crlf
# extensions for scripts which may be executable via. "#!..." must have LF
*.pl text eol=lf
*.plt text eol=lf
*.sh text eol=lf
*.cmd text eol=lf
# .cmd in unexpanded templates
*.cmd@* text eol=lf
# executable scripts w/o extensions
modules/ca/src/client/S99caRepeater@ text eol=lf
modules/libcom/src/log/S99logServer@ text eol=lf
startup/EpicsHostArch text eol=lf

View File

@@ -1,13 +0,0 @@
name: Check EditorConfig
on:
push:
pull_request:
jobs:
editorconfig:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: EditorConfig-Action
uses: greut/eclint-action@v0

View File

@@ -1,301 +0,0 @@
# .github/workflows/ci-scripts-build.yml for use with EPICS Base ci-scripts
# (see: https://github.com/epics-base/ci-scripts)
# This is YAML - indentation levels are crucial
# Workflow name, shared by all branches
name: Base
# Trigger on pushes and PRs to any branch
on:
push:
paths-ignore:
- 'documentation/*'
- 'startup/*'
- '.appveyor/*'
- '.tools/*'
- '.lgtm.yml'
- '.gitattributes'
- '**/*.html'
- '**/*.md'
pull_request:
paths-ignore:
- 'documentation/*'
- 'startup/*'
- '.appveyor/*'
- '.tools/*'
- '.lgtm.yml'
- '.gitattributes'
- '**/*.html'
- '**/*.md'
env:
SETUP_PATH: .ci-local:.ci
BASE: SELF
EPICS_TEST_IMPRECISE_TIMING: YES
jobs:
native:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
# Set environment variables from matrix parameters
env:
CMP: ${{ matrix.cmp }}
BCFG: ${{ matrix.configuration }}
CI_CROSS_TARGETS: ${{ matrix.cross }}
EXTRA: ${{ matrix.extra }}
TEST: ${{ matrix.test }}
strategy:
fail-fast: false
matrix:
# Job names also name artifacts, character limitations apply
include:
- os: ubuntu-22.04
cmp: gcc-12
name: "Ub-22 gcc-12 c++20 Werror"
# Turn all warnings into errors,
# except for those we could not fix (yet).
# Remove respective -Wno-error=... flag once it is fixed.
extra: "CMD_CXXFLAGS=-std=c++20
CMD_CPPFLAGS='-fdiagnostics-color
-Werror
-Wno-error=deprecated-declarations
-Wno-error=stringop-truncation
-Wno-error=restrict
-Wno-error=sizeof-pointer-memaccess
-Wno-error=nonnull
-Wno-error=dangling-pointer
-Wno-error=format-overflow
-Wno-error=format-security
-Wno-error=stringop-overread'"
- os: ubuntu-20.04
cmp: gcc
configuration: default
cross: "windows-x64-mingw"
name: "Ub-20 gcc-9 + MinGW"
- os: ubuntu-20.04
cmp: gcc
configuration: static
cross: "windows-x64-mingw"
name: "Ub-20 gcc-9 + MinGW, static"
- os: ubuntu-20.04
cmp: gcc
configuration: static
extra: "CMD_CXXFLAGS=-std=c++11"
name: "Ub-20 gcc-9 C++11, static"
- os: ubuntu-20.04
cmp: gcc
configuration: static
extra: "CMD_CFLAGS=-funsigned-char CMD_CXXFLAGS=-funsigned-char"
name: "Ub-20 gcc-9 unsigned char"
- os: ubuntu-20.04
cmp: clang
configuration: default
name: "Ub-20 clang-10"
- os: ubuntu-20.04
cmp: clang
configuration: default
extra: "CMD_CXXFLAGS=-std=c++11"
name: "Ub-20 clang-10 C++11"
- os: ubuntu-20.04
cmp: gcc
configuration: default
cross: "RTEMS-pc686-qemu@5"
name: "Ub-20 gcc-9 + RT-5.1 pc686"
- os: ubuntu-20.04
cmp: gcc
configuration: default
cross: "RTEMS-beatnik@5"
test: NO
name: "Ub-20 gcc-9 + RT-5.1 beatnik"
- os: ubuntu-20.04
cmp: gcc
configuration: default
cross: "RTEMS-xilinx_zynq_a9_qemu@5"
test: NO
name: "Ub-20 gcc-9 + RT-5.1 xilinx_zynq_a9_qemu"
- os: ubuntu-20.04
cmp: gcc
configuration: default
cross: "RTEMS-uC5282@5"
test: NO
name: "Ub-20 gcc-9 + RT-5.1 uC5282"
- os: ubuntu-20.04
cmp: gcc
configuration: default
name: "Ub-20 gcc-9 + RT-4.10"
cross: "RTEMS-pc386-qemu@4.10"
test: NO
- os: ubuntu-20.04
cmp: gcc
configuration: default
name: "Ub-20 gcc-9 + RT-4.9"
cross: "RTEMS-pc386-qemu@4.9"
- os: macos-latest
cmp: clang
configuration: default
name: "MacOS clang-12"
- os: windows-2019
cmp: vs2019
configuration: debug
name: "Win2019 MSC-19"
extra: "CMD_CXXFLAGS=-analysis"
- os: windows-2019
cmp: vs2019
configuration: static-debug
name: "Win2019 MSC-19, static"
extra: "CMD_CXXFLAGS=-analysis"
- os: windows-2019
cmp: vs2019
configuration: debug
name: "Win2019 MSC-19, debug"
- os: windows-2019
cmp: gcc
configuration: default
name: "Win2019 mingw"
# Cross builds
- os: ubuntu-latest
cmp: gcc
configuration: default
name: "Cross linux-aarch64"
cross: linux-aarch64
- os: ubuntu-latest
cmp: gcc
configuration: default
name: "Cross linux-arm gnueabi"
cross: linux-arm@arm-linux-gnueabi
- os: ubuntu-latest
cmp: gcc
configuration: default
name: "Cross linux-arm gnueabihf"
cross: linux-arm@arm-linux-gnueabihf
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Automatic core dumper analysis
uses: mdavidsaver/ci-core-dumper@master
- name: "apt-get install"
run: |
sudo apt-get update
sudo apt-get -y install qemu-system-x86 g++-mingw-w64-x86-64 gdb
if: runner.os == 'Linux'
- name: Prepare and compile dependencies
run: python .ci/cue.py prepare
- name: Build main module
run: python .ci/cue.py build
- name: Run main module tests
run: python .ci/cue.py -T 60M test
- name: Upload tapfiles Artifact
if: ${{ always() }}
uses: actions/upload-artifact@v3
with:
name: tapfiles ${{ matrix.name }}
path: '**/O.*/*.tap'
if-no-files-found: ignore
- name: Collect and show test results
if: ${{ always() }}
run: python .ci/cue.py -T 5M test-results
docker:
name: ${{ matrix.name }}
runs-on: ubuntu-latest
container:
image: ${{ matrix.image }}
# Set environment variables from matrix parameters
env:
CMP: ${{ matrix.cmp }}
BCFG: ${{ matrix.configuration }}
EXTRA: ${{ matrix.extra }}
TEST: ${{ matrix.test }}
strategy:
fail-fast: false
matrix:
# Job names also name artifacts, character limitations apply
include:
- name: "CentOS-7"
image: centos:7
cmp: gcc
configuration: default
- name: "Fedora-33"
image: fedora:33
cmp: gcc
configuration: default
- name: "Fedora-latest"
image: fedora:latest
cmp: gcc
configuration: default
steps:
- name: "Build newer Git"
# actions/checkout@v2 wants git >=2.18
# centos:7 has 1.8
if: matrix.image=='centos:7'
run: |
yum -y install curl make gcc curl-devel expat-devel gettext-devel openssl-devel zlib-devel perl-ExtUtils-MakeMaker
curl https://mirrors.edge.kernel.org/pub/software/scm/git/git-2.29.0.tar.gz | tar -xz
cd git-*
make -j2 prefix=/usr/local all
make prefix=/usr/local install
cd ..
rm -rf git-*
type -a git
git --version
- name: "Redhat setup"
run: |
dnfyum() {
dnf -y "$@" || yum -y "$@"
return $?
}
dnfyum install python3 gdb make perl gcc-c++ glibc-devel readline-devel ncurses-devel perl-devel perl-Test-Simple
git --version || dnfyum install git
# rather than just bite the bullet and link python3 -> python,
# people would rather just break all existing scripts...
[ -e /usr/bin/python ] || ln -sf python3 /usr/bin/python
python --version
- uses: actions/checkout@v3
with:
submodules: true
- name: Automatic core dumper analysis
uses: mdavidsaver/ci-core-dumper@master
- name: Prepare and compile dependencies
run: python .ci/cue.py prepare
- name: Build main module
run: python .ci/cue.py build
- name: Run main module tests
run: python .ci/cue.py -T 20M test
- name: Upload tapfiles Artifact
if: ${{ always() }}
uses: actions/upload-artifact@v3
with:
name: tapfiles ${{ matrix.name }}
path: '**/O.*/*.tap'
if-no-files-found: ignore
- name: Collect and show test results
if: ${{ always() }}
run: python .ci/cue.py -T 5M test-results

4
.gitignore vendored
View File

@@ -11,10 +11,6 @@
/modules/Makefile.local
O.*/
/QtC-*
/.qtc_*
/.vscode/
*.orig
*.log
.*.swp
.DS_Store
.iocsh_history

7
.gitmodules vendored
View File

@@ -22,7 +22,6 @@
path = modules/pva2pva
url = https://github.com/epics-base/pva2pva
branch = master
[submodule ".ci"]
path = .ci
url = https://github.com/epics-base/ci-scripts
branch = master
[submodule "modules/pcas"]
path = modules/pcas
url = https://github.com/epics-modules/pcas

View File

@@ -1,50 +0,0 @@
# Configuration for lgtm.com
#
path_classifiers:
test:
- exclude: /
- test
- "modules/*/test*"
library:
- modules/libcom/src/yacc
- modules/libcom/src/flex
template:
- src/template
- modules/ca/src/template
- modules/database/src/template
extraction:
cpp:
prepare:
packages:
- "libreadline-dev"
index:
build_command:
- "g++ --version"
- "make --version"
- "perl --version"
- "make -sj2 || echo '*** Build failed, ignored for lgtm ***'"
python:
index:
include:
- src/tools
# Interpreted languages to be excluded
javascript:
index:
exclude:
- "*"
# Compiled languages to be excluded
java:
index:
build_command: "echo No Java code in this project"
csharp:
index:
build_command: "echo No C# code in this project"
go:
index:
build_command: "echo No Go code in this project"

View File

@@ -1,102 +0,0 @@
#!/usr/bin/env python3
import logging
import sys
import re
from io import StringIO
_log = logging.getLogger(__name__)
def main(args):
logging.basicConfig(level=args.level)
if args.dev is True:
actions=[
('DEVELOPMENT_FLAG', '1'),
('DEV_SNAPSHOT', '-DEV'),
]
elif args.dev is False:
actions=[
('DEVELOPMENT_FLAG', '0'),
('DEV_SNAPSHOT', ''),
]
elif args.version:
M=re.match(r'R?(\d+).(\d+).(\d+)(?:.(\d+))?(-.*)?', args.version)
actions=[
('SITE_VERSION', None),
('SHORT_VERSION', None),
('MINOR_VERSION', M[2]),
('REVISION', M[2]),
('MODIFICATION', M[3]),
('MAINTENANCE_VERSION', M[3]),
('PATCH_LEVEL', M[4] or '0'),
('DEVELOPMENT_FLAG', '1' if (M[5] or '').upper().endswith('-DEV') else '0'),
('DEV_SNAPSHOT', M[5] or ''),
('MAJOR_VERSION', M[1]),
('VERSION', M[1]), # plain _VERSION must be last to resolve ambiguity
]
elif args.dry_run:
_log.debug('Print existing')
for fname in args.conf:
print('# ', fname)
with open(fname, 'r') as F:
sys.stdout.write(F.read())
return
else:
print('One of --version, --release, --dev, or --dry-run is required')
sys.exit(1)
for name, val in actions:
_log.debug('Pattern "%s" -> "%s"', name, val)
for fname in args.conf:
OUT=StringIO()
with open(fname, 'r') as F:
for line in F:
_log.debug('Line: %s', repr(line))
for name, val in actions:
M = re.match(r'(\s*[A-Z_]+' + name + r'\s*=[\t ]*)(\S*)(\s*)', line)
if M and val is None:
_log.debug('Ignore')
OUT.write(line)
break
elif M:
_log.debug(' Match %s -> %s', M.re.pattern, M.groups())
OUT.write(M[1]+val+M[3])
break
else:
_log.debug('No match')
OUT.write(line)
if args.dry_run:
print('# ', fname)
print(OUT.getvalue())
else:
with open(fname, 'w') as F:
F.write(OUT.getvalue())
def getargs():
from argparse import ArgumentParser
P = ArgumentParser()
P.add_argument('-n','--dry-run', action='store_true', default=False)
P.add_argument('-d','--debug', dest='level', action='store_const',
const=logging.DEBUG, default=logging.INFO)
P.add_argument('-V', '--version', help='A version in R1.2.3-xyz or 1.2.3 form')
P.add_argument('-D', '--dev', action='store_true', default=None)
P.add_argument('-R', '--release', dest='dev', action='store_false')
P.add_argument('conf', nargs='+',
help='A configure/CONFIG_*_VERSION file name')
return P
if __name__=='__main__':
main(getargs().parse_args())

View File

@@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/sh
#
# Make tar for git repo w/ one level of sub modules.
#
@@ -9,52 +9,24 @@ die() {
exit 1
}
maybedie() {
if [ "$DEVMODE" ]; then
echo "Warning: $1" >&2
else
echo "Error: $1" >&2
exit 1
fi
}
TOPREV="$1"
FINALTAR="$2"
PREFIX="$3"
usage() {
if ! [ "$TOPREV" ]
then
cat <<EOF >&2
usage: $0 [-v] [-d] <rev> [<outfile> [<prefix>]]
usage: $0 <rev> [<outfile> [<prefix>]]
<rev> may be any git revision spec. (tag or, using -d, branch or commit id).
<rev> may be any git revision spec. (tag, branch, or commit id).
If provided, <outfile> must end with ".tar", ".tar.gz" or ".tar.bz2".
If <outfile> is omitted, "base-<rev>.tar.gz" will be used.
If provided, <prefix> must end with "/". If <prefix> is omitted,
the default is "base-<rev>/".
Options:
-v Enable verbose prints
-d Enable permissive developer mode
EOF
exit 1
}
export DEVMODE=
while getopts "vd" OPT
do
case "$OPT" in
v) set -x;;
d) DEVMODE=1;;
?) echo "Unknown option"
usage;;
esac
done
shift $(($OPTIND - 1))
TOPREV="$1"
FINALTAR="$2"
PREFIX="${3:-}"
[ "$TOPREV" ] || usage
fi
case "$FINALTAR" in
"")
@@ -87,13 +59,16 @@ case "$PREFIX" in
esac
# Check for both <tag> and R<tag>
if ! [ `git tag -l $TOPREV` ]
if [ "$TOPREV" = "HEAD" ]
then
true
elif ! [ `git tag -l $TOPREV` ]
then
if [ `git tag -l R$TOPREV` ]
then
TOPREV="R$TOPREV"
else
maybedie "No tags exist '$TOPREV' or 'R$TOPREV'"
die "No tags exist '$TOPREV' or 'R$TOPREV'"
fi
fi
@@ -114,17 +89,11 @@ git archive --prefix=$PREFIX $TOPREV | tar -C "$TDIR"/tar -x
#
# sub-modules appear in tree as eg.:
# 160000 commit c3a6cfcf0dad4a4eeecf59b474710d06ff3eb68a modules/ca
git ls-tree -r $TOPREV | \
awk '/^[0-9]+ commit / && $4 != ".ci" {print $3, $4}' | \
git ls-tree -r $TOPREV | awk '/^[0-9]+ commit / {print $3, $4}' | \
while read HASH MODDIR
do
echo "Visiting $HASH $MODDIR"
if [ -e $MODDIR/.git ]
then
git -C $MODDIR archive --prefix=${PREFIX}${MODDIR}/ $HASH | tar -C "$TDIR"/tar -x
else
maybedie " Submodule not checked out."
fi
git -C $MODDIR archive --prefix=${PREFIX}${MODDIR}/ $HASH | tar -C "$TDIR"/tar -x
done
# make a list of files copied and filter out undesirables
@@ -136,19 +105,13 @@ sed -i -e 's|^\./||' "$TDIR"/list.1
# Exclude files
sed \
-e '/\/\.ci\//d' \
-e '/\/\.ci-local\//d' \
-e '/\/\.\?ci\//d' \
-e '/\/\.tools\//d' \
-e '/\/jenkins\//d' \
-e '/\/\.github\//d' \
-e '/\/\.gitmodules$/d' \
-e '/\/\.hgtags$/d' \
-e '/\/\.cproject$/d' \
-e '/\/\.git/d' \
-e '/\/\.project$/d' \
-e '/\/\.lgtm\.yml$/d' \
-e '/\/\.travis\.yml$/d' \
-e '/\/\.appveyor\.yml$/d' \
-e '/\/\.readthedocs\.yml$/d' \
"$TDIR"/list.1 > "$TDIR"/list.2
if ! diff -U 0 "$TDIR"/list.1 "$TDIR"/list.2
@@ -166,5 +129,5 @@ tar -t $TAROPT -f "$FINALTAR" > "$TDIR"/list.3
# make sure we haven't picked up anything extra
if ! diff -u "$TDIR"/list.2 "$TDIR"/list.3
then
die "Oops! Tarfile diff against plan shown above"
echo "Oops! Tarfile diff against plan shown above"
fi

27
.travis.yml Normal file
View File

@@ -0,0 +1,27 @@
sudo: false
dist: trusty
language: c
compiler:
- gcc
addons:
apt:
packages:
- libreadline6-dev
- libncurses5-dev
- perl
- clang
- g++-mingw-w64-i686
- qemu-system-x86
script:
- .ci/travis-build.sh
env:
- CMPLR=gcc
- CMPLR=clang
- CMPLR=gcc STATIC=YES
- CMPLR=clang STATIC=YES
- CMPLR=gcc EXTRA=CMD_CXXFLAGS=-std=c++11
- CMPLR=clang EXTRA=CMD_CXXFLAGS=-std=c++11
- WINE=32 TEST=NO STATIC=YES
- WINE=32 TEST=NO STATIC=NO
- RTEMS=4.10 TEST=YES
- RTEMS=4.9 TEST=YES

View File

@@ -23,3 +23,10 @@ DIRS += modules
modules_DEPEND_DIRS = src
include $(TOP)/configure/RULES_TOP
UNINSTALL_DIRS += $(INSTALL_LOCATION)/src
copysrc:
tar cf - --exclude-vcs --exclude-backups --exclude=O.* modules/*/src | tar xf - -C $(INSTALL_LOCATION)
tar:
tar cfjP epics_base-$(EPICS_VERSION_NUMBER).tar.bz2 $(INSTALL_LOCATION)

View File

@@ -16,10 +16,6 @@ ifneq ($(wildcard $(TOP)/configure/CONFIG_BASE_VERSION),)
CONFIG = $(TOP)/configure
BASE_TOP=YES
else
ifneq ($(origin EPICS_BASE),file)
# Essential for the EPICS build system, see convertRelease.pl
$(error EPICS_BASE must be set in a configure/RELEASE file)
endif
CONFIG ?= $(EPICS_BASE)/configure
endif
@@ -34,11 +30,6 @@ ifeq ($(origin EPICS_HOST_ARCH), undefined)
EHA :=
endif
# Make Perl hash iteration reproducible.
# See: https://reproducible-builds.org/docs/stable-outputs/
#
export PERL_HASH_SEED = 0
-include $(CONFIG)/RELEASE
-include $(CONFIG)/RELEASE.$(EPICS_HOST_ARCH)
-include $(CONFIG)/RELEASE.$(EPICS_HOST_ARCH).Common
@@ -67,13 +58,10 @@ include $(CONFIG)/CONFIG_BASE_VERSION
include $(CONFIG)/os/CONFIG.$(EPICS_HOST_ARCH).Common
-include $(CONFIG)/os/CONFIG_SITE.$(EPICS_HOST_ARCH).Common
# Parse configure/RELEASE to find all upstream modules
RELEASE_TOPS := $(shell $(CONVERTRELEASE) -T $(TOP) releaseTops)
ifdef T_A
# Information from the target's compiler
#
-include $(EPICS_BASE)/cfg/TOOLCHAIN.$(EPICS_HOST_ARCH).$(T_A)
# Cross compile specific definitions
#

View File

@@ -3,7 +3,8 @@
# National Laboratory.
# Copyright (c) 2002 The Regents of the University of California, as
# Operator of Los Alamos National Laboratory.
# EPICS Base is distributed subject to a Software License Agreement found
# EPICS BASE Versions 3.13.7
# and higher are distributed subject to a Software License Agreement found
# in file LICENSE that is included with this distribution.
#*************************************************************************
@@ -31,9 +32,9 @@ PROF_CFLAGS_YES = -p
GPROF_CFLAGS_YES = -pg
CODE_CFLAGS = $(PROF_CFLAGS_$(PROFILE)) $(GPROF_CFLAGS_$(GPROF))
CODE_CFLAGS += $(ASAN_FLAGS_$(ENABLE_ASAN))
WARN_CFLAGS_YES = -Wall -Werror-implicit-function-declaration
WARN_CFLAGS_YES = -Wall
WARN_CFLAGS_NO = -w
OPT_CFLAGS_YES = -O3
OPT_CFLAGS_YES = -O3 -g
OPT_CFLAGS_NO = -g
PROF_CXXFLAGS_YES = -p
@@ -42,22 +43,22 @@ CODE_CXXFLAGS = $(PROF_CXXFLAGS_$(PROFILE)) $(GPROF_CXXFLAGS_$(GPROF))
CODE_CXXFLAGS += $(ASAN_FLAGS_$(ENABLE_ASAN))
WARN_CXXFLAGS_YES = -Wall
WARN_CXXFLAGS_NO = -w
OPT_CXXFLAGS_YES = -O3
OPT_CXXFLAGS_YES = -O3 -g
OPT_CXXFLAGS_NO = -g
CODE_LDFLAGS = $(PROF_CXXFLAGS_$(PROFILE)) $(GPROF_CXXFLAGS_$(GPROF))
CODE_LDFLAGS += $(ASAN_LDFLAGS_$(ENABLE_ASAN))
OPT_LDFLAGS_NO = -g
PIPE_CFLAGS_YES_YES = -pipe
PIPE_CFLAGS = $(PIPE_CFLAGS_$(GCC_PIPE)_$(GNU))
PIPE_CXXFLAGS = $(PIPE_CFLAGS)
STATIC_LDFLAGS_YES = -static
STATIC_LDFLAGS_NO =
SHRLIB_CFLAGS = -fPIC
SHRLIB_LDFLAGS = -shared -fPIC -Wl,-h$@
LOADABLE_SHRLIB_LDFLAGS = -shared -fPIC -Wl,-h$@
SHRLIB_LDFLAGS = -shared -fPIC
LOADABLE_SHRLIB_LDFLAGS = -shared -fPIC
GNU_LDLIBS_YES = -lgcc

View File

@@ -31,29 +31,20 @@ endif # BASE_TOP
# Where to find the installed build tools
# Windows does not like commands with relative paths starting ../
# so TOOLS must be an absolute path, although Perl scripts are OK.
# FIND_TOOL is for scripts run before the build reaches src/tools
# and must also work in submodules when EPICS_BASE is not built.
# FIND_TOOL is for scripts run before the build reaches src/tools.
TOOLS = $(abspath $(EPICS_BASE_HOST_BIN))
FIND_TOOL = $(firstword $(wildcard $(TOOLS)/$(1) \
$(TOP)/src/tools/$(1)) $(EPICS_BASE)/src/tools/$(1))
#---------------------------------------------------------------
# Find Perl modules for dependencies
FIND_PM = $(wildcard $(EPICS_BASE)/lib/perl/$(1))
FIND_TOOL = $(firstword $(wildcard $(TOOLS)/$(1) $(EPICS_BASE)/src/tools/$(1)))
#---------------------------------------------------------------
# EPICS Base build tools and tool flags
PODTOHTML_pl = $(TOOLS)/podToHtml.pl
PODTOHTML_dep = $(PODTOHTML_pl) $(call FIND_PM,EPICS/PodHtml.pm)
PODTOHTML = $(PERL) $(PODTOHTML_pl)
PODTOHTML = $(PERL) $(TOOLS)/podToHtml.pl
CONVERTRELEASE = $(PERL) $(call FIND_TOOL,convertRelease.pl)
FULLPATHNAME = $(PERL) $(TOOLS)/fullPathName.pl
TAPTOJUNIT = $(PERL) $(TOOLS)/tap-to-junit-xml.pl
GENVERSIONHEADER = $(PERL) $(TOOLS)/genVersionHeader.pl $(QUIET_FLAG) $(QUESTION_FLAG)
MAKERPATH = $(PYTHON) $(TOOLS)/makeRPath.py
#---------------------------------------------------------------
# tools for installing libraries and products
INSTALL = $(PERL) $(TOOLS)/installEpics.pl $(QUIET_FLAG)
@@ -69,18 +60,3 @@ REPLACEVAR = $(PERL) $(TOOLS)/replaceVAR.pl
# tools for cleaning out unwanted files
CVSCLEAN = $(call FIND_TOOL,cvsclean.pl)
DEPCLEAN = $(call FIND_TOOL,depclean.pl)
#---------------------------------------------------------------
# Tools for testing
TAPS_FAILED_LOG = .taps-failed.log
TESTS_FAILED_LOG = .tests-failed.log
TESTS_FAILED_PATH = $(abspath $(TOP)/$(TESTS_FAILED_LOG))
TAPTOJUNIT = $(PERL) $(TOOLS)/tap-to-junit-xml.pl
PROVE = $(PERL) $(TOOLS)/epicsProve.pl --failures --color
PROVE.tap = $(PROVE) --ext .tap --exec "$(CAT)"
TESTFAILURES = $(PERL) $(TOOLS)/testFailures.pl
SHOWTESTFAILURES = $(TESTFAILURES) $(TESTS_FAILED_PATH) $(TAPS_FAILED_LOG)
PROVE_FAILURE = echo $(abspath .)>> $(TESTS_FAILED_PATH)
TAPFILE_FAILURE = echo $@>> $(TAPS_FAILED_LOG)

View File

@@ -48,15 +48,24 @@ EPICS_VERSION = 7
EPICS_REVISION = 0
# EPICS_MODIFICATION must be a number >=0 and <256
EPICS_MODIFICATION = 8
EPICS_MODIFICATION = 3
# EPICS_PATCH_LEVEL must be a number (win32 resource file requirement)
# Not included in the official EPICS version number if zero
EPICS_PATCH_LEVEL = 0
# Immediately after an official release the EPICS_PATCH_LEVEL is incremented
# and the -DEV suffix is added (similar to the Maven -SNAPSHOT versions)
# Between official releases, the EPICS_PATCH_LEVEL gets incremented
# and a -DEV suffix is added (similar to the Maven -SNAPSHOT versions)
EPICS_DEV_SNAPSHOT=
#EPICS_DEV_SNAPSHOT=-DEV
#EPICS_DEV_SNAPSHOT=-pre1
#EPICS_DEV_SNAPSHOT=-pre1-DEV
#EPICS_DEV_SNAPSHOT=-pre2
#EPICS_DEV_SNAPSHOT=-pre2-DEV
#EPICS_DEV_SNAPSHOT=-rc1
#EPICS_DEV_SNAPSHOT=-rc1-DEV
#EPICS_DEV_SNAPSHOT=-rc2
#EPICS_DEV_SNAPSHOT=-rc2-DEV
# No changes should be needed below here

View File

@@ -1,12 +0,0 @@
# Version number for the Channel Access API and shared library
EPICS_CA_MAJOR_VERSION = 4
EPICS_CA_MINOR_VERSION = 14
EPICS_CA_MAINTENANCE_VERSION = 3
# Development flag, set to zero for release versions
EPICS_CA_DEVELOPMENT_FLAG = 0
# Immediately after a release the MAINTENANCE_VERSION
# will be incremented and the DEVELOPMENT_FLAG set to 1

View File

@@ -38,8 +38,6 @@ BUILD_ARCHS = $(EPICS_HOST_ARCH) $(CROSS1) $(CROSS2)
# otherwise override this in os/CONFIG_SITE.<host_arch>.Common
PERL = perl -CSD
PYTHON = python
#-------------------------------------------------------
# Check configure/RELEASE file for consistency
CHECK_RELEASE_YES = checkRelease
@@ -56,7 +54,6 @@ GNU_DIR = /usr
# Directories
INSTALL_LOCATION = $(TOP)
INSTALL_ABSOLUTE = $(abspath $(INSTALL_LOCATION))
INSTALL_LOCATION_LIB = $(INSTALL_LOCATION)/lib
INSTALL_LOCATION_BIN = $(INSTALL_LOCATION)/bin
@@ -72,31 +69,21 @@ INSTALL_DBD = $(INSTALL_LOCATION)/dbd
INSTALL_DB = $(INSTALL_LOCATION)/db
INSTALL_CONFIG = $(INSTALL_LOCATION)/configure
#-------------------------------------------------------
# These are default settings that may be overridden later
# Directory for OS independant build created files
COMMON_DIR = ../O.Common
# Eventual install path (to be compiled into binaries)
FINAL_LOCATION = $(INSTALL_ABSOLUTE)
# IOC's view of install path
IOCS_APPL_TOP = $(INSTALL_ABSOLUTE)
# IOC's absolute path to $(TOP), may be overridden inside the application
IOCS_APPL_TOP = $(shell $(FULLPATHNAME) $(INSTALL_LOCATION))
#-------------------------------------------------------
# How to portably check the flags to make
makeflags := $(firstword $(filter-out -,$(filter-out --%,$(MAKEFLAGS))))
define checkflags
make-$1 := $(findstring $1,$(makeflags))
endef
# This is extensible to most single letter flags:
$(foreach flag,s q, $(eval $(call checkflags,$(flag))))
# Silent builds - suppress messages during 'make -s'
# Silencing the build - suppress messages during 'make -s'
NOP = :
ECHO = @$(if $(make-s),$(NOP),echo)
QUIET_FLAG := $(if $(make-s),-q,)
ECHO = @$(if $(findstring s,$(MFLAGS)),$(NOP),echo)
QUIET_FLAG := $(if $(findstring s,$(MFLAGS)),-q,)
#-------------------------------------------------------
# Convert 'make -q' flag into '-i' for genVersionHeader.pl
QUESTION_FLAG := $(if $(make-q),-i,)
QUESTION_FLAG := $(if $(findstring q,$(MFLAGS)),-i,)
#-------------------------------------------------------
ifdef T_A
@@ -142,8 +129,6 @@ LIB_SUFFIX =
SHRLIB_PREFIX = $(LIB_PREFIX)
DLLSTUB_PREFIX = $(LIB_PREFIX)
DLLSTUB_SUFFIX = $(LIB_SUFFIX)
LOADABLE_SHRLIB_PREFIX = $(SHRLIB_PREFIX)
LOADABLE_SHRLIB_SUFFIX = $(SHRLIB_SUFFIX)
BUILDLIB_PREFIX_YES = $(DLLSTUB_PREFIX)
BUILDLIB_PREFIX_NO = $(LIB_PREFIX)
@@ -155,23 +140,20 @@ BUILDLIB_SUFFIX = $(BUILDLIB_SUFFIX_$(SHARED_LIBRARIES))
#--------------------------------------------------
# vpath directories
POSIX_YES = os/posix
OS_IMPL_DIRS = $(if $(OS_API),os/$(OS_CLASS)-$(OS_API),) os/$(OS_CLASS)
GENERIC_SRC_DIRS = .. $(SRC_DIRS)
OS_SRC_DIRS += . $(foreach dir, .. $(SRC_DIRS), \
$(addprefix $(dir)/, $(OS_IMPL_DIRS) $(POSIX_$(POSIX)) os/default ))
$(addprefix $(dir)/, os/$(OS_CLASS) $(POSIX_$(POSIX)) os/default ))
CMPLR_SRC_DIRS += . $(foreach dir, .. $(SRC_DIRS), \
$(addprefix $(dir)/, compiler/$(CMPLR_CLASS) compiler/default ))
ALL_SRC_DIRS = $(CMPLR_SRC_DIRS) $(OS_SRC_DIRS) $(GENERIC_SRC_DIRS)
#--------------------------------------------------
# Directory for OS independant build created files
COMMON_DIR = ../O.Common
# compile line include directories
INSTALL_INCLUDE_DIRS = $(INSTALL_INCLUDE)/compiler/$(CMPLR_CLASS) \
$(INSTALL_INCLUDE)/os/$(OS_CLASS) $(INSTALL_INCLUDE)
INSTALL_INCLUDES += $(addprefix -I, $(INSTALL_INCLUDE_DIRS))
SRC_INCLUDES = $(addprefix -I, $(COMMON_DIR) $(wildcard $(ALL_SRC_DIRS)))
INSTALL_INCLUDES += \
-I$(INSTALL_INCLUDE)/compiler/$(CMPLR_CLASS) \
-I$(INSTALL_INCLUDE)/os/$(OS_CLASS) \
-I$(INSTALL_INCLUDE)
SRC_INCLUDES = -I$(COMMON_DIR) $(addprefix -I, $(wildcard $(ALL_SRC_DIRS)))
#--------------------------------------------------
# Target filename definitions
@@ -185,27 +167,23 @@ TESTSHRLIBNAME = $(TESTSHRLIBNAME_$(SHARED_LIBRARIES))
#--------------------------------------------------
# obj files
TARGET_OBJS = $($*_LDOBJS) $(addsuffix $(OBJ), \
$(basename $($*_OBJS) $($*_SRCS)))
TARGET_OBJS = $($*_LDOBJS) $(addsuffix $(OBJ),$(basename $($*_OBJS) $($*_SRCS)))
PRODUCT_OBJS = $(addsuffix $(OBJ), \
$(basename $(SRCS) $(USR_SRCS) $(PROD_SRCS) $(USR_OBJS) $(PROD_OBJS)))
PRODUCT_OBJS = $(addsuffix $(OBJ),$(basename $(SRCS) $(USR_SRCS) $(PROD_SRCS) $(USR_OBJS) $(PROD_OBJS)))
PROD_LD_OBJS = $(TARGET_OBJS) $(PRODUCT_OBJS)
LIBRARY_OBJS = $(addsuffix $(OBJ), \
$(basename $(SRCS) $(USR_SRCS) $(LIB_SRCS) $(LIBSRCS) $(USR_OBJS) $(LIB_OBJS)))
LIBRARY_OBJS = $(addsuffix $(OBJ),$(basename $(SRCS) $(USR_SRCS) $(LIB_SRCS) $(LIBSRCS) $(USR_OBJS) $(LIB_OBJS)))
LIBRARY_LD_OBJS = $(TARGET_OBJS) $(LIBRARY_OBJS)
#--------------------------------------------------
# Windows resource files
TARGET_RESS = $(if $(RES), $(addsuffix $(RES), $(basename $($*_RCS))))
TARGET_RESS = $(if $(RES),$(addsuffix $(RES),$(basename $($*_RCS))),)
PROD_RESS = $(if $(RES), $(addsuffix $(RES), $(basename $(RCS) $(PROD_RCS))))
PROD_RESS = $(if $(RES),$(addsuffix $(RES),$(basename $(RCS) $(PROD_RCS))),)
PROD_LD_RESS = $(TARGET_RESS) $(PROD_RESS)
LIBRARY_RESS = $(if $(RES), $(addsuffix $(RES), \
$(basename $(RCS) $(LIB_RCS) $(LIBRARY_RCS))))
LIBRARY_RESS = $(if $(RES),$(addsuffix $(RES),$(basename $(RCS) $(LIB_RCS) $(LIBRARY_RCS))),)
LIBRARY_LD_RESS = $(TARGET_RESS) $(LIBRARY_RESS)
#--------------------------------------------------
@@ -274,28 +252,27 @@ WARN_CXXFLAGS = $(WARN_CXXFLAGS_$($(BUILD_CLASS)_WARN))
OPT_CPPFLAGS = $(OPT_CPPFLAGS_$($(BUILD_CLASS)_OPT))
OPT_CFLAGS = $(OPT_CFLAGS_$($(BUILD_CLASS)_OPT))
OPT_CXXFLAGS = $(OPT_CXXFLAGS_$($(BUILD_CLASS)_OPT))
OPT_LDFLAGS = $(OPT_LDFLAGS_$($(BUILD_CLASS)_OPT))
# Static build flags
STATIC_CFLAGS = $(STATIC_CFLAGS_$(STATIC_BUILD))
STATIC_CXXFLAGS = $(STATIC_CXXFLAGS_$(STATIC_BUILD))
STATIC_CXXCFLAGS = $(STATIC_CXXFLAGS_$(STATIC_BUILD))
STATIC_LDFLAGS = $(STATIC_LDFLAGS_$(STATIC_BUILD))
STATIC_LDLIBS = $(STATIC_LDLIBS_$(STATIC_BUILD))
#--------------------------------------------------
# cflags for shared library src files
LIBRARY_SRCS = $(basename $(foreach lib, \
$(LIBRARY) $(TESTLIBRARY) $(LOADABLE_LIBRARY), \
$($(lib)_OBJSNAME) $(LIBRARY_OBJS)))
LIBRARY_SRC_CFLAGS = $(if $(findstring $*, $(LIBRARY_SRCS)), $(SHRLIB_CFLAGS))
# cflags for shared library src files (from SHRLIB_CFLAGS)
LIBRARY_SRCS=$(basename $(foreach lib,$(LIBRARY) $(TESTLIBRARY) $(LOADABLE_LIBRARY),$($(lib)_OBJSNAME) $(LIBRARY_OBJS)))
LIBRARY_SRC_CFLAGS=$($(patsubst $*,SHRLIB,$(findstring $*,$(LIBRARY_SRCS)))_CFLAGS)
#--------------------------------------------------
# ldflags for loadable and shared libraries
TARGET_LIB_LDFLAGS = $(if $(findstring $*, $(LOADABLE_LIBRARY)), \
$(LOADABLE_SHRLIB_LDFLAGS), $(SHRLIB_LDFLAGS))
# prefix, suffix, and ldflags for loadable shared libraries
TARGET_LIB_LDFLAGS=$($(patsubst $*,LOADABLE_,$(findstring $*,$(LOADABLE_LIBRARY)))SHRLIB_LDFLAGS)
LOADABLE_SHRLIB_PREFIX=$(SHRLIB_PREFIX)
LOADABLE_SHRLIB_SUFFIX=$(SHRLIB_SUFFIX)
#--------------------------------------------------
# Command-line input support default
COMMANDLINE_LIBRARY = EPICS
OP_SYS_LDLIBS += $(LDLIBS_$(COMMANDLINE_LIBRARY))
OP_SYS_LDFLAGS += $(LDFLAGS_$(COMMANDLINE_LIBRARY))
RUNTIME_LDFLAGS += $(RUNTIME_LDFLAGS_$(COMMANDLINE_LIBRARY))
@@ -303,31 +280,31 @@ RUNTIME_LDFLAGS += $(RUNTIME_LDFLAGS_$(COMMANDLINE_LIBRARY))
#--------------------------------------------------
# Flags
INCLUDES = -I. $(SRC_INCLUDES) $(INSTALL_INCLUDES) $(RELEASE_INCLUDES) \
$(TARGET_INCLUDES) $(USR_INCLUDES) $(CMD_INCLUDES) $(OP_SYS_INCLUDES) \
$($(BUILD_CLASS)_INCLUDES)
INCLUDES = -I. $(SRC_INCLUDES) $(INSTALL_INCLUDES) $(RELEASE_INCLUDES)\
$(TARGET_INCLUDES) $(USR_INCLUDES) $(CMD_INCLUDES) $(OP_SYS_INCLUDES)\
$($(BUILD_CLASS)_INCLUDES)
CFLAGS = $($(BUILD_CLASS)_CFLAGS) $(POSIX_CFLAGS) $(OPT_CFLAGS) \
$(DEBUG_CFLAGS) $(PIPE_CFLAGS) $(WARN_CFLAGS) $(TARGET_CFLAGS) \
$(USR_CFLAGS) $(CMD_CFLAGS) $(ARCH_DEP_CFLAGS) $(CODE_CFLAGS) \
$(STATIC_CFLAGS) $(OP_SYS_CFLAGS) $(LIBRARY_SRC_CFLAGS)
CFLAGS = $($(BUILD_CLASS)_CFLAGS) $(POSIX_CFLAGS) $(OPT_CFLAGS)\
$(DEBUG_CFLAGS) $(PIPE_CFLAGS) $(WARN_CFLAGS) $(TARGET_CFLAGS)\
$(USR_CFLAGS) $(CMD_CFLAGS) $(ARCH_DEP_CFLAGS) $(CODE_CFLAGS)\
$(STATIC_CFLAGS) $(OP_SYS_CFLAGS) $(LIBRARY_SRC_CFLAGS)
CXXFLAGS = $($(BUILD_CLASS)_CXXFLAGS) $(POSIX_CXXFLAGS) $(OPT_CXXFLAGS) \
$(DEBUG_CXXFLAGS) $(PIPE_CFLAGS) $(WARN_CXXFLAGS) $(TARGET_CXXFLAGS) \
$(USR_CXXFLAGS) $(CMD_CXXFLAGS) $(ARCH_DEP_CXXFLAGS) $(CODE_CXXFLAGS) \
$(STATIC_CXXFLAGS) $(OP_SYS_CXXFLAGS) $(LIBRARY_SRC_CFLAGS)
CXXFLAGS = $($(BUILD_CLASS)_CXXFLAGS) $(POSIX_CXXFLAGS) $(OPT_CXXFLAGS)\
$(DEBUG_CXXFLAGS) $(PIPE_CFLAGS) $(WARN_CXXFLAGS) $(TARGET_CXXFLAGS)\
$(USR_CXXFLAGS) $(CMD_CXXFLAGS) $(ARCH_DEP_CXXFLAGS) $(CODE_CXXFLAGS)\
$(STATIC_CXXCFLAGS) $(OP_SYS_CXXFLAGS) $(LIBRARY_SRC_CFLAGS)
LDFLAGS = $(OPT_LDFLAGS) $(TARGET_LDFLAGS) $(USR_LDFLAGS) $(CMD_LDFLAGS) \
$(POSIX_LDFLAGS) $(ARCH_DEP_LDFLAGS) $(DEBUG_LDFLAGS) $(OP_SYS_LDFLAGS) \
$($(BUILD_CLASS)_LDFLAGS) $(RUNTIME_LDFLAGS) $(CODE_LDFLAGS)
LDFLAGS = $(OPT_LDFLAGS) $(TARGET_LDFLAGS) $(USR_LDFLAGS) $(CMD_LDFLAGS)\
$(POSIX_LDFLAGS) $(ARCH_DEP_LDFLAGS) $(DEBUG_LDFLAGS) $(OP_SYS_LDFLAGS)\
$($(BUILD_CLASS)_LDFLAGS) $(RUNTIME_LDFLAGS) $(CODE_LDFLAGS)
LDLIBS = $(POSIX_LDLIBS) $(ARCH_DEP_LDLIBS) $(DEBUG_LDLIBS) $(OP_SYS_LDLIBS) \
$(GNU_LDLIBS_$(GNU))
LDLIBS = $(POSIX_LDLIBS) $(ARCH_DEP_LDLIBS) $(DEBUG_LDLIBS) $(OP_SYS_LDLIBS)\
$(GNU_LDLIBS_$(GNU))
CPPFLAGS = $($(BUILD_CLASS)_CPPFLAGS) $(POSIX_CPPFLAGS) $(OPT_CPPFLAGS) \
$(DEBUG_CPPFLAGS) $(WARN_CPPFLAGS) $(BASE_CPPFLAGS) $(TARGET_CPPFLAGS) \
$(USR_CPPFLAGS) $(CMD_CPPFLAGS) $(ARCH_DEP_CPPFLAGS) $(OP_SYS_CPPFLAGS) \
$(OP_SYS_INCLUDE_CPPFLAGS) $(CODE_CPPFLAGS) $(API_CPPFLAGS)
CPPFLAGS = $($(BUILD_CLASS)_CPPFLAGS) $(POSIX_CPPFLAGS) $(OPT_CPPFLAGS)\
$(DEBUG_CPPFLAGS) $(WARN_CPPFLAGS) $(BASE_CPPFLAGS) $(TARGET_CPPFLAGS)\
$(USR_CPPFLAGS) $(CMD_CPPFLAGS) $(ARCH_DEP_CPPFLAGS) $(OP_SYS_CPPFLAGS)\
$(OP_SYS_INCLUDE_CPPFLAGS) $(CODE_CPPFLAGS)
#--------------------------------------------------
# ar definition default
@@ -399,14 +376,14 @@ PATH_FILTER = $(1)$(warning PATH_FILTER is deprecated; used for $(1))
# each list starts with the destination directory name(s)
# to make sure it's there
INSTALL_PROD = $(PRODNAME:%= $(INSTALL_BIN)/%)
INSTALL_LIBS = $(LIBNAME:%=$(INSTALL_LIB)/%)
INSTALL_MUNCHS = $(MUNCHNAME:%=$(INSTALL_BIN)/%)
INSTALL_SHRLIBS = $(SHRLIBNAME:%=$(INSTALL_SHRLIB)/%)
INSTALL_LOADABLE_SHRLIBS = $(LOADABLE_SHRLIBNAME:%=$(INSTALL_SHRLIB)/%)
INSTALL_DLLSTUB_LIBS = $(DLLSTUB_LIBNAME:%=$(INSTALL_LIB)/%)
INSTALL_TCLLIBS = $(TCLLIBNAME:%=$(INSTALL_TCLLIB)/%)
INSTALL_TCLINDEX = $(TCLINDEX:%=$(INSTALL_TCLLIB)/%)
INSTALL_PROD= $(PRODNAME:%= $(INSTALL_BIN)/%)
INSTALL_LIBS= $(LIBNAME:%=$(INSTALL_LIB)/%)
INSTALL_MUNCHS= $(MUNCHNAME:%=$(INSTALL_BIN)/%)
INSTALL_SHRLIBS= $(SHRLIBNAME:%=$(INSTALL_SHRLIB)/%)
INSTALL_LOADABLE_SHRLIBS= $(LOADABLE_SHRLIBNAME:%=$(INSTALL_SHRLIB)/%)
INSTALL_DLLSTUB_LIBS=$(DLLSTUB_LIBNAME:%=$(INSTALL_LIB)/%)
INSTALL_TCLLIBS=$(TCLLIBNAME:%=$(INSTALL_TCLLIB)/%)
INSTALL_TCLINDEX=$(TCLINDEX:%=$(INSTALL_TCLLIB)/%)
INSTALL_SCRIPTS = $(SCRIPTS:%= $(INSTALL_BIN)/%)
INSTALL_OBJS = $(OBJSNAME:%= $(INSTALL_BIN)/%)
@@ -414,7 +391,7 @@ INSTALL_DOCS = $(DOCS:%= $(INSTALL_DOC)/%)
INSTALL_HTMLS = $(HTMLS:%= $(INSTALL_HTML)/$(HTMLS_DIR)/%)
INSTALL_TEMPLATE = $(addprefix $(INSTALL_TEMPLATES_SUBDIR)/, \
$(subst $(CONFIG),top/configure,$(TEMPLATES)))
$(subst $(CONFIG),top/configure,$(TEMPLATES)))
INSTALL_CONFIGS = $(CONFIGS:%= $(INSTALL_CONFIG)/%)
INSTALL_BIN_INSTALLS = $(addprefix $(INSTALL_BIN)/,$(notdir $(BIN_INSTALLS)))
@@ -449,41 +426,42 @@ INSTALL_INC += $(foreach inc, $(INC), \
$(CMPLR_INSTALL_INC) \
$(OS_INSTALL_INC) \
$(GENERIC_INSTALL_INC) \
$(GENERATED_INSTALL_INC)))
INSTALL_INC += $(addprefix $(INSTALL_INCLUDE)/os/$(OS_CLASS)/, $(INC_$(OS_CLASS)))
$(GENERATED_INSTALL_INC) ) )
INSTALL_INC += $(addprefix $(INSTALL_INCLUDE)/os/$(OS_CLASS)/, $(INC_$(OS_CLASS)) )
#
# Rule 0
#
CMPLR_INSTALL_INC = $(addprefix $(INSTALL_INCLUDE)/compiler/$(CMPLR_CLASS)/, \
$(foreach dir, $(CMPLR_SRC_DIRS), \
$(subst $(dir)/,, $(wildcard $(addsuffix /$(inc), $(dir))))))
CMPLR_INSTALL_INC = $(addprefix $(INSTALL_INCLUDE)/compiler/$(CMPLR_CLASS)/, $(INSTALL_INC_jjj) )
INSTALL_INC_jjj = $(foreach dir, $(CMPLR_SRC_DIRS), $(INSTALL_INC_iii) )
INSTALL_INC_iii = $(subst $(dir)/, , $(INSTALL_INC_hhh) )
INSTALL_INC_hhh = $(wildcard $(addsuffix /$(inc), $(dir)) )
#
# Rule 1
#
OS_INSTALL_INC = $(addprefix $(INSTALL_INCLUDE)/os/$(OS_CLASS)/, \
$(foreach dir, $(OS_SRC_DIRS), \
$(subst $(dir)/,, $(wildcard $(addsuffix /$(inc), $(dir))))))
OS_INSTALL_INC = $(addprefix $(INSTALL_INCLUDE)/os/$(OS_CLASS)/, $(INSTALL_INC_ggg) )
INSTALL_INC_ggg = $(foreach dir, $(OS_SRC_DIRS), $(INSTALL_INC_fff) )
INSTALL_INC_fff = $(subst $(dir)/, , $(INSTALL_INC_eee) )
INSTALL_INC_eee = $(wildcard $(addsuffix /$(inc), $(dir)) )
#
# Rule 2
#
GENERIC_INSTALL_INC = $(addprefix $(INSTALL_INCLUDE)/, \
$(foreach dir, .. $(SRC_DIRS), \
$(subst $(dir)/,, $(wildcard $(addsuffix /$(inc), $(dir))))))
GENERIC_INSTALL_INC = $(addprefix $(INSTALL_INCLUDE)/, $(INSTALL_INC_ccc) )
INSTALL_INC_ccc = $(foreach dir, .. $(SRC_DIRS), $(INSTALL_INC_bbb) )
INSTALL_INC_bbb = $(subst $(dir)/, , $(INSTALL_INC_aaa) )
INSTALL_INC_aaa = $(wildcard $(addsuffix /$(inc), $(dir)) )
#
# Rule 3
#
GENERATED_INSTALL_INC = $(INSTALL_INCLUDE)/$(inc)
#---------------------------------------------------------------
# Files listed in INC that must first be created in O.Common
COMMON_INC += $(filter $(COMMON_DIR)/%, \
$(foreach file, $(INC), \
$(firstword $(wildcard $(file) \
$(foreach dir, $(ALL_SRC_DIRS), \
$(addsuffix /$(file), $(dir)))) $(COMMON_DIR)/$(file))))
COMMON_INC += $(filter $(COMMON_DIR)/%, $(foreach file, $(INC), \
$(firstword $(SOURCE_INC) $(COMMON_DIR)/$(file) ) ) )
SOURCE_INC = $(wildcard $(file) $(SOURCE_INC_bbb) )
SOURCE_INC_bbb = $(foreach dir, $(ALL_SRC_DIRS), $(SOURCE_INC_aaa) )
SOURCE_INC_aaa = $(addsuffix /$(file), $(dir) )
endif

View File

@@ -1,34 +0,0 @@
#*************************************************************************
# Copyright (c) 2017 UChicago Argonne LLC, as Operator of Argonne
# National Laboratory.
# EPICS BASE is distributed subject to a Software License Agreement found
# in file LICENSE that is included with this distribution.
#*************************************************************************
# Installed perl scripts and dependent modules that have
# a significant effect on the script's output
DBDEXPAND_pl = $(EPICS_BASE_HOST_BIN)/dbdExpand.pl
DBDTORECTYPEH_pl = $(EPICS_BASE_HOST_BIN)/dbdToRecordtypeH.pl
DBDTORECTYPEH_dep = $(DBDTORECTYPEH_pl) $(call FIND_PM,DBD/Rec*.pm)
DBDTOMENUH_pl = $(EPICS_BASE_HOST_BIN)/dbdToMenuH.pl
DBDTOMENUH_dep = $(DBDTOMENUH_pl) $(call FIND_PM,DBD/Menu.pm)
DBDTOHTML_pl = $(EPICS_BASE_HOST_BIN)/dbdToHtml.pl
DBDTOHTML_dep = $(DBDTOHTML_pl) $(call FIND_PM,EPICS/Pod*Html.pm)
REGRECDEVDRV_pl = $(EPICS_BASE_HOST_BIN)/registerRecordDeviceDriver.pl
REGRECDEVDRV_dep = $(REGRECDEVDRV_pl)
# Commands for running scripts in recipes
DBEXPAND = $(PERL) $(DBDEXPAND_pl)
DBTORECORDTYPEH = $(PERL) $(DBDTORECTYPEH_pl)
DBTOMENUH = $(PERL) $(DBDTOMENUH_pl)
DBDTOHTML = $(PERL) $(DBDTOHTML_pl)
REGISTERRECORDDEVICEDRIVER = $(PERL) $(REGRECDEVDRV_pl)
# Installed binary executables, quoted for running on Windows
MAKEBPT = "$(EPICS_BASE_HOST_BIN)/makeBpt$(HOSTEXE)"
MSI3_15 = "$(EPICS_BASE_HOST_BIN)/msi$(HOSTEXE)"
# Libraries needed to link a basic IOC
EPICS_BASE_IOC_LIBS = dbRecStd dbCore ca Com
HAS_registerAllRecordDeviceDrivers=YES

View File

@@ -1,12 +0,0 @@
# Version number for the database APIs and shared library
EPICS_DATABASE_MAJOR_VERSION = 3
EPICS_DATABASE_MINOR_VERSION = 23
EPICS_DATABASE_MAINTENANCE_VERSION = 0
# Development flag, set to zero for release versions
EPICS_DATABASE_DEVELOPMENT_FLAG = 0
# Immediately after a release the MAINTENANCE_VERSION
# will be incremented and the DEVELOPMENT_FLAG set to 1

View File

@@ -3,8 +3,9 @@
# National Laboratory.
# Copyright (c) 2002 The Regents of the University of California, as
# Operator of Los Alamos National Laboratory.
# EPICS BASE is distributed subject to a Software License Agreement found
# in file LICENSE that is included with this distribution.
# EPICS BASE Versions 3.13.7
# and higher are distributed subject to a Software License Agreement found
# in file LICENSE that is included with this distribution.
#*************************************************************************
# Author: Andrew Johnson
# Date: 20 April 1995
@@ -53,3 +54,8 @@ EPICS_IOC_IGNORE_SERVERS=""
# EPICS_IOC_LOG_PORT Log server port number etc.
EPICS_IOC_LOG_PORT=7004
# Other services:
EPICS_CMD_PROTO_PORT=
EPICS_AR_PORT=7002

View File

@@ -1,12 +0,0 @@
# Version number for the libcom APIs and shared library
EPICS_LIBCOM_MAJOR_VERSION = 3
EPICS_LIBCOM_MINOR_VERSION = 23
EPICS_LIBCOM_MAINTENANCE_VERSION = 0
# Development flag, set to zero for release versions
EPICS_LIBCOM_DEVELOPMENT_FLAG = 0
# Immediately after a release the MAINTENANCE_VERSION
# will be incremented and the DEVELOPMENT_FLAG set to 1

View File

@@ -17,11 +17,11 @@
# Currently Supporting:
# cygwin-x86 (cygwin compiler used for host builds)
# cygwin-x86_64 (cygwin compiler used for host builds)
# darwin-aarch64 (M1 based Apple using CLANG compiler)
# darwin-x86 (Intel based Apple using CLANG compiler)
# darwin-ppc (PowerPC based Apple running OSX)
# darwin-ppcx86 (Universal binaries for both CPUs)
# darwin-x86 (Intel based Apple running OSX)
# freebsd-x86 (GNU compiler used for host builds)
# freebsd-x86_64 (GNU compiler used for host builds)
# linux-aarch64 (GNU compiler used for host builds)
# linux-arm (GNU compiler used for host builds)
# linux-ppc (GNU compiler used for host builds)
# linux-ppc64 (GNU compiler used for host builds)
@@ -51,6 +51,7 @@
# windows-x64-debug (MS Visual C++ compiler with debug option for host builds)
# EPICS_HOST_ARCH is a required environment variable
# Do not set EPICS_HOST_ARCH in this file.
# Use base/startup files to set EPICS_HOST_ARCH or
# provide EPICS_HOST_ARCH on the GNU make command line.
@@ -61,11 +62,23 @@
# ios-arm (darwin-x86 host)
# ios-386 (darwin-x86 host)
# linux-386 (linux-x86 host)
# linux-486 (linux-x86 host)
# linux-586 (linux-x86 host)
# linux-686 (linux-x86 host)
# linux-arm (linux-x86 or -x86_64 host)
# linux-aarch64 (linux-x86_64 host)
# linux-arm_eb (linux-x86 host)
# linux-arm_el (linux-x86 host)
# linux-athlon (linux-x86 host)
# linux-cris (Axis GNU crosscompiler on linux-x86 host)
# linux-cris_v10 (Axis GNU crosscompiler on linux-x86 host)
# linux-cris_v32 (Axis GNU crosscompiler on linux-x86 host)
# linux-microblaze
# linux-xscale_be
# vxWorks-486
# vxWorks-68040
# vxWorks-68040lc
# vxWorks-68060
# vxWorks-pentium
# vxWorks-ppc32 (32-bit PowerPC CPUs with full FPU)
# vxWorks-ppc32sf (32-bit PowerPC CPUs without FPU)
@@ -76,20 +89,18 @@
# vxWorks-ppc604_altivec
# vxWorks-mpc8540
# vxWorks-mpc8548
# RTEMS-beagleboneblack
# RTEMS-at91rm9200ek
# RTEMS-beatnik
# RTEMS-gen68360
# RTEMS-mcp750
# RTEMS-mvme167
# RTEMS-mvme2100
# RTEMS-mvme2700
# RTEMS-mvme3100
# RTEMS-mvme5500
# RTEMS-pc386 (RTEMS 4)
# RTEMS-pc386-qemu (RTEMS 4)
# RTEMS-pc686 (RTEMS 5)
# RTEMS-pc686-qemu (RTEMS 5)
# RTEMS-qoriq_e500
# RTEMS-pc386
# RTEMS-psim
# RTEMS-uC5282
# RTEMS-xilinx-zynq-a9_qemu
# RTEMS-xilinx_zynq_zedboard
# win32-x86-mingw (linux-x86 or -x86_64 host)
#
@@ -97,6 +108,7 @@
# Definitions in configure/os/CONFIG_SITE.<host>.Common
# may override this setting.
CROSS_COMPILER_TARGET_ARCHS=
#CROSS_COMPILER_TARGET_ARCHS=vxWorks-ppc32
# If only some of your host architectures can compile the
# above CROSS_COMPILER_TARGET_ARCHS specify those host
@@ -143,21 +155,13 @@ CROSS_WARN=YES
# different location then uncomment and set this.
#INSTALL_LOCATION=<fullpathname>
# The location from which files placed in INSTALL_LOCATION will actually run.
# This path is compiled into executables, and so should be an absolute.
# May be used to achieve the effect of autotools. eg.
# ./configure --prefix=<FINAL_LOCATION>
# make DESTDIR=<INSTALL_LOCATION>
# Defaults to the absolute expansion of $(INSTALL_LOCATION)
#FINAL_LOCATION=
# Use POSIX thread priority scheduling (if available).
# Must be either YES or NO
USE_POSIX_THREAD_PRIORITY_SCHEDULING = YES
# Site version number, if set will append '-' and this string to the
# EPICS version number string that is reported by many tools.
EPICS_SITE_VERSION =
EPICS_SITE_VERSION:=$(shell date +%Y-%m)
# For GNU compiler, use pipes rather than temporary files for
# communication between the various stages of compilation.
@@ -165,18 +169,10 @@ EPICS_SITE_VERSION =
GCC_PIPE = NO
# Set RPATH when linking executables and libraries.
# Must be either YES, NO, or ORIGIN. If you set this to NO you must also provide a
# Must be either YES or NO. If you set this to NO you must also provide a
# way for Base executables to find their shared libraries when they are
# run at build-time, e.g. set the LD_LIBRARY_PATH environment variable.
# ORIGIN is a feature of the ELF executable format used by Linux, freebsd, and solaris.
LINKER_USE_RPATH = YES
# Only used when LINKER_USE_RPATH=ORIGIN
# The build time root(s) of the relocatable tree (separate multiple w/ ':').
# Linking to libraries under any root directory will be relative.
# Linking to libraries outside of this root will be absolute.
# All root directories are considered to be the same.
LINKER_ORIGIN_ROOT = $(INSTALL_LOCATION)
# Overrides for the settings above may appear in a CONFIG_SITE.local file
-include $(CONFIG)/CONFIG_SITE.local

View File

@@ -24,40 +24,40 @@
# Site-specific environment settings
## Time service:
# EPICS_TZ
# Local timezone rules for vxWorks and RTEMS. The value follows the Posix
# TZ environment variable's Mm.n.d/h format (see the IBM link below for
# details). If TZ hasn't already been set when the osdTime timeRegister()
# C++ static constructor runs, this parameter will be copied into the TZ
# environment variable. Once the OS clock has been synchronized to NTP the
# routine tz2timezone() will be run to convert TZ into the TIMEZONE
# variable format that VxWorks needs.
# https://developer.ibm.com/articles/au-aix-posix/
# Japan Standard Time, no DST:
#EPICS_TZ = "JST-9"
# Central European (Summer) Time:
#EPICS_TZ = "CET-1CEST,M3.5.0/2,M10.5.0/3"
# Greenwich Mean/British Summer Time:
#EPICS_TZ = "GMT0BST,M3.5.0/1,M10.5.0/2"
# US Eastern Standard/Daylight Time:
#EPICS_TZ = "EST5EDT,M3.2.0/2,M11.1.0/2"
# US Central Standard/Daylight Time:
EPICS_TZ = "CST6CDT,M3.2.0/2,M11.1.0/2"
# US Mountain Standard/Daylight Time:
#EPICS_TZ = "MST7MDT,M3.2.0/2,M11.1.0/2"
# US Pacific Standard/Daylight Time:
#EPICS_TZ = "PST8PDT,M3.2.0/2,M11.1.0/2"
# US Hawaiian Standard Time, no DST:
#EPICS_TZ = "HST10"
# Time service:
# EPICS_TIMEZONE
# Local timezone info for vxWorks and RTEMS. The format is
# <name>::<minutesWest>:<startDST>:<endDST>
# where <name> is only used by strftime() for %Z conversions,
# and <startDST> and <endDST> are mmddhh - that is month,day,hour
# e.g. for ANL in 2018: EPICS_TIMEZONE=CUS::360:031102:110402
# The future dates below assume the rules don't get changed;
# see http://www.timeanddate.com/time/dst/2018.html to check.
#
# DST for 2019 US: Mar 10 - Nov 03
# EU: Mar 31 - Oct 27
EPICS_TIMEZONE = CUS::360:031002:110302
#EPICS_TIMEZONE = MET::-60:033102:102703
#
# DST for 2020 US: Mar 08 - Nov 01
# EU: Mar 29 - Oct 25
#EPICS_TIMEZONE = CUS::360:030802:110102
#EPICS_TIMEZONE = MET::-60:032902:102503
#
# DST for 2021 US: Mar 14 - Nov 07
# EU: Mar 28 - Oct 31
#EPICS_TIMEZONE = CUS::360:031402:110702
#EPICS_TIMEZONE = MET::-60:032802:103103
#
# DST for 2022 US: Mar 13 - Nov 06
# EU: Mar 27 - Oct 30
#EPICS_TIMEZONE = CUS::360:031302:110602
#EPICS_TIMEZONE = MET::-60:032702:103003
#
# DST for 2023 US: Mar 13 - Nov 06
# EU: Mar 27 - Oct 30
#EPICS_TIMEZONE = CUS::360:031202:110502
#EPICS_TIMEZONE = MET::-60:032602:102903
# EPICS_TS_NTP_INET
# NTP time server ip address for VxWorks and RTEMS.

View File

@@ -15,24 +15,10 @@ include $(TOP)/configure/CONFIG
TOOLS = $(TOP)/src/tools
CONFIGS += $(subst ../,,$(wildcard ../CONFIG*))
CONFIGS += $(subst ../,,$(wildcard ../os/CONFIG.*))
CONFIGS += $(subst ../,,$(wildcard ../os/CONFIG_SITE.*))
CONFIGS += $(subst ../,,$(wildcard ../os/CONFIG*))
CONFIGS += $(subst ../,,$(wildcard ../RELEASE*))
CONFIGS += $(subst ../,,$(wildcard ../RULES*))
CFG += CONFIG_LIBCOM_MODULE
CFG += CONFIG_LIBCOM_VERSION
CFG += CONFIG_CA_MODULE
CFG += CONFIG_CA_VERSION
CFG += CONFIG_DATABASE_MODULE
CFG += CONFIG_DATABASE_VERSION
CFG += TOOLCHAIN.$(EPICS_HOST_ARCH).$(T_A)
include $(TOP)/configure/RULES
TOOLCHAIN.$(EPICS_HOST_ARCH).$(T_A): toolchain.c
$(PREPROCESS.cpp)

View File

@@ -17,7 +17,7 @@ TEMPL_SUFFIX ?= .template
# vpath
vpath %.pm $(USR_VPATH) $(SRC_DIRS) $(dir $(DBD))
vpath %.pod $(USR_VPATH) $(SRC_DIRS) .. $(dir $(DBD))
vpath %.pod $(USR_VPATH) $(SRC_DIRS) $(dir $(DBD))
vpath %.dbd $(USR_VPATH) $(SRC_DIRS) $(dir $(DBD))
vpath %.db $(USR_VPATH) $(SRC_DIRS) $(dir $(DB))
vpath %.vdb $(USR_VPATH) $(SRC_DIRS) $(dir $(DB))
@@ -161,13 +161,13 @@ actionArchTargets = $(foreach action, $(ACTIONS), \
$(foreach arch, $(BUILD_ARCHS), $(action)$(DIVIDER)$(arch)))
cleanArchTargets = $(foreach arch, $(BUILD_ARCHS), clean$(DIVIDER)$(arch))
include $(CONFIG)/CONFIG_APP_INCLUDE
-include $(TOP)/configure/CONFIG_APP_INCLUDE
all: install
install: buildInstall
buildInstall: build
buildInstall : build
rebuild: clean install
@@ -196,53 +196,53 @@ endif
#---------------------------------------------------------------
# build dependancies, clean rule
inc: $(COMMON_INC) $(INSTALL_INC) $(COMMON_DBDS) $(COMMON_DBDCATS) \
$(INSTALL_DBDS) $(INSTALL_DBD_INSTALLS)
inc : $(COMMON_INC) $(INSTALL_INC)
build: $(COMMON_DBS) $(INSTALL_DBS) \
build : $(COMMON_DBDS) $(COMMON_DBS) $(COMMON_DBDCATS) \
$(INSTALL_DBDS) $(INSTALL_DBS) \
$(DBDDEPENDS_FILES) $(TARGETS) \
$(INSTALL_DB_INSTALLS)
$(INSTALL_DB_INSTALLS) $(INSTALL_DBD_INSTALLS)
clean: db_clean
db_clean:
db_clean :
@$(RM) $(COMMONS) $(DBDDEPENDS_FILES)
@$(RM) *_registerRecordDeviceDriver.cpp
@$(RM) $(TARGETS)
.PHONY: db_clean
.PHONY : db_clean
realclean: clean
#---------------------------------------------------------------
# Dependency files
%Record.h$(DEP): $(COMMON_DIR)/%Record.dbd $(DBDTORECTYPEH_dep)
%Record.h$(DEP): $(COMMON_DIR)/%Record.dbd
@$(RM) $@
@$(DBTORECORDTYPEH) -D $(DBDFLAGS) -o $(COMMONDEP_TARGET) $< > $@
@echo "$(COMMONDEP_TARGET): ../Makefile" >> $@
%Record.h$(DEP): %Record.dbd $(DBDTORECTYPEH_dep)
%Record.h$(DEP): %Record.dbd
@$(RM) $@
@$(DBTORECORDTYPEH) -D $(DBDFLAGS) -o $(COMMONDEP_TARGET) $< > $@
@echo "$(COMMONDEP_TARGET): ../Makefile" >> $@
%Record.h$(DEP): ../%Record.dbd $(DBDTORECTYPEH_dep)
%Record.h$(DEP): ../%Record.dbd
@$(RM) $@
@$(DBTORECORDTYPEH) -D $(DBDFLAGS) -o $(COMMONDEP_TARGET) $< > $@
@echo "$(COMMONDEP_TARGET): ../Makefile" >> $@
menu%.h$(DEP): $(COMMON_DIR)/menu%.dbd $(DBDTOMENUH_dep)
menu%.h$(DEP): $(COMMON_DIR)/menu%.dbd
@$(RM) $@
@$(DBTOMENUH) -D $(DBDFLAGS) -o $(COMMONDEP_TARGET) $< > $@
@echo "$(COMMONDEP_TARGET): ../Makefile" >> $@
menu%.h$(DEP): menu%.dbd $(DBDTOMENUH_dep)
menu%.h$(DEP): menu%.dbd
@$(RM) $@
@$(DBTOMENUH) -D $(DBDFLAGS) -o $(COMMONDEP_TARGET) $< > $@
@echo "$(COMMONDEP_TARGET): ../Makefile" >> $@
menu%.h$(DEP): ../menu%.dbd $(DBDTOMENUH_dep)
menu%.h$(DEP): ../menu%.dbd
@$(RM) $@
@$(DBTOMENUH) -D $(DBDFLAGS) -o $(COMMONDEP_TARGET) $< > $@
@echo "$(COMMONDEP_TARGET): ../Makefile" >> $@
@@ -261,7 +261,7 @@ menu%.h$(DEP): ../menu%.dbd $(DBDTOMENUH_dep)
@$(DBEXPAND) -D $(DBDFLAGS) -o $(COMMONDEP_TARGET) $< > $@
@echo "$(COMMONDEP_TARGET): ../Makefile" >> $@
%.dbd$(DEP): $($*_DBD)
%.dbd$(DEP):
@$(RM) $@
@$(DBEXPAND) -D $(DBDFLAGS) -o $(COMMONDEP_TARGET) $($*_DBD) > $@
@echo "$(COMMONDEP_TARGET): ../Makefile" >> $@
@@ -330,32 +330,32 @@ $(INSTALL_DB)/%$(TEMPL_SUFFIX): ../%$(TEMPL_SUFFIX)
#---------------------------------------------------------------
# INC files
$(COMMON_DIR)/%Record.h: $(COMMON_DIR)/%Record.dbd $(DBDTORECTYPEH_dep)
$(COMMON_DIR)/%Record.h: $(COMMON_DIR)/%Record.dbd
@$(RM) $(notdir $@)
$(DBTORECORDTYPEH) $(DBDFLAGS) -o $(notdir $@) $<
@$(MV) $(notdir $@) $@
$(COMMON_DIR)/%Record.h: %Record.dbd $(DBDTORECTYPEH_dep)
$(COMMON_DIR)/%Record.h: %Record.dbd
@$(RM) $(notdir $@)
$(DBTORECORDTYPEH) $(DBDFLAGS) -o $(notdir $@) $<
@$(MV) $(notdir $@) $@
$(COMMON_DIR)/%Record.h: ../%Record.dbd $(DBDTORECTYPEH_dep)
$(COMMON_DIR)/%Record.h: ../%Record.dbd
@$(RM) $(notdir $@)
$(DBTORECORDTYPEH) $(DBDFLAGS) -o $(notdir $@) $<
@$(MV) $(notdir $@) $@
$(COMMON_DIR)/menu%.h: $(COMMON_DIR)/menu%.dbd $(DBDTOMENUH_dep)
$(COMMON_DIR)/menu%.h: $(COMMON_DIR)/menu%.dbd
@$(RM) $(notdir $@)
$(DBTOMENUH) $(DBDFLAGS) -o $(notdir $@) $<
@$(MV) $(notdir $@) $@
$(COMMON_DIR)/menu%.h: menu%.dbd $(DBDTOMENUH_dep)
$(COMMON_DIR)/menu%.h: menu%.dbd
@$(RM) $(notdir $@)
$(DBTOMENUH) $(DBDFLAGS) -o $(notdir $@) $<
@$(MV) $(notdir $@) $@
$(COMMON_DIR)/menu%.h: ../menu%.dbd $(DBDTOMENUH_dep)
$(COMMON_DIR)/menu%.h: ../menu%.dbd
@$(RM) $(notdir $@)
$(DBTOMENUH) $(DBDFLAGS) -o $(notdir $@) $<
@$(MV) $(notdir $@) $@
@@ -366,7 +366,6 @@ $(COMMON_DIR)/menu%.h: ../menu%.dbd $(DBDTOMENUH_dep)
# DBD files
$(COMMON_DIR)/bpt%.dbd: bpt%.data
$(ECHO) "Converting data from $<"
@$(RM) $(notdir $@)
$(MAKEBPT) $< $(notdir $@)
@$(MV) $(notdir $@) $@
@@ -390,7 +389,7 @@ $(COMMON_DIR)/%.dbd: ../%Include.dbd
# Make DBDCAT file x depend on x_DBD source files
define DBDCAT_template
$$(COMMON_DIR)/$(1).dbd: ../Makefile $$(foreach file, $$($(1)_DBD),$$(DBDCAT_SOURCE) )
$$(COMMON_DIR)/$(1).dbd : ../Makefile $$(foreach file, $$($(1)_DBD),$$(DBDCAT_SOURCE) )
endef
$(foreach name,$(subst .dbd,,$(DBDCAT)), $(eval $(call DBDCAT_template,$(name))))
@@ -400,7 +399,7 @@ $(COMMON_DBDCATS):$(COMMON_DIR)/%.dbd:
$(DBDCAT_COMMAND)
@$(MV) $(notdir $@) $@
$(COMMON_DIR)/%.dbd: $($*_DBD)
$(COMMON_DIR)/%.dbd:
$(ECHO) "Creating dbd file $(notdir $@)"
@$(RM) $(notdir $@)
$(DBEXPAND) $(DBDFLAGS) -o $(notdir $@) $($*_DBD)
@@ -419,7 +418,7 @@ $(INSTALL_DBD)/%: ../%
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
define DBD_INSTALLS_template
$$(INSTALL_DBD)/$$(notdir $(1)): $(1)
$$(INSTALL_DBD)/$$(notdir $(1)) : $(1)
$(ECHO) "Installing $$@"
@$$(INSTALL) -d -m $$(INSTALL_PERMISSIONS) $$^ $$(INSTALL_DBD)
endef
@@ -430,38 +429,38 @@ $(foreach file, $(DBD_INSTALLS), $(eval $(call DBD_INSTALLS_template, $(file))))
#---------------------------------------------------------------
# HTML files
$(COMMON_DIR)/%.html: %.dbd.pod $(DBDTOHTML_pl)
$(COMMON_DIR)/%.html: %.dbd.pod
@$(RM) $(notdir $@)
$(DBDTOHTML) $(DBDFLAGS) -o $(notdir $@) $<
@$(MV) $(notdir $@) $@
$(COMMON_DIR)/%.html: %.pod $(PODTOHTML_dep)
@$(RM) $(notdir $@)
$(PODTOHTML) -s -s -o $(notdir $@) $<
@$(MV) $(notdir $@) $@
$(COMMON_DIR)/%.html: %.pm $(PODTOHTML_dep)
$(COMMON_DIR)/%.html: %.pod
@$(RM) $(notdir $@)
$(PODTOHTML) -o $(notdir $@) $<
@$(MV) $(notdir $@) $@
$(COMMON_DIR)/%.html: ../%.pm $(PODTOHTML_dep)
$(COMMON_DIR)/%.html: %.pm
@$(RM) $(notdir $@)
$(PODTOHTML) -o $(notdir $@) $<
@$(MV) $(notdir $@) $@
$(COMMON_DIR)/%.html: ../%.pm
@$(RM) $(notdir $@)
$(PODTOHTML) -s -o $(notdir $@) $<
@$(MKDIR) $(dir $@)
@$(MV) $(notdir $@) $@
$(COMMON_DIR)/%.html: ../%.pl $(PODTOHTML_dep)
$(COMMON_DIR)/%.html: ../%.pl
@$(RM) $(notdir $@)
$(PODTOHTML) -s -o $(notdir $@) $<
@$(MV) $(notdir $@) $@
.PRECIOUS: $(COMMON_DIR)/%.html
.PRECIOUS: $(COMMON_DIR)/%.html %.html
#---------------------------------------------------------------
# DB files
$(COMMON_DIR)/%.db: $(COMMON_DIR)/%.edf
$(COMMON_DIR)/%.db: $(COMMON_DIR)/%.edf
$(E2DB) $(E2DB_SYSFLAGS) $(E2DB_FLAGS) -n $*.VAR $<
@$(REPLACEVAR) < $*.VAR > $@
@$(RM) $*.VAR
@@ -515,7 +514,7 @@ $(INSTALL_DB)/%.db: $(COMMON_DIR)/%.db
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
define DB_INSTALLS_template
$$(INSTALL_DB)/$$(notdir $(1)): $(1)
$$(INSTALL_DB)/$$(notdir $(1)) : $(1)
$(ECHO) "Installing $$@"
@$$(INSTALL) -d -m $$(INSTALL_PERMISSIONS) $$^ $$(INSTALL_DB)
endef
@@ -527,19 +526,17 @@ $(foreach file, $(DB_INSTALLS), $(eval $(call DB_INSTALLS_template, $(file))))
#---------------------------------------------------------------
# register record,device,driver support
%_registerRecordDeviceDriver.cpp: $(COMMON_DIR)/%.dbd $(REGRECDEVDRV_dep)
%_registerRecordDeviceDriver.cpp: $(COMMON_DIR)/%.dbd
@$(RM) $@
$(REGISTERRECORDDEVICEDRIVER) $(REGRDDFLAGS) -o $@ \
$< $(basename $@) $(IOCS_APPL_TOP)
$(REGISTERRECORDDEVICEDRIVER) $(REGRDDFLAGS) -o $@ $< $(basename $@) $(IOCS_APPL_TOP)
%_registerRecordDeviceDriver.cpp: %.dbd $(REGRECDEVDRV_dep)
%_registerRecordDeviceDriver.cpp: %.dbd
@$(RM) $@
$(REGISTERRECORDDEVICEDRIVER) $(REGRDDFLAGS) -o $@ \
$< $(basename $@) $(IOCS_APPL_TOP)
$(REGISTERRECORDDEVICEDRIVER) $(REGRDDFLAGS) -o $@ $< $(basename $@) $(IOCS_APPL_TOP)
%_registerRecordDeviceDriver.cpp: ../%.dbd $(REGRECDEVDRV_dep)
%_registerRecordDeviceDriver.cpp: ../%.dbd
@$(RM) $@
$(REGISTERRECORDDEVICEDRIVER) $(REGRDDFLAGS) -o $@ \
$< $(basename $@) $(IOCS_APPL_TOP)
$(REGISTERRECORDDEVICEDRIVER) $(REGRDDFLAGS) -o $@ $< $(basename $@) $(IOCS_APPL_TOP)
.PRECIOUS: %_registerRecordDeviceDriver.cpp

View File

@@ -32,12 +32,12 @@ vpath %.l $(USR_VPATH) $(ALL_SRC_DIRS)
include $(CONFIG)/CONFIG_ADDONS
#---------------------------------------------------------------
# Set PROD, TESTPROD, OBJS, and LIBRARY
SCRIPTS_HOST += $(PERL_SCRIPTS)
# PERL_SCRIPTS are installed into existing $(INSTALL_BIN) for Host systems
# Host targets can compile and run programs
ifneq (,$(findstring Host,$(VALID_BUILDS)))
ifeq ($(findstring Host,$(VALID_BUILDS)),Host)
LIBRARY += $(LIBRARY_HOST)
LOADABLE_LIBRARY += $(LOADABLE_LIBRARY_HOST)
OBJS += $(OBJS_HOST)
@@ -49,21 +49,7 @@ TESTSCRIPTS += $(TESTSCRIPTS_HOST)
TESTPROD += $(TESTPROD_HOST)
endif
# Command targets have a command line and support main()
ifneq (,$(findstring Command,$(VALID_BUILDS)))
LIBRARY += $(LIBRARY_CMD)
LOADABLE_LIBRARY += $(LOADABLE_LIBRARY_CMD)
OBJS += $(OBJS_CMD)
PROD += $(PROD_CMD)
SCRIPTS += $(SCRIPTS_CMD)
TARGETS += $(TARGETS_CMD)
TESTLIBRARY += $(TESTLIBRARY_CMD)
TESTSCRIPTS += $(TESTSCRIPTS_CMD)
TESTPROD += $(TESTPROD_CMD)
endif
# Ioc targets can run IOCs
ifneq (,$(findstring Ioc,$(VALID_BUILDS)))
ifeq ($(findstring Ioc,$(VALID_BUILDS)),Ioc)
LIBRARY += $(LIBRARY_IOC)
LOADABLE_LIBRARY += $(LOADABLE_LIBRARY_IOC)
OBJS += $(OBJS_IOC)
@@ -89,7 +75,7 @@ HTMLS_DIR ?= .
# First target
all: install
ifeq ($(EPICS_HOST_ARCH),$(T_A))
ifeq ($(EPICS_HOST_ARCH),$T_A)
host: install
else
# Do nothing
@@ -100,23 +86,37 @@ include $(CONFIG)/RULES_FILE_TYPE
include $(CONFIG)/RULES.Db
#---------------------------------------------------------------
# Do not build anything if current path matches SKIP_BUILD
ifneq (,$(strip $(SKIP_BUILDS)))
CURRENT_MODULE=$(subst $(realpath $(TOP)/..)/,,$(subst $(realpath $(dir $(lastword $(MAKEFILE_LIST)))..)/,,$(realpath ..)))
ifneq ($(filter $(SKIP_BUILDS) $(addsuffix /%,$(SKIP_BUILDS)),$(CURRENT_MODULE)),)
$(info Skipping $(CURRENT_MODULE) for $(T_A))
PROD=
TESTPROD=
LIBRARY=
TESTLIBRARY=
LOADABLE_LIBRARY=
TESTS=
SRC_FILES=
endif
endif
#---------------------------------------------------------------
# Include defines and rules for prod, library and test* targets
ifneq (,$(strip $(PROD) $(TESTPROD) $(LIBRARY) $(TESTLIBRARY) \
$(LOADABLE_LIBRARY)))
#ifneq (,$(strip $(PROD) $(TESTPROD) $(LIBRARY) $(TESTLIBRARY) $(LOADABLE_LIBRARY) ))
include $(CONFIG)/RULES_TARGET
endif
#endif
#---------------------------------------------------------------
# Read dependency files
ifneq (inc,$(strip $(MAKECMDGOALS)))
ifneq (,$(strip $(HDEPENDS_FILES)))
$(filter-out $(wildcard *$(DEP)), $(HDEPENDS_FILES)): | $(COMMON_INC)
-include $(HDEPENDS_FILES)
endif
endif
#---------------------------------------------------------------
# Products and Object libraries
@@ -125,17 +125,17 @@ PRODTARGETS += $(PRODNAME) $(MUNCHNAME) $(CTDT_SRCS) $(CTDT_OBJS) $(NMS)
TESTPRODTARGETS += $(TESTPRODNAME) $(TESTMUNCHNAME)
#---------------------------------------------------------------
# Test result files
# Test specifications and test result files
#
ifneq (,$(strip $(TESTS)))
TARGETS += testspec
endif
# Enable testing if this host can run tests for the current target
ifneq (,$(filter $(T_A), $(EPICS_HOST_ARCH) $(CROSS_COMPILER_RUNTEST_ARCHS)))
# Enable testing if this host can run tests on the current target
ifneq (,$(findstring $(T_A),$(EPICS_HOST_ARCH) $(CROSS_COMPILER_RUNTEST_ARCHS)))
RUNTESTS_ENABLED = YES
TESTSCRIPTS.t = $(filter %.t, $(TESTSCRIPTS))
TAPFILES.t += $(TESTSCRIPTS.t:.t=.tap)
JUNITFILES.t += $(TESTSCRIPTS.t:.t=-results.xml)
TAPFILES += $(TAPFILES.t)
JUNITFILES += $(JUNITFILES.t)
TAPFILES += $(TESTSCRIPTS:.t=.tap)
JUNITFILES += $(TAPFILES:.tap=.xml)
endif
#---------------------------------------------------------------
@@ -164,14 +164,14 @@ build: inc
build: $(OBJSNAME) $(LIBTARGETS) $(PRODTARGETS) $(TESTPRODTARGETS) \
$(TARGETS) $(TESTSCRIPTS) $(INSTALL_LIB_INSTALLS)
inc: $(COMMON_INC) $(INSTALL_INC) $(INSTALL_CONFIGS) $(INSTALLS_CFG) \
$(INSTALL_HTMLS) $(INSTALLS_PERL_MODULES) $(INSTALL_SCRIPTS)
inc : $(COMMON_INC) $(INSTALL_INC) $(INSTALL_CONFIGS)
buildInstall: \
$(INSTALL_PROD) $(INSTALL_MUNCHS) \
buildInstall : \
$(INSTALL_SCRIPTS) $(INSTALL_PROD) $(INSTALL_MUNCHS) \
$(INSTALL_TCLLIBS) $(INSTALL_TCLINDEX) \
$(INSTALL_DOCS) \
$(INSTALL_OBJS) \
$(INSTALL_DOCS) \
$(INSTALL_HTMLS) \
$(INSTALL_TEMPLATE) \
$(INSTALL_BIN_INSTALLS)
@@ -191,9 +191,9 @@ ifdef RES
@$(RM) *$(RES)
endif
# Sort directories to remove duplicates & make parents first
$(sort $(DIRECTORY_TARGETS)):
$(MKDIR) $@
# Sort mkdir targets to remove duplicates & make parents first
$(DIRECTORY_TARGETS):
$(MKDIR) $(sort $@)
# Install LIB_INSTALLS libraries before linking executables
$(TESTPRODNAME) $(PRODNAME): | $(INSTALL_LIB_INSTALLS)
@@ -213,25 +213,18 @@ ifeq ($(EPICS_HOST_ARCH),$(T_A))
$(info Warning: RELEASE file consistency checks have been disabled)
endif
# $(FINAL_DIR) signals eventual install locations to makeRPath script
$(TESTPRODNAME): FINAL_DIR=.
$(PRODNAME): FINAL_DIR=$(INSTALL_BIN)
$(TESTSHRLIBNAME): FINAL_DIR=.
$(SHRLIBNAME): FINAL_DIR=$(INSTALL_SHRLIB)
$(LOADABLE_SHRLIBNAME): FINAL_DIR=$(INSTALL_SHRLIB)
#---------------------------------------------------------------
# The order of the following rules is
# VERY IMPORTANT !!!!
$(TESTPRODNAME) $(PRODNAME): $(PRODUCT_OBJS) $(PROD_RESS) $(PROD_DEPLIBS)
$(TESTPRODNAME) $(PRODNAME): %$(EXE): | $(INSTALL_LIB)
$(TESTPRODNAME) $(PRODNAME): %$(EXE):
@$(RM) $@
$(LINK.cpp)
$(DEBUGCMD) $(LINK.cpp)
$(MT_EXE_COMMAND)
%_ctdt$(OBJ): %_ctdt.c
%_ctdt$(OBJ) : %_ctdt.c
@$(RM) $@
$(COMPILE.ctdt) $<
@@ -249,9 +242,9 @@ $(TESTPRODNAME) $(PRODNAME): %$(EXE): | $(INSTALL_LIB)
# Cancel GNUMake's built-in rules, which don't have our _INC
# dependencies so could get used in some circumstances (gdd)
%.o: %.c
%.o: %.cc
%.o: %.cpp
%.o : %.c
%.o : %.cc
%.o : %.cpp
# Include files are order-only prerequisites for compilation:
%$(OBJ): %.c | $(COMMON_INC) $(INSTALL_INC)
@@ -285,7 +278,7 @@ YACCOPT ?= $($*_YACCOPT)
# must be a separate rule since when not using '-d' the
# prefix for .h will be different then .c
%.h: %.c %.y
%.h : %.c %.y
%.c: %.l
@$(RM) $@
@@ -329,10 +322,6 @@ $(LOADABLE_SHRLIBNAME): $(LOADABLE_SHRLIB_PREFIX)%$(LOADABLE_SHRLIB_SUFFIX):
$(LINK.shrlib)
$(MT_DLL_COMMAND)
$(LIBNAME) $(SHRLIBNAME) $(LOADABLE_SHRLIBNAME): | $(INSTALL_LIB)
$(INSTALL_LIB):
@$(MKDIR) $@
#---------------------------------------------------------------
# C++ munching for VxWorks
@@ -372,26 +361,23 @@ $(MODNAME): %$(MODEXT): %$(EXE)
#---------------------------------------------------------------
# Automated testing
runtests: run-tap-tests
run-tap-tests: | build
ifneq ($(TESTSCRIPTS.t),)
runtests: $(TESTSCRIPTS)
ifdef RUNTESTS_ENABLED
$(ECHO) "$(PROVE) $(TESTSCRIPTS.t)"
@$(PROVE) $(TESTSCRIPTS.t) || $(PROVE_FAILURE)
endif
-$(PERL) -MTest::Harness -e 'runtests @ARGV if @ARGV;' $^
endif
tapfiles: $(TAPFILES)
junitfiles: $(JUNITFILES)
# prevent deletion of partial output from failing tests
.PRECIOUS: $(TAPFILES) $(JUNITFILES)
testspec: $(TESTSCRIPTS)
@$(RM) $@
@echo OS-class: $(OS_CLASS) > $@
@echo Target-arch: $(T_A) >> $@
$(if $^, @echo Tests: $^ >> $@)
$(if $(TESTFILES), @echo Files: $(TESTFILES) >> $@)
$(if $(TESTSPEC_$(OS_CLASS)), @echo "Harness: $(TESTSPEC_$(OS_CLASS))" >> $@)
test-results: tap-results
tap-results: $(TAPFILES)
ifneq ($(strip $(TAPFILES)),)
test-results: tapfiles
ifneq ($(TAPFILES),)
ifdef RUNTESTS_ENABLED
$(ECHO) "$(PROVE.tap) $(TAPFILES)"
@$(PROVE.tap) $(TAPFILES) || $(PROVE_FAILURE)
prove --failures --ext .tap --exec "$(CAT)" --color $(TAPFILES)
endif
CURRENT_TAPFILES := $(wildcard $(TAPFILES))
@@ -399,21 +385,23 @@ CURRENT_JUNITFILES := $(wildcard $(JUNITFILES))
endif
clean-tests:
ifneq ($(CURRENT_TAPFILES)$(TAPS_FAILED_LOG),)
$(RM) $(CURRENT_TAPFILES) $(TAPS_FAILED_LOG)
ifneq ($(CURRENT_TAPFILES),)
$(RM) $(CURRENT_TAPFILES)
endif
ifneq ($(CURRENT_JUNITFILES),)
$(RM) $(CURRENT_JUNITFILES)
endif
tapfiles: $(TESTSCRIPTS) $(TAPFILES)
junitfiles: $(JUNITFILES)
# A .tap file is the output from running the associated test script
$(TAPFILES.t): %.tap: %.t | build
%.tap: %.t
ifdef RUNTESTS_ENABLED
$(ECHO) "$(PERL) $< -tap > $@"
@$(PERL) $< -tap > $@ || $(TAPFILE_FAILURE)
-$(PERL) $< -tap > $@
endif
$(JUNITFILES.t): %-results.xml: %.tap
%.xml: %.tap
$(TAPTOJUNIT) --puretap --output $@ --input $< $*
# If there's a perl test script (.plt) available, use it
@@ -428,23 +416,6 @@ $(JUNITFILES.t): %-results.xml: %.tap
$(PERL) $(TOOLS)/makeTestfile.pl $(T_A) $(EPICS_HOST_ARCH) $@ $<
#---------------------------------------------------------------
# Generate $(API_HEADER) files on request (%API.h)
ifdef API_HEADER
# Install them
INC += $(API_HEADER)
# Ensure we generate them early enough
INSTALL_API_HEADERS = $(addprefix $(INSTALL_INCLUDE)/,$(API_HEADER))
$(filter-out $(INSTALL_API_HEADERS), $(INSTALL_INC)) $(HDEPENDS_FILES): \
| $(INSTALL_API_HEADERS)
# How to make one
$(COMMON_DIR)/%API.h: $(TOOLS)/makeAPIheader.pl
@$(RM) $@
$(PERL) $(TOOLS)/makeAPIheader.pl -o $@ $(@:$(COMMON_DIR)/%API.h=%)
endif
# Generate header with version number from VCS
ifneq ($(GENVERSION),)
@@ -456,14 +427,14 @@ endif
# Install rules for BIN_INSTALLS and LIB_INSTALLS
define BIN_INSTALLS_template
$$(INSTALL_BIN)/$$(notdir $(1)): $(1)
$$(INSTALL_BIN)/$$(notdir $(1)) : $(1)
$(ECHO) "Installing $$(<F)"
@$$(INSTALL) -d -m $$(BIN_PERMISSIONS) $$^ $$(INSTALL_BIN)
endef
$(foreach file, $(BIN_INSTALLS), $(eval $(call BIN_INSTALLS_template, $(file))))
define LIB_INSTALLS_template
$$(INSTALL_LIB)/$$(notdir $(1)): $(1)
$$(INSTALL_LIB)/$$(notdir $(1)) : $(1)
$(ECHO) "Installing $$(<F)"
@$$(INSTALL) -d -m $$(LIB_PERMISSIONS) $$^ $$(INSTALL_LIB)
endef
@@ -513,11 +484,9 @@ $(INSTALL_TCLLIB)/%: ../%
@$(INSTALL) -d -m $(BIN_PERMISSIONS) $< $(INSTALL_TCLLIB)
endif
ifneq ($(TCLINDEX),)
$(INSTALL_TCLLIB)/$(TCLINDEX): $(INSTALL_TCLLIBS)
$(ECHO) "Updating $@"
$(ECHO) eval auto_mkindex $(INSTALL_TCLLIB) "$(TCLLIBNAME)" | tclsh
endif
$(INSTALL_LOADABLE_SHRLIBS): $(INSTALL_SHRLIB)/%: %
$(ECHO) "Installing loadable shared library $@"
@@ -539,19 +508,19 @@ $(INSTALL_CONFIG)/%: ../%
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
endif
$(INSTALL_INCLUDE)/%: $(COMMON_DIR)/%
$(INSTALL_INCLUDE)/% : $(COMMON_DIR)/%
$(ECHO) "Installing generated generic include file $@"
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
$(INSTALL_INCLUDE)/%: %
$(INSTALL_INCLUDE)/% : %
$(ECHO) "Installing generic include file $@"
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
$(INSTALL_INCLUDE)/os/$(OS_CLASS)/%: %
$(INSTALL_INCLUDE)/os/$(OS_CLASS)/% : %
$(ECHO) "Installing OS dependent include file $@"
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
$(INSTALL_INCLUDE)/compiler/$(CMPLR_CLASS)/%: %
$(INSTALL_INCLUDE)/compiler/$(CMPLR_CLASS)/% : %
$(ECHO) "Installing compiler dependent include file $@"
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
@@ -563,10 +532,6 @@ $(INSTALL_DOC)/%: ../%
$(ECHO) "Installing doc $@"
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(INSTALL_DOC)
$(INSTALL_HTML)/$(HTMLS_DIR)/%: $(COMMON_DIR)/%
$(ECHO) "Installing generated html $@"
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
$(INSTALL_HTML)/$(HTMLS_DIR)/%: %
$(ECHO) "Installing html $@"
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
@@ -575,6 +540,10 @@ $(INSTALL_HTML)/$(HTMLS_DIR)/%: ../%
$(ECHO) "Installing html $@"
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
$(INSTALL_HTML)/$(HTMLS_DIR)/%: $(COMMON_DIR)/%
$(ECHO) "Installing generated html $@"
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
$(INSTALL_TEMPLATES_SUBDIR)/%: ../%
$(ECHO) "Installing $@"
@$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D)
@@ -589,8 +558,8 @@ include $(CONFIG)/RULES_EXPAND
.PRECIOUS: $(COMMON_INC)
.PHONY: all host inc build install clean rebuild buildInstall build_clean
.PHONY: runtests run-tap-tests tapfiles junitfiles test-results tap-results
.PHONY: clean-tests checkRelease warnRelease noCheckRelease FORCE
.PHONY: runtests tapfiles clean-tests test-results junitfiles
.PHONY: checkRelease warnRelease noCheckRelease FORCE
include $(CONFIG)/RULES_COMMON

View File

@@ -27,7 +27,7 @@ $(foreach file,$(MAKEFILE_LIST), \
PRINT_Var = $(@:PRINT.%=%)
PRINT.%:
@+echo $(PRINT_Var) = '$($(PRINT_Var))'
@echo $(PRINT_Var) = '$($(PRINT_Var))'
.PHONY: PRINT PRINT.%

View File

@@ -4,7 +4,7 @@
# Copyright (c) 2002 The Regents of the University of California, as
# Operator of Los Alamos National Laboratory.
# EPICS BASE is distributed subject to a Software License Agreement found
# in the file LICENSE that is included with this distribution.
# in the file LICENSE that is included with this distribution.
#*************************************************************************
ARCHS += $(BUILD_ARCHS)
@@ -54,7 +54,7 @@ $(foreach dir, $(DIRS), \
define DEP_template2
$(1)$$(DIVIDER)$(2) : $$(foreach ddir, $$($(1)_DEPEND_DIRS), \
$$(addsuffix $$(DIVIDER)$(2),$$(ddir))) | before-$(2)
$$(addsuffix $$(DIVIDER)$(2),$$(ddir)))
endef
$(foreach action, $(ACTIONS), \
$(foreach dir, $(DIRS), \
@@ -79,24 +79,18 @@ $(foreach arch, $(ARCHS), \
dirPart = $(join $(dir $@), $(word 1, $(subst $(DIVIDER), ,$(notdir $@))))
actionArchPart = $(join $(word 2, $(subst $(DIVIDER), ,$(notdir $@))), \
$(addprefix $(DIVIDER),$(word 3, $(subst $(DIVIDER), ,$(notdir $@)))))
$(DIRS) $(dirActionTargets) $(dirArchTargets) $(dirActionArchTargets):
$(addprefix $(DIVIDER),$(word 3, $(subst $(DIVIDER), ,$(notdir $@)))))
$(DIRS) $(dirActionTargets) $(dirArchTargets) $(dirActionArchTargets) :
$(MAKE) -C $(dirPart) $(actionArchPart)
# before-action rules are run once prior to recursing through the
# list of subdirectories and running the action rule in each one.
# See DEP_template2 above for how that rule ordering is achieved.
beforeActions = $(addprefix before-,$(ACTIONS))
$(beforeActions):
$(ARCHS) $(ACTIONS) $(actionArchTargets) :%: \
$(foreach dir, $(DIRS), $(dir)$(DIVIDER)%)
.PHONY : $(DIRS) all host rebuild
.PHONY : $(ARCHS) $(ACTIONS) $(beforeActions)
.PHONY : $(dirActionTargets) $(dirArchTargets)
.PHONY : $(dirActionArchTargets)
.PHONY : $(actionArchTargets)
.PHONY: $(DIRS) all host rebuild
.PHONY: $(ARCHS) $(ACTIONS)
.PHONY: $(dirActionTargets) $(dirArchTargets)
.PHONY: $(dirActionArchTargets)
.PHONY: $(actionArchTargets)
include $(CONFIG)/RULES_COMMON

View File

@@ -12,67 +12,28 @@
vpath %@ $(USR_VPATH) $(ALL_SRC_DIRS)
#---------------------------------------------------------------
# Template variable expansion
# This feature allows you to instantiate simple template files at
# build-time, replacing macros spelled @NAME@ with values provided
# by the Makefile. The template filename must end with an @ sign,
# which is removed to create the expanded filename.
# Makefiles can use this variable expansion as follows:
#
# 1. Add the template filename (with the trailing @ sign) to either
# the EXPAND or EXPAND_COMMON variable, for example:
# EXPAND_COMMON += myVersion.h@
# Use EXPAND_COMMON for templates that don't depend on the
# target architecture (these will be generated in O.Common).
# 2. There are 2 ways of defining template macros. The simplest
# is to add a NAME=VALUE string to the EXPAND_VARS variable for
# the desired macros, e.g.:
# EXPAND_VARS += MY_MAJOR_VERSION=$(MY_MAJOR_VERSION)
# EXPAND_VARS += MY_MINOR_VERSION=$(MY_MINOR_VERSION)
# These values may not contain spaces, even if inside quotes.
# 3. A better way in the above case is to add the names of any
# Makefile variables that should be provided as macros to the
# variable EXPAND_ME, like this:
# EXPAND_ME += MY_MAJOR_VERSION
# EXPAND_ME += MY_MINOR_VERSION
# The values of these variables may contain spaces.
# 4. The macros TOP and ARCH will be set by the build system.
# TOP is the value of $(INSTALL_LOCATION) for this module.
# ARCH is the target architecture $(T_A), but is only set
# while expanding files in EXPAND
# 5. Add the expanded filename to some other variable that will
# cause it to be created and used, such as INC here:
# INC += myVersion.h
# Variable expansion
# Default settings
EXPAND_TOOL ?= $(PERL) $(TOOLS)/expandVars.pl $(QUIET_FLAG)
EXPAND_TOOL ?= $(PERL) $(TOOLS)/expandVars.pl
EXPANDARCH = -a $(T_A)
EXPANDFLAGS += -t $(INSTALL_LOCATION)
EXPANDFLAGS += $(addprefix -D ,$(EXPAND_VARS) $($@_EXPAND_VARS))
EXPANDFLAGS += $(foreach var, $(EXPAND_ME) $($@_EXPAND_ME), \
-D$(var)="$(strip $($(var)))")
EXPANDFLAGS += -t $(INSTALL_LOCATION) -a $(T_A)
EXPANDFLAGS += $(addprefix -D ,$(EXPAND_VARS))
# Output files
# The names of files to be expanded must end with '@'
EXPANDED = $(EXPAND:%@=%)
EXPANDED_COMMON = $(EXPAND_COMMON:%@=$(COMMON_DIR)/%)
$(EXPANDED): %: %@
$(ECHO) "Expanding $< to $@"
$(EXPAND_TOOL) $(EXPANDARCH) $(EXPANDFLAGS) $($@_EXPANDFLAGS) $< $@
$(EXPANDED_COMMON): $(COMMON_DIR)/%: %@
$(ECHO) "Expanding $< to $(COMMON_DIR)/$@"
$(EXPAND_TOOL) $(EXPANDFLAGS) $($@_EXPANDFLAGS) $< $@
@$(RM) $@
@$(EXPAND_TOOL) $(EXPANDFLAGS) $($@_EXPANDFLAGS) $< $@
clean: expand_clean
expand_clean:
@$(RM) $(EXPANDED) $(EXPANDED_COMMON)
@$(RM) $(EXPANDED)
.PRECIOUS: $(EXPANDED) $(EXPANDED_COMMON)
.PRECIOUS: $(EXPANDED)
.PHONY: expand_clean
#---------------------------------------------------------------
@@ -81,10 +42,8 @@ expand_clean:
ASSEMBLE_TOOL ?= $(PERL) $(TOOLS)/assembleSnippets.pl
define COMMON_ASSEMBLY_template
ifneq '$$($1_PATTERN)' ''
$1_SNIPPETS += $$(foreach dir, .. $$(SRC_DIRS), \
$$(wildcard $$(dir)/$$($1_PATTERN)))
endif
$(COMMON_DIR)/$1: $$($1_SNIPPETS)
$(ECHO) "Assembling common file $$@ from snippets"
@$(RM) $1
@@ -95,10 +54,8 @@ $(foreach asy, $(COMMON_ASSEMBLIES), \
$(eval $(call COMMON_ASSEMBLY_template,$(strip $(asy)))))
define ASSEMBLY_template
ifneq '$$($1_PATTERN)' ''
$1_SNIPPETS += $$(foreach dir, .. $$(SRC_DIRS), \
$$(wildcard $$(dir)/$$($1_PATTERN)))
endif
$1: $$($1_SNIPPETS)
$(ECHO) "Assembling file $$@ from snippets"
@$(RM) $$@
@@ -113,3 +70,4 @@ $1$(DEP):
endef
$(foreach asy, $(sort $(COMMON_ASSEMBLIES) $(ASSEMBLIES)), \
$(eval $(call ASSEMBLY_DEP_template,$(strip $(asy)))))

View File

@@ -22,14 +22,12 @@
# 7. Submodules must have a configure/CONFIG_SITE file that contains
# -include $(TOP)/../CONFIG_SITE.local
# Add checked-out submodules to DIRS, unless INSTALL_LOCATION is empty
LIVE_SUBMODULES = $(subst /Makefile,, \
$(wildcard $(addsuffix /Makefile, $(SUBMODULES))))
live = $(if $(wildcard $(INSTALL_CONFIG)/RULES_TOP),LIVE,DEAD)
DIRS += $($(live)_SUBMODULES)
# Add checked-out submodules to DIRS
DIRS += $(subst /Makefile,,$(wildcard $(addsuffix /Makefile, $(SUBMODULES))))
include $(CONFIG)/RULES_DIRS
INSTALL_LOCATION_ABS := $(abspath $(INSTALL_LOCATION))
RELEASE_LOCAL := RELEASE.$(EPICS_HOST_ARCH).local
# Ensure that RELEASE.<host>.local exists before doing anything else
@@ -39,17 +37,11 @@ all host $(DIRS) $(ARCHS) $(ACTIONS) $(dirActionTargets) $(dirArchTargets) \
# Convenience target
RELEASE.host: $(RELEASE_LOCAL)
$(RELEASE_LOCAL): Makefile $(CONFIG)/CONFIG_SITE \
$(wildcard $(CONFIG)/CONFIG_SITE.local)
$(RELEASE_LOCAL): Makefile CONFIG_SITE.local
$(ECHO) Creating $@ with
$(ECHO) " $(PARENT_MODULE) = $(INSTALL_ABSOLUTE)"
@echo $(PARENT_MODULE) = $(INSTALL_ABSOLUTE)> $@
$(ECHO) " $(PARENT_MODULE) = $(INSTALL_LOCATION_ABS)"
@echo $(PARENT_MODULE) = $(INSTALL_LOCATION_ABS)> $@
realclean:
$(RM) $(wildcard RELEASE.*.local)
.PHONY: RELEASE.host
# Testing: Combine test failure logs from the live submodules
TESTS_FAILED_LOGS = $(wildcard $(addsuffix /$(TESTS_FAILED_LOG), \
$(LIVE_SUBMODULES)))
runtests test-results: % : | $(addsuffix $(DIVIDER)%, $(LIVE_SUBMODULES))
$(if $(TESTS_FAILED_LOGS), \
@$(CAT) $(TESTS_FAILED_LOGS)>> $(TESTS_FAILED_PATH))
.PHONY: RELEASE.host realclean

View File

@@ -21,6 +21,7 @@ $(foreach target, $(PROD) $(TESTPROD) $(LIBRARY) $(TESTLIBRARY) $(LOADABLE_LIBRA
#-----------------------------------------------------------------------
# This define block requires GNU make 3.81
define PROD_template
ifeq ($$(strip $$($(1)_OBJS) $$($(1)_SRCS) $$(PRODUCT_OBJS)),)
$(1)_OBJS = $(1)$$(OBJ)
@@ -94,20 +95,12 @@ $(1)_DLL_DEPLIBS=$$(foreach lib, $$($(1)_DLL_LIBS), \
$$(LIB_PREFIX)$(1)$$(LIB_SUFFIX):$$($(1)_OBJSNAME) $$($(1)_RESS)
$$(LIB_PREFIX)$(1)$$(LIB_SUFFIX):$$($(1)_DEPLIBS)
ifneq ($$($(1)_API),)
$$(LIB_PREFIX)$(1)$$(LIB_SUFFIX): API_CPPFLAGS += -DBUILDING_$$($(1)_API)_API
endif
ifeq ($$(SHARED_LIBRARIES),YES)
ifdef SHRLIB_SUFFIX
$$(SHRLIB_PREFIX)$(1)$$(SHRLIB_SUFFIX):$$($(1)_OBJSNAME) $$($(1)_RESS)
$$(SHRLIB_PREFIX)$(1)$$(SHRLIB_SUFFIX):$$($(1)_DEPLIBS)
$$(SHRLIB_PREFIX)$(1)$$(SHRLIB_SUFFIX):$$($(1)_DLL_DEPLIBS)
ifneq ($$($(1)_API),)
$$(SHRLIB_PREFIX)$(1)$$(SHRLIB_SUFFIX): API_CPPFLAGS += -DBUILDING_$$($(1)_API)_API
endif
endif
endif
@@ -148,11 +141,6 @@ $(1)_DLL_DEPLIBS=$$(foreach lib, $$($(1)_DLL_LIBS),\
$$(LOADABLE_SHRLIB_PREFIX)$(1)$$(LOADABLE_SHRLIB_SUFFIX):$$($(1)_OBJSNAME) $$($(1)_RESS)
$$(LOADABLE_SHRLIB_PREFIX)$(1)$$(LOADABLE_SHRLIB_SUFFIX):$$($(1)_DEPLIBS)
$$(LOADABLE_SHRLIB_PREFIX)$(1)$$(LOADABLE_SHRLIB_SUFFIX):$$($(1)_DLL_DEPLIBS)
ifneq ($$($(1)_API),)
$$(LOADABLE_SHRLIB_PREFIX)$(1)$$(LOADABLE_SHRLIB_SUFFIX): \
API_CPPFLAGS += -DBUILDING_$$($(1)_API)_API
endif
endef
$(foreach target, $(LOADABLE_LIBRARY), \

View File

@@ -23,66 +23,59 @@ ifndef DISABLE_TOP_RULES
# Rules for a regular application top directory
#
# When run by 'make distclean' the realuninstall target also
# removes any modules/RELEASE.<host>.local files
distclean: realclean cvsclean realuninstall
distclean: realclean cvsclean realuninstall
realuninstall: uninstallDirs
$(RMDIR) $(INSTALL_LOCATION_BIN) $(INSTALL_LOCATION_LIB)
ifeq (modules,$(filter modules,$(DIRS)))
ifeq (distclean,$(filter distclean,$(MAKECMDGOALS)))
$(RM) $(wildcard modules/RELEASE.*.local)
endif
endif
realuninstall: uninstallDirs
$(RMDIR) $(INSTALL_LOCATION_BIN)
$(RMDIR) $(INSTALL_LOCATION_LIB)
UNINSTALL_DIRS += $(INSTALL_DB) $(INSTALL_DBD) $(INSTALL_DOC) $(INSTALL_HTML)
UNINSTALL_DIRS += $(INSTALL_INCLUDE) $(INSTALL_TEMPLATES) $(DIRECTORY_TARGETS)
ifneq ($(INSTALL_LOCATION),$(TOP))
UNINSTALL_DIRS += $(INSTALL_CONFIG)
endif
uninstallDirs:
UNINSTALL_DIRS += $(INSTALL_DB) $(INSTALL_DBD) $(INSTALL_DOC) $(INSTALL_HTML)
UNINSTALL_DIRS += $(INSTALL_INCLUDE) $(INSTALL_TEMPLATES) $(DIRECTORY_TARGETS)
ifneq ($(INSTALL_LOCATION),$(TOP))
UNINSTALL_DIRS += $(INSTALL_CONFIG)
endif
uninstallDirs:
$(RMDIR) $(UNINSTALL_DIRS)
# Remove the bin and lib directories if they have no sub-directories
#
EMPTY_INSTALL_DIRS = \
$(if $(wildcard $(INSTALL_LOCATION_BIN)/*),,$(INSTALL_LOCATION_BIN)) \
$(if $(wildcard $(INSTALL_LOCATION_LIB)/*),,$(INSTALL_LOCATION_LIB))
uninstall: archuninstall uninstallDirs
$(RMDIR) $(EMPTY_INSTALL_DIRS)
uninstall: archuninstall uninstallDirs
archuninstall: $(addprefix uninstall$(DIVIDER),$(BUILD_ARCHS))
archuninstall: $(addprefix uninstall$(DIVIDER),$(BUILD_ARCHS)) | cleandirs
uninstall$(DIVIDER)%:
$(RMDIR) $(addsuffix /$(subst uninstall$(DIVIDER),,$@), \
$(INSTALL_LOCATION_BIN) $(INSTALL_LOCATION_LIB))
archPart = $(word 2, $(subst $(DIVIDER), ,$@))
uninstall$(DIVIDER)%:
$(RMDIR) $(INSTALL_LOCATION_BIN)/$(archPart)
$(RMDIR) $(INSTALL_LOCATION_LIB)/$(archPart)
# Only run this at the top of the parent
runtests test-results:
@$(SHOWTESTFAILURES)
# Remove the bin and lib directories if they have no sub-directories
#
cleandirs:
@$(NOP)
ifeq ($(wildcard $(INSTALL_LOCATION_BIN)/*),)
$(RMDIR) $(INSTALL_LOCATION_BIN)
endif
ifeq ($(wildcard $(INSTALL_LOCATION_LIB)/*),)
$(RMDIR) $(INSTALL_LOCATION_LIB)
endif
else
#
# Using a disabled rule aborts
#
distclean uninstall realuninstall archuninstall:
cleandirs distclean uninstall realuninstall archuninstall:
$(error Target '$@' not available in a submodule)
endif # DISABLE_TOP_RULES
# Clean out old results
before-runtests before-test-results: rm-failure-file
rm-failure-file:
$(RM) $(TESTS_FAILED_PATH)
help:
@echo "Usage: gnumake [options] [target] ..."
@echo "Targets supported by all Makefiles:"
@echo " all - Same as install (default rule)"
@echo " inc - Installs header, dbd and html files"
@echo " inc - Installs header files"
@echo " build - Builds and installs all targets"
@echo " install - Builds and installs all targets"
@echo " buildInstall - Same as install (deprecated)"
@echo " clean - Removes the O.<arch> dirs created by running make"
@echo " In O.<arch> dir, clean removes build created files"
@echo " realclean - Removes ALL O.<arch> dirs"
@@ -107,14 +100,13 @@ ifndef DISABLE_TOP_RULES
@echo " uninstall$(DIVIDER)<arch> - Remove bin & lib directories for <arch> only."
@echo " uninstall - Remove install directories created by this hostarch."
@echo " realuninstall - Removes ALL install dirs"
@echo " distclean - Does realclean cvsclean realuninstall and deletes any"
@echo " generated modules/RELEASE.<host>.local files"
@echo " distclean - Same as realclean cvsclean realuninstall."
endif
@echo " help - Prints this list of valid make targets "
@echo "Object targets are supported by the O.<arch> level Makefile .e.g"
@echo " xxxRecord.o"
.PHONY: distclean uninstall rm-failure-file help
.PHONY: cleandirs distclean uninstall help
.PHONY: realuninstall archuninstall uninstallDirs
ifndef DISABLE_TOP_RULES

View File

@@ -3,8 +3,8 @@
# National Laboratory.
# Copyright (c) 2002 The Regents of the University of California, as
# Operator of Los Alamos National Laboratory.
# SPDX-License-Identifier: EPICS
# EPICS Base is distributed subject to a Software License Agreement found
# EPICS BASE Versions 3.13.7
# and higher are distributed subject to a Software License Agreement found
# in file LICENSE that is included with this distribution.
#*************************************************************************
# Makefile for base/src/sample

View File

@@ -0,0 +1,4 @@
# Include definitions common to linux pentium targets
include $(CONFIG)/os/CONFIG.Common.linux-x86_64
ARCH_DEP_CXXFLAGS += -fno-strict-aliasing

View File

@@ -0,0 +1 @@
include $(CONFIG)/os/CONFIG.Common.linux-clang

View File

@@ -28,13 +28,12 @@ ifneq ($(CONFIG),$(TOP)/configure)
endif
#--------------------------------------------------
# Set RTEMS_BSP and GNU_TARGET if not already done
# Set RTEMS_BSP from T_A if not already done
RTEMS_BSP ?= $(subst RTEMS-,,$(T_A))
GNU_TARGET ?= $(RTEMS_TARGET_CPU)-rtems
#-------------------------------------------------------
# Pick up the RTEMS tool/path definitions from the RTEMS BSP directory.
include $(RTEMS_BASE)/$(GNU_TARGET)$(RTEMS_VERSION)/$(RTEMS_BSP)/Makefile.inc
include $(RTEMS_BASE)/$(RTEMS_TARGET_CPU)-rtems$(RTEMS_VERSION)/$(RTEMS_BSP)/Makefile.inc
include $(RTEMS_CUSTOM)
include $(CONFIG.CC)
@@ -42,7 +41,7 @@ include $(CONFIG.CC)
# RTEMS cross-development tools
CC = $(RTEMS_TOOLS)/bin/$(CC_FOR_TARGET) $(GCCSPECS) -fasm
CCC = $(RTEMS_TOOLS)/bin/$(CXX)
CPP = $(RTEMS_TOOLS)/bin/$(CC_FOR_TARGET) -x c -E $(GCCSPECS)
CPP = $(RTEMS_TOOLS)/bin/$(CC_FOR_TARGET) -x c -E
AR = $(RTEMS_TOOLS)/bin/$(AR_FOR_TARGET)
LD = $(RTEMS_TOOLS)/bin/$(LD_FOR_TARGET) -r
@@ -63,7 +62,7 @@ CFLAGS = $($(BUILD_CLASS)_CFLAGS) $(POSIX_CFLAGS) $(OPT_CFLAGS)\
CXXFLAGS = $($(BUILD_CLASS)_CXXFLAGS) $(POSIX_CXXFLAGS) $(OPT_CXXFLAGS)\
$(DEBUG_CXXFLAGS) $(PIPE_CFLAGS) $(WARN_CXXFLAGS) $(TARGET_CXXFLAGS)\
$(USR_CXXFLAGS) $(CMD_CXXFLAGS) $(ARCH_DEP_CXXFLAGS) $(CODE_CXXFLAGS)\
$(STATIC_CXXFLAGS) $(OP_SYS_CXXFLAGS) $(LIBRARY_SRC_CFLAGS)
$(STATIC_CXXCFLAGS) $(OP_SYS_CXXFLAGS) $(LIBRARY_SRC_CFLAGS)
LDFLAGS = $(OPT_LDFLAGS) $(TARGET_LDFLAGS) $(USR_LDFLAGS) $(CMD_LDFLAGS)\
$(POSIX_LDFLAGS) $(ARCH_DEP_LDFLAGS) $(DEBUG_LDFLAGS) $(OP_SYS_LDFLAGS)\
@@ -77,10 +76,7 @@ CPPFLAGS += $($(BUILD_CLASS)_CPPFLAGS) $(POSIX_CPPFLAGS) $(OPT_CPPFLAGS)\
$(USR_CPPFLAGS) $(CMD_CPPFLAGS) $(ARCH_DEP_CPPFLAGS) $(OP_SYS_CPPFLAGS)\
$(OP_SYS_INCLUDE_CPPFLAGS) $(CODE_CPPFLAGS)
ECHO = @$(if $(make-s),$(NOP),echo)
# Originally set in os/CONFIG.UnixCommon.Common
MKDIR = mkdir -p
ECHO = @$(if $(findstring s,$(MFLAGS)),$(NOP),echo)
#--------------------------------------------------
# Although RTEMS uses gcc, it wants to use gcc its own way
@@ -99,39 +95,20 @@ MODEXT=.obj
OS_CLASS = RTEMS
#--------------------------------------------------
# Operating system compile & link flags
OP_SYS_CFLAGS += -D__LINUX_ERRNO_EXTENSIONS__
OP_SYS_CFLAGS_NET_yes = -DRTEMS_LEGACY_STACK
OP_SYS_CFLAGS += $(OP_SYS_CFLAGS_NET_$(RTEMS_HAS_NETWORKING))
ifeq ($(RTEMS_HAS_POSIX_API),yes)
POSIX_CPPFLAGS = -D_GNU_SOURCE -D_DEFAULT_SOURCE
endif
OP_SYS_LDLIBS_posix_NET_yes = -ltftpfs -lnfs -lz -ltelnetd
OP_SYS_LDLIBS_posix_NET_no = -ltftpfs -lbsd -lz
OP_SYS_LDLIBS_score_NET_yes = -lnfs
OP_SYS_LDLIBS_score_NET_no = -lnfs
OP_SYS_LDLIBS += -lrtemsCom -lCom
OP_SYS_LDLIBS += $(OP_SYS_LDLIBS_$(OS_API)_NET_$(RTEMS_HAS_NETWORKING))
OP_SYS_LDLIBS += -lrtemscpu -lc -lm
OP_SYS_LDFLAGS_posix = -u POSIX_Init
OP_SYS_LDFLAGS_score = -u Init \
# Operating system flags
OP_SYS_LDLIBS += -lrtemsCom -lc -lrtemscpu -lCom -lnfs -lm
OP_SYS_LDFLAGS += $(CPU_CFLAGS) -u Init \
$(PROJECT_RELEASE)/lib/no-dpmem.rel \
$(PROJECT_RELEASE)/lib/no-mp.rel \
$(PROJECT_RELEASE)/lib/no-part.rel \
$(PROJECT_RELEASE)/lib/no-signal.rel \
$(PROJECT_RELEASE)/lib/no-rtmon.rel
OP_SYS_LDFLAGS += $(CPU_CFLAGS) $(OP_SYS_LDFLAGS_$(OS_API))
# Settings for GeSys
MOD_SYS_LDFLAGS += $(CPU_CFLAGS) -Wl,-r -nostdlib
# Do not link against libraries which are part of the Generic Image
GESYS_LIBS += -lgcc
GESYS_LIBS += -lc -lm -lrtemscpu -lrtemsbsp -lrtems++
GESYS_LIBS += -lc -lm -lrtemscpu -lrtemsbsp -lrtems++ -lbspExt
GESYS_LIBS += -lcexp -ltecla_r -lspencer_regexp -lpmelf -lpmbfd
GESYS_LIBS += -lnfs -ltelnetd -lrtems-gdb-stub

View File

@@ -0,0 +1,14 @@
#
# CONFIG.Common.RTEMS-at91rm9200ek
# Author: Ralf Hartmann
# BESSY
# Ralf.Hartmann@bessy.de
#
# Atmel AT91RM9200-EK evaluation kit
# using the AT91RM9200 ARM9-based 32-bit RISC microcontroller
#
# All RTEMS targets use the same Makefile fragment
#
RTEMS_BSP = at91rm9200ek
RTEMS_TARGET_CPU = arm
include $(CONFIG)/os/CONFIG.Common.RTEMS

View File

@@ -1,18 +0,0 @@
#
# CONFIG.Common.RTEMS-beaglebineblack
# Author: Heinz Junkes <junkes@fhi-berlin.mpg.de>
#
# All RTEMS targets use the same Makefile fragment
#
#EXE = .elf
RTEMS_BSP = beagleboneblack
RTEMS_TARGET_CPU = arm
GNU_TARGET = arm-rtems
OP_SYS_LDLIBS += -Wl,--gc-sections
ARCH_DEP_LDFLAGS = -L$(RTEMS_BASE)/$(GNU_TARGET)$(RTEMS_VERSION)/beagleboneblack/lib/
include $(CONFIG)/os/CONFIG.Common.RTEMS

View File

@@ -8,16 +8,14 @@ EXE = .elf
RTEMS_BSP = beatnik
RTEMS_TARGET_CPU = powerpc
GNU_TARGET = powerpc-rtems
# optimization trouble in postfix.c
ARCH_DEP_CFLAGS += -DRTEMS_HAS_ALTIVEC
#will use bootp
#ARCH_DEP_CFLAGS += -DMY_DO_BOOTP=NULL
ARCH_DEP_CFLAGS += -DMY_DO_BOOTP=NULL
ARCH_DEP_CFLAGS += -DHAVE_MOTLOAD
ARCH_DEP_CFLAGS += -DRTEMS_NETWORK_CONFIG_MBUF_SPACE=2048
ARCH_DEP_CFLAGS += -DRTEMS_NETWORK_CONFIG_CLUSTER_SPACE=5120
OP_SYS_LDLIBS += -lbspExt
MUNCH_SUFFIX = .boot
MUNCHNAME = $(PRODNAME:%$(EXE)=%$(MUNCH_SUFFIX))
define MUNCH_CMD
$(RTEMS_TOOLS)/bin/$(OBJCOPY_FOR_TARGET) -O binary $< $@
endef

View File

@@ -0,0 +1,10 @@
#
# Author: W. Eric Norum
# Canadian Light Source
# eric@cls.usask.ca
#
# All RTEMS targets use the same Makefile fragment
#
RTEMS_BSP = gen68360
RTEMS_TARGET_CPU = m68k
include $(CONFIG)/os/CONFIG.Common.RTEMS

View File

@@ -0,0 +1,10 @@
#
# Author: W. Eric Norum
# Canadian Light Source
# eric@cls.usask.ca
#
# All RTEMS targets use the same Makefile fragment
#
RTEMS_BSP = mcp750
RTEMS_TARGET_CPU = ppc
include $(CONFIG)/os/CONFIG.Common.RTEMS

View File

@@ -0,0 +1,10 @@
#
# Author: W. Eric Norum
# Canadian Light Source
# eric@cls.usask.ca
#
# All RTEMS targets use the same Makefile fragment
#
RTEMS_BSP = mvme167
RTEMS_TARGET_CPU = m68k
include $(CONFIG)/os/CONFIG.Common.RTEMS

View File

@@ -11,6 +11,8 @@ GNU_TARGET = powerpc-rtems
ARCH_DEP_CFLAGS += -DMY_DO_BOOTP=NULL
ARCH_DEP_CFLAGS += -DHAVE_PPCBUG
OP_SYS_LDLIBS += -lbspExt
MUNCH_SUFFIX = .boot
define MUNCH_CMD
$(RTEMS_TOOLS)/bin/$(OBJCOPY_FOR_TARGET) -O binary -R .comment -S $< rtems
@@ -19,7 +21,6 @@ define MUNCH_CMD
$(PROJECT_RELEASE)/lib/bootloader.o \
--just-symbols=$< \
-b binary rtems.gz \
--no-warn-mismatch \
-T $(PROJECT_RELEASE)/lib/ppcboot.lds \
-Map $<.map
rm -f rtems.gz

View File

@@ -1,7 +1,7 @@
#
# Author: Matt Rippa
#
RTEMS_BSP = mvme2307
RTEMS_BSP = mvme2700
RTEMS_TARGET_CPU = powerpc
ARCH_DEP_CFLAGS += -DMY_DO_BOOTP=NULL
ARCH_DEP_CFLAGS += -DHAVE_PPCBUG
@@ -11,15 +11,15 @@ MUNCH_SUFFIX = .boot
define MUNCH_CMD
$(RTEMS_TOOLS)/bin/$(OBJCOPY_FOR_TARGET) -O binary -R .comment -S $< rtems
gzip -f9 rtems
$(RTEMS_TOOLS)/bin/$(LD_FOR_TARGET) -o $@.elf \
$(RTEMS_TOOLS)/bin/$(LD_FOR_TARGET) -o $@ \
$(PROJECT_RELEASE)/lib/bootloader.o \
--just-symbols=$< \
-b binary rtems.gz \
--no-warn-mismatch \
-T $(PROJECT_RELEASE)/lib/ppcboot.lds \
-Map $<.map
$(RTEMS_TOOLS)/bin/$(OBJCOPY_FOR_TARGET) -O binary $@.elf $@
rm -f rtems.gz $@.elf
rm -f rtems.gz
endef
OP_SYS_LDLIBS += -lbspExt
include $(CONFIG)/os/CONFIG.Common.RTEMS

View File

@@ -13,6 +13,8 @@ ARCH_DEP_CFLAGS += -DHAVE_MOTLOAD
ARCH_DEP_CFLAGS += -DRTEMS_NETWORK_CONFIG_MBUF_SPACE=2048
ARCH_DEP_CFLAGS += -DRTEMS_NETWORK_CONFIG_CLUSTER_SPACE=5120
OP_SYS_LDLIBS += -lbspExt
MUNCH_SUFFIX = .boot
define MUNCH_CMD
$(RTEMS_TOOLS)/bin/$(OBJCOPY_FOR_TARGET) -O binary $< $@

View File

@@ -14,9 +14,13 @@ ARCH_DEP_CFLAGS += -DRTEMS_NETWORK_CONFIG_MBUF_SPACE=2048
ARCH_DEP_CFLAGS += -DRTEMS_NETWORK_CONFIG_CLUSTER_SPACE=5120
ARCH_DEP_CFLAGS += -DBSP_NVRAM_BASE_ADDR=0xf1110000
OP_SYS_LDLIBS += -lbspExt
MUNCH_SUFFIX = .boot
define MUNCH_CMD
$(RTEMS_TOOLS)/bin/$(OBJCOPY_FOR_TARGET) -O binary $< $@
endef
OP_SYS_LDLIBS += -lbspExt
include $(CONFIG)/os/CONFIG.Common.RTEMS

View File

@@ -1,13 +1,12 @@
# CONFIG.Common.RTEMS-pc386
#
# Definitions for the RTEMS-pc386 target, RTEMS 4.x only
# Site-specific overrides go in CONFIG_SITE.Common.RTEMS-pc386
# Author: W. Eric Norum
# Canadian Light Source
# eric@cls.usask.ca
#
# All RTEMS targets use the same Makefile fragment
#
#-------------------------------------------------------
RTEMS_BSP = pc386
RTEMS_TARGET_CPU = i386
GNU_TARGET = i386-rtems
MUNCH_SUFFIX = .boot
define MUNCH_CMD
@@ -23,10 +22,3 @@ include $(CONFIG)/os/CONFIG.Common.RTEMS
# Put text segment where it will work with etherboot
#
OP_SYS_LDFLAGS += -Wl,-Ttext,0x100000
# This check must appear after the above include
ifeq ($(RTEMS_VERSION),5)
$(info *** This target is not compatible with the configured RTEMS version.)
$(info *** Build the RTEMS-pc686 (-qemu) target for RTEMS 5.x)
$(error Can't continue)
endif

View File

@@ -6,7 +6,6 @@
#-------------------------------------------------------
# Include definitions from RTEMS-pc386
# For Tests overwrite it with pc686
include $(CONFIG)/os/CONFIG.Common.RTEMS-pc386
RTEMS_QEMU_FIXUPS = YES

View File

@@ -1,39 +0,0 @@
# CONFIG.Common.RTEMS-pc686
#
# Definitions for the RTEMS-pc686 target, RTEMS 5.x only
# Site-specific overrides go in CONFIG_SITE.Common.RTEMS-pc686
#
#-------------------------------------------------------
#
# Author: W. Eric Norum
# Canadian Light Source
# eric@cls.usask.ca
#
# All RTEMS targets use the same Makefile fragment
#
RTEMS_BSP = pc686
RTEMS_TARGET_CPU = i386
GNU_TARGET = i386-rtems
MUNCH_SUFFIX = .boot
define MUNCH_CMD
$(RTEMS_TOOLS)/bin/$(OBJCOPY_FOR_TARGET) -O binary -R .comment -S $< $@
endef
OP_SYS_LDLIBS += -Wl,--gc-sections
ARCH_DEP_LDFLAGS = -L$(RTEMS_BASE)/$(GNU_TARGET)$(RTEMS_VERSION)/pc686/lib/
include $(CONFIG)/os/CONFIG.Common.RTEMS
#
# Put text segment where it will work with etherboot
#
OP_SYS_LDFLAGS += -Wl,-Ttext,0x100000
# This check must appear after the above include
ifneq ($(RTEMS_VERSION),5)
$(info *** This target is not compatible with the configured RTEMS version.)
$(info *** Build the RTEMS-pc386 (-qemu) target for RTEMS 4.x)
$(error Can't continue)
endif

View File

@@ -1,11 +0,0 @@
# CONFIG.Common.RTEMS-pc686-qemu
#
# Definitions for the RTEMS-pc686-qemu target
# Site-specific overrides go in CONFIG_SITE.Common.RTEMS-pc686-qemu
#
#-------------------------------------------------------
# Include definitions from RTEMS-pc686
include $(CONFIG)/os/CONFIG.Common.RTEMS-pc686
RTEMS_QEMU_FIXUPS = YES

View File

@@ -0,0 +1,10 @@
#
# Author: W. Eric Norum
# University of Saskatchewan
# eric.norum@usask.ca
#
# All RTEMS targets use the same Makefile fragment
#
RTEMS_BSP = psim
RTEMS_TARGET_CPU = ppc
include $(CONFIG)/os/CONFIG.Common.RTEMS

View File

@@ -1,48 +0,0 @@
#
# CONFIG.Common.RTEMS-qoriq_e500
# Author: Heinz Junkes <junkes@fhi-berlin.mpg.de>
#
# All RTEMS targets use the same Makefile fragment
#
EXE = .elf
RTEMS_BSP = qoriq_e500
RTEMS_TARGET_CPU = powerpc
GNU_TARGET = powerpc-rtems
# optimization trouble in postfix.c
ARCH_DEP_CFLAGS += -DRTEMS_HAS_ALTIVEC
#will use bootp
#ARCH_DEP_CFLAGS += -DMY_DO_BOOTP=NULL
#ARCH_DEP_CFLAGS += -DRTEMS_NETWORK_CONFIG_MBUF_SPACE=2048
#ARCH_DEP_CFLAGS += -DRTEMS_NETWORK_CONFIG_CLUSTER_SPACE=5120
#netbsdlib
#ARCH_DEP_CFLAGS += -I$(RTEMS_BASE)/powerpc-rtems5/qoriq_e500/lib/include
#OP_SYS_LDLIBS += -lbspExt #does not use posix stuff ... want to ignore
OP_SYS_LDLIBS += -Wl,--gc-sections
#ARCH_DEP_LDFLAGS = -mcpu=8540 -meabi -msdata=sysv -mstrict-align -mspe -mabi=spe -mfloat-gprs=double
ARCH_DEP_LDFLAGS = -L$(RTEMS_BASE)/$(GNU_TARGET)$(RTEMS_VERSION)/$(RTEMS_BSP)/lib
MUNCH_SUFFIX = .img
MUNCHNAME = $(PRODNAME:%$(EXE)=%$(MUNCH_SUFFIX))
define MUNCH_CMD
$(RTEMS_TOOLS)/bin/$(OBJCOPY_FOR_TARGET) -O binary $< $@
gzip -9 -f $@
$(RTEMS_TOOLS)/bin/mkimage.py -A ppc -O linux -T kernel -a 0x4000 -e 0x4000 -n $* -d $@.gz $*.img
endef
include $(CONFIG)/os/CONFIG.Common.RTEMS
RTEMSSYMS=$(PRODNAME:%$(EXE)=%.sym)
RTEMSIMGS=$(PRODNAME:%$(EXE)=%.bin)
INSTALL_RTEMSSYMS=$(RTEMSSYMS:%=$(INSTALL_BIN)/%)
INSTALL_RTEMSIMGS=$(RTEMSIMGS:%=$(INSTALL_BIN)/%)
%.sym: %$(EXE)
$(XSYMS) $^ $@
%.bin: %$(EXE)
$(OBJCOPY) -Obinary $^ $@
#PRODTARGETS+=$(INSTALL_RTEMSSYMS) $(INSTALL_RTEMSIMGS)

View File

@@ -9,10 +9,6 @@ RTEMS_BSP = uC5282
RTEMS_TARGET_CPU = m68k
ARCH_DEP_CFLAGS += -DMY_DO_BOOTP=NULL
# Hopefully a temporary fix:
ARCH_DEP_CXXFLAGS_5 = -std=c++98
ARCH_DEP_CXXFLAGS += $(ARCH_DEP_CXXFLAGS_$(RTEMS_VERSION))
MUNCH_SUFFIX = .boot
define MUNCH_CMD
$(RTEMS_TOOLS)/bin/$(OBJCOPY_FOR_TARGET) -O binary -R .comment -S $< $@

View File

@@ -1,20 +0,0 @@
#
# CONFIG.Common.RTEMS-xilinx_zynq_a9_qemu
# Author: Heinz Junkes <junkes@fhi-berlin.mpg.de>
#
# All RTEMS targets use the same Makefile fragment
#
#EXE = .elf
RTEMS_BSP = xilinx_zynq_a9_qemu
RTEMS_TARGET_CPU = arm
GNU_TARGET = arm-rtems
#use dhcp/bootp
ARCH_DEP_CFLAGS += -DMY_DO_BOOTP=NULL
OP_SYS_LDLIBS += -Wl,--gc-sections
ARCH_DEP_LDFLAGS = -L$(RTEMS_BASE)/$(GNU_TARGET)$(RTEMS_VERSION)/xilinx_zynq_a9_qemu/lib/
include $(CONFIG)/os/CONFIG.Common.RTEMS

View File

@@ -1,19 +0,0 @@
#
# CONFIG.Common.RTEMS-xilinx_zynq_zedboard
# Author: Heinz Junkes <junkes@fhi-berlin.mpg.de>
#
# All RTEMS targets use the same Makefile fragment
#
#EXE = .elf
RTEMS_BSP = xilinx_zynq_zedboard
RTEMS_TARGET_CPU = arm
GNU_TARGET = arm-rtems
OP_SYS_LDLIBS += -Wl,--gc-sections
ARCH_DEP_LDFLAGS = -L$(RTEMS_BASE)/$(GNU_TARGET)$(RTEMS_VERSION)/xilinx_zynq_zedboard/lib/
include $(CONFIG)/os/CONFIG.Common.RTEMS

View File

@@ -0,0 +1,6 @@
# Include definitions common to linux pentium targets
include $(CONFIG)/os/CONFIG.Common.linux-x86
COMMANDLINE_LIBRARY = READLINE_NCURSES
ARCH_DEP_CFLAGS += -march=i686

View File

@@ -0,0 +1,4 @@
# Include definitions common to linux pentium targets
include $(CONFIG)/os/CONFIG.Common.linux-x86_64
COMMANDLINE_LIBRARY = READLINE_NCURSES

View File

@@ -0,0 +1,7 @@
# Include definitions common to linux pentium targets
include $(CONFIG)/os/CONFIG.Common.linux-x86
ARCH_DEP_CFLAGS += -march=i686
# remove warning in anyscalar.h
ARCH_DEP_CXXFLAGS += -fno-strict-aliasing

View File

@@ -0,0 +1,5 @@
# Include definitions common to linux pentium targets
include $(CONFIG)/os/CONFIG.Common.linux-x86_64
# remove warning in anyscalar.h
ARCH_DEP_CXXFLAGS += -fno-strict-aliasing

View File

@@ -0,0 +1 @@
include $(CONFIG)/os/CONFIG.Common.linux-clang

View File

@@ -0,0 +1,8 @@
include $(CONFIG)/os/CONFIG.Common.vxWorks-ppc604_long
VXWORKS_VERSION = 5.5.1
WIND_BASE = /afs/psi.ch/project/vxworks/Tornado2.2.1
#there is a problem with our ccppc and optimization
# -O0 works, -O and -O1 and higher are buggy
OPT_CFLAGS_YES = -O0
OPT_CXXFLAGS_YES = -O0

View File

@@ -8,7 +8,7 @@
#-------------------------------------------------------
# Unix valid build types
VALID_BUILDS = Host Ioc Command
VALID_BUILDS = Host Ioc
#-------------------------------------------------------
# Unix prefix and suffix definitions
@@ -56,7 +56,7 @@ SHRLIB_LDLIBS = $(addprefix -l, $($*_LDLIBS) $(LIB_LIBS) $(USR_LIBS)) \
SHRLIB_DEPLIB_DIRS = $(foreach word, \
$(sort $(INSTALL_LIB)/ $(dir $($*_DEPLIBS) $(SHRLIB_DEPLIBS))), \
$(abspath $(word)))
$(shell $(FULLPATHNAME) $(word)))
SHRLIBDIR_LDFLAGS += $(SHRLIB_DEPLIB_DIRS:%=-L%)
@@ -85,7 +85,7 @@ PROD_LDLIBS += $($(firstword $(LDLIBS_STATIC_$(STATIC_BUILD)) \
PROD_DEPLIB_DIRS = $(foreach word, \
$(sort $(INSTALL_LIB)/ $(dir $($*_DEPLIBS) $(PROD_DEPLIBS))), \
$(abspath $(word)))
$(shell $(FULLPATHNAME) $(word)))
PRODDIR_LDFLAGS += $(PROD_DEPLIB_DIRS:%=-L%)

View File

@@ -0,0 +1,2 @@
include $(CONFIG)/os/CONFIG.Common.vxWorks-ppc604_long
VXWORKS_VERSION = 6.2

View File

@@ -0,0 +1,5 @@
include $(CONFIG)/os/CONFIG.Common.vxWorks-ppc603_long
VXWORKS_VERSION = 6.3
# Buggy "uninitialized variable" warning produces many false positives
ARCH_DEP_CXXFLAGS += -Wno-uninitialized

View File

@@ -0,0 +1,5 @@
include $(CONFIG)/os/CONFIG.Common.vxWorks-ppc604_long
VXWORKS_VERSION = 6.3
# Buggy "uninitialized variable" warning produces many false positives
ARCH_DEP_CXXFLAGS += -Wno-uninitialized

View File

@@ -0,0 +1,2 @@
include $(CONFIG)/os/CONFIG.Common.vxWorks-ppc603_long
VXWORKS_VERSION = 6.6

View File

@@ -0,0 +1,2 @@
include $(CONFIG)/os/CONFIG.Common.vxWorks-ppc604_long
VXWORKS_VERSION = 6.6

View File

@@ -0,0 +1,5 @@
include $(CONFIG)/os/CONFIG.Common.vxWorks-ppc604_long
VXWORKS_VERSION = 6.7
#needed when including memPartLib.h, e.g. through moduleLib.h or loadLib.h
ARCH_DEP_CFLAGS += -D_VSB_CONFIG_FILE='<../lib/h/config/vsbConfig.h>'

View File

@@ -1,14 +1,14 @@
# CONFIG.Common.darwin-aarch64
# CONFIG.Common.darwin-ppc
#
# This file is maintained by the build community.
#
# Definitions for darwin-aarch64 target builds
# Sites may override these definitions in CONFIG_SITE.Common.darwin-aarch64
# Definitions for darwin-ppc target builds
# Sites may override these definitions in CONFIG_SITE.Common.darwin-ppc
#-------------------------------------------------------
#
# To build universal binaries, configure ARCH_CLASS
# in the file CONFIG_SITE.Common.darwin-aarch64
# in the file CONFIG_SITE.Common.darwin-ppc
# Include definitions common to all Darwin targets
include $(CONFIG)/os/CONFIG.darwinCommon.darwinCommon

View File

@@ -0,0 +1,14 @@
# CONFIG.Common.darwin-ppcx86
#
# This file is maintained by the build community.
#
# Definitions for Darwin universal PowerPC + x86 target builds
# Sites may override these definitions in CONFIG_SITE.Common.darwin-ppcx86
#-------------------------------------------------------
#
# To build universal binaries, configure ARCH_CLASS
# in the file CONFIG_SITE.Common.darwin-ppcx86
# Include definitions common to all Darwin targets
include $(CONFIG)/os/CONFIG.darwinCommon.darwinCommon

View File

@@ -0,0 +1,25 @@
# DeltaTau PowerPMAC with ELDK 4.2
# Include definitions common to all Linux targets
include $(CONFIG)/os/CONFIG.Common.linuxCommon
COMMANDLINE_LIBRARY = READLINE_NCURSES
ARCH_CLASS = ppc
ELDK=/opt/eldk-4.2
GNU_TARGET=ppc_4xxFP
GNU_DIR=$(ELDK)/usr
# This cross tool chain is installed in a somehow weired way
# Without the following lines it does not work on RHEL7
# but it worked on SL6
ARCH_DEP_CXXFLAGS += -I $(ELDK)/$(GNU_TARGET)/usr/include/c++/4.2.2
ARCH_DEP_CXXFLAGS += -I $(ELDK)/$(GNU_TARGET)/usr/include/c++/4.2.2/powerpc-linux
ARCH_DEP_CXXFLAGS += -I $(ELDK)/$(GNU_TARGET)/usr/include/c++/4.2.2/backward
ARCH_DEP_LDFLAGS += -Wl,-rpath-link,$(ELDK)/$(GNU_TARGET)/lib
ARCH_DEP_LDFLAGS += -Wl,-rpath-link,$(ELDK)/$(GNU_TARGET)/usr/lib
# Some drivers complain
ARCH_DEP_CFLAGS += -fno-strict-aliasing

View File

@@ -0,0 +1,14 @@
# Virtex FPGA embedded Processor with ELDK 5.1
# Include definitions common to all Linux targets
include $(CONFIG)/os/CONFIG.Common.linuxCommon
ARCH_CLASS = ppc
SDK = eldk
SDK_DIR = /opt/eldk-5.1
SDK_HOST_ARCH = $(GNU_HOST_ARCH)-$(SDK)-$(GNU_HOST_OS)
GNU_TARGET = powerpc-4xx-softfloat
GNU_ARCH = ppc405-linux
GNU_DIR = $(SDK_DIR)/$(GNU_TARGET)/sysroots/$(SDK_HOST_ARCH)/usr
GNU_BIN = $(GNU_DIR)/bin/$(GNU_ARCH)

View File

@@ -0,0 +1,15 @@
# IOxOS IFC1210 with ELDK 5.2
# Include definitions common to all Linux targets
include $(CONFIG)/os/CONFIG.Common.linuxCommon
ARCH_CLASS = ppc
SDK = eldk
SDK_DIR = /opt/eldk-5.2
SDK_HOST_ARCH = $(GNU_HOST_ARCH)-$(SDK)-$(GNU_HOST_OS)
GNU_TARGET = powerpc-e500v2
GNU_ARCH = ppce500v2-linux-gnuspe
GNU_DIR = $(SDK_DIR)/$(GNU_TARGET)/sysroots/$(SDK_HOST_ARCH)/usr
GNU_BIN = $(GNU_DIR)/bin/$(GNU_ARCH)
GNU_TARGET_INCLUDE_DIR =

View File

@@ -0,0 +1,21 @@
# DeltaTau PowerPMAC with ELDK 5.2
# Include definitions common to all Linux targets
include $(CONFIG)/os/CONFIG.Common.linuxCommon
ARCH_CLASS = ppc
SDK = eldk
SDK_DIR = /opt/eldk-5.3
SDK_HOST_ARCH = $(GNU_HOST_ARCH)-$(SDK)-$(GNU_HOST_OS)
GNU_ARCH = ppc440e-linux
SDKTARGETSYSROOT=$(SDK_DIR)/powerpc-4xx/sysroots
GNU_DIR = $(SDKTARGETSYSROOT)/$(SDK_HOST_ARCH)/usr
GNU_BIN = $(GNU_DIR)/bin/$(GNU_ARCH)
GNU_TARGET_INCLUDE_DIR =
GNU_TARGET=powerpc-linux
ARCH_DEP_CPPFLAGS = -m32 -mcpu=440fp -mhard-float
ARCH_DEP_CPPFLAGS += --sysroot=$(SDKTARGETSYSROOT)/$(GNU_ARCH)
ARCH_DEP_LDFLAGS = --sysroot=$(SDKTARGETSYSROOT)/$(GNU_ARCH)
AS=$(GNU_BIN)/$(GNU_TARGET)-as

View File

@@ -7,10 +7,6 @@
# Include definitions common to all Unix targets
include $(CONFIG)/os/CONFIG.Common.UnixCommon
GNU = NO
CMPLR_CLASS = clang
CC = clang
CCC = clang++
OS_CLASS = freebsd

View File

@@ -0,0 +1,23 @@
# IOxOS IFC1211 with Freescale QorIQ 2.0 toolchain
# Include definitions common to all Linux targets
include $(CONFIG)/os/CONFIG.Common.linuxCommon
ARCH_CLASS = ppc
SDK = fslsdk
SDK_DIR = /opt/fsl-qoriq/2.0
SDK_HOST_ARCH = $(GNU_HOST_ARCH_64)-$(SDK)-$(GNU_HOST_OS)
SDK_TARGET = ppc64e6500-fsl-linux
GNU_TARGET = powerpc64-fsl-linux
SDKTARGETSYSROOT = $(SDK_DIR)/sysroots/$(SDK_TARGET)
GNU_DIR = $(SDK_DIR)/sysroots/$(SDK_HOST_ARCH)/usr
GNU_BIN = $(GNU_DIR)/bin/$(GNU_TARGET)
ARCH_DEP_CPPFLAGS = --sysroot=$(SDKTARGETSYSROOT)
ARCH_DEP_CFLAGS = -mcpu=e6500 -m64 -mhard-float
ARCH_DEP_LDFLAGS = --sysroot=$(SDKTARGETSYSROOT)
# warning -O2 and higher are broken!
#OPT_CFLAGS_YES = -O1
#OPT_CXXFLAGS_YES = -O1

View File

@@ -77,7 +77,7 @@ OP_SYS_LDFLAGS += -dynamic -Z -L$(SDK_DIR)/usr/lib -L$(SDK_DIR)/usr/lib/system
# Shared libraries
SHRLIB_VERSION = $(EPICS_VERSION).$(EPICS_REVISION).$(EPICS_MODIFICATION)
SHRLIB_LDFLAGS = -dynamiclib -flat_namespace -undefined suppress \
-install_name $(abspath $(INSTALL_LIB))/$@ \
-install_name $(shell $(FULLPATHNAME) $(INSTALL_LIB))/$@ \
-compatibility_version $(EPICS_VERSION).$(EPICS_REVISION) \
-current_version $(SHRLIB_VERSION)
SHRLIB_SUFFIX_BASE = .dylib

View File

@@ -0,0 +1,21 @@
# CONFIG.Common.linux-386
#
# This file is maintained by the build community.
#
# Definitions for linux-386 target builds
# Sites may override these definitions in CONFIG_SITE.Common.linux-386
#-------------------------------------------------------
# Include definitions common to all linux x86 targets
include $(CONFIG)/os/CONFIG.Common.linux-x86
ARCH_DEP_CFLAGS = -march=i386
ifeq ($(BUILD_CLASS),CROSS)
VALID_BUILDS = Ioc
endif
# If your crosscompiler name has a GNU target prefix like <gnutarget>-gcc,
# e.g. i386-pc-linux-gnu-gcc, put a GNU_TARGET definition in
# CONFIG_SITE.<host>.linux-386 file, e.g. GNU_TARGET=i386-pc-linux-gnu

View File

@@ -0,0 +1,19 @@
# CONFIG.Common.linux-486
#
# Definitions for linux-486 target builds
# Sites may override these definitions in CONFIG_SITE.Common.linux-486
#-------------------------------------------------------
# Include definitions common to all linux x86 targets
include $(CONFIG)/os/CONFIG.Common.linux-x86
ARCH_DEP_CFLAGS = -march=i486
ifeq ($(BUILD_CLASS),CROSS)
VALID_BUILDS = Ioc
endif
# If your crosscompiler name has a GNU target prefix like <gnutarget>-gcc,
# e.g. i486-pc-linux-gnu-gcc, put a GNU_TARGET definition in
# CONFIG_SITE.<host>.linux-486 file, e.g. GNU_TARGET=i486-pc-linux-gnu

View File

@@ -0,0 +1,21 @@
# CONFIG.Common.linux-586
#
# Definitions for linux-586 target builds
# Sites may override these definitions in CONFIG_SITE.Common.linux-586
#-------------------------------------------------------
# Include definitions common to all linux x86 targets
include $(CONFIG)/os/CONFIG.Common.linux-x86
# i586 is equivalent to pentium
ARCH_DEP_CFLAGS = -march=i586
ifeq ($(BUILD_CLASS),CROSS)
VALID_BUILDS = Ioc
endif
# If your crosscompiler name has a GNU target prefix like <gnutarget>-gcc,
# e.g. i586-pc-linux-gnu-gcc, put a GNU_TARGET definition in
# CONFIG_SITE.<host>.linux-586 file, e.g. GNU_TARGET=i586-pc-linux-gnu

View File

@@ -0,0 +1,20 @@
# CONFIG.Common.linux-686
#
# Definitions for linux-686 target builds
# Sites may override these definitions in CONFIG_SITE.Common.linux-686
#-------------------------------------------------------
# Include definitions common to all linux x86 targets
include $(CONFIG)/os/CONFIG.Common.linux-x86
# i686 is euivalent to pentiumpro
ARCH_DEP_CFLAGS = -march=i686
ifeq ($(BUILD_CLASS),CROSS)
VALID_BUILDS = Ioc
endif
# If your crosscompiler name has a GNU target prefix like <gnutarget>-gcc,
# e.g. i686-pc-linux-gnu-gcc, put a GNU_TARGET definition in
# CONFIG_SITE.<host>.linux-686 file, e.g. GNU_TARGET=i686-pc-linux-gnu

View File

@@ -1,11 +0,0 @@
# CONFIG.Common.linux-aarch64
#
# Definitions for linux-arm target builds
# Override these settings in CONFIG_SITE.Common.linux-aarch64
#-------------------------------------------------------
# Include definitions common to all Linux targets
include $(CONFIG)/os/CONFIG.Common.linuxCommon
ARCH_CLASS = aarch64

View File

@@ -0,0 +1,9 @@
# CONFIG.Common.linux-arm_eb
#
# Definitions for linux-arm_eb (big endian) target builds
# Sites may override these definitions in CONFIG_SITE.Common.linux-arm_eb
#-------------------------------------------------------
# Include definitions common to all Linux-arm targets
include $(CONFIG)/os/CONFIG.Common.linux-arm

View File

@@ -0,0 +1,9 @@
# CONFIG.Common.linux-arm_el
#
# Definitions for linux-arm_el (little endian) target builds
# Sites may override these definitions in CONFIG_SITE.Common.linux-arm_el
#-------------------------------------------------------
# Include definitions common to all linux-arm targets
include $(CONFIG)/os/CONFIG.Common.linux-arm

View File

@@ -0,0 +1,19 @@
# CONFIG.Common.linux-athlon
#
# Definitions for linux-athlon target builds
# Sites may override these definitions in CONFIG_SITE.Common.linux-athlon
#-------------------------------------------------------
# Include definitions common to all linux x86 targets
include $(CONFIG)/os/CONFIG.Common.linux-x86
ARCH_DEP_CFLAGS += -march=athlon-mp -mfpmath=sse
ifeq ($(BUILD_CLASS),CROSS)
VALID_BUILDS = Ioc
endif
# If your crosscompiler name has a GNU target prefix like <gnutarget>-gcc,
# e.g. athlon-pc-linux-gnu-gcc, put a GNU_TARGET definition in
# CONFIG_SITE.<host>.linux-athlon file, e.g. GNU_TARGET=athlon-pc-linux-gnu

View File

@@ -0,0 +1,5 @@
include $(CONFIG)/os/CONFIG.Common.linuxCommon
GNU = NO
CMPLR_CLASS = clang
CC = clang
CCC = clang++

View File

@@ -0,0 +1,58 @@
# CONFIG.Common.linux-cris
#
# Author: Peter Zumbruch
# GSI
# P.Zumbruch@gsi.de
#
# Definitions for linux-cris target builds
# Sites may override these definitions in CONFIG_SITE.Common.linux-cris
#-------------------------------------------------------
# Include definitions common to all linux targets
include $(CONFIG)/os/CONFIG.Common.linuxCommon
ARCH_CLASS = cris
ifeq ($(BUILD_CLASS),CROSS)
GNU_TARGET = cris-axis-linux-gnu
# prefix of compiler tools
CMPLR_SUFFIX =
CMPLR_PREFIX = $(addsuffix -,$(GNU_TARGET))
# CROSS_TOP_DIR
# usually AXIS_TOP_DIR is defined via
# the init_env script of the SDK provided by Axis
#
## AXIS_TOP_DIR defined? Make missing mandatory variable visible
AXIS_TOP_DIR?=UNDEFINED_ENV__AXIS_TOP_DIR
AXIS_SDK_DIR?=$(AXIS_TOP_DIR)
# CROSS_INCLUDES
AXIS_SDK_TARGET_INCLUDE_DIR = $(AXIS_SDK_DIR)/target/$(GNU_TARGET)/include
AXIS_SDK_TARGET_INCLUDE_DIR +=$(AXIS_SDK_DIR)/target/$(GNU_TARGET)/usr/include
CROSS_INCLUDES = $(addprefix -isystem ,$(AXIS_SDK_TARGET_INCLUDE_DIR))
# CROSS_LDFLAGS
AXIS_SDK_TARGET_LIB_DIR = $(AXIS_SDK_DIR)/target/$(GNU_TARGET)/lib
AXIS_SDK_TARGET_LIB_DIR += $(AXIS_SDK_DIR)/target/$(GNU_TARGET)/usr/lib
CROSS_LDFLAGS = $(addprefix -L,$(AXIS_SDK_TARGET_LIB_DIR))
-include $(CONFIG)/os/CONFIG_SITE.Common.linux-cris
ifeq ($(EPICS_HOST_ARCH), linux-x86)
-include $(CONFIG)/os/CONFIG.linux-x86.linux-cris
-include $(CONFIG)/os/CONFIG_SITE.linux-x86.linux-cris
endif
endif
SHARED_LIBRARIES=NO
STATIC_BUILD=YES
ARCH_DEP_CFLAGS += -mno-mul-bug-workaround
OP_SYS_CFLAGS += -mlinux
ARCH_DEP_CPPFLAGS += -D_cris_ -mlinux
#uncomment CRIS_COMPILER_DEBUG for debugging cris-compiled code
#CRIS_COMPILER_DEBUG

View File

@@ -15,7 +15,7 @@ include $(CONFIG)/os/CONFIG.Common.linuxCommon
ARCH_CLASS = microblaze
ifeq ($(BUILD_CLASS),CROSS)
VALID_BUILDS = Ioc Command
VALID_BUILDS = Ioc
GNU_TARGET = microblazeel-unknown-linux-gnu
CMPLR_PREFIX = $(addsuffix -,$(GNU_TARGET))
endif

View File

@@ -13,7 +13,7 @@ include $(CONFIG)/os/CONFIG.Common.linuxCommon
ARCH_CLASS = xscale
ifeq ($(BUILD_CLASS),CROSS)
VALID_BUILDS = Ioc Command
VALID_BUILDS = Ioc
GNU_TARGET = xscale_be
CMPLR_PREFIX = $(GNU_TARGET:%=%-)

View File

@@ -23,17 +23,15 @@ STATIC_LDFLAGS_YES= -Wl,-Bstatic
STATIC_LDFLAGS_NO=
STATIC_LDLIBS_YES= -Wl,-Bdynamic
# Set runtime path for shared libraries if LINKER_USE_RPATH=YES
SHRLIBDIR_RPATH_LDFLAGS_YES = $(SHRLIB_DEPLIB_DIRS:%=-Wl,-rpath,%)
SHRLIBDIR_RPATH_LDFLAGS_ORIGIN = $(shell $(MAKERPATH) -O '\$$ORIGIN' -F $(FINAL_DIR) -R $(LINKER_ORIGIN_ROOT) $(SHRLIB_DEPLIB_DIRS))
# Set runtime path for shared libraries if USE_RPATH=YES and STATIC_BUILD=NO
SHRLIBDIR_RPATH_LDFLAGS_YES_NO = $(SHRLIB_DEPLIB_DIRS:%=-Wl,-rpath,%)
SHRLIBDIR_LDFLAGS += \
$(SHRLIBDIR_RPATH_LDFLAGS_$(LINKER_USE_RPATH))
$(SHRLIBDIR_RPATH_LDFLAGS_$(LINKER_USE_RPATH)_$(STATIC_BUILD))
# Set runtime path for products if LINKER_USE_RPATH=YES
PRODDIR_RPATH_LDFLAGS_YES = $(PROD_DEPLIB_DIRS:%=-Wl,-rpath,%)
PRODDIR_RPATH_LDFLAGS_ORIGIN = $(shell $(MAKERPATH) -O '\$$ORIGIN' -F $(FINAL_DIR) -R $(LINKER_ORIGIN_ROOT) $(PROD_DEPLIB_DIRS))
# Set runtime path for products if USE_RPATH=YES and STATIC_BUILD=NO
PRODDIR_RPATH_LDFLAGS_YES_NO = $(PROD_DEPLIB_DIRS:%=-Wl,-rpath,%)
PRODDIR_LDFLAGS += \
$(PRODDIR_RPATH_LDFLAGS_$(LINKER_USE_RPATH))
$(PRODDIR_RPATH_LDFLAGS_$(LINKER_USE_RPATH)_$(STATIC_BUILD))
# Link libraries controlled by COMMANDLINE_LIBRARY
# The newest Linux versions only need readline, older ones need both

View File

@@ -0,0 +1,19 @@
# Moxa DA-66x with SDK 4.2 and ARM7 processor
# Include definitions common to all Linux ARM targets
include $(CONFIG)/os/CONFIG.Common.linux-arm
GNU_DIR=/afs/psi.ch/project/embeddedlinux/moxa/arm-linux-4.4.2-v4
GNU_TARGET=arm
ARCH_DEP_LDFLAGS+=-Wl,-rpath-link,$(GNU_DIR)/arm-none-linux-gnueabi/lib
ARCH_DEP_LDFLAGS+=-Wl,-rpath-link,$(INSTALL_LIB)
COMMANDLINE_LIBRARY = READLINE_NCURSES
# suppress note "the mangling of 'va_list' has changed in GCC 4.4"
ARCH_DEP_CXXFLAGS += -Wno-psabi
ARCH_DEP_CFLAGS += -funwind-tables
# remove warning in anyscalar.h
ARCH_DEP_CXXFLAGS += -fno-strict-aliasing

View File

@@ -0,0 +1,15 @@
# Moxa DA-66x with Montavista Linux 4.0
# Include definitions common to all Linux targets
include $(CONFIG)/os/CONFIG.Common.linuxCommon
COMMANDLINE_LIBRARY = READLINE_CURSES
ARCH_CLASS = xscale
GNU_DIR=/afs/psi.ch/project/embeddedlinux/moxa/xscale_be/armv5teb-montavista-linuxeabi
ARCH_DEP_CFLAGS += -funwind-tables
# Cannot build PVA because of missing boost support
SKIP_BUILDS = pv% normativeTypes

View File

@@ -0,0 +1,41 @@
# RaspberryPi with github.com/raspberrypi/tools toolchain
# Tested on:
# * Raspberry 3B+ Raspbian 9
# * Raspberry 2 Raspbian 7
# Include definitions common to all Linux targets
include $(CONFIG)/os/CONFIG.Common.linuxCommon
# Using readline:
# Due to missing/messed up libs in the toolchain, readline needs copies of
# libtinfo.so.5.9 and libreadline.so.6.2 from a Raspbian 7 rootfs
# /lib/arm-linux-gnueabihf/ to the toolchain, e.g.
# $(SDK_DIR)/gcc-linaro-arm-linux-gnueabihf-raspbian/arm-linux-gnueabihf/libc/lib/arm-linux-gnueabihf/
# and manually created links libtinfo.so.5 and libreadline.so.
# For gcc-linaro-arm-linux-gnueabihf-raspbian, an existing incompatible
# libtinfo.so.5 is in the way. Remove it.
# (Built with glibc 2.16 like installed on Raspbian 9 but toolchain uses glibc 2.13.)
# Also copy /usr/include/readline/ directory from some readline 6 installation
# to $(SDK_DIR)/gcc-linaro-arm-linux-gnueabihf-raspbian/arm-linux-gnueabihf/libc/usr/include/
ARCH_CLASS = arm
SDK_DIR = /opt/raspberrypi/arm-bcm2708
# Available SDK_TARGETs:
# gcc 4.8.3 for 32 bit hosts with GLIBC 2.3 or higher
SDK_TARGET = gcc-linaro-arm-linux-gnueabihf-raspbian
# gcc 4.8.3 for 64 bit hosts with GLIBC 2.14 or higher
# SDK_TARGET = gcc-linaro-arm-linux-gnueabihf-raspbian-x64
# gcc 4.7.1 for 64 bit hosts with GLIBC 2.8 or higher
# SDK_TARGET = arm-linux-gnueabihf
# gcc 4.7.1 for 32 bit hosts with GLIBC 2.4 or higher
# SDK_TARGET = arm-bcm2708hardfp-linux-gnueabi
# SDK_TARGET = arm-bcm2708-linux-gnueabi
GNU_DIR = $(SDK_DIR)/$(SDK_TARGET)
GNU_TARGET = $(if $(filter arm-bcm2708%,SDK_TARGET),$(SDK_TARGET),arm-linux-gnueabihf)

Some files were not shown because too many files have changed in this diff Show More