Skip to content

Commit

Permalink
mono: update to v6.12.0.182 (#5677)
Browse files Browse the repository at this point in the history
* mono: update to v6.12.0.182
- update mono
- fix BTLS library for aarch64 built with gcc 4 (#3666)
- remove some features to keep the package as small as possible
  - remove boehm gc
  - remove ikvm library
- add a script to update mono ca certificates after installation

* fix build for ARMv5
- enforce build of BTLS library for ARMv5 archs
- fixes mono/mono#11422

* fix ffmpeg dependency evaluation in prepare build
  • Loading branch information
hgy59 authored Mar 30, 2023
1 parent 4635d62 commit a578b4b
Show file tree
Hide file tree
Showing 11 changed files with 73 additions and 257 deletions.
16 changes: 10 additions & 6 deletions .github/actions/prepare.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,12 +57,16 @@ packages=$(printf %s "${SPK_TO_BUILD}" | tr ' ' '\n' | sort -u | tr '\n' ' ')
for i in {4..6}; do
ffmpeg_dependent_packages=$(find spk/ -maxdepth 2 -mindepth 2 -name "Makefile" -exec grep -Ho "FFMPEG_VERSION = ${i}" {} \; | grep -Po ".*spk/\K[^/]*" | sort | tr '\n' ' ')

# If packages are found in the list then ensure
# relevant ffmpeg|ffmpeg5|ffmpeg6 is first in list
# then remove any duplicates from the list
if [ "${ffmpeg_dependent_packages}" != "" ]; then
packages=$(echo "ffmpeg${i} ${packages}" | sed ':s;s/\(\<\S*\>\)\(.*\)\<\1\>/\1\2/g;ts;s/ */ /g')
fi
# If packages contain a package that depends on ffmpeg (or is ffmpeg), then ensure
# relevant ffmpeg4|ffmpeg5|ffmpeg6 is first in list
for package in ${packages}
do
if [ "$(echo ffmpeg${i} ${ffmpeg_dependent_packages} | grep -ow ${package})" != "" ]; then
packages_without_ffmpeg=$(echo "${packages}" | tr ' ' '\n' | grep -v "ffmpeg${i}" | tr '\n' ' ')
packages="ffmpeg${i} ${packages_without_ffmpeg}"
break
fi
done
done

# find all noarch packages
Expand Down
39 changes: 22 additions & 17 deletions cross/mono/Makefile
Original file line number Diff line number Diff line change
@@ -1,21 +1,20 @@
PKG_NAME = mono
PKG_VERS = 5.20.1.34
PKG_EXT = tar.bz2
PKG_VERS = 6.12.0.182
PKG_EXT = tar.xz
PKG_DIST_NAME = $(PKG_NAME)-$(PKG_VERS).$(PKG_EXT)
PKG_DIST_SITE = https://download.mono-project.com/sources/mono
PKG_DIR = $(PKG_NAME)-$(PKG_VERS)

BUILD_DEPENDS = native/$(PKG_NAME)
# native/mono must be of the same version
BUILD_DEPENDS = native/mono

HOMEPAGE = https://www.mono-project.com
COMMENT = Cross platform, open source .NET development framework.
LICENSE = https://www.mono-project.com/docs/faq/licensing

# Although qoriq can be compiled successfully it won't run as classic floating point unit not available
# Although qoriq can be compiled successfully it won't run as a classic floating point unit is not available
# For details see: https://github.com/SynoCommunity/spksrc/issues/3470#issuecomment-469391052
UNSUPPORTED_ARCHS = $(PPC_ARCHS)
# Mono versions newer than 5.8.0 have an incompatibility with aarch64 on DSM 6.x (issue #3666)
UNSUPPORTED_ARCHS_TCVERSION = aarch64-6.1

PRE_CONFIGURE_TARGET = mono_pre_configure
GNU_CONFIGURE = 1
Expand All @@ -27,33 +26,39 @@ CONFIGURE_ARGS = --disable-mcs-build
CONFIGURE_ARGS += --enable-btls
CONFIGURE_ARGS += --disable-dependency-tracking
CONFIGURE_ARGS += --without-mcs-docs
CONFIGURE_ARGS += --disable-boehm
CONFIGURE_ARGS += --without-ikvm-native
# disable some features
CONFIGURE_ARGS += --enable-minimal=profiler

# Optimize compilation for size
ADDITIONAL_CFLAGS = -Os
# Optimize compilation for minimal size
ADDITIONAL_CFLAGS = -Os

include ../../mk/spksrc.cross-cc.mk
include ../../mk/spksrc.common.mk

PLIST_TRANSFORM = cat
ifeq ($(findstring $(ARCH),$(ARMv5_ARCHS)),$(ARCH))
AG_ARGS = --host=arm-linux
PLIST_TRANSFORM = sed -e '/:lib\/libmono-btls-shared.so/d'
# enforce build of BTLS library
CONFIGURE_ARGS += ac_cv_header_stdalign_h=yes
endif
ifeq ($(findstring $(ARCH),$(ARMv7_ARCHS) $(ARMv7L_ARCHS)),$(ARCH))
AG_ARGS = --host=arm-linux
ifeq ($(findstring $(TCVERSION), "5.0 5.1 5.2"),$(TCVERSION))
PLIST_TRANSFORM = sed -e '/:lib\/libmono-btls-shared.so/d'
endif
endif
ifeq ($(findstring $(ARCH),$(ARMv8_ARCHS)),$(ARCH))
AG_ARGS = --host=aarch64-linux
PLIST_TRANSFORM = sed -e '/:bin\/mono-boehm/d' -e '/:lib\/libmonoboehm/d'
ifeq ($(call version_lt, ${TCVERSION}, 7.0),1)
# fix for https://github.com/SynoCommunity/spksrc/issues/3666
ADDITIONAL_CFLAGS += -fno-split-wide-types
endif
endif
ifeq ($(findstring $(ARCH),$(i686_ARCHS)),$(ARCH))
ifeq ($(findstring $(TCVERSION), "5.0 5.1 5.2"),$(TCVERSION))
PLIST_TRANSFORM = sed -e '/:lib\/libmono-btls-shared.so/d'
endif
endif
AG_ARGS += --disable-mcs-build
AG_ARGS += --disable-boehm
AG_ARGS += --without-ikvm-native

include ../../mk/spksrc.cross-cc.mk

.PHONY: mono_pre_configure
mono_pre_configure:
Expand Down
44 changes: 12 additions & 32 deletions cross/mono/PLIST
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
rsc:bin/al
rsc:bin/al2
rsc:bin/csc
rsc:bin/csc-dim
rsc:bin/csi
rsc:bin/gacutil
rsc:bin/gacutil2
Expand All @@ -16,29 +15,24 @@ rsc:bin/mdoc-update
rsc:bin/mdoc-validate
rsc:bin/mdvalidater
rsc:bin/mkbundle
bin:bin/mono
bin:bin/mono-boehm
lnk:bin/mono
rsc:bin/mono-configuration-crypto
bin:bin/monodis
rsc:bin/monodocer
rsc:bin/monodocs2html
rsc:bin/monodocs2slashdoc
rsc:bin/mono-find-provides
rsc:bin/mono-find-requires
rsc:bin/mono-gdb.py
rsc:bin/mono-heapviz
rsc:bin/monop
rsc:bin/monop2
rsc:bin/mono-package-runtime
rsc:bin/mono-service
rsc:bin/mono-service2
bin:bin/mono-sgen
rsc:bin/mono-sgen-gdb.py
rsc:bin/mono-test-install
bin:bin/mprof-report
rsc:bin/nunit-console
rsc:bin/nunit-console2
rsc:bin/nunit-console4
bin:bin/monodis
rsc:bin/monodocer
rsc:bin/monodocs2html
rsc:bin/monodocs2slashdoc
rsc:bin/monop
rsc:bin/monop2
rsc:bin/peverify
rsc:bin/resgen
rsc:bin/resgen2
Expand All @@ -63,32 +57,18 @@ rsc:etc/mono/4.5/settings.map
rsc:etc/mono/4.5/web.config
rsc:etc/mono/browscap.ini
rsc:etc/mono/config
lib:lib/libikvm-native.so
lib:lib/libMonoPosixHelper.so
lib:lib/libMonoSupportW.so
lnk:lib/libmono-2.0.so
lnk:lib/libmono-2.0.so.1
lib:lib/libmono-2.0.so.1.0.0
lnk:lib/libmonoboehm-2.0.so
lnk:lib/libmonoboehm-2.0.so.1
lib:lib/libmonoboehm-2.0.so.1.0.0
lib:lib/libmono-btls-shared.so
lib:lib/libMonoPosixHelper.so
lnk:lib/libmono-profiler-aot.so
lnk:lib/libmono-profiler-aot.so.0
lib:lib/libmono-profiler-aot.so.0.0.0
lnk:lib/libmono-profiler-coverage.so
lnk:lib/libmono-profiler-coverage.so.0
lib:lib/libmono-profiler-coverage.so.0.0.0
lnk:lib/libmono-profiler-log.so
lnk:lib/libmono-profiler-log.so.0
lib:lib/libmono-profiler-log.so.0.0.0
lnk:lib/libmonosgen-2.0.so
lnk:lib/libmonosgen-2.0.so.1
lib:lib/libmonosgen-2.0.so.1.0.0
lib:lib/libMonoSupportW.so
lnk:lib/libmono-native.so
lnk:lib/libmono-native.so.0
lib:lib/libmono-native.so.0.0.0
lnk:lib/libmonosgen-2.0.so
lnk:lib/libmonosgen-2.0.so.1
lib:lib/libmonosgen-2.0.so.1.0.0
rsc:lib/mono/lldb/mono.py
rsc:share/mono-2.0/mono/cil/cil-opcodes.xml
rsc:share/mono-2.0/mono/eglib/eglib-config.h
rsc:share/mono-2.0/mono/profiler/mono-profiler-coverage.suppression
6 changes: 3 additions & 3 deletions cross/mono/digests
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
mono-5.20.1.34.tar.bz2 SHA1 06f6bce0644c87ed132f3f2155a940c3b6fcf8e6
mono-5.20.1.34.tar.bz2 SHA256 cd91d44cf62515796ba90dfdc274bb33471c25a2f1a262689a3bdc0a672b7c8b
mono-5.20.1.34.tar.bz2 MD5 b4af6c8d1f23f19809a5c18d43bac613
mono-6.12.0.182.tar.xz SHA1 c55424b3e2f3a89915941fba1920f1db6a44f7b2
mono-6.12.0.182.tar.xz SHA256 57366a6ab4f3b5ecf111d48548031615b3a100db87c679fc006e8c8a4efd9424
mono-6.12.0.182.tar.xz MD5 3e7d4c67a03f4edc542c57d2684c9819
109 changes: 0 additions & 109 deletions cross/mono/patches/002-explicit-use-of-python2.patch

This file was deleted.

12 changes: 7 additions & 5 deletions native/mono/Makefile
Original file line number Diff line number Diff line change
@@ -1,22 +1,24 @@
PKG_NAME = mono
PKG_VERS = 5.20.1.34
PKG_EXT = tar.bz2
PKG_VERS = 6.12.0.182
PKG_EXT = tar.xz
PKG_DIST_NAME = $(PKG_NAME)-$(PKG_VERS).$(PKG_EXT)
PKG_DIST_SITE = https://download.mono-project.com/sources/$(PKG_NAME)
PKG_DIST_SITE = https://download.mono-project.com/sources/mono
PKG_DIR = $(PKG_NAME)-$(PKG_VERS)

DEPENDS =

HOMEPAGE = https://www.mono-project.com
COMMENT = Cross platform, open source .NET development framework.
LICENSE = https://github.com/mono/mono/blob/master/LICENSE
LICENSE = https://www.mono-project.com/docs/faq/licensing/

GNU_CONFIGURE = 1

CONFIGURE_ARGS = --disable-dependency-tracking
# disable-static does not work without disable-libraries
CONFIGURE_ARGS += --disable-static --disable-libraries
CONFIGURE_ARGS += --disable-static --disable-libraries
CONFIGURE_ARGS += --without-mcs-docs
CONFIGURE_ARGS += --disable-boehm
CONFIGURE_ARGS += --without-ikvm-native

POST_INSTALL_TARGET = mono_native_post_install

Expand Down
6 changes: 3 additions & 3 deletions native/mono/digests
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
mono-5.20.1.34.tar.bz2 SHA1 06f6bce0644c87ed132f3f2155a940c3b6fcf8e6
mono-5.20.1.34.tar.bz2 SHA256 cd91d44cf62515796ba90dfdc274bb33471c25a2f1a262689a3bdc0a672b7c8b
mono-5.20.1.34.tar.bz2 MD5 b4af6c8d1f23f19809a5c18d43bac613
mono-6.12.0.182.tar.xz SHA1 c55424b3e2f3a89915941fba1920f1db6a44f7b2
mono-6.12.0.182.tar.xz SHA256 57366a6ab4f3b5ecf111d48548031615b3a100db87c679fc006e8c8a4efd9424
mono-6.12.0.182.tar.xz MD5 3e7d4c67a03f4edc542c57d2684c9819
2 changes: 2 additions & 0 deletions native/mono/patches/001-relocate-specialfolders.patch
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# adjust location of special folders to match package installed on DSM
#
--- ./mcs/class/corlib/System/Environment.cs.orig 2018-02-17 20:23:18.195842002 +0100
+++ ./mcs/class/corlib/System/Environment.cs 2018-02-17 20:27:50.300067318 +0100
@@ -676,7 +676,7 @@
Expand Down
Loading

0 comments on commit a578b4b

Please sign in to comment.