mirror of
https://github.com/roswell/roswell.git
synced 2026-09-10 07:16:17 -04:00
Compare commits
89 commits
v22.12.14.
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
28e6455a3a | ||
|
|
0ed46fb92a | ||
|
|
267ff72edc | ||
|
|
05a2c2fa3b | ||
|
|
6c010f97d0 | ||
|
|
aa261f4e46 | ||
|
|
ac187eadaa | ||
|
|
c7170d4cb7 | ||
|
|
9709c0db0f | ||
|
|
d6d4a761f1 | ||
|
|
d6b5e2ad0e | ||
|
|
f10677c8e9 | ||
|
|
d0b368951c | ||
|
|
05c290ce48 | ||
|
|
aac28aaedd | ||
|
|
2a04f0314c | ||
|
|
b897695f19 | ||
|
|
bb4af5fc0e | ||
|
|
b31ff3aeb7 | ||
|
|
b2ecbe902e | ||
|
|
a776a353dd | ||
|
|
b16e0e7391 | ||
|
|
bae37247f1 | ||
|
|
e6ccbc4430 | ||
|
|
feb5647990 | ||
|
|
029e979374 | ||
|
|
82f902bf43 | ||
|
|
e2da0bf7bc | ||
|
|
b2286cf4f3 | ||
|
|
8c8da03e77 | ||
|
|
7d4262e76f | ||
|
|
7ff8d0fb09 | ||
|
|
7b08fc7204 | ||
|
|
46b1ff35ac | ||
|
|
266dc81908 | ||
|
|
77c175103f | ||
|
|
1bd85255b4 | ||
|
|
0dc9b1150d | ||
|
|
b3e12e0133 | ||
|
|
8fc5809743 | ||
|
|
70f379a58c | ||
|
|
ddf356ab38 | ||
|
|
dbb6e5894e | ||
|
|
beb2bad2fd | ||
|
|
412566b8a5 | ||
|
|
f2127bb813 | ||
|
|
776835811a | ||
|
|
8d5471eba1 | ||
|
|
de01eec94f | ||
|
|
1ef739bd3e | ||
|
|
da2a76e50c | ||
|
|
daebc205f9 | ||
|
|
730cfe3f94 | ||
|
|
3f8dccc11c | ||
|
|
6d74fbdeb9 | ||
|
|
9b212cda7c | ||
|
|
06233e5218 | ||
|
|
c0a347fdf2 | ||
|
|
4c17a2b653 | ||
|
|
0498baf088 | ||
|
|
0e7a2f1b6d | ||
|
|
0807dbd547 | ||
|
|
5b267381a6 | ||
|
|
08ca16dcc3 | ||
|
|
bf91af67cc | ||
|
|
ab3017dcc6 | ||
|
|
6158d1cca7 | ||
|
|
a844895c67 | ||
|
|
b6d1eb1fd8 | ||
|
|
06e5dc6be2 | ||
|
|
ec4c9b39ca | ||
|
|
afe3e39d86 | ||
|
|
53ec6fb392 | ||
|
|
5c0b3913c9 | ||
|
|
4eec08cca7 | ||
|
|
76848fa7dc | ||
|
|
1381da6ad8 | ||
|
|
638608236c | ||
|
|
16e2aa2300 | ||
|
|
74bb83a467 | ||
|
|
db9b518f1a | ||
|
|
bdc4a133ce | ||
|
|
6bb93dd033 | ||
|
|
209a51377e | ||
|
|
f9bbd2e1e7 | ||
|
|
c6a91b91a6 | ||
|
|
c9c89cebcb | ||
|
|
b516ad6972 | ||
|
|
04b495d76b |
69
.github/workflows/build.yml
vendored
69
.github/workflows/build.yml
vendored
|
|
@ -1,69 +0,0 @@
|
||||||
name: CI
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
#pull_request:
|
|
||||||
#schedule:
|
|
||||||
# - cron: '0 */2 * * *'
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build-windows:
|
|
||||||
runs-on: windows-latest
|
|
||||||
timeout-minutes: 90
|
|
||||||
strategy:
|
|
||||||
fail-fast: false
|
|
||||||
matrix:
|
|
||||||
arch: [x86_64, i686]
|
|
||||||
include:
|
|
||||||
- arch: x86_64
|
|
||||||
arch2: amd64
|
|
||||||
bit: 64
|
|
||||||
- arch: i686
|
|
||||||
arch2: i686
|
|
||||||
bit: 32
|
|
||||||
env:
|
|
||||||
RESULT_NAME: windows-${{ matrix.arch2 }}
|
|
||||||
RESULT_PATH: windows-${{ matrix.arch2 }}
|
|
||||||
RESULT_PATH_SUB: roswell
|
|
||||||
steps:
|
|
||||||
- run: git config --global core.autocrlf false
|
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- uses: msys2/setup-msys2@v2
|
|
||||||
with:
|
|
||||||
msystem: MINGW${{ matrix.bit }}
|
|
||||||
path-type: inherit
|
|
||||||
release: true
|
|
||||||
update: true
|
|
||||||
install: 'base-devel mingw-w64-${{ matrix.arch }}-toolchain'
|
|
||||||
- name: Run MSYS2 once
|
|
||||||
shell: msys2 {0}
|
|
||||||
run: |
|
|
||||||
pwd
|
|
||||||
echo $MSYSTEM
|
|
||||||
echo $MSYS2_PATH_TYPE
|
|
||||||
echo $PATH
|
|
||||||
- name: Build
|
|
||||||
shell: msys2 {0}
|
|
||||||
run: |
|
|
||||||
gcc -v
|
|
||||||
./bootstrap
|
|
||||||
./configure
|
|
||||||
make
|
|
||||||
make install
|
|
||||||
make winrelease
|
|
||||||
- name: Copy result
|
|
||||||
if: always()
|
|
||||||
shell: msys2 {0}
|
|
||||||
run: |
|
|
||||||
mkdir -p $RESULT_PATH
|
|
||||||
cp *.zip $RESULT_PATH/tmp.zip
|
|
||||||
cd $RESULT_PATH
|
|
||||||
7z x tmp.zip
|
|
||||||
rm tmp.zip
|
|
||||||
- name: Upload Result
|
|
||||||
if: always()
|
|
||||||
uses: actions/upload-artifact@v1
|
|
||||||
with:
|
|
||||||
name: ${{ env.RESULT_NAME }}
|
|
||||||
path: ${{ env.RESULT_PATH }}
|
|
||||||
|
|
||||||
60
.github/workflows/linux.yml
vendored
60
.github/workflows/linux.yml
vendored
|
|
@ -1,4 +1,4 @@
|
||||||
name: linux
|
name: Linux
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
|
|
@ -6,51 +6,58 @@ on:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
runs-on: ubuntu-18.04
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
|
image: [musl64]
|
||||||
|
variant: ['', '-musl', '-glibc2.31']
|
||||||
|
target: ['x86_64', 'arm64', 'riscv64']
|
||||||
include:
|
include:
|
||||||
- lisp: sbcl-bin/2.0.0
|
# set default docker platform and image suffix.
|
||||||
target: x86-64
|
- {docker-platform: linux/amd64 ,docker-image-suffix: '', makeopts: musl }
|
||||||
image: musl64
|
- {target: arm64 ,docker-platform: linux/arm64 ,docker-image-suffix: 'aarch64' }
|
||||||
makeopts: musl
|
- {target: riscv64 ,docker-platform: linux/riscv64 ,docker-image-suffix: 'riscv64' }
|
||||||
- lisp: sbcl-bin/2.0.0
|
- {image: deb, makeopts: deb, target: x86-64 ,docker-platform: linux/amd64}
|
||||||
target: x86-64
|
- {image: pandoc, makeopts: docs, target: x86-64 ,docker-platform: linux/amd64}
|
||||||
image: musl64
|
|
||||||
makeopts: musl
|
|
||||||
variant: -musl
|
|
||||||
- lisp: sbcl-bin/2.0.0
|
|
||||||
target: x86-64
|
|
||||||
image: deb
|
|
||||||
makeopts: deb
|
|
||||||
- lisp: sbcl-bin/2.0.0
|
|
||||||
target: x86-64
|
|
||||||
image: pandoc
|
|
||||||
makeopts: docs
|
|
||||||
environment: SET_VERSION
|
environment: SET_VERSION
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v4
|
||||||
|
- name: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@v3
|
||||||
|
with:
|
||||||
|
image: tonistiigi/binfmt:qemu-v8.1.5
|
||||||
- name: setenv
|
- name: setenv
|
||||||
run: |
|
run: |
|
||||||
echo "$HOME/.roswell/bin" >> $GITHUB_PATH
|
echo "$HOME/.roswell/bin" >> $GITHUB_PATH
|
||||||
echo "ROSWELL_BRANCH=release" >> $GITHUB_ENV
|
echo "ROSWELL_BRANCH=release" >> $GITHUB_ENV
|
||||||
- name: checkenv
|
- name: checkenv
|
||||||
run: |
|
run: |
|
||||||
uname -s
|
uname -s -m
|
||||||
uname -m
|
|
||||||
- name: Install Roswell
|
- name: Install Roswell
|
||||||
env:
|
env:
|
||||||
LISP: ${{ matrix.lisp }}
|
LISP: sbcl-bin/2.4.0
|
||||||
GITHUB_OAUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_OAUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
IMAGE: ${{ matrix.image }}
|
IMAGE: ${{ matrix.image }}
|
||||||
run: |
|
run: |
|
||||||
sh scripts/install-for-ci.sh
|
sh scripts/install-for-ci.sh
|
||||||
ros install snmsts/sn.github
|
ros install snmsts/sn.github
|
||||||
|
- name: Login to GitHub Container Registry
|
||||||
|
uses: docker/login-action@v3
|
||||||
|
with:
|
||||||
|
registry: docker.pkg.github.com
|
||||||
|
username: ${{ github.actor }}
|
||||||
|
password: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
- name: pull or build&push docker image
|
||||||
|
env:
|
||||||
|
DOCKER_PLATFORM: ${{ matrix.docker-platform }}
|
||||||
|
DOCKER_BUILD_OPTIONS: ${{ matrix.docker-build-options }}
|
||||||
|
DOCKER_IMAGE_SUFFIX: ${{ matrix.docker-image-suffix }}
|
||||||
|
IMAGE: ${{ matrix.image }}
|
||||||
|
run: |
|
||||||
if [ -n "$IMAGE" ]; then
|
if [ -n "$IMAGE" ]; then
|
||||||
docker login docker.pkg.github.com -u snmsts -p $GITHUB_OAUTH_TOKEN;
|
|
||||||
make -f scripts/Makefile pull-docker || make -f scripts/Makefile build-docker push-docker
|
make -f scripts/Makefile pull-docker || make -f scripts/Makefile build-docker push-docker
|
||||||
fi
|
fi
|
||||||
- name: build
|
- name: build
|
||||||
|
|
@ -60,6 +67,9 @@ jobs:
|
||||||
DOCKER: ${{ matrix.docker }}
|
DOCKER: ${{ matrix.docker }}
|
||||||
SUFFIX: ${{ matrix.suffix }}
|
SUFFIX: ${{ matrix.suffix }}
|
||||||
LINKFLAGS: ${{ matrix.linkflags }}
|
LINKFLAGS: ${{ matrix.linkflags }}
|
||||||
|
DOCKER_PLATFORM: ${{ matrix.docker-platform }}
|
||||||
|
DOCKER_BUILD_OPTIONS: ${{ matrix.docker-build-options }}
|
||||||
|
DOCKER_IMAGE_SUFFIX: ${{ matrix.docker-image-suffix }}
|
||||||
IMAGE: ${{ matrix.image }}
|
IMAGE: ${{ matrix.image }}
|
||||||
MAKEOPTS: ${{ matrix.makeopts }}
|
MAKEOPTS: ${{ matrix.makeopts }}
|
||||||
VARIANT: ${{ matrix.variant }}
|
VARIANT: ${{ matrix.variant }}
|
||||||
|
|
|
||||||
23
.github/workflows/osx.yml
vendored
23
.github/workflows/osx.yml
vendored
|
|
@ -6,25 +6,34 @@ on:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
runs-on: macos-10.15
|
runs-on: ${{ matrix.target == 'arm64' && 'macos-14' || 'macos-15-intel' }}
|
||||||
strategy:
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
lisp: [sbcl-bin/2.0.0]
|
lisp: [sbcl-bin/2.3.8]
|
||||||
target: [x86-64]
|
target: [arm64, x86-64]
|
||||||
environment: SET_VERSION
|
environment: SET_VERSION
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v4
|
||||||
|
- name: setenv
|
||||||
|
run: |
|
||||||
|
echo "$HOME/.roswell/bin" >> $GITHUB_PATH
|
||||||
|
echo "ROSWELL_INSTALL_DIR=$HOME/.roswell" >> $GITHUB_ENV
|
||||||
- name: checkenv
|
- name: checkenv
|
||||||
run: |
|
run: |
|
||||||
uname -s
|
uname -s -m
|
||||||
uname -m
|
|
||||||
brew install autoconf automake
|
brew install autoconf automake
|
||||||
- name: Build
|
- name: Build
|
||||||
|
env:
|
||||||
|
CFLAGS: -mmacosx-version-min=10.9
|
||||||
|
CXXFLAGS: -mmacosx-version-min=10.9
|
||||||
|
LDFLAGS: -mmacosx-version-min=10.9
|
||||||
|
ARCH: ${{ matrix.target }}
|
||||||
run: |
|
run: |
|
||||||
gcc -v
|
gcc -v
|
||||||
./bootstrap
|
./bootstrap
|
||||||
./configure
|
./configure --prefix=$ROSWELL_INSTALL_DIR
|
||||||
make
|
make
|
||||||
make install
|
make install
|
||||||
make pack
|
make pack
|
||||||
|
|
|
||||||
28
.github/workflows/test.yml
vendored
28
.github/workflows/test.yml
vendored
|
|
@ -1,7 +1,8 @@
|
||||||
name: test
|
name: test
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
schedule:
|
||||||
|
- cron: '0 1 * * *'
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
|
@ -12,7 +13,7 @@ jobs:
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
os: [macos-10.15, ubuntu-18.04]
|
os: [macos-latest, ubuntu-latest]
|
||||||
lisp:
|
lisp:
|
||||||
- alisp
|
- alisp
|
||||||
- cmu-bin/2019-06
|
- cmu-bin/2019-06
|
||||||
|
|
@ -20,27 +21,34 @@ jobs:
|
||||||
- ecl
|
- ecl
|
||||||
- clisp
|
- clisp
|
||||||
- ccl-bin
|
- ccl-bin
|
||||||
- sbcl/1.4.0
|
- sbcl/2.4.0
|
||||||
- ccl32
|
- ccl32
|
||||||
experimental: [false]
|
experimental: [false]
|
||||||
|
exclude:
|
||||||
|
- lisp: ccl-bin
|
||||||
|
os: macos-latest
|
||||||
|
- lisp: ccl32
|
||||||
|
os: macos-latest
|
||||||
|
- lisp: cmu-bin/2019-06
|
||||||
|
os: macos-latest
|
||||||
include:
|
include:
|
||||||
- lisp: mkcl
|
- lisp: mkcl
|
||||||
os: macos-10.15
|
os: macos-latest
|
||||||
experimental: true
|
experimental: true
|
||||||
- lisp: mkcl
|
- lisp: mkcl
|
||||||
os: ubuntu-18.04
|
os: ubuntu-latest
|
||||||
experimental: true
|
experimental: true
|
||||||
- lisp: sbcl/git
|
- lisp: sbcl/git
|
||||||
os: macos-10.15
|
os: macos-latest
|
||||||
experimental: true
|
experimental: true
|
||||||
- lisp: sbcl/git
|
- lisp: sbcl/git
|
||||||
os: ubuntu-18.04
|
os: ubuntu-latest
|
||||||
experimental: true
|
experimental: true
|
||||||
- lisp: abcl
|
- lisp: abcl
|
||||||
os: macos-10.15
|
os: macos-latest
|
||||||
experimental: true
|
experimental: true
|
||||||
- lisp: abcl
|
- lisp: abcl
|
||||||
os: ubuntu-18.04
|
os: ubuntu-latest
|
||||||
experimental: true
|
experimental: true
|
||||||
|
|
||||||
env:
|
env:
|
||||||
|
|
@ -63,5 +71,5 @@ jobs:
|
||||||
ros version=t run
|
ros version=t run
|
||||||
ros install prove
|
ros install prove
|
||||||
run-prove roswell-test.asd 2>&1
|
run-prove roswell-test.asd 2>&1
|
||||||
ros -q run && [`ros -q run 2>&1` == ""]
|
ros -q run && [ "$(ros -q run 2>&1)" = "" ]
|
||||||
ros config
|
ros config
|
||||||
|
|
|
||||||
55
.github/workflows/windows.yml
vendored
55
.github/workflows/windows.yml
vendored
|
|
@ -35,7 +35,12 @@ jobs:
|
||||||
path-type: inherit
|
path-type: inherit
|
||||||
release: true
|
release: true
|
||||||
update: true
|
update: true
|
||||||
install: 'base-devel mingw-w64-${{ matrix.arch }}-toolchain p7zip'
|
install: >-
|
||||||
|
base-devel
|
||||||
|
p7zip
|
||||||
|
autotools
|
||||||
|
mingw-w64-${{ matrix.arch }}-toolchain
|
||||||
|
mingw-w64-${{ matrix.arch }}-autotools
|
||||||
- name: Run MSYS2 once
|
- name: Run MSYS2 once
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
|
|
@ -58,3 +63,51 @@ jobs:
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
make -f scripts/Makefile latest-version win-upload
|
make -f scripts/Makefile latest-version win-upload
|
||||||
|
|
||||||
|
build-windows-arm64:
|
||||||
|
runs-on: windows-11-arm
|
||||||
|
timeout-minutes: 90
|
||||||
|
env:
|
||||||
|
RESULT_NAME: windows-aarch64
|
||||||
|
RESULT_PATH: windows-aarch64
|
||||||
|
RESULT_PATH_SUB: roswell
|
||||||
|
|
||||||
|
environment: SET_VERSION
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- run: git config --global core.autocrlf false
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- uses: msys2/setup-msys2@v2
|
||||||
|
with:
|
||||||
|
msystem: CLANGARM64
|
||||||
|
path-type: inherit
|
||||||
|
release: true
|
||||||
|
update: true
|
||||||
|
install: >-
|
||||||
|
base-devel
|
||||||
|
p7zip
|
||||||
|
autotools
|
||||||
|
mingw-w64-clang-aarch64-toolchain
|
||||||
|
mingw-w64-clang-aarch64-autotools
|
||||||
|
- name: Run MSYS2 once
|
||||||
|
shell: msys2 {0}
|
||||||
|
run: |
|
||||||
|
pwd
|
||||||
|
echo $MSYSTEM
|
||||||
|
echo $MSYSTEM_CARCH
|
||||||
|
echo $PATH
|
||||||
|
- name: Build
|
||||||
|
shell: msys2 {0}
|
||||||
|
run: |
|
||||||
|
clang -v
|
||||||
|
./bootstrap
|
||||||
|
CC=clang ./configure
|
||||||
|
make
|
||||||
|
make install
|
||||||
|
make pack.zip
|
||||||
|
- name: Upload
|
||||||
|
env:
|
||||||
|
GITHUB_OAUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
shell: msys2 {0}
|
||||||
|
run: |
|
||||||
|
make -f scripts/Makefile latest-version win-upload
|
||||||
|
|
|
||||||
36
ChangeLog
36
ChangeLog
|
|
@ -1,3 +1,39 @@
|
||||||
|
roswell (26.02.116-1) unstable; urgency=low
|
||||||
|
|
||||||
|
* Fix: failure to load djula on sbcl 2.5.11 environment.
|
||||||
|
* Fix: declaration-definition disagreement in src/cmd-run.h. (reported by ItsMeForLua and fixed by Trichiurus-lepturus)
|
||||||
|
* Fix: support sbcl lisp-implementation-version returning '2.4.10.roswell'.
|
||||||
|
* Change: Allegro CL upgraded to release 11.0express. (by Xiaming Chen)
|
||||||
|
* Change: ros command return 1 when script file not found.
|
||||||
|
* Change: ros fmt rewritten to use cl-indentify.
|
||||||
|
|
||||||
|
-- SANO,Masatoshi <snmsts@gmail.com> Tue, 24 Feb 2026 06:39:51 +0900
|
||||||
|
|
||||||
|
roswell (24.10.115-1) unstable; urgency=low
|
||||||
|
|
||||||
|
* New: tested on darwin/ppc environment.
|
||||||
|
* New: tested on netbsd/aarch64 environment.
|
||||||
|
* Fix: absolute path error on Windows (by Ashton Fagg)
|
||||||
|
* Fix: build error on non Windows environment with windres (reported by Richard DW Redcroft)
|
||||||
|
* Fix: error message in build (by Rongsong Shen)
|
||||||
|
|
||||||
|
-- snmsts <snmsts@gmail.com> Wed, 16 Oct 2024 15:06:42 +0900
|
||||||
|
|
||||||
|
roswell (23.10.14.114-1) unstable; urgency=low
|
||||||
|
|
||||||
|
* New: use patchelf to support for distributions like guix/nix.
|
||||||
|
* Fix: 'ros.installing' feature not work. (reported by Fukamachi)
|
||||||
|
* Fix: fix windows build script (by Jeongsoo, Park)
|
||||||
|
* Fix: ros fmt (by Daniel Jay Haskin)
|
||||||
|
|
||||||
|
-- SANO Masatoshi <snmsts@gmail.com> Tue, 03 Oct 2023 12:57:11 +0000
|
||||||
|
|
||||||
|
roswell (22.12.14.113-1) unstable; urgency=low
|
||||||
|
|
||||||
|
* Fix: release CI for debian package.
|
||||||
|
|
||||||
|
-- SANO Masatoshi <snmsts@gmail.com> Sat, 10 Dec 2022 23:14:05 +0800
|
||||||
|
|
||||||
roswell (22.12.14.112-1) unstable; urgency=low
|
roswell (22.12.14.112-1) unstable; urgency=low
|
||||||
|
|
||||||
* New: Support cab extract on windows.
|
* New: Support cab extract on windows.
|
||||||
|
|
|
||||||
14
Makefile.am
14
Makefile.am
|
|
@ -77,7 +77,8 @@ LISPS = helper.el \
|
||||||
install+7zip.lisp install-abcl-bin.lisp install-allegro.lisp \
|
install+7zip.lisp install-abcl-bin.lisp install-allegro.lisp \
|
||||||
install-ccl-bin.lisp install-clasp-bin.lisp install-clasp.lisp \
|
install-ccl-bin.lisp install-clasp-bin.lisp install-clasp.lisp \
|
||||||
install-clisp.lisp install-clisp-head.lisp \
|
install-clisp.lisp install-clisp-head.lisp \
|
||||||
install-cmu-bin.lisp install-ecl.lisp install-quicklisp.lisp \
|
install-cmu-bin.lisp install-dotcl-bin.lisp install-ecl.lisp \
|
||||||
|
install-quicklisp.lisp \
|
||||||
install-sbcl-bin.lisp install-sbcl.lisp install-sbcl-source.lisp \
|
install-sbcl-bin.lisp install-sbcl.lisp install-sbcl-source.lisp \
|
||||||
install-sbcl-head.lisp \
|
install-sbcl-head.lisp \
|
||||||
install-slime.lisp install-sly.lisp \
|
install-slime.lisp install-sly.lisp \
|
||||||
|
|
@ -107,7 +108,7 @@ dist_roslisppatch_DATA = patch/sbcl-1.3.11.patch patch/sbcl-posix-tests.patch
|
||||||
release-prepare:
|
release-prepare:
|
||||||
ros scripts/release.ros prepare
|
ros scripts/release.ros prepare
|
||||||
release-commit:
|
release-commit:
|
||||||
ros scripts/release.ros release
|
ros scripts/release.ros release-commit
|
||||||
release-push:
|
release-push:
|
||||||
ros scripts/release.ros release-push
|
ros scripts/release.ros release-push
|
||||||
release-changelog:
|
release-changelog:
|
||||||
|
|
@ -122,7 +123,7 @@ winrelease: roswell/Makefile
|
||||||
cp lisp/*.lisp lisp/*.ros lisp/*.el roswell/lisp
|
cp lisp/*.lisp lisp/*.ros lisp/*.el roswell/lisp
|
||||||
cd documents;MSYSTEM=MINGW64 make roswell.chm
|
cd documents;MSYSTEM=MINGW64 make roswell.chm
|
||||||
cp documents/roswell.chm roswell/documents
|
cp documents/roswell.chm roswell/documents
|
||||||
7z a Roswell-`if [ $$MSYSTEM = 'MINGW64' ];then echo x86_64 ;else echo i686; fi`.zip roswell/ros.exe roswell/lisp/*.* roswell/documents/roswell.chm
|
7z a Roswell-`if [ "$$MSYSTEM" = "MINGW64" ];then echo x86_64 ;elif [ "$$MSYSTEM" = "CLANGARM64" ];then echo aarch64; else echo i686; fi`.zip roswell/ros.exe roswell/lisp/*.* roswell/documents/roswell.chm
|
||||||
debian:
|
debian:
|
||||||
ros debian/debian.ros all
|
ros debian/debian.ros all
|
||||||
test:
|
test:
|
||||||
|
|
@ -131,7 +132,7 @@ brewpr:
|
||||||
git pull
|
git pull
|
||||||
if [ `uname` = 'Darwin' ];then brew bump-formula-pr -v --url=https://github.com/roswell/roswell/archive/`git describe --abbrev=0 --tags`.tar.gz roswell; fi
|
if [ `uname` = 'Darwin' ];then brew bump-formula-pr -v --url=https://github.com/roswell/roswell/archive/`git describe --abbrev=0 --tags`.tar.gz roswell; fi
|
||||||
|
|
||||||
PACK = $(PACKAGE)-$(VERSION)-$(shell uname -s | tr '[A-Z]' '[a-z]' | sed -E 's/([^-]*).*/\1/')-$(shell uname -m)$(SBCL_BIN_VARIANT)
|
PACK = $(PACKAGE)-$(VERSION)-$(shell uname -s | tr '[A-Z]' '[a-z]' | sed -E 's/([^-]*).*/\1/')-$(ARCH)$(SBCL_BIN_VARIANT)
|
||||||
|
|
||||||
roswell/Makefile:
|
roswell/Makefile:
|
||||||
rm -rf roswell
|
rm -rf roswell
|
||||||
|
|
@ -144,7 +145,7 @@ roswell/Makefile:
|
||||||
echo " mkdir -p $$""(prefix)/etc/roswell/patch" >> $@
|
echo " mkdir -p $$""(prefix)/etc/roswell/patch" >> $@
|
||||||
echo " mkdir -p $$""(mandir)" >> $@
|
echo " mkdir -p $$""(mandir)" >> $@
|
||||||
echo " install -c ros$(EXEEXT) $$""(prefix)/bin" >> $@
|
echo " install -c ros$(EXEEXT) $$""(prefix)/bin" >> $@
|
||||||
echo " install -c -m 644 $(LISPS:%=lisp/%) $$""(prefix)/etc/roswell" >> $@
|
echo " install -c -m 644 $(ROSS:%=lisp/%) $(LISPS:%=lisp/%) $$""(prefix)/etc/roswell" >> $@
|
||||||
echo " install -c -m 644 $(dist_roslisppatch_DATA) $$""(prefix)/etc/roswell/patch" >> $@
|
echo " install -c -m 644 $(dist_roslisppatch_DATA) $$""(prefix)/etc/roswell/patch" >> $@
|
||||||
if [ 'x$(MDS)' != 'x' ]; then \
|
if [ 'x$(MDS)' != 'x' ]; then \
|
||||||
echo " install -c $(MDS:%.md=man/%.1) $$""(mandir)" >> $@; \
|
echo " install -c $(MDS:%.md=man/%.1) $$""(mandir)" >> $@; \
|
||||||
|
|
@ -161,6 +162,7 @@ $(PACK).tar.bz2: roswell/Makefile
|
||||||
cp src/ros$(EXEEXT) roswell
|
cp src/ros$(EXEEXT) roswell
|
||||||
$(MKDIR_P) roswell/lisp
|
$(MKDIR_P) roswell/lisp
|
||||||
cp $(LISPS:%=lisp/%) roswell/lisp
|
cp $(LISPS:%=lisp/%) roswell/lisp
|
||||||
|
cp $(ROSS:%=lisp/%) roswell/lisp
|
||||||
cp $(dist_roslisppatch_DATA) roswell/patch
|
cp $(dist_roslisppatch_DATA) roswell/patch
|
||||||
if [ 'x$(MDS)' != x ]; then \
|
if [ 'x$(MDS)' != x ]; then \
|
||||||
$(MKDIR_P) roswell/man; \
|
$(MKDIR_P) roswell/man; \
|
||||||
|
|
@ -170,7 +172,7 @@ $(PACK).tar.bz2: roswell/Makefile
|
||||||
|
|
||||||
pack: $(PACK).tar.bz2
|
pack: $(PACK).tar.bz2
|
||||||
|
|
||||||
WINPACK = roswell_$(VERSION)_$(shell if [ $$MSYSTEM = 'MINGW64' ];then echo amd64 ;else echo i686; fi)
|
WINPACK = roswell_$(VERSION)_$(shell if [ "$$MSYSTEM" = "MINGW64" ];then echo amd64 ;elif [ "$$MSYSTEM" = "CLANGARM64" ];then echo aarch64; else echo i686; fi)
|
||||||
|
|
||||||
pack.zip: $(PACK).tar.bz2
|
pack.zip: $(PACK).tar.bz2
|
||||||
7z a $(WINPACK).zip roswell
|
7z a $(WINPACK).zip roswell
|
||||||
|
|
|
||||||
10
configure.ac
10
configure.ac
|
|
@ -2,7 +2,7 @@
|
||||||
# Process this file with autoconf to produce a configure script.
|
# Process this file with autoconf to produce a configure script.
|
||||||
|
|
||||||
AC_PREREQ([2.59])
|
AC_PREREQ([2.59])
|
||||||
AC_INIT([roswell],[22.12.14.112],snmsts@gmail.com)
|
AC_INIT([roswell],[26.02.116],snmsts@gmail.com)
|
||||||
CFLAGS=${CFLAGS=""}
|
CFLAGS=${CFLAGS=""}
|
||||||
CXXFLAGS=${CXXFLAGS=""}
|
CXXFLAGS=${CXXFLAGS=""}
|
||||||
|
|
||||||
|
|
@ -58,7 +58,7 @@ AC_CHECK_HEADERS(gnu/libc-version.h)
|
||||||
AC_CHECK_HEADERS(windows.h,[with_windows=true])
|
AC_CHECK_HEADERS(windows.h,[with_windows=true])
|
||||||
AM_CONDITIONAL([WITH_WINDOWS], [test "$with_windows" != ""])
|
AM_CONDITIONAL([WITH_WINDOWS], [test "$with_windows" != ""])
|
||||||
AC_CHECK_TOOL([WINDRES], [windres], [])
|
AC_CHECK_TOOL([WINDRES], [windres], [])
|
||||||
AM_CONDITIONAL([WITH_WIN_ICON], [test "$WINDRES" != ""])
|
AM_CONDITIONAL([WITH_WIN_ICON], [test "$WINDRES" != "" -a "$with_windows" != ""])
|
||||||
|
|
||||||
AC_CHECK_MEMBERS([struct dirent.d_type],,,[#include <dirent.h>])
|
AC_CHECK_MEMBERS([struct dirent.d_type],,,[#include <dirent.h>])
|
||||||
|
|
||||||
|
|
@ -108,6 +108,12 @@ AC_ARG_WITH([sbcl_bin_variant],
|
||||||
AC_SUBST([SBCL_BIN_VARIANT], ["${SBCL_BIN_VARIANT}"])
|
AC_SUBST([SBCL_BIN_VARIANT], ["${SBCL_BIN_VARIANT}"])
|
||||||
AC_DEFINE_UNQUOTED([SBCL_BIN_VARIANT],["${SBCL_BIN_VARIANT}"],[variant for sbcl-bin])
|
AC_DEFINE_UNQUOTED([SBCL_BIN_VARIANT],["${SBCL_BIN_VARIANT}"],[variant for sbcl-bin])
|
||||||
|
|
||||||
|
AC_ARG_WITH([fixed_arch],
|
||||||
|
[AS_HELP_STRING([--with-fixed-arch=string],[set arch instead of on the fly detecting [default=''] possible choices are 'armhf', 'arm64'.])],
|
||||||
|
[FIXED_ARCH=$withval],[FIXED_ARCH=""])
|
||||||
|
AC_SUBST([FIXED_ARCH], ["${FIXED_ARCH}"])
|
||||||
|
AC_DEFINE_UNQUOTED([FIXED_ARCH],["${FIXED_ARCH}"],[arch to decide binary])
|
||||||
|
|
||||||
# man file (ros.1) generation switch
|
# man file (ros.1) generation switch
|
||||||
AC_ARG_ENABLE([manual_generation],
|
AC_ARG_ENABLE([manual_generation],
|
||||||
[AS_HELP_STRING([--enable-manual-generation],[generate manual if enabled])],
|
[AS_HELP_STRING([--enable-manual-generation],[generate manual if enabled])],
|
||||||
|
|
|
||||||
22
debian/debian.ros
vendored
22
debian/debian.ros
vendored
|
|
@ -5,7 +5,7 @@ exec ros -Q -L sbcl-bin -- $0 "$@"
|
||||||
|#
|
|#
|
||||||
(progn ;;init forms
|
(progn ;;init forms
|
||||||
(ros:ensure-asdf)
|
(ros:ensure-asdf)
|
||||||
#+quicklisp (ql:quickload '(:cl-html-parse :uiop :dexador) :silent t))
|
#+quicklisp (ql:quickload '(:jonathan :uiop :dexador) :silent t))
|
||||||
|
|
||||||
(defpackage :ros.script.debian.3703769507
|
(defpackage :ros.script.debian.3703769507
|
||||||
(:use :cl))
|
(:use :cl))
|
||||||
|
|
@ -20,24 +20,16 @@ exec ros -Q -L sbcl-bin -- $0 "$@"
|
||||||
(if branch
|
(if branch
|
||||||
(format nil "https://github.com/~A/archive/~A.tar.gz" base branch)
|
(format nil "https://github.com/~A/archive/~A.tar.gz" base branch)
|
||||||
(multiple-value-bind (body res)
|
(multiple-value-bind (body res)
|
||||||
(dex:get (format nil "https://github.com/~A/releases/" base))
|
(dex:get (format nil "https://api.github.com/repos/~A/releases" base)
|
||||||
|
:headers '(("X-GitHub-Api-Version" . "2022-11-28")))
|
||||||
(when (= res 200)
|
(when (= res 200)
|
||||||
(net.html.parser:parse-html
|
(getf (first (jojo:parse body)) :|tarball_url|))))))
|
||||||
body
|
|
||||||
:callbacks
|
|
||||||
(list (cons :a (lambda (arg)
|
|
||||||
(let ((href (getf (cdr (car arg)) :href)))
|
|
||||||
(when (and (> (length href) 6)
|
|
||||||
(equal (subseq href (-(length href) 6))
|
|
||||||
"tar.gz")
|
|
||||||
;; href which include "archive" not "release"
|
|
||||||
(eql (aref href (1+ (position #\a href))) #\r))
|
|
||||||
(return-from get-newest-url (format nil "https://github.com~A" href)))))))
|
|
||||||
:callback-only t))))))
|
|
||||||
|
|
||||||
(defun fetch-upstream (&optional (output *pwd*))
|
(defun fetch-upstream (&optional (output *pwd*))
|
||||||
(let* ((url (get-newest-url "roswell/roswell"))
|
(let* ((url (get-newest-url "roswell/roswell"))
|
||||||
(path (merge-pathnames (subseq url (1+ (position #\/ url :from-end t))) output)))
|
(path (make-pathname :name (format nil "roswell_~A.tar" (subseq url (1+ (position #\/ url :from-end t))))
|
||||||
|
:defaults output
|
||||||
|
:type "gz")))
|
||||||
(roswell.util:download url path)
|
(roswell.util:download url path)
|
||||||
path))
|
path))
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -126,10 +126,14 @@ IR1 (deftransform), IR2 (VOP) information in the infodb."
|
||||||
(setf (sb-impl::package-%shadowing-symbols package) nil)
|
(setf (sb-impl::package-%shadowing-symbols package) nil)
|
||||||
(format t ".")
|
(format t ".")
|
||||||
(setf (sb-impl::package-internal-symbols package)
|
(setf (sb-impl::package-internal-symbols package)
|
||||||
(sb-impl::make-package-hashtable 0))
|
(if (fboundp 'sb-impl::make-symbol-table)
|
||||||
|
(sb-impl::make-symbol-table 0)
|
||||||
|
(sb-impl::make-package-hashtable 0)))
|
||||||
(format t ".")
|
(format t ".")
|
||||||
(setf (sb-impl::package-external-symbols package)
|
(setf (sb-impl::package-external-symbols package)
|
||||||
(sb-impl::make-package-hashtable 0))
|
(if (fboundp 'sb-impl::make-symbol-table)
|
||||||
|
(sb-impl::make-symbol-table 0)
|
||||||
|
(sb-impl::make-package-hashtable 0)))
|
||||||
(format t ".")
|
(format t ".")
|
||||||
(setf (sb-impl::package-tables package) #())
|
(setf (sb-impl::package-tables package) #())
|
||||||
(format t ".")
|
(format t ".")
|
||||||
|
|
|
||||||
|
|
@ -33,33 +33,44 @@
|
||||||
|
|
||||||
(defun roswell-installed-system-name (system-name)
|
(defun roswell-installed-system-name (system-name)
|
||||||
;; should return repo part of system-name.
|
;; should return repo part of system-name.
|
||||||
;; "user//repo" "user//repo/branch" "git://bra/bra/bra/repo.git" "github://user/repo"
|
;; "user:repo[:branch or tag][/subsystem/name]" "git://bra/bra/bra/repo.git" "github://user/repo"
|
||||||
(when (find "" (split-sequence #\/ system-name) :test 'equal) ;; found "//"
|
(let ((split (split-sequence #\: system-name)))
|
||||||
(if (find #\: system-name)
|
(when (rest split) ;; found ":"
|
||||||
(values nil "not implemented yet") ;; TBD
|
(if (ignore-errors (and (eql (aref (second split) 0) #\/)
|
||||||
(second (remove "" (split-sequence #\/ system-name) :test 'equal)))))
|
(eql (aref (second split) 1) #\/)))
|
||||||
|
(values nil "not implemented yet") ;; TBD
|
||||||
|
(let* ((str (first (last split)))
|
||||||
|
(pos (position #\/ str))
|
||||||
|
(subsystem (if pos
|
||||||
|
(prog1
|
||||||
|
(subseq str pos)
|
||||||
|
(setf (first (last split)) (subseq str 0 pos)))
|
||||||
|
"")))
|
||||||
|
(values (and (second split)
|
||||||
|
(not (zerop (length (second split))))
|
||||||
|
(format nil "~A~A" (second split) subsystem))
|
||||||
|
(lambda (system-name)
|
||||||
|
(roswell:roswell `("install" ,(format nil "~{~A~^/~}" split)
|
||||||
|
)))))))))
|
||||||
|
|
||||||
(defun roswell-installable-searcher (system-name)
|
(defun roswell-installable-searcher (system-name)
|
||||||
(let ((name (roswell-installed-system-name system-name))
|
(multiple-value-bind (name func)
|
||||||
pname)
|
(roswell-installed-system-name system-name)
|
||||||
(and
|
(and
|
||||||
name
|
name
|
||||||
(not (when (setf pname (read-call "asdf/find-system::primary-system-name" system-name))
|
(not (equal name system-name))
|
||||||
(asdf:find-system pname nil)))
|
(let ((result
|
||||||
(prog1
|
(or (ignore-errors (asdf:find-system name))
|
||||||
(or (quicklisp-client:local-projects-searcher name)
|
(progn
|
||||||
(unless (find system-name (loop for ar = (ros:getenv "ROSINSTALL") then (subseq ar (1+ p))
|
(funcall func system-name)
|
||||||
for p = (position #\, ar)
|
(local-project-build-hash :rebuild t)
|
||||||
for arg = (if p (subseq ar 0 p) ar)
|
(asdf:find-system name))
|
||||||
collect arg
|
(return-from roswell-installable-searcher)))) ;;can't find.
|
||||||
while p)
|
(when result
|
||||||
:test 'equal)
|
(let ((*load-pathname* nil))
|
||||||
(roswell:roswell `("install" ,system-name))
|
(eval `(asdf:defsystem ,system-name
|
||||||
(quicklisp-client:register-local-projects)
|
:depends-on (,name)))))
|
||||||
(quicklisp-client:local-projects-searcher name))
|
result))))
|
||||||
(return-from roswell-installable-searcher)) ;;can't find.
|
|
||||||
(eval `(asdf:defsystem ,system-name :depends-on (,name))))
|
|
||||||
(asdf:find-system system-name))))
|
|
||||||
|
|
||||||
(defun local-project-enum (path)
|
(defun local-project-enum (path)
|
||||||
(let ((sub (remove-if (lambda (x)
|
(let ((sub (remove-if (lambda (x)
|
||||||
|
|
|
||||||
71
lisp/fmt.ros
71
lisp/fmt.ros
|
|
@ -5,17 +5,30 @@ exec ros -Q -N roswell -- $0 "$@"
|
||||||
|#
|
|#
|
||||||
(progn ;;init forms
|
(progn ;;init forms
|
||||||
(ros:ensure-asdf)
|
(ros:ensure-asdf)
|
||||||
#+quicklisp
|
#+sbcl (require "sb-introspect")
|
||||||
(progn
|
#+quicklisp (ql:quickload '("cl-indentify") :silent t))
|
||||||
(unless (ql:where-is-system :lem)
|
|
||||||
(roswell:roswell '("git" "clone" "https://github.com/cxxxr/lem.git"))
|
|
||||||
(roswell.util:read-call "roswell.util:local-project-build-hash" :rebuild t))
|
|
||||||
(ql:quickload '("swank" "lem" "lem-lisp-syntax") :silent t)))
|
|
||||||
|
|
||||||
(defpackage :ros.script.fmt.3707812168
|
(defpackage :ros.script.fmt.3707812168
|
||||||
(:use :cl))
|
(:use :cl))
|
||||||
(in-package :ros.script.fmt.3707812168)
|
(in-package :ros.script.fmt.3707812168)
|
||||||
|
|
||||||
|
(defun function-lambda-list (fn)
|
||||||
|
"Portably retrieve a function's lambda list."
|
||||||
|
(ignore-errors
|
||||||
|
#+sbcl
|
||||||
|
(funcall (find-symbol "FUNCTION-LAMBDA-LIST" "SB-INTROSPECT") fn)
|
||||||
|
#-sbcl nil))
|
||||||
|
|
||||||
|
(defun register-macro-templates ()
|
||||||
|
"Auto-detect macros with &body and register cl-indentify templates."
|
||||||
|
(do-all-symbols (sym)
|
||||||
|
(when (macro-function sym)
|
||||||
|
(let* ((arglist (function-lambda-list (macro-function sym)))
|
||||||
|
(body-pos (position '&body arglist)))
|
||||||
|
(when body-pos
|
||||||
|
(setf (indentify:indent-template sym)
|
||||||
|
`(:style :call :count ,body-pos)))))))
|
||||||
|
|
||||||
(defun system (path)
|
(defun system (path)
|
||||||
(let ((* (when (and (probe-file path)
|
(let ((* (when (and (probe-file path)
|
||||||
(equal (pathname-type path) "asd"))
|
(equal (pathname-type path) "asd"))
|
||||||
|
|
@ -37,15 +50,39 @@ exec ros -Q -N roswell -- $0 "$@"
|
||||||
(list c)))))
|
(list c)))))
|
||||||
(when *
|
(when *
|
||||||
(ql:quickload * :silent (not (ros:verbose)))
|
(ql:quickload * :silent (not (ros:verbose)))
|
||||||
(lem-lisp-syntax.indent:indentation-update)
|
(register-macro-templates)
|
||||||
(r (asdf:find-system *))))))
|
(r (asdf:find-system *))))))
|
||||||
|
|
||||||
|
(defun register-standard-templates ()
|
||||||
|
"Override templates to match Lem/Emacs/SLIME indentation."
|
||||||
|
;; if: (&rest nil) in Lem - all args aligned with first arg
|
||||||
|
(setf (indentify:indent-template 'if) '(:count 3))
|
||||||
|
;; case/typecase: (4 &rest (&whole 2 &rest 1)) - clause body at paren+1
|
||||||
|
(dolist (sym '(case ccase ecase typecase ctypecase etypecase))
|
||||||
|
(setf (indentify:indent-template sym)
|
||||||
|
'(:count 1 :sub (nil nil (:style :list)))))
|
||||||
|
;; cond: (&rest (&whole 2 &rest 1)) - clause body at paren+1
|
||||||
|
(setf (indentify:indent-template 'cond)
|
||||||
|
'(:count 0 :sub (nil (:style :list)))))
|
||||||
|
|
||||||
|
(defun format-file (file)
|
||||||
|
(let ((result (with-output-to-string (out)
|
||||||
|
(with-open-file (in file)
|
||||||
|
(indentify:indentify in out)))))
|
||||||
|
(with-open-file (out file :direction :output :if-exists :supersede)
|
||||||
|
(with-input-from-string (in result)
|
||||||
|
(loop for line = (read-line in nil)
|
||||||
|
while line
|
||||||
|
do (write-string (string-right-trim '(#\Space #\Tab) line) out)
|
||||||
|
(terpri out))))))
|
||||||
|
|
||||||
(defun main (&rest argv)
|
(defun main (&rest argv)
|
||||||
"go fmt like something"
|
"go fmt like something"
|
||||||
|
(indentify:load-default-templates)
|
||||||
|
(register-standard-templates)
|
||||||
(dolist (arg (if argv
|
(dolist (arg (if argv
|
||||||
(prog1 (loop for arg in argv
|
(loop for arg in argv
|
||||||
append (or (system arg) (list arg)))
|
append (or (system arg) (list arg)))
|
||||||
(lem-lisp-syntax:indentation-update))
|
|
||||||
(ignore-errors
|
(ignore-errors
|
||||||
(let* ((name (first (last (pathname-directory *default-pathname-defaults*))))
|
(let* ((name (first (last (pathname-directory *default-pathname-defaults*))))
|
||||||
(path (probe-file (make-pathname :name name :type "asd"))))
|
(path (probe-file (make-pathname :name name :type "asd"))))
|
||||||
|
|
@ -53,18 +90,6 @@ exec ros -Q -N roswell -- $0 "$@"
|
||||||
(append (directory "*.lisp")
|
(append (directory "*.lisp")
|
||||||
(directory "*.ros")))))))
|
(directory "*.ros")))))))
|
||||||
(if (probe-file arg)
|
(if (probe-file arg)
|
||||||
(let ((buffer (lem-base:find-file-buffer arg)))
|
(format-file arg)
|
||||||
(setf (lem-base:buffer-syntax-table buffer)
|
|
||||||
lem-lisp-syntax:*syntax-table*)
|
|
||||||
(setf (lem-base:variable-value 'lem-base:calc-indent-function :buffer buffer)
|
|
||||||
'lem-lisp-syntax:calc-indent)
|
|
||||||
(lem-base:indent-region (lem-base:buffer-start-point buffer)
|
|
||||||
(lem-base:buffer-end-point buffer))
|
|
||||||
(loop with regexp = "[ ]+$" ;; remove trailing spaces.
|
|
||||||
for start = (lem-base:search-forward-regexp (lem-base:copy-point (lem-base:buffer-start-point buffer)) regexp)
|
|
||||||
while start
|
|
||||||
for end = (lem-base:search-backward-regexp (lem-base:copy-point start) regexp)
|
|
||||||
do (lem-base:delete-between-points start end))
|
|
||||||
(lem-base:write-to-file buffer (lem-base:buffer-filename buffer)))
|
|
||||||
(format *error-output* "~A does not exist" arg))))
|
(format *error-output* "~A does not exist" arg))))
|
||||||
;;; vim: set ft=lisp lisp:
|
;;; vim: set ft=lisp lisp:
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@
|
||||||
(mapcar #'usage
|
(mapcar #'usage
|
||||||
'("Usage:"
|
'("Usage:"
|
||||||
""
|
""
|
||||||
"To install a new Lisp implementaion:"
|
"To install a new Lisp implementation:"
|
||||||
" ~A install impl [options]"
|
" ~A install impl [options]"
|
||||||
"or a system from the GitHub:"
|
"or a system from the GitHub:"
|
||||||
" ~A install fukamachi/prove/v2.0.0 [repository... ]"
|
" ~A install fukamachi/prove/v2.0.0 [repository... ]"
|
||||||
|
|
@ -30,6 +30,7 @@
|
||||||
""
|
""
|
||||||
"For more details on impl specific options, type:"
|
"For more details on impl specific options, type:"
|
||||||
" ~A help install impl"
|
" ~A help install impl"
|
||||||
|
"e.g.: ~A help install sbcl"
|
||||||
""
|
""
|
||||||
""
|
""
|
||||||
"Candidates impls for installation are:")))
|
"Candidates impls for installation are:")))
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,4 @@
|
||||||
|
;; -*- lexical-binding: nil; -*-
|
||||||
(defun roswell-configdir ()
|
(defun roswell-configdir ()
|
||||||
(substring (shell-command-to-string "ros roswell-internal-use version confdir") 0 -1))
|
(substring (shell-command-to-string "ros roswell-internal-use version confdir") 0 -1))
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -160,7 +160,8 @@ have the latest asdf, and this file has a workaround for this.
|
||||||
(ext:run-shell-command (format nil "~{~A~^ ~}" args))))))
|
(ext:run-shell-command (format nil "~{~A~^ ~}" args))))))
|
||||||
|
|
||||||
(defun exec (args)
|
(defun exec (args)
|
||||||
#+(and unix sbcl)
|
#+(and unix sbcl
|
||||||
|
(not haiku))
|
||||||
(execvp (first args) args)
|
(execvp (first args) args)
|
||||||
#+(and unix ccl)
|
#+(and unix ccl)
|
||||||
(ignore-errors
|
(ignore-errors
|
||||||
|
|
@ -174,8 +175,8 @@ have the latest asdf, and this file has a workaround for this.
|
||||||
|
|
||||||
(cond
|
(cond
|
||||||
(is-quicklisp-already-available
|
(is-quicklisp-already-available
|
||||||
(unless (equal (opt "quicklisp")
|
(unless (equal (ignore-errors (truename (pathname (opt "quicklisp"))))
|
||||||
(namestring (symbol-value (read-from-string "ql:*quicklisp-home*"))))
|
(ignore-errors (truename (symbol-value (read-from-string "ql:*quicklisp-home*")))))
|
||||||
(setf *local-project-directories*
|
(setf *local-project-directories*
|
||||||
(copy-list
|
(copy-list
|
||||||
(symbol-value (read-from-string "ql:*local-project-directories*")))))
|
(symbol-value (read-from-string "ql:*local-project-directories*")))))
|
||||||
|
|
@ -308,13 +309,25 @@ As a hacky side effect, files with the same name as PROVIDE is not loaded.
|
||||||
(or *version-cache*
|
(or *version-cache*
|
||||||
(setf *version-cache* (roswell '("roswell-internal-use" "version") :string t)))))
|
(setf *version-cache* (roswell '("roswell-internal-use" "version") :string t)))))
|
||||||
|
|
||||||
|
(defun implementation-version ()
|
||||||
|
"cut off after third? dot from lisp-implementation-version"
|
||||||
|
(let ((version (lisp-implementation-version)))
|
||||||
|
(loop with j = 0
|
||||||
|
for i from 0 to (1- (length version))
|
||||||
|
when (eql (aref version i) #\.)
|
||||||
|
do (incf j)
|
||||||
|
(when (= j 3)
|
||||||
|
(return-from implementation-version (subseq version 0 i))))
|
||||||
|
version))
|
||||||
|
|
||||||
|
|
||||||
#+sbcl
|
#+sbcl
|
||||||
(when (ignore-errors (string-equal (opt "impl") "sbcl-bin" :end1 8))
|
(when (ignore-errors (string-equal (opt "impl") "sbcl-bin" :end1 8))
|
||||||
(flet ((source (version)
|
(flet ((source (version)
|
||||||
(let ((path (merge-pathnames (format nil "src/sbcl-~A/" version) (opt "homedir"))))
|
(let ((path (merge-pathnames (format nil "src/sbcl-~A/" version) (opt "homedir"))))
|
||||||
(when (probe-file path)
|
(when (probe-file path)
|
||||||
(sb-ext:set-sbcl-source-location path)))))
|
(sb-ext:set-sbcl-source-location path)))))
|
||||||
(or (source (lisp-implementation-version))
|
(or (source (implementation-version))
|
||||||
(source "git"))))
|
(source "git"))))
|
||||||
|
|
||||||
(defun source-registry (arg &rest rest)
|
(defun source-registry (arg &rest rest)
|
||||||
|
|
@ -433,7 +446,8 @@ As a hacky side effect, files with the same name as PROVIDE is not loaded.
|
||||||
(with-open-file (in arg)
|
(with-open-file (in arg)
|
||||||
(body in)))
|
(body in)))
|
||||||
(*latest-system* (apply 'hook (cons arg *argv*)))
|
(*latest-system* (apply 'hook (cons arg *argv*)))
|
||||||
(t (format t "script ~S does not exist~%" arg)))))
|
(t (format t "script ~S does not exist~%" arg)
|
||||||
|
(quit 1)))))
|
||||||
|
|
||||||
(defun stdin (arg &rest rest)
|
(defun stdin (arg &rest rest)
|
||||||
(declare (ignorable arg rest))
|
(declare (ignorable arg rest))
|
||||||
|
|
|
||||||
|
|
@ -9,8 +9,21 @@
|
||||||
(defvar *msys2-arch*)
|
(defvar *msys2-arch*)
|
||||||
(defvar *msys2-bits*)
|
(defvar *msys2-bits*)
|
||||||
|
|
||||||
|
(defun msys2-get-release (version)
|
||||||
|
"
|
||||||
|
In the new GitHub releases, the release name is a date with dashes
|
||||||
|
and the version is a date without.
|
||||||
|
"
|
||||||
|
(if (equal (length version) 8)
|
||||||
|
(format nil "~A-~A-~A"
|
||||||
|
(subseq version 0 4)
|
||||||
|
(subseq version 4 6)
|
||||||
|
(subseq version 6 8))
|
||||||
|
version))
|
||||||
|
|
||||||
(defun msys2-get-version ()
|
(defun msys2-get-version ()
|
||||||
'("20180531"))
|
'("20230127"))
|
||||||
|
|
||||||
;;sha1 "309f604a165179d50fbe4131cf87bd160769f974"
|
;;sha1 "309f604a165179d50fbe4131cf87bd160769f974"
|
||||||
;;(ironclad:byte-array-to-hex-string (ironclad:digest-file :sha1 path))
|
;;(ironclad:byte-array-to-hex-string (ironclad:digest-file :sha1 path))
|
||||||
|
|
||||||
|
|
@ -33,9 +46,12 @@
|
||||||
(when (or (not (probe-file path))
|
(when (or (not (probe-file path))
|
||||||
(opt "download.force"))
|
(opt "download.force"))
|
||||||
(download
|
(download
|
||||||
(format nil "~Amsys2/Base/~A/msys2-base-~A-~A.tar.xz"
|
(format nil "~A~A/msys2-base-~A-~A.tar.xz"
|
||||||
(msys2-uri)
|
(msys2-uri)
|
||||||
*msys2-arch* *msys2-arch* (getf argv :version))
|
(msys2-get-release
|
||||||
|
(getf argv :version))
|
||||||
|
*msys2-arch*
|
||||||
|
(getf argv :version))
|
||||||
path))
|
path))
|
||||||
(format t " done.~%")
|
(format t " done.~%")
|
||||||
(expand path
|
(expand path
|
||||||
|
|
@ -67,11 +83,10 @@
|
||||||
"make zlib-devel"))
|
"make zlib-devel"))
|
||||||
:output t
|
:output t
|
||||||
:error-output t))
|
:error-output t))
|
||||||
|
|
||||||
(uiop/run-program:run-program
|
(uiop/run-program:run-program
|
||||||
`(,(uiop:native-namestring (merge-pathnames "autorebase.bat" msys)))
|
`(,(uiop:native-namestring (merge-pathnames "autorebase.bat" msys)))
|
||||||
:output t
|
:output t
|
||||||
:error-output t)
|
:error-output t)
|
||||||
(setf (config "msys2.version") (getf argv :version)))))
|
(setf (config "msys2.version") (getf argv :version)))))
|
||||||
(cons t argv))
|
(cons t argv))
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -8,27 +8,50 @@
|
||||||
(mapcar #'car *allegro-agreement-uri*))
|
(mapcar #'car *allegro-agreement-uri*))
|
||||||
|
|
||||||
(defun make-allegro-uri (argv &key
|
(defun make-allegro-uri (argv &key
|
||||||
(uname (uname))
|
(uname (uname))
|
||||||
(uname-m (uname-m))
|
(uname-m (uname-m))
|
||||||
(version (getf argv :version)))
|
(version (getf argv :version)))
|
||||||
(let ((os (intern uname :keyword))
|
(let ((os (intern uname :keyword))
|
||||||
(machine (intern uname-m :keyword)))
|
(machine (intern uname-m :keyword)))
|
||||||
(cond ((find version '("10.1express" "100express") :test 'equal)
|
(cond ((find version '("11.0express"
|
||||||
|
"10.1express")
|
||||||
|
:test 'equal)
|
||||||
(format nil "~@{~A~}"
|
(format nil "~@{~A~}"
|
||||||
(allegro-uri) "pub/acl" version "/"
|
(allegro-uri) "ftp/pub/acl" version "/"
|
||||||
(case os (:|darwin| "macosx") (t os))
|
(ecase os
|
||||||
(if (eql os :|windows|) ""
|
(:|linux| (ecase machine
|
||||||
(case machine (:|x86| 86) (:|x86-64| 86)))
|
(:|x86-64| "linuxamd64.64")
|
||||||
|
(:|arm64| "linuxarm64")
|
||||||
|
(:|x86| "linux86")))
|
||||||
|
(:|darwin| (case machine
|
||||||
|
(:|arm64| "macarm64.64")
|
||||||
|
(:|x86-64| "macosx86-64.64")))
|
||||||
|
(:|windows| os) ;; 32bit only
|
||||||
|
(:|freebsd| os)) ;; 32bit only
|
||||||
"/acl" version
|
"/acl" version
|
||||||
(case os (:|linux| "-linux") (:|darwin| "-macosx") (:|windows| "") (t os))
|
(ecase os
|
||||||
"-" (if (eql os :|darwin|) "x64"
|
(:|linux| (format nil "~@{~A~}"
|
||||||
(case machine (:|x86-64| "x86") (t machine)))
|
"-linux-"
|
||||||
(case os
|
(ecase machine
|
||||||
(:|linux| (cond ((equal "10.1express" version) ".tbz2")
|
(:|x86-64| "x64")
|
||||||
((equal "100express" version) ".bz2")))
|
(:|arm64| "aarch64")
|
||||||
(:|darwin| ".dmg")
|
(:|x86| "x86"))
|
||||||
(:|windows| ".exe"))))
|
(cond
|
||||||
((equal "101b" version)))))
|
((equal "100express" version) ".bz2")
|
||||||
|
(t ".tbz2"))))
|
||||||
|
(:|darwin| (format nil "~@{~A~}"
|
||||||
|
(if (equal version "10.1express")
|
||||||
|
"-macosx-"
|
||||||
|
"-macos-")
|
||||||
|
(ecase machine
|
||||||
|
(:|x86-64| "x64.dmg")
|
||||||
|
(:|arm64| "arm64.dmg"))))
|
||||||
|
(:|windows| "-x86.exe")
|
||||||
|
(:|freebsd| (format nil "~@{~A~}"
|
||||||
|
"-freebsd-"
|
||||||
|
(ecase machine
|
||||||
|
(:|x86-64| "x86.tbz2")
|
||||||
|
(:|x86| "x86.tbz2"))))))))))
|
||||||
|
|
||||||
(defun allegro-argv-parse (argv)
|
(defun allegro-argv-parse (argv)
|
||||||
(format *error-output* "~&Installing allegro/~A...~%" (getf argv :version))
|
(format *error-output* "~&Installing allegro/~A...~%" (getf argv :version))
|
||||||
|
|
@ -65,7 +88,9 @@
|
||||||
(uiop/filesystem:delete-directory-tree
|
(uiop/filesystem:delete-directory-tree
|
||||||
path :validate t))
|
path :validate t))
|
||||||
(ql-impl-util:rename-directory
|
(ql-impl-util:rename-directory
|
||||||
(merge-pathnames (format nil "acl~A/" (getf argv :version)) impls)
|
(first (loop for file in (directory (merge-pathnames (format nil "acl~A*/" (getf argv :version)) impls))
|
||||||
|
when (probe-file file)
|
||||||
|
collect it))
|
||||||
(merge-pathnames (format nil "~A/" (opt "as")) impls))))
|
(merge-pathnames (format nil "~A/" (opt "as")) impls))))
|
||||||
(cons t argv)))
|
(cons t argv)))
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@
|
||||||
(let* ((src (merge-pathnames (format nil "asdf-~A/" version) src))
|
(let* ((src (merge-pathnames (format nil "asdf-~A/" version) src))
|
||||||
(cmd (list (sh) "-lc" (format nil "cd ~S;~A"
|
(cmd (list (sh) "-lc" (format nil "cd ~S;~A"
|
||||||
(#+win32 mingw-namestring #-win32 princ-to-string src)
|
(#+win32 mingw-namestring #-win32 princ-to-string src)
|
||||||
(or #+freebsd "gmake" "make")))))
|
(make)))))
|
||||||
(uiop/os:chdir src)
|
(uiop/os:chdir src)
|
||||||
(format t "~&chdir ~A~%" src)
|
(format t "~&chdir ~A~%" src)
|
||||||
(uiop/run-program:run-program cmd :output t :ignore-error-status nil)
|
(uiop/run-program:run-program cmd :output t :ignore-error-status nil)
|
||||||
|
|
|
||||||
|
|
@ -21,11 +21,31 @@
|
||||||
(or (cdr (assoc (uname-m) *cmu-uname-m-alist* :test 'equal))
|
(or (cdr (assoc (uname-m) *cmu-uname-m-alist* :test 'equal))
|
||||||
(uname-m)))
|
(uname-m)))
|
||||||
|
|
||||||
|
(defun cmu-bin-directory-uri (version)
|
||||||
|
(format nil "~@{~A~}" (cmu-bin-uri) (if (find #\- version) "snapshots/" "release/")
|
||||||
|
(substitute #\/ #\- version) "/"))
|
||||||
|
|
||||||
|
(defun cmu-bin-archive-name (version extra)
|
||||||
|
(format nil "~@{~A~}" "cmucl-" version "-" (cmu-uname-m) "-" (uname) (if extra ".extra" "")))
|
||||||
|
|
||||||
|
(defun cmu-bin-archive-type (version)
|
||||||
|
"CMUCL was published as .tar.bz2 up to 21e and as .tar.xz from 21f on,
|
||||||
|
so ask the download directory which one it has for VERSION."
|
||||||
|
(let ((file (merge-pathnames (format nil "tmp/cmu-bin-~A.html" version) (homedir)))
|
||||||
|
(name (cmu-bin-archive-name version nil)))
|
||||||
|
(or (ignore-errors
|
||||||
|
(download (cmu-bin-directory-uri version) file :interval (* 60 60))
|
||||||
|
(loop for link in (get-elements-by-tag-name (plump:parse file) "a")
|
||||||
|
for href = (plump:get-attribute link "href")
|
||||||
|
thereis (and href
|
||||||
|
(find-if (lambda (type)
|
||||||
|
(equal href (format nil "~A~A" name type)))
|
||||||
|
'(".tar.xz" ".tar.bz2")))))
|
||||||
|
".tar.bz2")))
|
||||||
|
|
||||||
(defun cmu-bin-archive-uri (version extra)
|
(defun cmu-bin-archive-uri (version extra)
|
||||||
(let ((uname (uname))
|
(format nil "~@{~A~}" (cmu-bin-directory-uri version)
|
||||||
(cmu-uname-m (cmu-uname-m)))
|
(cmu-bin-archive-name version extra) (cmu-bin-archive-type version)))
|
||||||
(format nil "~@{~A~}" (cmu-bin-uri) (if (find #\- version) "snapshots/" "release/")
|
|
||||||
(substitute #\/ #\- version) "/cmucl-" version "-" cmu-uname-m "-" uname (if extra ".extra" "") ".tar.bz2")))
|
|
||||||
|
|
||||||
(defun cmu-bin-argv-parse (argv)
|
(defun cmu-bin-argv-parse (argv)
|
||||||
(format *error-output* "~&Installing cmu-bin/~A...~%" (getf argv :version))
|
(format *error-output* "~&Installing cmu-bin/~A...~%" (getf argv :version))
|
||||||
|
|
|
||||||
95
lisp/install-dotcl-bin.lisp
Normal file
95
lisp/install-dotcl-bin.lisp
Normal file
|
|
@ -0,0 +1,95 @@
|
||||||
|
(roswell:include "util-install")
|
||||||
|
(defpackage :roswell.install.dotcl-bin
|
||||||
|
(:use :cl :roswell.install :roswell.util :roswell.locations))
|
||||||
|
(in-package :roswell.install.dotcl-bin)
|
||||||
|
|
||||||
|
(defun dotcl-bin-impl ()
|
||||||
|
(merge-pathnames (format nil "impls/~A/~A/dotcl-bin/" (uname-m) (uname)) (homedir)))
|
||||||
|
|
||||||
|
(defun dotcl-bin-rid ()
|
||||||
|
(let* ((arch (uname-m))
|
||||||
|
(os (uname))
|
||||||
|
(arch-key (cond ((equal arch "x86-64") "x64")
|
||||||
|
((equal arch "arm64") "arm64")
|
||||||
|
(t (error "dotcl-bin: unsupported arch ~A" arch))))
|
||||||
|
(os-key (cond ((equal os "linux") "linux")
|
||||||
|
((equal os "darwin") "osx")
|
||||||
|
((equal os "windows") "win")
|
||||||
|
(t (error "dotcl-bin: unsupported os ~A" os)))))
|
||||||
|
(format nil "~A-~A" os-key arch-key)))
|
||||||
|
|
||||||
|
(defvar *dotcl-bin-version-cache* nil)
|
||||||
|
|
||||||
|
(defun dotcl-bin-get-version ()
|
||||||
|
(or *dotcl-bin-version-cache*
|
||||||
|
(setf *dotcl-bin-version-cache*
|
||||||
|
(let ((file (merge-pathnames "tmp/dotcl-bin.json" (homedir))))
|
||||||
|
(format *error-output* "Checking version to install....~%")
|
||||||
|
(download "https://api.github.com/repos/dotcl/dotcl/releases" file)
|
||||||
|
(with-open-file (in file)
|
||||||
|
(loop for line = (read-line in nil nil) while line
|
||||||
|
for pos = (search "\"tag_name\"" line)
|
||||||
|
when pos
|
||||||
|
collect (let* ((q1 (position #\" line :start (+ pos 11)))
|
||||||
|
(q2 (and q1 (position #\" line :start (1+ q1)))))
|
||||||
|
(when (and q1 q2)
|
||||||
|
(let ((tag (subseq line (1+ q1) q2)))
|
||||||
|
(if (and (plusp (length tag)) (char= (aref tag 0) #\v))
|
||||||
|
(subseq tag 1)
|
||||||
|
tag))))))))))
|
||||||
|
|
||||||
|
(defun dotcl-bin-argv-parse (argv)
|
||||||
|
(set-opt "prefix" (dotcl-bin-impl))
|
||||||
|
(cons t argv))
|
||||||
|
|
||||||
|
(defun dotcl-bin-download (argv)
|
||||||
|
(let ((rid (dotcl-bin-rid))
|
||||||
|
(ver (version argv)))
|
||||||
|
(set-opt "as" ver)
|
||||||
|
(set-opt "download.uri"
|
||||||
|
(format nil "https://github.com/dotcl/dotcl/releases/download/v~A/dotcl-~A-~A.tar.bz2"
|
||||||
|
ver rid ver))
|
||||||
|
(set-opt "download.archive"
|
||||||
|
(let ((pos (position #\/ (opt "download.uri") :from-end t)))
|
||||||
|
(when pos
|
||||||
|
(merge-pathnames (format nil "archives/~A"
|
||||||
|
(subseq (opt "download.uri") (1+ pos)))
|
||||||
|
(homedir)))))
|
||||||
|
`((,(opt "download.archive") ,(opt "download.uri")))))
|
||||||
|
|
||||||
|
(defun dotcl-bin-expand (argv)
|
||||||
|
(format t "~%Extracting archive:~A~%" (opt "download.archive"))
|
||||||
|
(let ((dest (merge-pathnames (format nil "~A/" (opt "as")) (dotcl-bin-impl))))
|
||||||
|
(when (probe-file dest)
|
||||||
|
(uiop/filesystem:delete-directory-tree dest :validate t))
|
||||||
|
(ensure-directories-exist dest)
|
||||||
|
(expand (opt "download.archive") dest)
|
||||||
|
#-os-windows
|
||||||
|
(let ((apphost (merge-pathnames "runtime" dest)))
|
||||||
|
(when (probe-file apphost)
|
||||||
|
(uiop:run-program (list "chmod" "+x" (namestring apphost))
|
||||||
|
:ignore-error-status t))))
|
||||||
|
(cons t argv))
|
||||||
|
|
||||||
|
(defun dotcl-bin-script (argv)
|
||||||
|
(let* ((dotnet (which "dotnet"))
|
||||||
|
(dir (merge-pathnames (format nil "~A/" (opt "as")) (dotcl-bin-impl))))
|
||||||
|
(unless dotnet
|
||||||
|
(format *error-output* "Error: 'dotnet' (.NET SDK 10+) was not found in PATH.~%")
|
||||||
|
(format *error-output* " Install .NET SDK 10 from https://dotnet.microsoft.com/download~%")
|
||||||
|
(format *error-output* " 'ros use dotcl-bin' will fail without dotnet.~%")
|
||||||
|
(roswell:quit 1))
|
||||||
|
(install-script
|
||||||
|
(merge-pathnames "dotcl" dir)
|
||||||
|
(format nil "exec \"~Aruntime\" \"$@\"" dir))
|
||||||
|
(cons t argv)))
|
||||||
|
|
||||||
|
(defun dotcl-bin (type)
|
||||||
|
(case type
|
||||||
|
(:install `(,(decide-version 'dotcl-bin-get-version)
|
||||||
|
dotcl-bin-argv-parse
|
||||||
|
,(decide-download 'dotcl-bin-download)
|
||||||
|
dotcl-bin-expand
|
||||||
|
dotcl-bin-script
|
||||||
|
setup))
|
||||||
|
(:list 'dotcl-bin-get-version)))
|
||||||
|
|
@ -90,7 +90,7 @@
|
||||||
(homedir)))
|
(homedir)))
|
||||||
:direction :output :if-exists :append :if-does-not-exist :create)
|
:direction :output :if-exists :append :if-does-not-exist :create)
|
||||||
(format out "~&--~&~A~%" (date))
|
(format out "~&--~&~A~%" (date))
|
||||||
(let* ((cmd (format nil "make"))
|
(let* ((cmd (make))
|
||||||
(*standard-output* (make-broadcast-stream out #+sbcl(make-instance 'count-line-stream))))
|
(*standard-output* (make-broadcast-stream out #+sbcl(make-instance 'count-line-stream))))
|
||||||
(ecl-chdir argv)
|
(ecl-chdir argv)
|
||||||
(uiop/run-program:run-program cmd :output t :ignore-error-status t)))
|
(uiop/run-program:run-program cmd :output t :ignore-error-status t)))
|
||||||
|
|
@ -108,7 +108,7 @@
|
||||||
(format out "~&--~&~A~%" (date))
|
(format out "~&--~&~A~%" (date))
|
||||||
(let ((*standard-output* (make-broadcast-stream
|
(let ((*standard-output* (make-broadcast-stream
|
||||||
out #+sbcl(make-instance 'count-line-stream))))
|
out #+sbcl(make-instance 'count-line-stream))))
|
||||||
(uiop/run-program:run-program "make install" :output t)))
|
(uiop/run-program:run-program (format nil "~A install" (make)) :output t)))
|
||||||
(format *error-output* "done.~%"))
|
(format *error-output* "done.~%"))
|
||||||
(cons t argv))
|
(cons t argv))
|
||||||
|
|
||||||
|
|
@ -119,7 +119,7 @@
|
||||||
(*standard-output* (make-broadcast-stream
|
(*standard-output* (make-broadcast-stream
|
||||||
out #+sbcl(make-instance 'count-line-stream))))
|
out #+sbcl(make-instance 'count-line-stream))))
|
||||||
(uiop/run-program:run-program
|
(uiop/run-program:run-program
|
||||||
(list (sh) "-lc" (format nil "cd ~S;make clean" (namestring (uiop:getcwd))))
|
(list (sh) "-lc" (format nil "cd ~S;~A clean" (namestring (uiop:getcwd)) (make)))
|
||||||
:output t))
|
:output t))
|
||||||
(format t "done.~%")
|
(format t "done.~%")
|
||||||
(cons t argv))
|
(cons t argv))
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@
|
||||||
(defuri clisp-version-uri "http://ftp.gnu.org/pub/gnu/clisp/release/")
|
(defuri clisp-version-uri "http://ftp.gnu.org/pub/gnu/clisp/release/")
|
||||||
(defuri clisp-head-version-uri "https://github.com/roswell/clisp_head/releases/download/files/clisp_head.tsv")
|
(defuri clisp-head-version-uri "https://github.com/roswell/clisp_head/releases/download/files/clisp_head.tsv")
|
||||||
(defuri 7za-uri "http://sourceforge.net/projects/sevenzip/files/7-Zip/9.20/7za920.zip/download#")
|
(defuri 7za-uri "http://sourceforge.net/projects/sevenzip/files/7-Zip/9.20/7za920.zip/download#")
|
||||||
(defuri allegro-uri "ftp://ftp.franz.com/")
|
(defuri allegro-uri "https://franz.com/")
|
||||||
(defuri abcl-bin-uri "https://common-lisp.net/project/armedbear/releases/")
|
(defuri abcl-bin-uri "https://common-lisp.net/project/armedbear/releases/")
|
||||||
(defuri ccl-bin-uri "https://github.com/roswell/ccl_bin/releases/download/")
|
(defuri ccl-bin-uri "https://github.com/roswell/ccl_bin/releases/download/")
|
||||||
(defuri clasp-bin-uri "https://github.com/roswell/clasp_bin/releases/download/")
|
(defuri clasp-bin-uri "https://github.com/roswell/clasp_bin/releases/download/")
|
||||||
|
|
@ -28,7 +28,7 @@
|
||||||
(defuri ffcall-uri "https://github.com/roswell/libffcall/archive/")
|
(defuri ffcall-uri "https://github.com/roswell/libffcall/archive/")
|
||||||
|
|
||||||
(defuri sigsegv-uri "http://ftpmirror.gnu.org/libsigsegv/")
|
(defuri sigsegv-uri "http://ftpmirror.gnu.org/libsigsegv/")
|
||||||
(defuri msys2-uri "http://kent.dl.sourceforge.net/project/")
|
(defuri msys2-uri "https://github.com/msys2/msys2-installer/releases/download/")
|
||||||
|
|
||||||
(defuri clisp-patch1-uri "https://raw.githubusercontent.com/Homebrew/homebrew/2fb8cb1a2279f80dc89900b3ebaca9e5afc90494/Library/Formula/clisp.rb")
|
(defuri clisp-patch1-uri "https://raw.githubusercontent.com/Homebrew/homebrew/2fb8cb1a2279f80dc89900b3ebaca9e5afc90494/Library/Formula/clisp.rb")
|
||||||
|
|
||||||
|
|
@ -54,6 +54,7 @@
|
||||||
|
|
||||||
(export
|
(export
|
||||||
(defvar *allegro-agreement-uri*
|
(defvar *allegro-agreement-uri*
|
||||||
'(("10.1express" . #1="http://franz.com/ftp/pub/legal/ACL-Express-20150812.pdf")
|
'(("11.0express" . "https://franz.com/ftp/pub/legal/ACL-Express-20170301.pdf")
|
||||||
|
("10.1express" . #1="https://franz.com/ftp/pub/legal/ACL-Express-20170301.pdf")
|
||||||
("100express" . #1#)
|
("100express" . #1#)
|
||||||
("101b" . "http://franz.com/products/licensing/FSLA10.1.beta.pdf"))))
|
("101b" . "http://franz.com/products/licensing/FSLA10.1.beta.pdf"))))
|
||||||
|
|
|
||||||
|
|
@ -26,10 +26,17 @@ exec ros -Q -m roswell -N roswell -- $0 "$@"
|
||||||
;; update systems
|
;; update systems
|
||||||
(dolist (alias argv)
|
(dolist (alias argv)
|
||||||
(loop
|
(loop
|
||||||
with path = (ignore-errors
|
with path = (or
|
||||||
(make-pathname
|
(and (find #\/ alias)
|
||||||
:type nil :name nil
|
(let ((dir (merge-pathnames
|
||||||
:defaults (asdf:system-source-file (asdf:find-system alias))))
|
(format nil "local-projects/~A/" alias)
|
||||||
|
(roswell.util:homedir))))
|
||||||
|
(when (probe-file (merge-pathnames ".git/" dir))
|
||||||
|
dir)))
|
||||||
|
(ignore-errors
|
||||||
|
(make-pathname
|
||||||
|
:type nil :name nil
|
||||||
|
:defaults (asdf:system-source-file (asdf:find-system alias)))))
|
||||||
for f in *update-functions*
|
for f in *update-functions*
|
||||||
for r = (and path (funcall f path))
|
for r = (and path (funcall f path))
|
||||||
when r do (roswell:roswell `("install" ,alias))
|
when r do (roswell:roswell `("install" ,alias))
|
||||||
|
|
|
||||||
|
|
@ -174,7 +174,8 @@
|
||||||
*error-output* (make-broadcast-stream)
|
*error-output* (make-broadcast-stream)
|
||||||
*trace-output*(make-broadcast-stream)))
|
*trace-output*(make-broadcast-stream)))
|
||||||
(if (ql:where-is-system system)
|
(if (ql:where-is-system system)
|
||||||
(progn (ql:quickload system)
|
(progn (asdf:load-asd (asdf:system-source-file system))
|
||||||
|
(ql:quickload system)
|
||||||
(ignore-errors(asdf:oos 'asdf:load-op system :force t)))
|
(ignore-errors(asdf:oos 'asdf:load-op system :force t)))
|
||||||
(ql:quickload system)))
|
(ql:quickload system)))
|
||||||
(format *error-output* "~&[~a/3] Processing build-hook.." (incf step))
|
(format *error-output* "~&[~a/3] Processing build-hook.." (incf step))
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
#+ros.init
|
#+ros.init
|
||||||
(roswell:include '("util" "system") "util-template")
|
(roswell:include '("util" "system") "util-template")
|
||||||
#+quicklisp
|
#+quicklisp
|
||||||
(ql:quickload '("uiop" "djula") :silent t)
|
(ignore-errors (ql:quickload '("uiop" "djula") :silent t))
|
||||||
(defpackage :roswell.util.template
|
(defpackage :roswell.util.template
|
||||||
(:use :cl)
|
(:use :cl)
|
||||||
(:export
|
(:export
|
||||||
|
|
@ -113,7 +113,8 @@
|
||||||
:name (format nil "roswell.init.~A" template-name)))
|
:name (format nil "roswell.init.~A" template-name)))
|
||||||
|
|
||||||
(defun apply-djula (template-string stream params)
|
(defun apply-djula (template-string stream params)
|
||||||
(apply 'djula::render-template* (djula::compile-string template-string) stream
|
(apply (read-from-string "djula::render-template*")
|
||||||
|
(read-call "djula::compile-string" template-string) stream
|
||||||
`(,@params
|
`(,@params
|
||||||
:author ,(author)
|
:author ,(author)
|
||||||
:email ,(email)
|
:email ,(email)
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
(:import-from :ros :opt :ensure-asdf :*local-project-directories*)
|
(:import-from :ros :opt :ensure-asdf :*local-project-directories*)
|
||||||
(:export
|
(:export
|
||||||
:uname :uname-m :homedir :config :impl :which :config-env :checkoutdir
|
:uname :uname-m :homedir :config :impl :which :config-env :checkoutdir
|
||||||
:parse-version-spec :head :download :expand :sh :chdir :system :module
|
:parse-version-spec :head :download :expand :sh :make :chdir :system :module
|
||||||
:core-extention :clone-github :opt :read-call :set-opt :copy-dir
|
:core-extention :clone-github :opt :read-call :set-opt :copy-dir
|
||||||
:roswell-installable-searcher :setenv :unsetenv :ensure-asdf :split-sequence
|
:roswell-installable-searcher :setenv :unsetenv :ensure-asdf :split-sequence
|
||||||
:local-project-build-hash))
|
:local-project-build-hash))
|
||||||
|
|
@ -196,6 +196,9 @@ Example:
|
||||||
(which "bash")
|
(which "bash")
|
||||||
"sh"))
|
"sh"))
|
||||||
|
|
||||||
|
(defun make ()
|
||||||
|
(or #+freebsd "gmake" "make"))
|
||||||
|
|
||||||
(defvar *version*
|
(defvar *version*
|
||||||
`(:roswell ,(or (ignore-errors (roswell:version))
|
`(:roswell ,(or (ignore-errors (roswell:version))
|
||||||
(progn
|
(progn
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
(defsystem "roswell"
|
(defsystem "roswell"
|
||||||
:version "22.12.14.112"
|
:version "26.2.116"
|
||||||
:author "SANO Masatoshi"
|
:author "SANO Masatoshi"
|
||||||
:license "MIT"
|
:license "MIT"
|
||||||
:depends-on ("simple-date-time" "split-sequence" "plump" "zip")
|
:depends-on ("simple-date-time" "split-sequence" "plump" "zip")
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
FROM alpine:3.13
|
FROM alpine:3.20
|
||||||
run apk add --no-cache \
|
run apk add --no-cache \
|
||||||
alpine-sdk automake autoconf curl-dev bash linux-headers \
|
alpine-sdk automake autoconf curl-dev bash linux-headers \
|
||||||
curl-static nghttp2-static openssl-libs-static brotli-static zlib-static; \
|
curl-static nghttp2-static openssl-libs-static brotli-static zlib-static zstd-static c-ares-static \
|
||||||
cd /tmp/roswell;./bootstrap;./configure --with-sbcl-bin-variant='-musl';make; make install; \
|
libidn2-static libunistring-static libpsl-static;
|
||||||
ros install sbcl-bin/2.0.5; \
|
|
||||||
rm -rf /tmp/roswell
|
|
||||||
|
|
|
||||||
|
|
@ -1 +1 @@
|
||||||
roswell-musl:64
|
roswell-musl:24.10
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,12 @@
|
||||||
-include .env
|
-include .env
|
||||||
export $(shell sed 's/=.*//' .env)
|
export $(shell sed 's/=.*//' .env)
|
||||||
|
|
||||||
|
DOCKER_REPO ?= docker.pkg.github.com/roswell/roswell
|
||||||
|
DOCKER_PLATFORM ?= linux/amd64
|
||||||
|
DOCKER_BUILD_OPTIONS ?=
|
||||||
|
DOCKER_IMAGE_SUFFIX ?=
|
||||||
|
IMAGE ?=
|
||||||
|
|
||||||
all:
|
all:
|
||||||
echo all
|
echo all
|
||||||
|
|
||||||
|
|
@ -16,20 +22,27 @@ show:
|
||||||
@echo VERSION=$(VERSION) VARIANT=$(VARIANT)
|
@echo VERSION=$(VERSION) VARIANT=$(VARIANT)
|
||||||
|
|
||||||
build-docker:
|
build-docker:
|
||||||
docker build -t docker.pkg.github.com/roswell/roswell/$$(cat ./scripts/Docker/$(IMAGE)/Name) ./scripts/Docker/$(IMAGE)
|
docker build \
|
||||||
|
--platform $(DOCKER_PLATFORM) \
|
||||||
|
-t $(DOCKER_REPO)/$$(cat ./scripts/Docker/$(IMAGE)/Name)$(DOCKER_IMAGE_SUFFIX) \
|
||||||
|
$(DOCKER_BUILD_OPTIONS) \
|
||||||
|
./scripts/Docker/$(IMAGE)
|
||||||
push-docker:
|
push-docker:
|
||||||
docker push docker.pkg.github.com/roswell/roswell/$$(cat ./scripts/Docker/$(IMAGE)/Name);
|
docker push $(DOCKER_REPO)/$$(cat ./scripts/Docker/$(IMAGE)/Name)$(DOCKER_IMAGE_SUFFIX);
|
||||||
pull-docker:
|
pull-docker:
|
||||||
docker pull docker.pkg.github.com/roswell/roswell/$$(cat ./scripts/Docker/$(IMAGE)/Name);
|
docker pull $(DOCKER_REPO)/$$(cat ./scripts/Docker/$(IMAGE)/Name)$(DOCKER_IMAGE_SUFFIX);
|
||||||
docker:
|
docker:
|
||||||
docker run \
|
docker run \
|
||||||
|
--rm \
|
||||||
|
--platform $(DOCKER_PLATFORM) \
|
||||||
-v `pwd`:/tmp2 \
|
-v `pwd`:/tmp2 \
|
||||||
-e ARCH=$(ARCH) \
|
-e ARCH=$(ARCH) \
|
||||||
-e VERSION=$(VERSION) \
|
-e VERSION=$(VERSION) \
|
||||||
|
-e SUFFIX=$(SUFFIX) \
|
||||||
-e CFLAGS=$(CFLAGS) \
|
-e CFLAGS=$(CFLAGS) \
|
||||||
-e LINKFLAGS=$(LINKFLAGS) \
|
-e LINKFLAGS=$(LINKFLAGS) \
|
||||||
-e VARIANT=$(VARIANT) \
|
-e VARIANT=$(VARIANT) \
|
||||||
docker.pkg.github.com/roswell/roswell/$$(cat ./scripts/Docker/$(IMAGE)/Name) \
|
$(DOCKER_REPO)/$$(cat ./scripts/Docker/$(IMAGE)/Name)$(DOCKER_IMAGE_SUFFIX) \
|
||||||
bash \
|
bash \
|
||||||
-c "cd /tmp2;make -f scripts/Makefile $(MAKEOPTS)"
|
-c "cd /tmp2;make -f scripts/Makefile $(MAKEOPTS)"
|
||||||
upload:
|
upload:
|
||||||
|
|
@ -41,7 +54,7 @@ musl:
|
||||||
./bootstrap
|
./bootstrap
|
||||||
./configure --enable-maintainer-mode --with-sbcl-bin-variant=$(VARIANT) \
|
./configure --enable-maintainer-mode --with-sbcl-bin-variant=$(VARIANT) \
|
||||||
LDFLAGS="--static -static-libgcc -static-libstdc++ -static" \
|
LDFLAGS="--static -static-libgcc -static-libstdc++ -static" \
|
||||||
LIBS="-lcurl -lbrotlidec-static -lbrotlicommon-static -lnghttp2 -lssl -lcrypto -lz"
|
LIBS="-lcurl -lbrotlidec -lbrotlicommon -lnghttp2 -lssl -lcrypto -lz -lzstd -lcares -lidn2 -lunistring -lpsl"
|
||||||
make
|
make
|
||||||
make pack
|
make pack
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
ROSWELL_RELEASE_VERSION=21.10.14.111
|
ROSWELL_RELEASE_VERSION=26.02.116
|
||||||
ROSWELL_TARBALL_PATH=$HOME/roswell.tar.gz
|
ROSWELL_TARBALL_PATH=$HOME/roswell.tar.gz
|
||||||
ROSWELL_DIR=$HOME/.roswell
|
ROSWELL_DIR=$HOME/.roswell
|
||||||
ROSWELL_REPO=${ROSWELL_REPO:-https://github.com/roswell/roswell}
|
ROSWELL_REPO=${ROSWELL_REPO:-https://github.com/roswell/roswell}
|
||||||
|
|
@ -33,10 +33,16 @@ log () {
|
||||||
|
|
||||||
fetch () {
|
fetch () {
|
||||||
echo "Downloading $1..."
|
echo "Downloading $1..."
|
||||||
if curl --no-progress-bar --retry 10 -o $2 -L $1; then
|
if curl --no-progress-bar --retry 10 --connect-timeout 30 \
|
||||||
return 0;
|
--max-time 300 -o "$2" -L "$1" 2>&1; then
|
||||||
|
echo "✓ Successfully downloaded $1"
|
||||||
|
return 0
|
||||||
else
|
else
|
||||||
echo "Failed to download $1."
|
code=$? # capture curl's exit code immediately
|
||||||
|
echo "✗ Failed to download $1"
|
||||||
|
echo " URL: $1"
|
||||||
|
echo " Destination: $2"
|
||||||
|
echo " Curl exit code: $code"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
@ -159,7 +165,7 @@ install_roswell_bin () {
|
||||||
GNUMAKE=/usr/local/bin/gmake
|
GNUMAKE=/usr/local/bin/gmake
|
||||||
apt_unless_installed roswell
|
apt_unless_installed roswell
|
||||||
elif [ `uname` = "Darwin" ] && [ $ROSWELL_BRANCH = release ]; then
|
elif [ `uname` = "Darwin" ] && [ $ROSWELL_BRANCH = release ]; then
|
||||||
apt_unless_installed roswell
|
brew upgrade roswell 2>/dev/null || brew install roswell
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
@ -202,8 +208,6 @@ install_sbcl_bin () {
|
||||||
install_lisp_dependency () {
|
install_lisp_dependency () {
|
||||||
case "$USE_LISP" in
|
case "$USE_LISP" in
|
||||||
alisp|allegro)
|
alisp|allegro)
|
||||||
apt_unless_installed libc6-i386
|
|
||||||
apt_unless_installed gcc-multilib
|
|
||||||
USE_LISP=allegro
|
USE_LISP=allegro
|
||||||
;;
|
;;
|
||||||
cmu|cmucl|cmu-bin)
|
cmu|cmucl|cmu-bin)
|
||||||
|
|
@ -221,6 +225,13 @@ install_lisp_dependency () {
|
||||||
apt_unless_installed gcc-multilib
|
apt_unless_installed gcc-multilib
|
||||||
ros config set ccl.bit 32
|
ros config set ccl.bit 32
|
||||||
;;
|
;;
|
||||||
|
sbcl/*)
|
||||||
|
if [ "$(uname)" = "Darwin" ]; then
|
||||||
|
brew install zstd 2>/dev/null || true
|
||||||
|
else
|
||||||
|
apt_unless_installed libzstd-dev
|
||||||
|
fi
|
||||||
|
;;
|
||||||
# 'sbcl-bin' is the default
|
# 'sbcl-bin' is the default
|
||||||
"")
|
"")
|
||||||
USE_LISP=sbcl-bin
|
USE_LISP=sbcl-bin
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,7 @@ exec ros -Q -L sbcl-bin -- $0 "$@"
|
||||||
(d (multiple-value-list(decode-universal-time (get-universal-time)))))
|
(d (multiple-value-list(decode-universal-time (get-universal-time)))))
|
||||||
(setf (first version) (- (nth 5 d) 2000)
|
(setf (first version) (- (nth 5 d) 2000)
|
||||||
(second version) (nth 4 d)
|
(second version) (nth 4 d)
|
||||||
(fourth version) (1+ (fourth version)))
|
(first (last version)) (1+ (first (last version))))
|
||||||
(format nil "~{~2,'0d~^.~}" version)))
|
(format nil "~{~2,'0d~^.~}" version)))
|
||||||
|
|
||||||
(defun edit-file (path match replace version &key test)
|
(defun edit-file (path match replace version &key test)
|
||||||
|
|
@ -119,7 +119,7 @@ exec ros -Q -L sbcl-bin -- $0 "$@"
|
||||||
`("To release"
|
`("To release"
|
||||||
"1. Review changes and complete ChangeLog"
|
"1. Review changes and complete ChangeLog"
|
||||||
"2. Type"
|
"2. Type"
|
||||||
"make release")))
|
"make release-commit")))
|
||||||
|
|
||||||
(defun prepare (argv)
|
(defun prepare (argv)
|
||||||
(declare (ignore argv))
|
(declare (ignore argv))
|
||||||
|
|
@ -139,7 +139,7 @@ exec ros -Q -L sbcl-bin -- $0 "$@"
|
||||||
(edit-roswell-asd)
|
(edit-roswell-asd)
|
||||||
(show-how-to-release))
|
(show-how-to-release))
|
||||||
|
|
||||||
(defun release (argv)
|
(defun release-commit (argv)
|
||||||
(declare (ignore argv))
|
(declare (ignore argv))
|
||||||
(!"git checkout master")
|
(!"git checkout master")
|
||||||
(!"git add ChangeLog configure.ac roswell.asd")
|
(!"git add ChangeLog configure.ac roswell.asd")
|
||||||
|
|
@ -179,7 +179,7 @@ exec ros -Q -L sbcl-bin -- $0 "$@"
|
||||||
|
|
||||||
(defun main (subcmd &rest argv)
|
(defun main (subcmd &rest argv)
|
||||||
(declare (ignorable argv))
|
(declare (ignorable argv))
|
||||||
(let ((subcmd (find subcmd '(prepare release release-push changelog release-ci)
|
(let ((subcmd (find subcmd '(prepare release-commit release-push changelog release-ci)
|
||||||
:test 'equal :key 'string-downcase)))
|
:test 'equal :key 'string-downcase)))
|
||||||
(when subcmd
|
(when subcmd
|
||||||
(funcall subcmd argv))))
|
(funcall subcmd argv))))
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@ ros_SOURCES = main.c opt.c download.c download_windows.c archive.c archive_windo
|
||||||
cmd-internal.c cmd-script.c \
|
cmd-internal.c cmd-script.c \
|
||||||
cmd-run.c cmd-run-sbcl.c cmd-run-ccl.c cmd-run-clasp.c cmd-run-clisp.c cmd-run-ecl.c \
|
cmd-run.c cmd-run-sbcl.c cmd-run-ccl.c cmd-run-clasp.c cmd-run-clisp.c cmd-run-ecl.c \
|
||||||
cmd-run-mkcl.c cmd-run-abcl.c cmd-run-cmu.c cmd-run-acl.c cmd-run-lispworks.c \
|
cmd-run-mkcl.c cmd-run-abcl.c cmd-run-cmu.c cmd-run-acl.c cmd-run-lispworks.c \
|
||||||
cmd-run-npt.c \
|
cmd-run-npt.c cmd-run-dotcl.c \
|
||||||
cmd-install.c install-sbcl-bin.c install-sbcl-bin_windows.c
|
cmd-install.c install-sbcl-bin.c install-sbcl-bin_windows.c
|
||||||
|
|
||||||
if WITH_WIN_ICON
|
if WITH_WIN_ICON
|
||||||
|
|
|
||||||
45
src/cmd-run-dotcl.c
Normal file
45
src/cmd-run-dotcl.c
Normal file
|
|
@ -0,0 +1,45 @@
|
||||||
|
#include "opt.h"
|
||||||
|
|
||||||
|
char** cmd_run_dotcl(int argc,char** argv,struct sub_command* cmd) {
|
||||||
|
char* home=configdir();
|
||||||
|
char* arch=uname_m();
|
||||||
|
char* os=uname_s();
|
||||||
|
char* impl=(char*)cmd->name;
|
||||||
|
char* version=(char*)cmd->short_name;
|
||||||
|
/*[apphost binary] --eval init.lisp --eval (ros:run '(...)) [repl] */
|
||||||
|
int i;
|
||||||
|
char* impl_path=impldir(arch,os,impl, version);
|
||||||
|
char* help=get_opt("help",0);
|
||||||
|
char* script=get_opt("script",0);
|
||||||
|
char* program=get_opt("program",0);
|
||||||
|
char* dotcl_version=get_opt("version",0);
|
||||||
|
LVal ret=0;
|
||||||
|
|
||||||
|
s(arch),s(os);
|
||||||
|
|
||||||
|
ret=conss(cat(home,impl_path,DIRSEP,"runtime",EXE_EXTENTION,NULL),ret);
|
||||||
|
|
||||||
|
if(dotcl_version) {
|
||||||
|
ret=conss(q("--eval"),ret);
|
||||||
|
ret=conss(q("(progn (format t \"~A ~A~%\" (lisp-implementation-type) (lisp-implementation-version)) (dotcl:quit))"),ret);
|
||||||
|
}
|
||||||
|
ret=conss(q("--eval"),ret);
|
||||||
|
ret=conss(s_cat(q("(progn #-ros.init(cl:load \""),s_escape_string(lispdir()),q("init.lisp"),q("\"))"),NULL),ret);
|
||||||
|
ret=conss(q("--eval"),ret);
|
||||||
|
ret=conss(s_cat(q("(ros:run '("),q(program?program:""),
|
||||||
|
script?cat("(:script ",script,")","(:quit ())",NULL):q(""),
|
||||||
|
q("))"),NULL),ret);
|
||||||
|
|
||||||
|
/* dotcl exits after --eval/--load by default; for interactive (no script)
|
||||||
|
append the `repl` subcommand to keep the process alive. */
|
||||||
|
if(!script) {
|
||||||
|
ret=conss(q("repl"),ret);
|
||||||
|
}
|
||||||
|
|
||||||
|
for(i=1;i<argc;++i)
|
||||||
|
ret=conss(q(argv[i]),ret);
|
||||||
|
|
||||||
|
s(impl_path);
|
||||||
|
cond_printf(1,"\nhelp=%s script=%s\n",help?"t":"nil",script?script:"nil");
|
||||||
|
return stringlist_array(nreverse(ret));
|
||||||
|
}
|
||||||
|
|
@ -26,6 +26,8 @@ struct run_impl_t impls_to_run[]={
|
||||||
{"lispworks",&cmd_run_lispworks},
|
{"lispworks",&cmd_run_lispworks},
|
||||||
{"mkcl",&cmd_run_mkcl},
|
{"mkcl",&cmd_run_mkcl},
|
||||||
{"npt",&cmd_run_npt},
|
{"npt",&cmd_run_npt},
|
||||||
|
{"dotcl",&cmd_run_dotcl},
|
||||||
|
{"dotcl-bin",&cmd_run_dotcl},
|
||||||
};
|
};
|
||||||
|
|
||||||
struct proc_opt run;
|
struct proc_opt run;
|
||||||
|
|
@ -193,6 +195,10 @@ char** determin_args(int argc,char **argv) {
|
||||||
int i=position_char("/",_);
|
int i=position_char("/",_);
|
||||||
cmd.name=subseq(_,0,i);
|
cmd.name=subseq(_,0,i);
|
||||||
cmd.short_name=subseq(_,i+1,0);
|
cmd.short_name=subseq(_,i+1,0);
|
||||||
|
if(cmd.short_name==NULL) {
|
||||||
|
cond_printf(0,"%s does not exist.stop.\n", _);
|
||||||
|
exit(EXIT_FAILURE);
|
||||||
|
}
|
||||||
for(i=0;i<sizeof(impls_to_run)/sizeof(struct run_impl_t);++i)
|
for(i=0;i<sizeof(impls_to_run)/sizeof(struct run_impl_t);++i)
|
||||||
if(strcmp(impls_to_run[i].name,cmd.name)==0) {
|
if(strcmp(impls_to_run[i].name,cmd.name)==0) {
|
||||||
arg=impls_to_run[i].impl(argc,argv,&cmd);
|
arg=impls_to_run[i].impl(argc,argv,&cmd);
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,8 @@ extern char** cmd_run_acl(int argc,char** argv,struct sub_command* cmd);
|
||||||
extern char** cmd_run_lispworks(int argc,char** argv,struct sub_command* cmd);
|
extern char** cmd_run_lispworks(int argc,char** argv,struct sub_command* cmd);
|
||||||
extern char** cmd_run_mkcl(int argc,char** argv,struct sub_command* cmd);
|
extern char** cmd_run_mkcl(int argc,char** argv,struct sub_command* cmd);
|
||||||
extern char** cmd_run_npt(int argc,char** argv,struct sub_command* cmd);
|
extern char** cmd_run_npt(int argc,char** argv,struct sub_command* cmd);
|
||||||
extern LVal register_runtime_options();
|
extern char** cmd_run_dotcl(int argc,char** argv,struct sub_command* cmd);
|
||||||
|
extern struct proc_opt* register_runtime_options(struct proc_opt* cmd);
|
||||||
int setup(char* target,char* env,char* impl);
|
int setup(char* target,char* env,char* impl);
|
||||||
#define SETUP_SYSTEM(sys,msg) {\
|
#define SETUP_SYSTEM(sys,msg) {\
|
||||||
cond_printf(0,"%s",msg); \
|
cond_printf(0,"%s",msg); \
|
||||||
|
|
|
||||||
|
|
@ -75,6 +75,7 @@ static size_t header_callback(char *buffer, size_t size,size_t nitems, int *opt)
|
||||||
int download_simple (char* uri,char* path,int opt) {
|
int download_simple (char* uri,char* path,int opt) {
|
||||||
FILE *bodyfile;
|
FILE *bodyfile;
|
||||||
char* path_partial=cat(path,".partial",NULL);
|
char* path_partial=cat(path,".partial",NULL);
|
||||||
|
cond_printf(1,"download_simple(\"%s\",\"%s\",%d)\n",uri,path,opt);
|
||||||
bodyfile = fopen(path_partial,"wb");
|
bodyfile = fopen(path_partial,"wb");
|
||||||
if(bodyfile == NULL) {
|
if(bodyfile == NULL) {
|
||||||
s(path_partial);
|
s(path_partial);
|
||||||
|
|
@ -121,7 +122,9 @@ int download_simple (char* uri,char* path,int opt) {
|
||||||
curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1L);
|
curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1L);
|
||||||
curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, write_data);
|
curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, write_data);
|
||||||
curl_easy_setopt(curl, CURLOPT_HEADERFUNCTION, header_callback);
|
curl_easy_setopt(curl, CURLOPT_HEADERFUNCTION, header_callback);
|
||||||
curl_easy_setopt(curl,CURLOPT_WRITEDATA,bodyfile);
|
curl_easy_setopt(curl, CURLOPT_WRITEDATA,bodyfile);
|
||||||
|
if((verbose & 2) != 0)
|
||||||
|
curl_easy_setopt(curl, CURLOPT_VERBOSE, 1L);
|
||||||
if(ignoressl) {
|
if(ignoressl) {
|
||||||
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYPEER, 0);
|
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYPEER, 0);
|
||||||
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYHOST, 0);
|
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYHOST, 0);
|
||||||
|
|
|
||||||
|
|
@ -158,12 +158,50 @@ int sbcl_bin_install(struct install_options* param) {
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef __linux__
|
||||||
|
int sbcl_bin_patchelf(struct install_options* param) {
|
||||||
|
char* home=configdir();
|
||||||
|
char* src=param->expand_path;
|
||||||
|
char* roswell_path=which(argv_orig[0]); /* which ros */
|
||||||
|
int patchelf_available;
|
||||||
|
int ret;
|
||||||
|
char* impl=param->impl;
|
||||||
|
char* version=param->version;
|
||||||
|
char* impl_path= cat(home,impldir(param->arch,param->os,impl,version),NULL);
|
||||||
|
char* patchelf_cmd=which("patchelf");
|
||||||
|
char* result;
|
||||||
|
char* ros;
|
||||||
|
patchelf_available=strlen(patchelf_cmd)?1:0;
|
||||||
|
s(patchelf_cmd);
|
||||||
|
if(!patchelf_available) {
|
||||||
|
fprintf(stderr,"'patchelf' not detected.no patching for sbcl\n");
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
patchelf_cmd=cat("patchelf --print-interpreter ",roswell_path,NULL);
|
||||||
|
result=system_(patchelf_cmd);
|
||||||
|
ros=remove_char("\r\n",result);
|
||||||
|
s(patchelf_cmd),s(result),s(roswell_path);
|
||||||
|
cond_printf(1,"roswell's interpreter is '%s'...\n",ros);
|
||||||
|
patchelf_cmd=cat("patchelf --set-interpreter ",ros," ",impl_path,"/bin/sbcl ",NULL);
|
||||||
|
ret=System(patchelf_cmd);
|
||||||
|
s(patchelf_cmd),s(impl_path),s(home),s(ros);
|
||||||
|
if(ret!=0) {
|
||||||
|
fprintf(stderr,"'patchelf' for sbcl failed.\n");
|
||||||
|
}
|
||||||
|
cond_printf(0,"patchelf sbcl Done.");
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
install_cmds install_sbcl_bin_full[]={
|
install_cmds install_sbcl_bin_full[]={
|
||||||
sbcl_version_bin,
|
sbcl_version_bin,
|
||||||
start,
|
start,
|
||||||
sbcl_bin_download,
|
sbcl_bin_download,
|
||||||
sbcl_bin_expand,
|
sbcl_bin_expand,
|
||||||
sbcl_bin_install,
|
sbcl_bin_install,
|
||||||
|
#ifdef __linux__
|
||||||
|
sbcl_bin_patchelf,
|
||||||
|
#endif
|
||||||
NULL
|
NULL
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -10,8 +10,12 @@ char* homedir(void) {
|
||||||
}
|
}
|
||||||
|
|
||||||
char* truename(const char* path) {
|
char* truename(const char* path) {
|
||||||
char* ret=realpath(path,NULL);
|
char* buf=alloc(PATH_MAX);
|
||||||
return ret?ret:which((char*)path);
|
char* ret=realpath(path,buf);
|
||||||
|
if(ret)
|
||||||
|
return buf;
|
||||||
|
s(buf);
|
||||||
|
return which((char*)path);
|
||||||
}
|
}
|
||||||
|
|
||||||
int ensure_directories_exist(char* path) {
|
int ensure_directories_exist(char* path) {
|
||||||
|
|
@ -71,9 +75,15 @@ char* currentdir(void) {
|
||||||
return append_trail_slash(q_(getcwd(buf,2048)));
|
return append_trail_slash(q_(getcwd(buf,2048)));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int is_valid_path(const char *path) {
|
||||||
|
return path[0] == '/';
|
||||||
|
}
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
char* homedir(void);
|
char* homedir(void);
|
||||||
char* currentdir(void);
|
char* currentdir(void);
|
||||||
|
int is_valid_path(const char *);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
char* configdir(void) {
|
char* configdir(void) {
|
||||||
|
|
@ -82,9 +92,10 @@ char* configdir(void) {
|
||||||
|
|
||||||
if (env) /* note: env can be a NULL */
|
if (env) /* note: env can be a NULL */
|
||||||
{
|
{
|
||||||
if (env[0] != DIRSEP[0]) /* note: DIRSEP == \\ on windows, / on unix */
|
if (!is_valid_path(env))
|
||||||
{
|
{
|
||||||
cond_printf(0,"Error: %s must be absolute. Got: %s \n",c,env);
|
cond_printf(0,"Error: %s must be absolute. Got: %s \n",c,env);
|
||||||
|
abort();
|
||||||
}
|
}
|
||||||
s(c); /* note : this frees c. */
|
s(c); /* note : this frees c. */
|
||||||
return append_trail_slash(q(env));
|
return append_trail_slash(q(env));
|
||||||
|
|
@ -143,3 +154,4 @@ char* basedir(void) {
|
||||||
s(cd_);
|
s(cd_);
|
||||||
return configdir();
|
return configdir();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -64,4 +64,21 @@ char* currentdir(void) {
|
||||||
char buf[2048];
|
char buf[2048];
|
||||||
return append_trail_slash(q_(_getcwd(buf,2048)));
|
return append_trail_slash(q_(_getcwd(buf,2048)));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int is_valid_path(const char *path) {
|
||||||
|
//
|
||||||
|
// On Windows, an absolute path can technically
|
||||||
|
// start with a drive letter (i.e. c:\roswell),
|
||||||
|
// but could also be a UNC path (i.e. \\OTHERMACHINE\roswell).
|
||||||
|
//
|
||||||
|
// But, if invoked inside an msys2 shell we could get a UNIX-style path.
|
||||||
|
//
|
||||||
|
// It appears however that the latter two scenarios are not supported
|
||||||
|
// by other parts of the codebase, so we shall enforce here that only
|
||||||
|
// regular Windows-style paths are allowed.
|
||||||
|
//
|
||||||
|
|
||||||
|
return (isalpha(path[0]) && path[1] == ':' && (path[2] == '\\' || path[2] == '/'));
|
||||||
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
45
src/util.c
45
src/util.c
|
|
@ -9,14 +9,42 @@ char* uname_s(void) {
|
||||||
s(p2);
|
s(p2);
|
||||||
return q("solaris");
|
return q("solaris");
|
||||||
}
|
}
|
||||||
|
if(strcmp(p2,"Linux")==0 &&
|
||||||
|
strcmp(UNAME_M,"aarch64") ==0) {
|
||||||
|
char* result=system_("uname -o");
|
||||||
|
char* result2=remove_char("\r\n",result);
|
||||||
|
s(result);
|
||||||
|
if(strcmp(result2,"Android")==0) {
|
||||||
|
s(result2),s(p2);
|
||||||
|
/* termux? */
|
||||||
|
return q("android");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(strcmp(p2,"DragonFly")==0) {
|
||||||
|
s(p2);
|
||||||
|
return q("DFlyBSD");
|
||||||
|
}
|
||||||
return downcase(p2);
|
return downcase(p2);
|
||||||
}
|
}
|
||||||
|
|
||||||
char* uname_m(void) {
|
char* uname_m(void) {
|
||||||
char *p2=q(UNAME_M);
|
char *p2=q(UNAME_M);
|
||||||
if(strcmp(p2,"i86pc")==0) {
|
if(strlen(FIXED_ARCH) !=0) {
|
||||||
s(p2);
|
s(p2);
|
||||||
return q("x86-64");
|
return q(FIXED_ARCH);
|
||||||
|
}
|
||||||
|
if(strcmp(p2,"i86pc")==0) {
|
||||||
|
/* solaris */
|
||||||
|
s(p2);
|
||||||
|
char* result=system_("isainfo -k");
|
||||||
|
char* result2=remove_char("\r\n",result);
|
||||||
|
s(result);
|
||||||
|
if(strcmp(result2,"amd64")==0) {
|
||||||
|
s(result2);
|
||||||
|
return q("x86-64");
|
||||||
|
}
|
||||||
|
s(result2);
|
||||||
|
return q("x86");
|
||||||
}
|
}
|
||||||
if(strcmp(p2,"i686")==0) {
|
if(strcmp(p2,"i686")==0) {
|
||||||
s(p2);
|
s(p2);
|
||||||
|
|
@ -30,12 +58,19 @@ char* uname_m(void) {
|
||||||
s(p2);
|
s(p2);
|
||||||
return q("x86-64");
|
return q("x86-64");
|
||||||
}
|
}
|
||||||
|
if(strcmp(p2,"evbarm")==0 ) {
|
||||||
|
/*netbsd arm*/
|
||||||
|
char* result=system_("uname -p");
|
||||||
|
s(p2);
|
||||||
|
p2=remove_char("\r\n",result);
|
||||||
|
}
|
||||||
if(strcmp(p2,"aarch64")==0) {
|
if(strcmp(p2,"aarch64")==0) {
|
||||||
s(p2);
|
s(p2);
|
||||||
return q("arm64");
|
return q("arm64");
|
||||||
}
|
}
|
||||||
if(strcmp(p2,"armv6l")==0 ||
|
if(strcmp(p2,"armv6l")==0 ||
|
||||||
strcmp(p2,"armv7l")==0) {
|
strcmp(p2,"armv7l")==0 ||
|
||||||
|
strcmp(p2,"armv8l")==0) {
|
||||||
char* result=system_("readelf -A /proc/self/exe |grep Tag_ABI_VFP_args|wc -l");
|
char* result=system_("readelf -A /proc/self/exe |grep Tag_ABI_VFP_args|wc -l");
|
||||||
char* result2=remove_char("\r\n",result);
|
char* result2=remove_char("\r\n",result);
|
||||||
s(result);
|
s(result);
|
||||||
|
|
@ -51,6 +86,10 @@ char* uname_m(void) {
|
||||||
s(p2);
|
s(p2);
|
||||||
return q("armel");
|
return q("armel");
|
||||||
}
|
}
|
||||||
|
if(strcmp(p2,"Power Macintosh")==0) {
|
||||||
|
s(p2);
|
||||||
|
return q("ppc");
|
||||||
|
}
|
||||||
return substitute_char('-','_',p2);
|
return substitute_char('-','_',p2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -13,6 +13,7 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#ifndef HAVE_WINDOWS_H
|
#ifndef HAVE_WINDOWS_H
|
||||||
|
#include <ctype.h>
|
||||||
#include <pwd.h>
|
#include <pwd.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <grp.h>
|
#include <grp.h>
|
||||||
|
|
@ -142,6 +143,7 @@ int directory_exist_p (char* path);
|
||||||
int change_directory(const char* path);
|
int change_directory(const char* path);
|
||||||
int delete_directory(char* pathspec,int recursive);
|
int delete_directory(char* pathspec,int recursive);
|
||||||
char* impldir(char* arch,char* os,char* impl,char* version);
|
char* impldir(char* arch,char* os,char* impl,char* version);
|
||||||
|
int is_valid_path(const char *path);
|
||||||
/*util_file.c */
|
/*util_file.c */
|
||||||
int delete_file(char* pathspec);
|
int delete_file(char* pathspec);
|
||||||
int rename_file(char* file,char* new_name);
|
int rename_file(char* file,char* new_name);
|
||||||
|
|
|
||||||
|
|
@ -23,12 +23,18 @@ char* uname_m(void) {
|
||||||
return q("x86-64");
|
return q("x86-64");
|
||||||
if(carch && strcmp(carch,"i686")==0)
|
if(carch && strcmp(carch,"i686")==0)
|
||||||
return q("x86");
|
return q("x86");
|
||||||
|
if(carch && strcmp(carch,"aarch64")==0)
|
||||||
|
return q("arm64");
|
||||||
char* msystem=getenv("MSYSTEM");
|
char* msystem=getenv("MSYSTEM");
|
||||||
if(msystem && strcmp(msystem,"MINGW64")==0)
|
if(msystem && strcmp(msystem,"MINGW64")==0)
|
||||||
return q("x86-64");
|
return q("x86-64");
|
||||||
if(msystem && strcmp(msystem,"MINGW32")==0)
|
if(msystem && strcmp(msystem,"MINGW32")==0)
|
||||||
return q("x86");
|
return q("x86");
|
||||||
#if defined(_WIN64)
|
if(msystem && strcmp(msystem,"CLANGARM64")==0)
|
||||||
|
return q("arm64");
|
||||||
|
#if defined(__aarch64__)
|
||||||
|
return q("arm64");
|
||||||
|
#elif defined(_WIN64)
|
||||||
return q("x86-64");
|
return q("x86-64");
|
||||||
#elif defined(_WIN32)
|
#elif defined(_WIN32)
|
||||||
BOOL isWow64 = FALSE;
|
BOOL isWow64 = FALSE;
|
||||||
|
|
|
||||||
|
|
@ -86,7 +86,7 @@
|
||||||
(! "ros list")
|
(! "ros list")
|
||||||
(! "ros list installed")
|
(! "ros list installed")
|
||||||
(! "ros list dump")
|
(! "ros list dump")
|
||||||
(! "ros swank install")
|
(! "ros install slime")
|
||||||
(! (format nil "ros help install ~A" (ros:opt "default.lisp")))
|
(! (format nil "ros help install ~A" (ros:opt "default.lisp")))
|
||||||
|
|
||||||
#+sbcl
|
#+sbcl
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue