Skip to content

Commit

Permalink
Release: Merge alpha 7.142.80 into stable
Browse files Browse the repository at this point in the history
  • Loading branch information
WhoBrokeTheBuild committed May 21, 2024
2 parents a4dd26c + 0ac427c commit 997b0d8
Show file tree
Hide file tree
Showing 134 changed files with 10,920 additions and 14,819 deletions.
18 changes: 13 additions & 5 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ def OSList = [
'ubuntu18',
'ubuntu20',
'ubuntu22',
'ubuntu24',
'rhel7',
'rhel8',
'rhel9',
Expand All @@ -13,6 +14,7 @@ def OSList = [
'debian9-64',
'debian10-64',
'debian11-64',
'debian12-64',
'test-asan',
'test-tsan',
'test-ubsan',
Expand All @@ -39,6 +41,7 @@ if (BRANCH_NAME == "stable") {
}

def new_version = '0.0.0';
def new_tag = null;

def release_file_list = [];

Expand Down Expand Up @@ -105,6 +108,8 @@ pipeline {
if (new_version == '0.0.0') {
error "Failed to calculate new version"
}

new_tag = "${BRANCH_NAME}_release-" + new_version.replaceAll("\\.", "-")

echo "Calculated new version to be ${new_version}"
}
Expand All @@ -121,10 +126,14 @@ pipeline {
ws("${WORKSPACE}/${OS}") {
stage("${OS} Clone") {
checkout scm;

if (new_tag) {
sh "git tag ${new_tag} || true"
}
}

stage("${OS} Bootstrap") {
sh "./deploy/build.sh --os=bootstrap --branch=${BRANCH_NAME} --version=${new_version}"
sh "./deploy/build.sh --os=bootstrap --branch=${BRANCH_NAME}"

if (OS.endsWith("armhf")) {
sh "docker run --rm --privileged multiarch/qemu-user-static:register --reset"
Expand All @@ -146,7 +155,7 @@ pipeline {

if (!OS.startsWith("test-")) {
stage("${OS} Release") {
sh "./deploy/build.sh --os=${OS} --release --branch=${BRANCH_NAME} --version=${new_version}"
sh "./deploy/build.sh --os=${OS} --release --branch=${BRANCH_NAME} --version=${new_version} --keys=/mdsplus/certs"

findFiles(glob: "packages/*.tgz").each {
file -> release_file_list.add(WORKSPACE + "/" + file.path)
Expand Down Expand Up @@ -220,8 +229,7 @@ pipeline {

stage("Publish to GitHub") {
ws("${WORKSPACE}/publish") {
def tag = "${BRANCH_NAME}_release-" + new_version.replaceAll("\\.", "-")
echo "Creating GitHub Release and Tag for ${tag}"
echo "Creating GitHub Release and Tag for ${new_tag}"
withCredentials([
usernamePassword(
credentialsId: 'MDSplusJenkins',
Expand All @@ -231,7 +239,7 @@ pipeline {

// TODO: Protect against spaces in filenames
def release_file_list_arg = release_file_list.join(" ")
sh "./deploy/create_github_release.py --tag ${tag} --api-token \$GITHUB_ACCESS_TOKEN ${release_file_list_arg}"
sh "./deploy/create_github_release.py --tag ${new_tag} --api-token \$GITHUB_ACCESS_TOKEN ${release_file_list_arg}"
}

}
Expand Down
12 changes: 10 additions & 2 deletions _include/_mdsversion.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#define VERSIONCONST CONCAT(LIBPREFIX, Version)
#define GETRELEASE CONCAT(LIBPREFIX, Release)
#define GETRELEASEDSC CONCAT(LIBPREFIX, ReleaseDsc)
#define GETRELEASEDATE CONCAT(LIBPREFIX, ReleaseDate)

EXPORT
const mds_version_t VERSIONCONST = {
Expand All @@ -17,14 +18,15 @@ const mds_version_t VERSIONCONST = {
"@RELEASE_BRANCH@",
};


static pthread_once_t once = PTHREAD_ONCE_INIT;
static char tag[64];
static mdsdsc_t RELEASE_D = { 0, DTYPE_T, CLASS_S, tag };

static const char release_date[64] = "@RELEASE_DATE@";

static void buildtag()
{
RELEASE_D.length = snprintf(tag, sizeof(tag), "%.12s_release_%d.%d.%d",
RELEASE_D.length = snprintf(tag, sizeof(tag), "%.12s_release-%d-%d-%d",
VERSIONCONST.BRANCH,
VERSIONCONST.MAJOR,
VERSIONCONST.MINOR,
Expand All @@ -44,3 +46,9 @@ const mdsdsc_t *GETRELEASEDSC()
pthread_once(&once, buildtag);
return &RELEASE_D;
}

EXPORT
const char *GETRELEASEDATE()
{
return release_date;
}
4 changes: 3 additions & 1 deletion _include/mdsmsg.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
#include <stdio.h>
#include <time.h>
#include <string.h>

// To activate the MDSDBG() debug messages, uncomment the following line.
//#define DEBUG
//#undef DEBUG
#ifdef MDSDBG
Expand All @@ -27,7 +29,7 @@
#define __MDSMSGPREFIX(LV) ( \
{ \
pos = __FILE__; \
while (!strncmp(pos, "../", 3)) \
while (!strncmp(pos, "../", (unsigned long int) 3)) \
pos += 3; \
pos = msg + sprintf(msg, "%c, %u:%lu, %u.%09u: %s:%d ", \
LV, getpid(), CURRENT_THREAD_ID(), \
Expand Down
1 change: 1 addition & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -533,6 +533,7 @@ esac

# add specific flags for fortran depending on compiler version
AX_FORTRAN_FLAGS([FCFLAGS])
AX_C_FLAGS([CFLAGS])

AC_CHECK_SIZEOF(long)

Expand Down
1 change: 1 addition & 0 deletions deploy/os/debian12-64.opts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--platform=debian --valgrind=memcheck,helgrind --dockerimage=mdsplus/builder:debian_bookworm-64 --distname=DebianBookworm --arch=amd64
1 change: 1 addition & 0 deletions deploy/os/ubuntu24.opts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--platform=debian --valgrind=memcheck,helgrind --dockerimage=mdsplus/builder:ubuntu24-64 --distname=Ubuntu24 --arch=amd64
1 change: 1 addition & 0 deletions deploy/packaging/debian/kernel.noarch
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,7 @@
./usr/local/mdsplus/tdi/treeshr/TreeOpenEdit.fun
./usr/local/mdsplus/tdi/treeshr/TreeOpenNew.fun
./usr/local/mdsplus/tdi/treeshr/TreePut.fun
./usr/local/mdsplus/tdi/treeshr/TreePutDeserialized.fun
./usr/local/mdsplus/tdi/treeshr/TreePutRecord.fun
./usr/local/mdsplus/tdi/treeshr/TreeQuit.fun
./usr/local/mdsplus/tdi/treeshr/TreeSetCurrentShot.fun
Expand Down
2 changes: 2 additions & 0 deletions deploy/packaging/debian/matlab.noarch
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,10 @@
./usr/local/mdsplus/matlab/private/javaConnect.m
./usr/local/mdsplus/matlab/private/javaExecute.m
./usr/local/mdsplus/matlab/private/javaFromMatlab.m
./usr/local/mdsplus/matlab/private/javaFromMatlabCell.m
./usr/local/mdsplus/matlab/private/javaFromMatlabStruct.m
./usr/local/mdsplus/matlab/private/javaToMatlab.m
./usr/local/mdsplus/matlab/private/javaToMatlabCell.m
./usr/local/mdsplus/matlab/private/javaToMatlabStruct.m
./usr/local/mdsplus/matlab/private/pythonActivate.m
./usr/local/mdsplus/matlab/private/pythonConnect.m
Expand Down
1 change: 1 addition & 0 deletions deploy/packaging/debian/python.noarch
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
./usr/local/mdsplus/python/MDSplus/mdsdcl.py
./usr/local/mdsplus/python/MDSplus/mdsscalar.py
./usr/local/mdsplus/python/MDSplus/modpython.py
./usr/local/mdsplus/python/MDSplus/pyproject.toml
./usr/local/mdsplus/python/MDSplus/scope.py
./usr/local/mdsplus/python/MDSplus/setup.py
./usr/local/mdsplus/python/MDSplus/pyproject.toml
Expand Down
9 changes: 9 additions & 0 deletions deploy/packaging/debian/rfxdevices.noarch
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,12 @@
./usr/local/mdsplus/pydevices/RfxDevices/MARTE.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_COMPONENT.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_CONVERSION.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_DOUBLEH_MASTER.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_DOUBLEH_SLAVE.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_DTACQAI.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_DTACQAO.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_DUTY_CYCLE.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_EPICSCA.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_EPICS_IN.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_EPICS_OUT.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_EXPR.py
Expand All @@ -51,13 +54,19 @@
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_NI6368_DAC.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_NI6368_DO.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_NI6368_SYNCH_DI.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_OPCUA_IN.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_OPCUA_OUT.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_OPCUA_SERVER.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_OUT.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_PYTHON.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_PYTHON_GENERIC.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_PYTHON_PID.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_PYTHON_PWM.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RAMP.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RESAMPLER.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RFXMODEL.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RTNIN.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RTNOUT.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RTSM.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_SIMULINK.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_SIMULINK_DTT.py
Expand Down
12 changes: 12 additions & 0 deletions deploy/packaging/linux.xml
Original file line number Diff line number Diff line change
Expand Up @@ -836,6 +836,12 @@ rm -f /etc/ld.so.conf.d/mdsplus.conf 2&gt;/dev/null
</packages>

<!-- dist first -->
<external_packages dist="Ubuntu24">
<numpy package="python3-numpy"/>
<java package="java-runtime"/>
<readline package="libreadline8"/>
</external_packages>

<external_packages dist="Ubuntu22">
<numpy package="python3-numpy"/>
<java package="java-runtime"/>
Expand All @@ -848,6 +854,12 @@ rm -f /etc/ld.so.conf.d/mdsplus.conf 2&gt;/dev/null
<readline package="libreadline8"/>
</external_packages>

<external_packages dist="DebianBookworm">
<numpy package="python3-numpy"/>
<java package="java-runtime"/>
<readline package="libreadline8"/>
</external_packages>

<external_packages dist="DebianBullseye">
<numpy package="python3-numpy"/>
<java package="java-runtime"/>
Expand Down
1 change: 1 addition & 0 deletions deploy/packaging/redhat/kernel.noarch
Original file line number Diff line number Diff line change
Expand Up @@ -263,6 +263,7 @@
./usr/local/mdsplus/tdi/treeshr/TreeOpenEdit.fun
./usr/local/mdsplus/tdi/treeshr/TreeOpenNew.fun
./usr/local/mdsplus/tdi/treeshr/TreePut.fun
./usr/local/mdsplus/tdi/treeshr/TreePutDeserialized.fun
./usr/local/mdsplus/tdi/treeshr/TreePutRecord.fun
./usr/local/mdsplus/tdi/treeshr/TreeQuit.fun
./usr/local/mdsplus/tdi/treeshr/TreeSetCurrentShot.fun
Expand Down
2 changes: 2 additions & 0 deletions deploy/packaging/redhat/matlab.noarch
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,10 @@
./usr/local/mdsplus/matlab/private/javaConnect.m
./usr/local/mdsplus/matlab/private/javaExecute.m
./usr/local/mdsplus/matlab/private/javaFromMatlab.m
./usr/local/mdsplus/matlab/private/javaFromMatlabCell.m
./usr/local/mdsplus/matlab/private/javaFromMatlabStruct.m
./usr/local/mdsplus/matlab/private/javaToMatlab.m
./usr/local/mdsplus/matlab/private/javaToMatlabCell.m
./usr/local/mdsplus/matlab/private/javaToMatlabStruct.m
./usr/local/mdsplus/matlab/private/pythonActivate.m
./usr/local/mdsplus/matlab/private/pythonConnect.m
Expand Down
1 change: 1 addition & 0 deletions deploy/packaging/redhat/python.noarch
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
./usr/local/mdsplus/python/MDSplus/mdsdcl.py
./usr/local/mdsplus/python/MDSplus/mdsscalar.py
./usr/local/mdsplus/python/MDSplus/modpython.py
./usr/local/mdsplus/python/MDSplus/pyproject.toml
./usr/local/mdsplus/python/MDSplus/scope.py
./usr/local/mdsplus/python/MDSplus/setup.py
./usr/local/mdsplus/python/MDSplus/pyproject.toml
Expand Down
9 changes: 9 additions & 0 deletions deploy/packaging/redhat/rfxdevices.noarch
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,12 @@
./usr/local/mdsplus/pydevices/RfxDevices/MARTE.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_COMPONENT.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_CONVERSION.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_DOUBLEH_MASTER.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_DOUBLEH_SLAVE.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_DTACQAI.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_DTACQAO.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_DUTY_CYCLE.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_EPICSCA.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_EPICS_IN.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_EPICS_OUT.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_EXPR.py
Expand All @@ -52,13 +55,19 @@
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_NI6368_DAC.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_NI6368_DO.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_NI6368_SYNCH_DI.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_OPCUA_IN.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_OPCUA_OUT.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_OPCUA_SERVER.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_OUT.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_PYTHON.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_PYTHON_GENERIC.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_PYTHON_PID.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_PYTHON_PWM.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RAMP.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RESAMPLER.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RFXMODEL.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RTNIN.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RTNOUT.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_RTSM.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_SIMULINK.py
./usr/local/mdsplus/pydevices/RfxDevices/MARTE2_SIMULINK_DTT.py
Expand Down
2 changes: 2 additions & 0 deletions deploy/platform/bootstrap/bootstrap_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,7 @@ trap cleanup EXIT INT
docker run -t -a stdout -a stderr --cidfile=$cid \
-u $(id -u):$(id -g) --privileged \
-e "HOME=/tmp" \
-e "BRANCH" \
-e "RELEASE_VERSION" \
-v "${SRCDIR}:${DOCKER_SRCDIR}" \
${DOCKERIMAGE} "${DOCKER_SRCDIR}/bootstrap"
3 changes: 2 additions & 1 deletion include/mdsobjects.h
Original file line number Diff line number Diff line change
Expand Up @@ -4504,9 +4504,10 @@ namespace MDSplus
closeAllTrees();
}
void setDefault(char *path);
Data *get(const char *expr, Data **args, int nArgs);
Data *get(const char *expr, Data **args, int nArgs, bool serialized = true);
Data *get(const char *expr) { return get(expr, 0, 0); }
void put(const char *path, char *expr, Data **args, int nArgs);
void put(const char *path, Data *data);
PutMany *putMany() { return new PutMany(this); }
GetMany *getMany() { return new GetMany(this); }
// Get TreeNode instance for (a subset of) TreeNode functionality in thin
Expand Down
Loading

0 comments on commit 997b0d8

Please sign in to comment.