Skip to content
Open
8 changes: 8 additions & 0 deletions cmake/utils.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,14 @@ function(detect_os)
execute_process(COMMAND arch
OUTPUT_VARIABLE DISTRO_ARCH OUTPUT_STRIP_TRAILING_WHITESPACE)
set(BDM_OS "${DISTRO_NAME}-${DISTRO_VERSION}")
if(BDM_OS MATCHES "debian|mint|eepin|pop|neon")
set(BDM_OS "ubuntu-24.04")
elseif (BDM_OS MATCHES "buntu")
set(BDM_OS "ubuntu-${DISTRO_VERSION}")
if (BDM_OS MATCHES "buntu-24|buntu-25|buntu-26")
set(BDM_OS "ubuntu-24.04")
endif()
endif()
set(DETECTED_OS "${BDM_OS}" PARENT_SCOPE)
set(DETECTED_ARCH "${DISTRO_ARCH}" PARENT_SCOPE)
if("${DISTRO_ARCH}" STREQUAL "aarch64")
Expand Down
1 change: 1 addition & 0 deletions src/core/exporter.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

#include <memory>
#include <string>
#include <cstdint>

namespace bdm {

Expand Down
1 change: 1 addition & 0 deletions third_party/cxxopts-v2.2.1/cxxopts.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ THE SOFTWARE.
#include <string>
#include <unordered_map>
#include <unordered_set>
#include <cstdint>
#include <vector>

#ifdef __cpp_lib_optional
Expand Down
8 changes: 8 additions & 0 deletions util/installation/common/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,14 @@ function DetectOs {
DISTRIBUTOR=$(grep -oP '(?<=^ID=).+' /etc/os-release | tr -d '"')
RELEASE=$(grep -oP '(?<=^VERSION_ID=).+' /etc/os-release | tr -d '"')
OS="${DISTRIBUTOR}-${RELEASE}"
if echo "$OS" | grep -Eiq 'debian|mint|eepin|pop|neon' ; then
OS="ubuntu-24.04"
elif echo "$DISTRIBUTOR" | grep -Eiq 'buntu' ; then
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove leading spaces before elif for consistency with surrounding indentation.

OS="ubuntu-${RELEASE}"
if echo "$OS" | grep -Eiq 'buntu-24|buntu-25|buntu-26' ; then
OS="ubuntu-24.04"
fi
fi
echo $OS | awk '{print tolower($0)}'
elif [ `uname` = "Darwin" ]; then
# macOS
Expand Down
3 changes: 3 additions & 0 deletions util/installation/ubuntu-24.04/package_list_extra
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
g++-11
gcc-11
gfortran-11
clang
clang-format
clang-tidy
Expand Down
18 changes: 13 additions & 5 deletions util/installation/ubuntu-24.04/package_list_required
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the updates! From what I can see, several packages promoted to “required” don’t seem necessary for a minimal build. Could we move them back to package_list_extra unless the core build fails without them?

If any of these are hard requirements for the default configuration, please keep them and add a short rationale inline so it’s clear why they’re in the required set.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dear stavros @sportokalidis .

From the packages I inspected I think that the lsb_release and gcc-11 are the only optional ones.

Other packages like patch may come preinstalled in some distros.

So I will rebase the commit and make the required change.

I am really sorry for the delay,
John Papadopoulos

Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
curl
build-essential
freeglut3-dev
g++
gcc
g++-11
gcc-11
gfortran
patch
git
doxygen
libblas-dev
libbz2-dev
liblapack-dev
Expand All @@ -16,15 +18,21 @@ libpthread-stubs0-dev
make
wget
zlib1g-dev
python3-dev
libbz2-dev
graphviz-dev
libgsl-dev
valgrind
libffi-dev
liblzma-dev
libreadline-dev
libsqlite3-dev
libglew-dev
libssl-dev
python3-openssl
tk-dev
xz-utils
zlib1g-dev
uuid-dev
python3-dev
libldap-dev
libcfitsio-dev
libncurses-dev

16 changes: 10 additions & 6 deletions util/installation/ubuntu-24.04/prerequisites.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,16 +40,18 @@ sudo apt-get install apt-transport-https
# Update
sudo apt-get update

# Install required packages
while read -r package; do
sudo apt-get install -y "$package"
done < $BDM_PROJECT_DIR/util/installation/ubuntu-24.04/package_list_required

# Install CMAKE
CMAKE_VER=3.19.3
CMAKE_SH="cmake-${CMAKE_VER}-linux-x86_64.sh"
curl -L -O https://github.com/Kitware/CMake/releases/download/v${CMAKE_VER}/${CMAKE_SH}
sudo bash "${CMAKE_SH}" --prefix=/usr/local --skip-license
rm "${CMAKE_SH}"

# Install required packages
sudo apt-get install -y \
$(cat $BDM_PROJECT_DIR/util/installation/ubuntu-24.04/package_list_required)

if [ -n "${PYENV_ROOT}" ]; then
unset PYENV_ROOT
fi
Expand Down Expand Up @@ -80,8 +82,10 @@ if [ $1 == "all" ]; then
# Don't install --user: the packages should end up in the PYENV_ROOT directory
python -m pip install -r $BDM_PROJECT_DIR/util/installation/ubuntu-24.04/pip_packages.txt

sudo apt-get install -y \
$(cat $BDM_PROJECT_DIR/util/installation/ubuntu-24.04/package_list_extra)
while read -r package; do
sudo apt-get install -y "$package"
done < $BDM_PROJECT_DIR/util/installation/ubuntu-24.04/package_list_extra

fi

exit 0
Loading