Skip to content

Building out of tree doesn't work #188

@auriocus

Description

@auriocus

Describe the bug
As soon as INSTALL_LOCATION is set in CONFIG_SITE.local, the build fails. In my environment, weinstall modules under /soft/epics/inst-<EPICS_VERSION>/ by setting:

EPICS_BASE = /soft/epics/base-7.0.9
SUPPORT = /soft/epics/inst-7.0.9
INSTALL_LOCATION_APP = $(SUPPORT)/opcua-0.11.0

in RELEASE.local and
and

ifdef INSTALL_LOCATION_APP
   INSTALL_LOCATION = $(INSTALL_LOCATION_APP)
endif

in CONFIG_SITE.local. For the "traditional" modules like asyn, busy, calc etc. that works, but opcua fails to compile.

To Reproduce

Recompile opcua with the settings above. If you don't set INSTALL_LOCATION_APP, then it compiles flawlessly in-place. With that setting, it raises an error:

ln -s libopcua.so.0.11 /soft/epics/inst-7.0.9/opcua-0.11.0/lib/linux-x86_64/libopcua.so
Installing library /soft/epics/inst-7.0.9/opcua-0.11.0/lib/linux-x86_64/libopcua.a
make[2]: Leaving directory '/soft/epics/modules/opcua-0.11.0/devOpcuaSup/O.linux-x86_64'
make[1]: Leaving directory '/soft/epics/modules/opcua-0.11.0/devOpcuaSup'
make -C ./unitTestApp install
make[1]: Entering directory '/soft/epics/modules/opcua-0.11.0/unitTestApp'
make -C ./src install
make -C ./Db install
make[2]: Entering directory '/soft/epics/modules/opcua-0.11.0/unitTestApp/src'
make[2]: Entering directory '/soft/epics/modules/opcua-0.11.0/unitTestApp/Db'
perl -CSD /soft/epics/base-7.0.9/bin/linux-x86_64/makeMakefile.pl O.linux-x86_64 ../../..
mkdir -p O.Common
perl -CSD /soft/epics/base-7.0.9/bin/linux-x86_64/makeMakefile.pl O.linux-x86_64 ../../..
mkdir -p O.Common
make -C O.linux-x86_64 -f ../Makefile TOP=../../.. \
    T_A=linux-x86_64 install
make[3]: Entering directory '/soft/epics/modules/opcua-0.11.0/unitTestApp/Db/O.linux-x86_64'
make -C O.linux-x86_64 -f ../Makefile TOP=../../.. \
    T_A=linux-x86_64 install
make[3]: Entering directory '/soft/epics/modules/opcua-0.11.0/unitTestApp/src/O.linux-x86_64'
/soft/epics/inst-7.0.9/opcua-0.11.0/cfg/RULES_OPCUA:10: *** CONFIG_OPCUA was not loaded.  Stop.
make[3]: Leaving directory '/soft/epics/modules/opcua-0.11.0/unitTestApp/Db/O.linux-x86_64'
make[2]: *** [/soft/epics/base-7.0.9/configure/RULES_ARCHS:58: install.linux-x86_64] Error 2
make[2]: Leaving directory '/soft/epics/modules/opcua-0.11.0/unitTestApp/Db'
make[1]: *** [/soft/epics/base-7.0.9/configure/RULES_DIRS:85: Db.install] Error 2
make[1]: *** Waiting for unfinished jobs....
/soft/epics/inst-7.0.9/opcua-0.11.0/cfg/RULES_OPCUA:10: *** CONFIG_OPCUA was not loaded.  Stop.
make[3]: Leaving directory '/soft/epics/modules/opcua-0.11.0/unitTestApp/src/O.linux-x86_64'
make[2]: *** [/soft/epics/base-7.0.9/configure/RULES_ARCHS:58: install.linux-x86_64] Error 2
make[2]: Leaving directory '/soft/epics/modules/opcua-0.11.0/unitTestApp/src'
make[1]: *** [/soft/epics/base-7.0.9/configure/RULES_DIRS:85: src.install] Error 2
make[1]: Leaving directory '/soft/epics/modules/opcua-0.11.0/unitTestApp'
make: *** [/soft/epics/base-7.0.9/configure/RULES_DIRS:85: unitTestApp.install] Error 2

The module is still compiled:

204b098663a5:/home # find /soft/epics/inst-7.0.9/opcua-0.11.0/
/soft/epics/inst-7.0.9/opcua-0.11.0/
/soft/epics/inst-7.0.9/opcua-0.11.0/configure
/soft/epics/inst-7.0.9/opcua-0.11.0/configure/RELEASE
/soft/epics/inst-7.0.9/opcua-0.11.0/configure/RELEASE.local
/soft/epics/inst-7.0.9/opcua-0.11.0/cfg
/soft/epics/inst-7.0.9/opcua-0.11.0/cfg/RULES_OPCUA
/soft/epics/inst-7.0.9/opcua-0.11.0/cfg/CONFIG_OPCUA
/soft/epics/inst-7.0.9/opcua-0.11.0/lib
/soft/epics/inst-7.0.9/opcua-0.11.0/lib/linux-x86_64
/soft/epics/inst-7.0.9/opcua-0.11.0/lib/linux-x86_64/libopcua.so.0.11
/soft/epics/inst-7.0.9/opcua-0.11.0/lib/linux-x86_64/libopcua.so
/soft/epics/inst-7.0.9/opcua-0.11.0/lib/linux-x86_64/libopcua.a
/soft/epics/inst-7.0.9/opcua-0.11.0/include
/soft/epics/inst-7.0.9/opcua-0.11.0/include/opcuaItemRecord.h
/soft/epics/inst-7.0.9/opcua-0.11.0/include/menuDefAction.h
/soft/epics/inst-7.0.9/opcua-0.11.0/include/devOpcuaVersion.h
/soft/epics/inst-7.0.9/opcua-0.11.0/include/devOpcuaVersionNum.h
/soft/epics/inst-7.0.9/opcua-0.11.0/dbd
/soft/epics/inst-7.0.9/opcua-0.11.0/dbd/menuDefAction.dbd
/soft/epics/inst-7.0.9/opcua-0.11.0/dbd/opcuaItemRecord.dbd
/soft/epics/inst-7.0.9/opcua-0.11.0/dbd/opcua.dbd
/soft/epics/inst-7.0.9/opcua-0.11.0/dbd/devOpcua.dbd
/soft/epics/inst-7.0.9/opcua-0.11.0/html
/soft/epics/inst-7.0.9/opcua-0.11.0/html/menuDefAction.html


Setup (please complete the following information if applicable):

  • OPCUA Support: 0.11.0
  • Platform: OpenSuSE 15.6
  • EPICS Base: 7.0.9
  • Client library: open62541

Additional context
I'm trying to adjust the epics-build-tool from KIT for our environment, therefore I have a series of patches against the source tree. The patchset is attached.

01-paths.patch.txt

03-libs.patch.txt
05-lib64.patch.txt
07-gitrepo.patch.txt

Metadata

Metadata

Assignees

No one assigned

    Labels

    build systemRelated to the build and the Make rules

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions