SHA256
1
0
forked from pool/racket

Accepting request 690400 from home:WernerFink:branches:devel:languages:misc

- Add patch extflvector-length-inlined.patch from upstream commit
  80f84f21 to get extflvector-length work even on i586

- Spec file clean up
- Try to get it work on some ix86 CPU versions

- Require some missed libraries and certificates for build
  as well as for installation even if rmplint cries 
- Update to racket 7.2
  * The contract system supports collapsible contracts, which avoid
    repeated wrappers in certain pathological situations. Thanks to Daniel
    Feltey.
  * Quickscript, a scripting tool for DrRacket, has become part of the
    standard distribution. Thanks to Laurent Orseau.
  * The web server's built-in configuration for serving static files
    recognizes the ".mjs" extension for JavaScript modules.
  * The `data/enumerate` library supports an additional form of
    subtraction via `but-not/e`, following Yorgey and Foner's ICFP'18
    paper. Thanks to Max New.
  * The `letrec.rkt` example model in Redex has been changed to more
    closely match Racket, which led to some bug fixes in Racket's
    implementation of `letrec` and `set!`.
  * The racklog library has seen a number of improvements, including fixes
    to logic variable binding, logic variables containing predicates being
    applicable, and the introduction of an `%andmap` higher-order predicate.

OBS-URL: https://build.opensuse.org/request/show/690400
OBS-URL: https://build.opensuse.org/package/show/devel:languages:misc/racket?expand=0&rev=32
This commit is contained in:
Dr. Werner Fink 2019-04-02 11:13:17 +00:00 committed by Git OBS Bridge
parent 7387d0223b
commit fc107ab268
9 changed files with 196 additions and 24 deletions

View File

@ -1,9 +1,32 @@
<?xml version="1.0"?>
<constraints>
<sandbox>kvm</sandbox>
<hostlabel exclude="true">SLOW_CPU</hostlabel>
<hardware>
<processors>4</processors>
<memory>
<physicalmemory>
<size unit="G">4</size>
</physicalmemory>
<memory>
<size unit="G">6</size>
</memory>
<disk>
<size unit="G">1</size>
</disk>
</hardware>
<overwrite>
<conditions>
<arch>i586</arch>
<arch>x86_64</arch>
</conditions>
<hardware>
<cpu>
<flag>mmx</flag>
<flag>sse</flag>
<flag>sse2</flag>
<flag>sse3</flag>
<flag>ssse3</flag>
</cpu>
</hardware>
</overwrite>
</constraints>

View File

@ -0,0 +1,26 @@
From 80f84f2132233f8bcba05273cc23414caff8bd9c Mon Sep 17 00:00:00 2001
From: Matthew Flatt <mflatt@racket-lang.org>
Date: Sat, 2 Feb 2019 19:38:41 -0700
Subject: [PATCH] fix extflvector-length for platforms where it's not inlined
---
racket/src/racket/src/number.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/racket/src/racket/src/number.c b/racket/src/racket/src/number.c
index 954efffbf1..e486ce265d 100644
--- a/racket/src/racket/src/number.c
+++ b/racket/src/racket/src/number.c
@@ -1083,7 +1083,11 @@ void scheme_init_extfl_number(Scheme_Startup_Env *env)
ADD_PRIM_W_ARITY("make-shared-extflvector", make_shared_extflvector, 1, 2, env);
p = scheme_make_immed_prim(extflvector_length, "extflvector-length", 1, 1);
- SCHEME_PRIM_PROC_FLAGS(p) |= scheme_intern_prim_opt_flags(SCHEME_PRIM_IS_UNARY_INLINED
+ if (MZ_LONG_DOUBLE_AVAIL_AND(1))
+ flags = SCHEME_PRIM_IS_BINARY_INLINED;
+ else
+ flags = SCHEME_PRIM_SOMETIMES_INLINED;
+ SCHEME_PRIM_PROC_FLAGS(p) |= scheme_intern_prim_opt_flags(flags
| SCHEME_PRIM_PRODUCES_FIXNUM);
scheme_addto_prim_instance("extflvector-length", p, env);

View File

@ -1,6 +0,0 @@
addFilter("unexpanded-macro /usr/share/racket/collects/srfi/")
addFilter("file-contains-buildroot.*/usr/share/racket/pkgs/.*zo")
addFilter("file-contains-buildroot.*/usr/share/doc/packages/racket/syntax/module-helpers.html")
addFilter("file-contains-buildroot.*/usr/share/doc/packages/racket/rackunit/api.html")
addFilter("file-contains-buildroot.*/usr/share/doc/packages/racket/reference/collects.html")

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:e973298a17893bb3afeafc68ca422bb9ffbd6c307059c753bcd1ffaccd071fa0
size 26282006

3
racket-7.2-src.tgz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:e42d1ff0bb8c6b483a720387e5e9e68d39c1386cfdb14c565fc9d517e3049889
size 26412598

16
racket-doc.patch Normal file
View File

@ -0,0 +1,16 @@
---
share/pkgs/scribble-lib/help/search.rkt | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
--- share/pkgs/scribble-lib/help/search.rkt
+++ share/pkgs/scribble-lib/help/search.rkt 2019-03-28 07:38:19.695803840 +0000
@@ -43,7 +43,8 @@
(let* ([path (build-path (find-user-doc-dir) sub)]
[path (if (file-exists? path) path (build-path (find-doc-dir) sub))])
(notify path)
- (if (file-exists? path)
+ (if (and (file-exists? path)
+ (file-exists? (build-path (find-doc-dir) "docindex.sqlite")))
(send-url/file path #:fragment fragment #:query query)
(let ([part (lambda (pfx x) (if x (string-append pfx x) ""))])
(send-url (string-append

8
racket-rpmlintrc Normal file
View File

@ -0,0 +1,8 @@
addFilter(".*unexpanded-macro.*/usr/share/racket/collects/srfi/.*")
addFilter(".*W:.*explicit-lib-dependency.*lib.*")
addFilter(".*W:.*zero-length.*")
addFilter(".*W:.*pem-certificate.*/test\.pem.*")
addFilter(".*W:.*script-without-shebang.*/starter-sh.*")
addFilter(".*file-contains-buildroot.*/usr/share/doc/packages/racket/syntax/module-helpers.html.*")
addFilter(".*file-contains-buildroot.*/usr/share/doc/packages/racket/rackunit/api.html.*")
addFilter(".*file-contains-buildroot.*/usr/share/doc/packages/racket/reference/collects.html.*")

View File

@ -1,3 +1,38 @@
-------------------------------------------------------------------
Mon Apr 1 11:32:05 UTC 2019 - Dr. Werner Fink <werner@suse.de>
- Add patch extflvector-length-inlined.patch from upstream commit
80f84f21 to get extflvector-length work even on i586
-------------------------------------------------------------------
Fri Mar 29 12:55:43 UTC 2019 - Dr. Werner Fink <werner@suse.de>
- Spec file clean up
- Try to get it work on some ix86 CPU versions
-------------------------------------------------------------------
Wed Mar 27 18:12:23 UTC 2019 - Dr. Werner Fink <werner@suse.de>
- Require some missed libraries and certificates for build
as well as for installation even if rmplint cries
- Update to racket 7.2
* The contract system supports collapsible contracts, which avoid
repeated wrappers in certain pathological situations. Thanks to Daniel
Feltey.
* Quickscript, a scripting tool for DrRacket, has become part of the
standard distribution. Thanks to Laurent Orseau.
* The web server's built-in configuration for serving static files
recognizes the ".mjs" extension for JavaScript modules.
* The `data/enumerate` library supports an additional form of
subtraction via `but-not/e`, following Yorgey and Foner's ICFP'18
paper. Thanks to Max New.
* The `letrec.rkt` example model in Redex has been changed to more
closely match Racket, which led to some bug fixes in Racket's
implementation of `letrec` and `set!`.
* The racklog library has seen a number of improvements, including fixes
to logic variable binding, logic variables containing predicates being
applicable, and the introduction of an `%andmap` higher-order predicate.
-------------------------------------------------------------------
Thu Nov 29 22:02:09 UTC 2018 - Tomasz Olszewski <olszewst@gmail.com>

View File

@ -1,7 +1,7 @@
#
# spec file for package racket
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2012, 2013 Togan Muftuoglu toganm@opensuse.org
#
# All modifications and additions to the file contributed by third parties
@ -18,7 +18,7 @@
Name: racket
Version: 7.1
Version: 7.2
Release: 0
Summary: Scheme implementation with teaching tools
License: LGPL-2.1-or-later AND GPL-3.0-or-later
@ -26,9 +26,12 @@ Group: Development/Languages/Scheme
Url: http://racket-lang.org
Source0: http://download.racket-lang.org/installers/%version/%name-%version-src.tgz
Source2: racket-completion.bash
Source3: racket-6.10.1.rpmlintrc
Source3: racket-rpmlintrc
Patch0: racket-doc.patch
Patch1: extflvector-length-inlined.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: ImageMagick
BuildRequires: ca-certificates
BuildRequires: chrpath
BuildRequires: fdupes
BuildRequires: gcc-c++
@ -41,8 +44,10 @@ BuildRequires: update-desktop-files
BuildRequires: pkgconfig(cairo)
BuildRequires: pkgconfig(fontconfig)
BuildRequires: pkgconfig(freetype2)
BuildRequires: pkgconfig(gtk+-2.0)
BuildRequires: pkgconfig(glib-2.0)
BuildRequires: pkgconfig(gtk+-3.0)
BuildRequires: pkgconfig(ice)
BuildRequires: pkgconfig(libedit)
BuildRequires: pkgconfig(libffi)
BuildRequires: pkgconfig(libpng)
BuildRequires: pkgconfig(openssl)
@ -58,9 +63,20 @@ BuildRequires: pkgconfig(xmu)
BuildRequires: pkgconfig(xrender)
BuildRequires: pkgconfig(xt)
BuildRequires: pkgconfig(zlib)
# The rpmbuild does not detect those!
Requires: libcairo2
Requires: libedit0
Requires: libglib-2_0-0
Requires: libgtk-3-0
Requires: libpango-1_0-0
Requires: libsqlite3-0
Provides: %name-drracket = %version-%release
Provides: %name-games = %version-%release
Provides: %name-webserver = %version-%release
Recommends: racket-doc = %{version}-%{release}
%define add_optflags(a:f:t:p:w:W:d:g:O:A:C:D:E:H:i:M:n:P:U:u:l:s:X:B:I:L:b:V:m:x:c:S:E:o:v:) \
%global optflags %{optflags} %{**}
# maggia has this
# Disable the debug package since otherwise a build would create the following
@ -81,6 +97,15 @@ the creation of embedded and domain-specific languages, language constructs
such as classes or modules, and separate dialects of Racket enable different
semantics.
%package doc
Summary: Documentation HTML files for Racket
Group: Development/Languages/Scheme
Provides: %{name}:%{_docdir}/%{name}/docindex.sqlite
BuildArch: noarch
%description doc
A local installation of the Racket documentation system.
%package devel
Summary: Development header files for Racket
Group: Development/Languages/Scheme
@ -95,17 +120,23 @@ compile and link programs which use Racket.
%prep
%setup -q
%patch0 -p0
%patch1 -p2
cp %{S:2} src/.
cp -p %{S:2} src/
%build
cd src
cd src/
%add_optflags -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=500 -fno-gcse
%configure --prefix="%_datadir" --docdir="%_defaultdocdir/%name" --enable-shared \
--disable-static --disable-strip --enable-places --enable-lt="%_bindir/libtool" \
--enable-pthread
%configure --prefix="%_datadir" --docdir="%_defaultdocdir/%name" --enable-shared --disable-static --disable-strip --enable-places --enable-lt="%_bindir/libtool"
make %{?_smp_mflags} VERBOSE=1
%install
cd src
cd src/
# use the following if setting extra plt_setup options
# export LD_LIBRARY_PATH=%%buildroot%%_libdir
@ -119,8 +150,37 @@ install -d %buildroot/%_datadir/doc/%name/
find %buildroot%_libdir -name "*.la" -delete
find %buildroot%_libdir -name "*.a" -delete
find %buildroot%_datadir -name ".LOCKpkgs.rktd" -delete
install -Dm 644 %{S:2} %buildroot%_sysconfdir/bash_completion.d/%name
# make system clear
for bin in mred mzscheme racket
do
test -e $bin || continue
chrpath --delete %{buildroot}%{_bindir}/$bin || :
done
for bin in gracket starter
do
test -e $bin || continue
chrpath --delete %{buildroot}%{_libdir}/$bin || :
done
for bin in c-printf crypt esd magick sndfile tcl xmmsctrl xosd
do
bin=%{buildroot}%{_datadir}/%{name}/pkgs/racket-doc/ffi/examples/use-${bin}.rkt
test -e $bin || continue
sed -ri '1s@(/usr/bin/)env +@\1@p' $bin
chmod 755 $bin
done
chmod 755 %{buildroot}%{_datadir}/%{name}/pkgs/htdp-lib/2htdp/uchat/xrun
for html in syntax/module-helpers rackunit/api reference/collects
do
html=%{_docdir}/%{name}/${html}.html
test -e $html || continue
sed -ri 's@%{buildroot}@@g' $html
done
# Bash completion
install -Dm 644 %{S:2} %buildroot%_datadir/bash_completion/completions/%name
install -Dm 644 %_builddir/%name-%version/share/pkgs/drracket/drracket/drracket.png %buildroot%_datadir/pixmaps/drracket.png
# rewrite path in .desktop files
@ -128,6 +188,9 @@ install -Dm 644 %_builddir/%name-%version/share/pkgs/drracket/drracket/drracket.
%suse_update_desktop_file -c drracket "DrRacket" "DrRacket is an interactive, integrated, graphical programming environment for the Racket programming languages" "%_bindir/drracket" "drracket" Development IDE
%suse_update_desktop_file -c slideshow "Slideshow" "Slideshow is a Racket-based tool for writing slide presentations as programs" "%_bindir/slideshow" "drracket" Development Documentation
# Due package split we do this explicit to support older rpm version as well
install -m 0644 ../README %{buildroot}%{_docdir}/%{name}/README
%fdupes %buildroot%_prefix
%post
@ -140,8 +203,8 @@ install -Dm 644 %_builddir/%name-%version/share/pkgs/drracket/drracket/drracket.
%files
%defattr(-,root,root,-)
%doc README
%doc %{_docdir}/%{name}
%doc %dir %{_docdir}/%{name}
%doc %{_docdir}/%{name}/README
%_bindir/drracket
%_bindir/gracket
%_bindir/gracket-text
@ -164,7 +227,7 @@ install -Dm 644 %_builddir/%name-%version/share/pkgs/drracket/drracket/drracket.
%_bindir/slatex
%_bindir/slideshow
%_bindir/swindle
%_libdir/*.so
%_libdir/libracket3m-%{version}.so
%_libdir/%name/mzdyn3m.o
%_datadir/%name/*
%_libdir/%name/starter
@ -181,19 +244,26 @@ install -Dm 644 %_builddir/%name-%version/share/pkgs/drracket/drracket/drracket.
%_mandir/man1/plt-help*
%dir %_libdir/%name
%dir %_datadir/%name
%dir %_sysconfdir/bash_completion.d/
%dir %_datadir/bash_completion
%dir %_datadir/bash_completion/completions
%dir %_sysconfdir/%name
%_sysconfdir/bash_completion.d/%name
%_datadir/bash_completion/completions/%name
%config %_sysconfdir/%name/config.rktd
%_datadir/applications/drracket.desktop
%_datadir/applications/slideshow.desktop
%_datadir/pixmaps/drracket.png
%exclude %_datadir/%name/pkgs/mzscheme-lib/mzscheme/examples/*
%files doc
%defattr(-,root,root,-)
%doc %{_docdir}/%{name}/*
%exclude %{_docdir}/%{name}/README
%files devel
%defattr(-,root,root,-)
%_includedir/%name/*
%_libdir/%name/buildinfo
%_libdir/libracket3m.so
%dir %_includedir/%name
%_datadir/%name/pkgs/mzscheme-lib/mzscheme/examples/*