Raymond Toy pushed to branch issue-373-handle-temp-files at cmucl / cmucl
Commits:
-
ef48eb2a
by Carl Shapiro at 2025-02-18T22:46:55-08:00
-
6c8861a0
by Raymond Toy at 2025-02-20T13:55:13+00:00
-
5b452f9a
by Raymond Toy at 2025-02-20T13:55:13+00:00
-
a6846d44
by Raymond Toy at 2025-02-21T03:13:50+00:00
-
f21c6507
by Raymond Toy at 2025-02-21T03:13:51+00:00
-
f370206e
by Raymond Toy at 2025-02-21T13:25:03+00:00
-
8ea8e2a0
by Raymond Toy at 2025-02-21T13:25:03+00:00
-
576f422e
by Raymond Toy at 2025-02-21T05:42:51-08:00
-
cb65bb7e
by Raymond Toy at 2025-02-21T05:52:50-08:00
-
490b48a3
by Raymond Toy at 2025-02-24T04:03:16+00:00
-
c0b4f40a
by Raymond Toy at 2025-02-24T04:03:16+00:00
-
bf0a4435
by Raymond Toy at 2025-02-27T22:21:25+00:00
-
8335d636
by Raymond Toy at 2025-02-27T22:21:25+00:00
-
d5c2ab6a
by Raymond Toy at 2025-03-02T06:05:53-08:00
-
de2abad2
by Raymond Toy at 2025-03-25T14:10:15+00:00
-
7aaca65e
by Raymond Toy at 2025-03-25T14:10:15+00:00
-
7e2d05db
by Raymond Toy at 2025-03-30T21:16:32+00:00
-
fea9f546
by Raymond Toy at 2025-03-30T21:16:32+00:00
-
e90fa5af
by Raymond Toy at 2025-03-30T20:10:38-07:00
-
78cb9dbd
by Raymond Toy at 2025-05-09T06:55:39-07:00
-
3e8a929d
by Raymond Toy at 2025-05-09T06:55:39-07:00
-
b37ed3a9
by Raymond Toy at 2025-05-10T08:30:16-07:00
12 changed files:
- .gitlab-ci.yml
- src/code/exports.lisp
- src/code/fd-stream.lisp
- src/code/pathname.lisp
- src/code/unix.lisp
- src/docs/cmu-user/unix.tex
- src/general-info/release-21f.md
- src/i18n/locale/cmucl-unix.pot
- src/i18n/locale/cmucl.pot
- src/lisp/Linux-os.c
- src/lisp/elf.h
- tests/fd-streams.lisp
Changes:
| ... | ... | @@ -3,44 +3,38 @@ variables: |
| 3 | 3 | version: "2024-08-x86"
|
| 4 | 4 | bootstrap: "-B boot-2024-08"
|
| 5 | 5 | |
| 6 | - |
|
| 7 | -stages:
|
|
| 8 | - - install
|
|
| 9 | - - build
|
|
| 10 | - - test
|
|
| 11 | - - ansi-test
|
|
| 12 | - - benchmark
|
|
| 13 | - - analyze
|
|
| 14 | - |
|
| 15 | -cache:
|
|
| 16 | - |
|
| 17 | - |
|
| 18 | -linux:install:
|
|
| 6 | +# Default install configuration to download the cmucl tarballs to use
|
|
| 7 | +# for building.
|
|
| 8 | +.install_template: &install_configuration
|
|
| 19 | 9 | stage: install
|
| 20 | - tags:
|
|
| 21 | - - linux
|
|
| 22 | 10 | artifacts:
|
| 23 | 11 | paths:
|
| 24 | 12 | - snapshot/
|
| 25 | 13 | script:
|
| 26 | - - wget -nv $download_url/cmucl-$version-linux.tar.bz2
|
|
| 27 | - - wget -nv $download_url/cmucl-$version-linux.extra.tar.bz2
|
|
| 14 | + - echo PATH = $PATH
|
|
| 15 | + - ls -F /usr/local/bin
|
|
| 16 | + - type -all gitlab-runner
|
|
| 17 | + # Download binaries. (Do we really need the extras tarball?)
|
|
| 18 | + - $CURL -o cmucl-$version-$osname.tar.bz2 $download_url/cmucl-$version-$osname.tar.bz2
|
|
| 19 | + - $CURL -o cmucl-$version-$osname.extra.tar.bz2 $download_url/cmucl-$version-$osname.extra.tar.bz2
|
|
| 28 | 20 | - mkdir snapshot
|
| 29 | - - (cd snapshot; tar xjf ../cmucl-$version-linux.tar.bz2; tar xjf ../cmucl-$version-linux.extra.tar.bz2)
|
|
| 21 | + - (cd snapshot; tar xjf ../cmucl-$version-$osname.tar.bz2; tar xjf ../cmucl-$version-$osname.extra.tar.bz2)
|
|
| 30 | 22 | |
| 31 | -linux:build:
|
|
| 23 | +# Default build configuration to be added to each build stage for each
|
|
| 24 | +# OS. This assumes we don't need anything special between OSes, and
|
|
| 25 | +# the option '-C ""' is good enough. We also override the default
|
|
| 26 | +# build dirs by using the -b option so that we know where the results
|
|
| 27 | +# are, independent of OS.
|
|
| 28 | +.build_template: &build_configuration
|
|
| 32 | 29 | stage: build
|
| 33 | - tags:
|
|
| 34 | - - linux
|
|
| 35 | 30 | artifacts:
|
| 36 | 31 | paths:
|
| 37 | 32 | - dist/
|
| 38 | - - linux-2/*.log
|
|
| 39 | - - linux-3/*.log
|
|
| 40 | - - linux-4/
|
|
| 41 | - needs:
|
|
| 42 | - - job: linux:install
|
|
| 43 | - artifacts: true
|
|
| 33 | + - build-2/*.log
|
|
| 34 | + - build-3/*.log
|
|
| 35 | + - build-4/
|
|
| 36 | + # Needed by Linux analyzer stage
|
|
| 37 | + - src/lisp/cmucl-version.h
|
|
| 44 | 38 | script:
|
| 45 | 39 | # Do cross compile first
|
| 46 | 40 | #- bin/create-target.sh xtarget x86_linux_clang
|
| ... | ... | @@ -49,11 +43,79 @@ linux:build: |
| 49 | 43 | # Regular build using the cross-compiled result or snapshot. The
|
| 50 | 44 | # analyzer job requires gcc, so make sure we build with gcc here
|
| 51 | 45 | # instead of clang.
|
| 52 | - - bin/build.sh $bootstrap -R -C "x86_linux" -o snapshot/bin/lisp
|
|
| 53 | - # - bin/build.sh $bootstrap -R -C "x86_linux" -o snapshot/bin/lisp
|
|
| 46 | + - bin/build.sh $bootstrap -b build -R -C "" -o snapshot/bin/lisp
|
|
| 54 | 47 | # When the result of `git describe` cannot be used as a version
|
| 55 | 48 | # string, an alternative can be provided with the -V flag
|
| 56 | - - bin/make-dist.sh -I dist linux-4
|
|
| 49 | + - bin/make-dist.sh -I dist build-4
|
|
| 50 | + |
|
| 51 | +# Default configuration for running the ansi-tests.
|
|
| 52 | +.ansi_test_template: &ansi_test_configuration
|
|
| 53 | + stage: ansi-test
|
|
| 54 | + artifacts:
|
|
| 55 | + paths:
|
|
| 56 | + - ansi-test/test.out
|
|
| 57 | + script:
|
|
| 58 | + - bin/run-ansi-tests.sh -l dist/bin/lisp
|
|
| 59 | +
|
|
| 60 | +# Default configuration for running unit tests.
|
|
| 61 | +.unit_test_template: &unit_test_configuration
|
|
| 62 | + stage: test
|
|
| 63 | + artifacts:
|
|
| 64 | + paths:
|
|
| 65 | + - ansi-test/test.out
|
|
| 66 | + - test.log
|
|
| 67 | + script:
|
|
| 68 | + - echo LANG = $LANG
|
|
| 69 | + - bin/run-unit-tests.sh -l dist/bin/lisp 2>&1 | tee test.log
|
|
| 70 | + |
|
| 71 | +# Default configuration to test creation of lisp executable and
|
|
| 72 | +# testing the exectuable works.
|
|
| 73 | +.exec_test_template: &exec_test_configuration
|
|
| 74 | + stage: test
|
|
| 75 | + script:
|
|
| 76 | + # Create an executable and test it by printing the version.
|
|
| 77 | + - dist/bin/lisp -eval '(save-lisp "saved-lisp-executable" :executable t)'
|
|
| 78 | + - ./saved-lisp-executable --version
|
|
| 79 | + |
|
| 80 | +# Default configuration for running the benchmarks.
|
|
| 81 | +.benchmark_template: &benchmark_configuration
|
|
| 82 | + stage: benchmark
|
|
| 83 | + artifacts:
|
|
| 84 | + paths:
|
|
| 85 | + - benchmarks/cl-bench/results
|
|
| 86 | + script:
|
|
| 87 | + - cd benchmarks/cl-bench
|
|
| 88 | + - mkdir tmp
|
|
| 89 | + - CMUCL=../../snapshot/bin/lisp ./run-cmucl.sh
|
|
| 90 | + - CMUCL=../../dist/bin/lisp ./run-cmucl.sh
|
|
| 91 | + - ../../snapshot/bin/lisp -load report
|
|
| 92 | +
|
|
| 93 | +stages:
|
|
| 94 | + - install
|
|
| 95 | + - build
|
|
| 96 | + - test
|
|
| 97 | + - ansi-test
|
|
| 98 | + - benchmark
|
|
| 99 | + - analyze
|
|
| 100 | + |
|
| 101 | +cache:
|
|
| 102 | + |
|
| 103 | +#### Linux jobs ####
|
|
| 104 | +linux:install:
|
|
| 105 | + <<: *install_configuration
|
|
| 106 | + tags:
|
|
| 107 | + - linux
|
|
| 108 | + variables:
|
|
| 109 | + osname: "linux"
|
|
| 110 | + CURL: "curl"
|
|
| 111 | + |
|
| 112 | +linux:build:
|
|
| 113 | + <<: *build_configuration
|
|
| 114 | + tags:
|
|
| 115 | + - linux
|
|
| 116 | + needs:
|
|
| 117 | + - job: linux:install
|
|
| 118 | + artifacts: true
|
|
| 57 | 119 | |
| 58 | 120 | linux:cross-build:
|
| 59 | 121 | stage: build
|
| ... | ... | @@ -84,31 +146,21 @@ linux:cross-build: |
| 84 | 146 | - bin/make-dist.sh -I xdist xlinux-4
|
| 85 | 147 | |
| 86 | 148 | linux:test:
|
| 87 | - stage: test
|
|
| 149 | + <<: *unit_test_configuration
|
|
| 88 | 150 | tags:
|
| 89 | 151 | - linux
|
| 90 | - artifacts:
|
|
| 91 | - paths:
|
|
| 92 | - - ansi-test/test.out
|
|
| 93 | - - test.log
|
|
| 94 | 152 | needs:
|
| 95 | 153 | # Needs artifacts from build (dist/)
|
| 96 | 154 | - job: linux:build
|
| 97 | 155 | artifacts: true
|
| 98 | - script:
|
|
| 99 | - - bin/run-unit-tests.sh -l dist/bin/lisp 2>&1 | tee test.log
|
|
| 100 | 156 | |
| 101 | 157 | linux:exec-test:
|
| 102 | - stage: test
|
|
| 158 | + <<: *exec_test_configuration
|
|
| 103 | 159 | tags:
|
| 104 | 160 | - linux
|
| 105 | 161 | needs:
|
| 106 | 162 | - job: linux:build
|
| 107 | 163 | artifacts: true
|
| 108 | - script:
|
|
| 109 | - # Create an executable and test it by printing the version.
|
|
| 110 | - - dist/bin/lisp -eval '(save-lisp "saved-lisp-executable" :executable t)'
|
|
| 111 | - - ./saved-lisp-executable --version
|
|
| 112 | 164 | |
| 113 | 165 | linux:cross-test:
|
| 114 | 166 | stage: test
|
| ... | ... | @@ -126,141 +178,76 @@ linux:cross-test: |
| 126 | 178 | - bin/run-unit-tests.sh -l xdist/bin/lisp 2>&1 | tee cross-test.log
|
| 127 | 179 | |
| 128 | 180 | linux:ansi-test:
|
| 129 | - stage: ansi-test
|
|
| 181 | + <<: *ansi_test_configuration
|
|
| 130 | 182 | tags:
|
| 131 | 183 | - linux
|
| 132 | - artifacts:
|
|
| 133 | - paths:
|
|
| 134 | - - ansi-test/test.out
|
|
| 135 | 184 | needs:
|
| 136 | 185 | # Needs artifacts from build (dist/)
|
| 137 | 186 | - job: linux:build
|
| 138 | 187 | artifacts: true
|
| 139 | - script:
|
|
| 140 | - - bin/run-ansi-tests.sh -l dist/bin/lisp
|
|
| 141 | 188 |
|
| 142 | 189 | linux:benchmark:
|
| 143 | - stage: benchmark
|
|
| 190 | + <<: *benchmark_configuration
|
|
| 144 | 191 | tags:
|
| 145 | 192 | - linux
|
| 146 | - artifacts:
|
|
| 147 | - paths:
|
|
| 148 | - - benchmarks/cl-bench/results
|
|
| 149 | 193 | needs:
|
| 150 | 194 | # Needs artifacts from install (snapshot/) and build (dist/)
|
| 151 | 195 | - job: linux:install
|
| 152 | 196 | artifacts: true
|
| 153 | 197 | - job: linux:build
|
| 154 | - script:
|
|
| 155 | - - cd benchmarks/cl-bench
|
|
| 156 | - - mkdir tmp
|
|
| 157 | - - CMUCL=../../snapshot/bin/lisp ./run-cmucl.sh
|
|
| 158 | - - CMUCL=../../dist/bin/lisp ./run-cmucl.sh
|
|
| 159 | - - ../../snapshot/bin/lisp -load report
|
|
| 160 | 198 | |
| 199 | +#### OSX (Mac) jobs ####
|
|
| 161 | 200 | osx:install:
|
| 162 | - stage: install
|
|
| 201 | + <<: *install_configuration
|
|
| 163 | 202 | tags:
|
| 164 | 203 | - macos-virtualbox
|
| 165 | - artifacts:
|
|
| 166 | - paths:
|
|
| 167 | - - snapshot/
|
|
| 168 | - script:
|
|
| 169 | - - echo PATH = $PATH
|
|
| 170 | - - ls -F /usr/local/bin
|
|
| 171 | - - type -all gitlab-runner
|
|
| 172 | - - /opt/local/bin/curl -o cmucl-$version-darwin.tar.bz2 $download_url/cmucl-$version-darwin.tar.bz2
|
|
| 173 | - - mkdir snapshot
|
|
| 174 | - - (cd snapshot; tar xjf ../cmucl-$version-darwin.tar.bz2)
|
|
| 204 | + variables:
|
|
| 205 | + osname: "darwin"
|
|
| 206 | + CURL: "/opt/local/bin/curl"
|
|
| 175 | 207 | |
| 176 | 208 | osx:build:
|
| 177 | - stage: build
|
|
| 209 | + <<: *build_configuration
|
|
| 178 | 210 | tags:
|
| 179 | 211 | - macos-virtualbox
|
| 180 | - artifacts:
|
|
| 181 | - paths:
|
|
| 182 | - - dist/
|
|
| 183 | - - darwin-2/*.log
|
|
| 184 | - - darwin-3/*.log
|
|
| 185 | - - darwin-4/*.log
|
|
| 186 | 212 | needs:
|
| 187 | 213 | - job: osx:install
|
| 188 | 214 | artifacts: true
|
| 189 | - script:
|
|
| 190 | - # Do cross compile first
|
|
| 191 | - #- bin/create-target.sh xtarget x86_darwin
|
|
| 192 | - #- bin/create-target.sh xcross x86_darwin
|
|
| 193 | - #- bin/cross-build-world.sh -crl -B boot-2020-04-1 xtarget xcross src/tools/cross-scripts/cross-x86-x86.lisp snapshot/bin/lisp
|
|
| 194 | - # Regular build using the cross-compiled result or snapshot.
|
|
| 195 | - # Need /opt/local/bin to get msgmerge and msgfmt programs.
|
|
| 196 | - - PATH=/opt/local/bin:$PATH bin/build.sh $bootstrap -R -C "" -o snapshot/bin/lisp
|
|
| 197 | - # If needed use -V to specify the version in case some tag makes git
|
|
| 198 | - # describe return something that make-dist.sh doesn't like.
|
|
| 199 | - - bin/make-dist.sh -I dist darwin-4
|
|
| 200 | 215 | |
| 201 | 216 | osx:test:
|
| 202 | - stage: test
|
|
| 217 | + <<: *unit_test_configuration
|
|
| 203 | 218 | tags:
|
| 204 | 219 | - macos-virtualbox
|
| 205 | - artifacts:
|
|
| 206 | - paths:
|
|
| 207 | - - ansi-test/test.out
|
|
| 208 | - - test.log
|
|
| 209 | 220 | needs:
|
| 210 | 221 | # Needs artifacts from build (dist/)
|
| 211 | 222 | - job: osx:build
|
| 212 | 223 | artifacts: true
|
| 213 | - script:
|
|
| 214 | - - echo LANG = $LANG
|
|
| 215 | - - bin/run-unit-tests.sh -l dist/bin/lisp 2>&1 | tee test.log
|
|
| 216 | 224 | |
| 217 | 225 | osx:exec-test:
|
| 218 | - stage: test
|
|
| 226 | + <<: *exec_test_configuration
|
|
| 219 | 227 | tags:
|
| 220 | 228 | - macos-virtualbox
|
| 221 | 229 | needs:
|
| 222 | 230 | - job: osx:build
|
| 223 | 231 | artifacts: true
|
| 224 | - script:
|
|
| 225 | - # Create an executable and test it by printing the version.
|
|
| 226 | - - dist/bin/lisp -eval '(save-lisp "saved-lisp-executable" :executable t)'
|
|
| 227 | - - ./saved-lisp-executable --version
|
|
| 228 | 232 |
|
| 229 | 233 | osx:ansi-test:
|
| 230 | - stage: ansi-test
|
|
| 234 | + <<: *ansi_test_configuration
|
|
| 231 | 235 | tags:
|
| 232 | 236 | - macos-virtualbox
|
| 233 | - artifacts:
|
|
| 234 | - paths:
|
|
| 235 | - - ansi-test/test.out
|
|
| 236 | 237 | needs:
|
| 237 | 238 | # Needs artifacts from build (dist/)
|
| 238 | 239 | - job: osx:build
|
| 239 | 240 | artifacts: true
|
| 240 | - script:
|
|
| 241 | - # NB: sometimes we can't clone the ansi-test repo (bad cert!?!).
|
|
| 242 | - # Manually cloning it in the gitlab build dir helps with this
|
|
| 243 | - # issue until we can figure out what's going on.
|
|
| 244 | - - bin/run-ansi-tests.sh -l dist/bin/lisp
|
|
| 245 | 241 |
|
| 246 | 242 | osx:benchmark:
|
| 247 | - stage: benchmark
|
|
| 243 | + <<: *benchmark_configuration
|
|
| 248 | 244 | tags:
|
| 249 | 245 | - macos-virtualbox
|
| 250 | - artifacts:
|
|
| 251 | - paths:
|
|
| 252 | - - benchmarks/cl-bench/results
|
|
| 253 | 246 | needs:
|
| 254 | 247 | # Needs artifacts from install (snapshot/) and build (dist/)
|
| 255 | 248 | - job: osx:install
|
| 256 | 249 | artifacts: true
|
| 257 | 250 | - job: osx:build
|
| 258 | - script:
|
|
| 259 | - - cd benchmarks/cl-bench
|
|
| 260 | - - mkdir tmp
|
|
| 261 | - - CMUCL=../../snapshot/bin/lisp ./run-cmucl.sh
|
|
| 262 | - - CMUCL=../../dist/bin/lisp ./run-cmucl.sh
|
|
| 263 | - - ../../snapshot/bin/lisp -load report
|
|
| 264 | 251 | |
| 265 | 252 | # Optional job that runs the static analyzer. It needs the files from
|
| 266 | 253 | # the linux-4 directory built in the linux:build job.
|
| ... | ... | @@ -280,75 +267,41 @@ linux:static-analyzer: |
| 280 | 267 | # the results to the log file instead of also having it go to the
|
| 281 | 268 | # console. If someday there's less or no output, we can consider
|
| 282 | 269 | # having the logs go to the console too.
|
| 283 | - - make -C linux-4/lisp clean
|
|
| 284 | - - make -C linux-4/lisp CFLAGS=-fanalyzer > analyzer.log 2>&1
|
|
| 270 | + - make -C build-4/lisp clean
|
|
| 271 | + - make -C build-4/lisp CFLAGS=-fanalyzer > analyzer.log 2>&1
|
|
| 285 | 272 | |
| 273 | +#### OpenSUSE jobs ####
|
|
| 286 | 274 | opensuse:install:
|
| 287 | - stage: install
|
|
| 275 | + <<: *install_configuration
|
|
| 288 | 276 | tags:
|
| 289 | 277 | - opensuse
|
| 290 | - artifacts:
|
|
| 291 | - paths:
|
|
| 292 | - - snapshot/
|
|
| 293 | - script:
|
|
| 294 | - - wget -nv $download_url/cmucl-$version-linux.tar.bz2
|
|
| 295 | - - wget -nv $download_url/cmucl-$version-linux.extra.tar.bz2
|
|
| 296 | - - mkdir snapshot
|
|
| 297 | - - (cd snapshot; tar xjf ../cmucl-$version-linux.tar.bz2; tar xjf ../cmucl-$version-linux.extra.tar.bz2)
|
|
| 278 | + variables:
|
|
| 279 | + osname: "linux"
|
|
| 280 | + CURL: "curl"
|
|
| 298 | 281 | |
| 299 | 282 | opensuse:build:
|
| 300 | - stage: build
|
|
| 283 | + <<: *build_configuration
|
|
| 301 | 284 | tags:
|
| 302 | 285 | - opensuse
|
| 303 | - artifacts:
|
|
| 304 | - paths:
|
|
| 305 | - - dist/
|
|
| 306 | - - linux-2/*.log
|
|
| 307 | - - linux-3/*.log
|
|
| 308 | - - linux-4/
|
|
| 309 | 286 | needs:
|
| 310 | 287 | - job: opensuse:install
|
| 311 | 288 | artifacts: true
|
| 312 | - script:
|
|
| 313 | - # Do cross compile first
|
|
| 314 | - #- bin/create-target.sh xtarget x86_linux_clang
|
|
| 315 | - #- bin/create-target.sh xcross x86_linux_clang
|
|
| 316 | - #- bin/cross-build-world.sh -crl -B boot-2020-04-1 xtarget xcross src/tools/cross-scripts/cross-x86-x86.lisp snapshot/bin/lisp
|
|
| 317 | - # Regular build using the cross-compiled result or snapshot. The
|
|
| 318 | - # analyzer job requires gcc, so make sure we build with gcc here
|
|
| 319 | - # instead of clang.
|
|
| 320 | - - bin/build.sh $bootstrap -R -C "x86_linux" -o snapshot/bin/lisp
|
|
| 321 | - # - bin/build.sh $bootstrap -R -C "x86_linux" -o snapshot/bin/lisp
|
|
| 322 | - # If needed use -V to specify the version in case some tag makes git
|
|
| 323 | - # describe return something that make-dist.sh doesn't like.
|
|
| 324 | - - bin/make-dist.sh -I dist linux-4
|
|
| 325 | 289 | |
| 326 | 290 | opensuse:test:
|
| 327 | - stage: test
|
|
| 291 | + <<: *unit_test_configuration
|
|
| 328 | 292 | tags:
|
| 329 | - - linux
|
|
| 330 | - artifacts:
|
|
| 331 | - paths:
|
|
| 332 | - - ansi-test/test.out
|
|
| 333 | - - test.log
|
|
| 293 | + - opensuse
|
|
| 334 | 294 | needs:
|
| 335 | 295 | # Needs artifacts from build (dist/)
|
| 336 | 296 | - job: opensuse:build
|
| 337 | 297 | artifacts: true
|
| 338 | - script:
|
|
| 339 | - - bin/run-unit-tests.sh -l dist/bin/lisp 2>&1 | tee test.log
|
|
| 340 | 298 | |
| 341 | 299 | opensuse:ansi-test:
|
| 342 | - stage: ansi-test
|
|
| 300 | + <<: *ansi_test_configuration
|
|
| 343 | 301 | tags:
|
| 344 | - - linux
|
|
| 345 | - artifacts:
|
|
| 346 | - paths:
|
|
| 347 | - - ansi-test/test.out
|
|
| 302 | + - opensuse
|
|
| 348 | 303 | needs:
|
| 349 | 304 | # Needs artifacts from build (dist/)
|
| 350 | 305 | - job: opensuse:build
|
| 351 | 306 | artifacts: true
|
| 352 | - script:
|
|
| 353 | - - bin/run-ansi-tests.sh -l dist/bin/lisp
|
|
| 354 | 307 |
| ... | ... | @@ -31,6 +31,9 @@ |
| 31 | 31 | (if (find-package "BIGNUM")
|
| 32 | 32 | (rename-package "BIGNUM" "BIGNUM" 'nil)
|
| 33 | 33 | (make-package "BIGNUM" :nicknames 'nil :use nil))
|
| 34 | +(if (find-package "ERRNO")
|
|
| 35 | + (rename-package "ERRNO" "ERRNO" 'nil)
|
|
| 36 | + (make-package "ERRNO" :nicknames 'nil :use nil))
|
|
| 34 | 37 | (if (find-package "UNIX")
|
| 35 | 38 | (rename-package "UNIX" "UNIX" 'nil)
|
| 36 | 39 | (make-package "UNIX" :nicknames 'nil :use nil))
|
| ... | ... | @@ -196,6 +199,450 @@ |
| 196 | 199 | "MULTIPLY-BIGNUM-AND-FIXNUM" "MULTIPLY-BIGNUMS" "MULTIPLY-FIXNUMS"
|
| 197 | 200 | "NEGATE-BIGNUM" "SUBTRACT-BIGNUM"))
|
| 198 | 201 | |
| 202 | +(defpackage "ERRNO"
|
|
| 203 | + #+linux
|
|
| 204 | + (:export "E2BIG"
|
|
| 205 | + "EACCES"
|
|
| 206 | + "EADDRINUSE"
|
|
| 207 | + "EADDRNOTAVAIL"
|
|
| 208 | + "EADV"
|
|
| 209 | + "EAFNOSUPPORT"
|
|
| 210 | + "EAGAIN"
|
|
| 211 | + "EALREADY"
|
|
| 212 | + "EBADE"
|
|
| 213 | + "EBADF"
|
|
| 214 | + "EBADFD"
|
|
| 215 | + "EBADMSG"
|
|
| 216 | + "EBADR"
|
|
| 217 | + "EBADRQC"
|
|
| 218 | + "EBADSLT"
|
|
| 219 | + "EBFONT"
|
|
| 220 | + "EBUSY"
|
|
| 221 | + "ECHILD"
|
|
| 222 | + "ECHRNG"
|
|
| 223 | + "ECOMM"
|
|
| 224 | + "ECONNABORTED"
|
|
| 225 | + "ECONNREFUSED"
|
|
| 226 | + "ECONNRESET"
|
|
| 227 | + "EDEADLK"
|
|
| 228 | + "EDEADLOCK"
|
|
| 229 | + "EDESTADDRREQ"
|
|
| 230 | + "EDOM"
|
|
| 231 | + "EDOTDOT"
|
|
| 232 | + "EDQUOT"
|
|
| 233 | + "EEXIST"
|
|
| 234 | + "EFAULT"
|
|
| 235 | + "EFBIG"
|
|
| 236 | + "EHOSTDOWN"
|
|
| 237 | + "EHOSTUNREACH"
|
|
| 238 | + "EIDRM"
|
|
| 239 | + "EILSEQ"
|
|
| 240 | + "EINPROGRESS"
|
|
| 241 | + "EINTR"
|
|
| 242 | + "EINVAL"
|
|
| 243 | + "EIO"
|
|
| 244 | + "EISCONN"
|
|
| 245 | + "EISDIR"
|
|
| 246 | + "EISNAM"
|
|
| 247 | + "EL2HLT"
|
|
| 248 | + "EL2NSYNC"
|
|
| 249 | + "EL3HLT"
|
|
| 250 | + "EL3RST"
|
|
| 251 | + "ELIBACC"
|
|
| 252 | + "ELIBBAD"
|
|
| 253 | + "ELIBEXEC"
|
|
| 254 | + "ELIBMAX"
|
|
| 255 | + "ELIBSCN"
|
|
| 256 | + "ELNRNG"
|
|
| 257 | + "ELOOP"
|
|
| 258 | + "EMFILE"
|
|
| 259 | + "EMLINK"
|
|
| 260 | + "EMSGSIZE"
|
|
| 261 | + "EMULTIHOP"
|
|
| 262 | + "ENAMETOOLONG"
|
|
| 263 | + "ENAVAIL"
|
|
| 264 | + "ENETDOWN"
|
|
| 265 | + "ENETRESET"
|
|
| 266 | + "ENETUNREACH"
|
|
| 267 | + "ENFILE"
|
|
| 268 | + "ENOANO"
|
|
| 269 | + "ENOBUFS"
|
|
| 270 | + "ENOCSI"
|
|
| 271 | + "ENODATA"
|
|
| 272 | + "ENODEV"
|
|
| 273 | + "ENOENT"
|
|
| 274 | + "ENOEXEC"
|
|
| 275 | + "ENOLCK"
|
|
| 276 | + "ENOLINK"
|
|
| 277 | + "ENOMEM"
|
|
| 278 | + "ENOMSG"
|
|
| 279 | + "ENONET"
|
|
| 280 | + "ENOPKG"
|
|
| 281 | + "ENOPROTOOPT"
|
|
| 282 | + "ENOSPC"
|
|
| 283 | + "ENOSR"
|
|
| 284 | + "ENOSTR"
|
|
| 285 | + "ENOSYS"
|
|
| 286 | + "ENOTBLK"
|
|
| 287 | + "ENOTCONN"
|
|
| 288 | + "ENOTDIR"
|
|
| 289 | + "ENOTEMPTY"
|
|
| 290 | + "ENOTNAM"
|
|
| 291 | + "ENOTSOCK"
|
|
| 292 | + "ENOTTY"
|
|
| 293 | + "ENOTUNIQ"
|
|
| 294 | + "ENXIO"
|
|
| 295 | + "EOPNOTSUPP"
|
|
| 296 | + "EOVERFLOW"
|
|
| 297 | + "EPERM"
|
|
| 298 | + "EPFNOSUPPORT"
|
|
| 299 | + "EPIPE"
|
|
| 300 | + "EPROTO"
|
|
| 301 | + "EPROTONOSUPPORT"
|
|
| 302 | + "EPROTOTYPE"
|
|
| 303 | + "ERANGE"
|
|
| 304 | + "EREMCHG"
|
|
| 305 | + "EREMOTE"
|
|
| 306 | + "EREMOTEIO"
|
|
| 307 | + "ERESTART"
|
|
| 308 | + "EROFS"
|
|
| 309 | + "ESHUTDOWN"
|
|
| 310 | + "ESOCKTNOSUPPORT"
|
|
| 311 | + "ESPIPE"
|
|
| 312 | + "ESRCH"
|
|
| 313 | + "ESRMNT"
|
|
| 314 | + "ESTALE"
|
|
| 315 | + "ESTRPIPE"
|
|
| 316 | + "ESUCCESS"
|
|
| 317 | + "ETIME"
|
|
| 318 | + "ETIMEDOUT"
|
|
| 319 | + "ETOOMANYREFS"
|
|
| 320 | + "ETXTBSY"
|
|
| 321 | + "EUCLEAN"
|
|
| 322 | + "EUNATCH"
|
|
| 323 | + "EUSERS"
|
|
| 324 | + "EWOULDBLOCK"
|
|
| 325 | + "EXDEV"
|
|
| 326 | + "EXFULL"
|
|
| 327 | + )
|
|
| 328 | + #+(or bsd darwin)
|
|
| 329 | + (:export "E2BIG"
|
|
| 330 | + "EACCES"
|
|
| 331 | + "EADDRINUSE"
|
|
| 332 | + "EADDRNOTAVAIL"
|
|
| 333 | + "EAFNOSUPPORT"
|
|
| 334 | + "EAGAIN"
|
|
| 335 | + "EALREADY"
|
|
| 336 | + "EBADF"
|
|
| 337 | + "EBUSY"
|
|
| 338 | + "ECHILD"
|
|
| 339 | + "ECONNABORTED"
|
|
| 340 | + "ECONNREFUSED"
|
|
| 341 | + "ECONNRESET"
|
|
| 342 | + "EDEADLK"
|
|
| 343 | + "EDESTADDRREQ"
|
|
| 344 | + "EDOM"
|
|
| 345 | + "EDQUOT"
|
|
| 346 | + "EEXIST"
|
|
| 347 | + "EFAULT"
|
|
| 348 | + "EFBIG"
|
|
| 349 | + "EHOSTDOWN"
|
|
| 350 | + "EHOSTUNREACH"
|
|
| 351 | + "EINPROGRESS"
|
|
| 352 | + "EINTR"
|
|
| 353 | + "EINVAL"
|
|
| 354 | + "EIO"
|
|
| 355 | + "EISCONN"
|
|
| 356 | + "EISDIR"
|
|
| 357 | + "ELOCAL"
|
|
| 358 | + "ELOOP"
|
|
| 359 | + "EMFILE"
|
|
| 360 | + "EMLINK"
|
|
| 361 | + "EMSGSIZE"
|
|
| 362 | + "ENAMETOOLONG"
|
|
| 363 | + "ENETDOWN"
|
|
| 364 | + "ENETRESET"
|
|
| 365 | + "ENETUNREACH"
|
|
| 366 | + "ENFILE"
|
|
| 367 | + "ENOBUFS"
|
|
| 368 | + "ENODEV"
|
|
| 369 | + "ENOENT"
|
|
| 370 | + "ENOEXEC"
|
|
| 371 | + "ENOMEM"
|
|
| 372 | + "ENOPROTOOPT"
|
|
| 373 | + "ENOSPC"
|
|
| 374 | + "ENOTBLK"
|
|
| 375 | + "ENOTCONN"
|
|
| 376 | + "ENOTDIR"
|
|
| 377 | + "ENOTEMPTY"
|
|
| 378 | + "ENOTSOCK"
|
|
| 379 | + "ENOTTY"
|
|
| 380 | + "ENXIO"
|
|
| 381 | + "EOPNOTSUPP"
|
|
| 382 | + "EPERM"
|
|
| 383 | + "EPFNOSUPPORT"
|
|
| 384 | + "EPIPE"
|
|
| 385 | + "EPROCLIM"
|
|
| 386 | + "EPROTONOSUPPORT"
|
|
| 387 | + "EPROTOTYPE"
|
|
| 388 | + "ERANGE"
|
|
| 389 | + "EREMOTE"
|
|
| 390 | + "EROFS"
|
|
| 391 | + "ESHUTDOWN"
|
|
| 392 | + "ESOCKTNOSUPPORT"
|
|
| 393 | + "ESPIPE"
|
|
| 394 | + "ESRCH"
|
|
| 395 | + "ESUCCESS"
|
|
| 396 | + "ETIMEDOUT"
|
|
| 397 | + "ETOOMANYREFS"
|
|
| 398 | + "ETXTBSY"
|
|
| 399 | + "EUSERS"
|
|
| 400 | + "EVICEERR"
|
|
| 401 | + "EVICEOP"
|
|
| 402 | + "EWOULDBLOCK"
|
|
| 403 | + "EXDEV"
|
|
| 404 | + )
|
|
| 405 | + #+solaris
|
|
| 406 | + (:export "E2BIG"
|
|
| 407 | + "EACCES"
|
|
| 408 | + "EADDRINUSE"
|
|
| 409 | + "EADDRNOTAVAIL"
|
|
| 410 | + "EADV"
|
|
| 411 | + "EAFNOSUPPORT"
|
|
| 412 | + "EAGAIN"
|
|
| 413 | + "EALREADY"
|
|
| 414 | + "EBADE"
|
|
| 415 | + "EBADF"
|
|
| 416 | + "EBADFD"
|
|
| 417 | + "EBADMSG"
|
|
| 418 | + "EBADR"
|
|
| 419 | + "EBADRQC"
|
|
| 420 | + "EBADSLT"
|
|
| 421 | + "EBFONT"
|
|
| 422 | + "EBUSY"
|
|
| 423 | + "ECANCELED"
|
|
| 424 | + "ECHILD"
|
|
| 425 | + "ECHRNG"
|
|
| 426 | + "ECOMM"
|
|
| 427 | + "ECONNABORTED"
|
|
| 428 | + "ECONNREFUSED"
|
|
| 429 | + "ECONNRESET"
|
|
| 430 | + "EDEADLK"
|
|
| 431 | + "EDEADLOCK"
|
|
| 432 | + "EDESTADDRREQ"
|
|
| 433 | + "EDOM"
|
|
| 434 | + "EEXIST"
|
|
| 435 | + "EFAULT"
|
|
| 436 | + "EFBIG"
|
|
| 437 | + "EHOSTDOWN"
|
|
| 438 | + "EHOSTUNREACH"
|
|
| 439 | + "EIDRM"
|
|
| 440 | + "EILSEQ"
|
|
| 441 | + "EINPROGRESS"
|
|
| 442 | + "EINTR"
|
|
| 443 | + "EINVAL"
|
|
| 444 | + "EIO"
|
|
| 445 | + "EISCONN"
|
|
| 446 | + "EISDIR"
|
|
| 447 | + "EL2HLT"
|
|
| 448 | + "EL2NSYNC"
|
|
| 449 | + "EL3HLT"
|
|
| 450 | + "EL3RST"
|
|
| 451 | + "ELIBACC"
|
|
| 452 | + "ELIBBAD"
|
|
| 453 | + "ELIBEXEC"
|
|
| 454 | + "ELIBMAX"
|
|
| 455 | + "ELIBSCN"
|
|
| 456 | + "ELNRNG"
|
|
| 457 | + "ELOOP"
|
|
| 458 | + "EMFILE"
|
|
| 459 | + "EMLINK"
|
|
| 460 | + "EMSGSIZE"
|
|
| 461 | + "EMULTIHOP"
|
|
| 462 | + "ENAMETOOLONG"
|
|
| 463 | + "ENETDOWN"
|
|
| 464 | + "ENETRESET"
|
|
| 465 | + "ENETUNREACH"
|
|
| 466 | + "ENFILE"
|
|
| 467 | + "ENOANO"
|
|
| 468 | + "ENOBUFS"
|
|
| 469 | + "ENOCSI"
|
|
| 470 | + "ENODATA"
|
|
| 471 | + "ENODEV"
|
|
| 472 | + "ENOENT"
|
|
| 473 | + "ENOEXEC"
|
|
| 474 | + "ENOLCK"
|
|
| 475 | + "ENOLINK"
|
|
| 476 | + "ENOMEM"
|
|
| 477 | + "ENOMSG"
|
|
| 478 | + "ENONET"
|
|
| 479 | + "ENOPKG"
|
|
| 480 | + "ENOPROTOOPT"
|
|
| 481 | + "ENOSPC"
|
|
| 482 | + "ENOSR"
|
|
| 483 | + "ENOSTR"
|
|
| 484 | + "ENOSYS"
|
|
| 485 | + "ENOTBLK"
|
|
| 486 | + "ENOTCONN"
|
|
| 487 | + "ENOTDIR"
|
|
| 488 | + "ENOTEMPTY"
|
|
| 489 | + "ENOTSOCK"
|
|
| 490 | + "ENOTSUP"
|
|
| 491 | + "ENOTTY"
|
|
| 492 | + "ENOTUNIQ"
|
|
| 493 | + "ENXIO"
|
|
| 494 | + "EOPNOTSUPP"
|
|
| 495 | + "EOVERFLOW"
|
|
| 496 | + "EPERM"
|
|
| 497 | + "EPFNOSUPPORT"
|
|
| 498 | + "EPIPE"
|
|
| 499 | + "EPROTO"
|
|
| 500 | + "EPROTONOSUPPORT"
|
|
| 501 | + "EPROTOTYPE"
|
|
| 502 | + "ERANGE"
|
|
| 503 | + "EREMCHG"
|
|
| 504 | + "EREMOTE"
|
|
| 505 | + "ERESTART"
|
|
| 506 | + "EROFS"
|
|
| 507 | + "ESHUTDOWN"
|
|
| 508 | + "ESOCKTNOSUPPORT"
|
|
| 509 | + "ESPIPE"
|
|
| 510 | + "ESRCH"
|
|
| 511 | + "ESRMNT"
|
|
| 512 | + "ESTALE"
|
|
| 513 | + "ESTRPIPE"
|
|
| 514 | + "ESUCCESS"
|
|
| 515 | + "ETIME"
|
|
| 516 | + "ETIMEDOUT"
|
|
| 517 | + "ETOOMANYREFS"
|
|
| 518 | + "ETXTBSY"
|
|
| 519 | + "EUNATCH"
|
|
| 520 | + "EUSERS"
|
|
| 521 | + "EWOULDBLOCK"
|
|
| 522 | + "EXDEV"
|
|
| 523 | + "EXFULL"
|
|
| 524 | + )
|
|
| 525 | + #-(or linux solaris bsd darwin)
|
|
| 526 | + (:export "E2BIG"
|
|
| 527 | + "EACCES"
|
|
| 528 | + "EADDRINUSE"
|
|
| 529 | + "EADDRNOTAVAIL"
|
|
| 530 | + "EADV"
|
|
| 531 | + "EAFNOSUPPORT"
|
|
| 532 | + "EAGAIN"
|
|
| 533 | + "EALREADY"
|
|
| 534 | + "EBADE"
|
|
| 535 | + "EBADF"
|
|
| 536 | + "EBADFD"
|
|
| 537 | + "EBADMSG"
|
|
| 538 | + "EBADR"
|
|
| 539 | + "EBADRQC"
|
|
| 540 | + "EBADSLT"
|
|
| 541 | + "EBFONT"
|
|
| 542 | + "EBUSY"
|
|
| 543 | + "ECANCELED"
|
|
| 544 | + "ECHILD"
|
|
| 545 | + "ECHRNG"
|
|
| 546 | + "ECOMM"
|
|
| 547 | + "ECONNABORTED"
|
|
| 548 | + "ECONNREFUSED"
|
|
| 549 | + "ECONNRESET"
|
|
| 550 | + "EDEADLK"
|
|
| 551 | + "EDEADLOCK"
|
|
| 552 | + "EDESTADDRREQ"
|
|
| 553 | + "EDOM"
|
|
| 554 | + "EEXIST"
|
|
| 555 | + "EFAULT"
|
|
| 556 | + "EFBIG"
|
|
| 557 | + "EHOSTDOWN"
|
|
| 558 | + "EHOSTUNREACH"
|
|
| 559 | + "EIDRM"
|
|
| 560 | + "EILSEQ"
|
|
| 561 | + "EINPROGRESS"
|
|
| 562 | + "EINTR"
|
|
| 563 | + "EINVAL"
|
|
| 564 | + "EIO"
|
|
| 565 | + "EISCONN"
|
|
| 566 | + "EISDIR"
|
|
| 567 | + "EL2HLT"
|
|
| 568 | + "EL2NSYNC"
|
|
| 569 | + "EL3HLT"
|
|
| 570 | + "EL3RST"
|
|
| 571 | + "ELIBACC"
|
|
| 572 | + "ELIBBAD"
|
|
| 573 | + "ELIBEXEC"
|
|
| 574 | + "ELIBMAX"
|
|
| 575 | + "ELIBSCN"
|
|
| 576 | + "ELNRNG"
|
|
| 577 | + "ELOOP"
|
|
| 578 | + "EMFILE"
|
|
| 579 | + "EMLINK"
|
|
| 580 | + "EMSGSIZE"
|
|
| 581 | + "EMULTIHOP"
|
|
| 582 | + "ENAMETOOLONG"
|
|
| 583 | + "ENETDOWN"
|
|
| 584 | + "ENETRESET"
|
|
| 585 | + "ENETUNREACH"
|
|
| 586 | + "ENFILE"
|
|
| 587 | + "ENOANO"
|
|
| 588 | + "ENOBUFS"
|
|
| 589 | + "ENOCSI"
|
|
| 590 | + "ENODATA"
|
|
| 591 | + "ENODEV"
|
|
| 592 | + "ENOENT"
|
|
| 593 | + "ENOEXEC"
|
|
| 594 | + "ENOLCK"
|
|
| 595 | + "ENOLINK"
|
|
| 596 | + "ENOMEM"
|
|
| 597 | + "ENOMSG"
|
|
| 598 | + "ENONET"
|
|
| 599 | + "ENOPKG"
|
|
| 600 | + "ENOPROTOOPT"
|
|
| 601 | + "ENOSPC"
|
|
| 602 | + "ENOSR"
|
|
| 603 | + "ENOSTR"
|
|
| 604 | + "ENOSYS"
|
|
| 605 | + "ENOTBLK"
|
|
| 606 | + "ENOTCONN"
|
|
| 607 | + "ENOTDIR"
|
|
| 608 | + "ENOTEMPTY"
|
|
| 609 | + "ENOTSOCK"
|
|
| 610 | + "ENOTSUP"
|
|
| 611 | + "ENOTTY"
|
|
| 612 | + "ENOTUNIQ"
|
|
| 613 | + "ENXIO"
|
|
| 614 | + "EOPNOTSUPP"
|
|
| 615 | + "EOVERFLOW"
|
|
| 616 | + "EPERM"
|
|
| 617 | + "EPFNOSUPPORT"
|
|
| 618 | + "EPIPE"
|
|
| 619 | + "EPROTO"
|
|
| 620 | + "EPROTONOSUPPORT"
|
|
| 621 | + "EPROTOTYPE"
|
|
| 622 | + "ERANGE"
|
|
| 623 | + "EREMCHG"
|
|
| 624 | + "EREMOTE"
|
|
| 625 | + "ERESTART"
|
|
| 626 | + "EROFS"
|
|
| 627 | + "ESHUTDOWN"
|
|
| 628 | + "ESOCKTNOSUPPORT"
|
|
| 629 | + "ESPIPE"
|
|
| 630 | + "ESRCH"
|
|
| 631 | + "ESRMNT"
|
|
| 632 | + "ESTALE"
|
|
| 633 | + "ESTRPIPE"
|
|
| 634 | + "ESUCCESS"
|
|
| 635 | + "ETIME"
|
|
| 636 | + "ETIMEDOUT"
|
|
| 637 | + "ETOOMANYREFS"
|
|
| 638 | + "ETXTBSY"
|
|
| 639 | + "EUNATCH"
|
|
| 640 | + "EUSERS"
|
|
| 641 | + "EWOULDBLOCK"
|
|
| 642 | + "EXDEV"
|
|
| 643 | + "EXFULL"
|
|
| 644 | + ))
|
|
| 645 | + |
|
| 199 | 646 | (defpackage "UNIX"
|
| 200 | 647 | (:export "UNIX-CURRENT-DIRECTORY"
|
| 201 | 648 | "UNIX-OPEN"
|
| ... | ... | @@ -309,18 +756,8 @@ |
| 309 | 756 | |
| 310 | 757 | ;; Other symbols from structures, etc.
|
| 311 | 758 | "C-CC" "C-CFLAG" "C-IFLAG" "C-ISPEED" "C-LFLAG" "C-OFLAG" "C-OSPEED"
|
| 312 | - "CHECK" "D-NAME" "D-RECLEN" "E2BIG" "EACCES" "EADDRINUSE" "EADDRNOTAVAIL"
|
|
| 313 | - "EAFNOSUPPORT" "EAGAIN" "EALREADY" "EBADF" "EBUSY" "ECHILD"
|
|
| 314 | - "ECONNABORTED" "ECONNREFUSED" "ECONNRESET" "EDEADLK" "EDESTADDRREQ"
|
|
| 315 | - "EDOM" "EDQUOT" "EEXIST" "EFAULT" "EFBIG" "EHOSTDOWN" "EHOSTUNREACH"
|
|
| 316 | - "EINPROGRESS" "EINTR" "EINVAL" "EIO" "EISCONN" "EISDIR" "ELOOP" "EMFILE"
|
|
| 317 | - "EMLINK" "EMSGSIZE" "ENAMETOOLONG" "ENETDOWN" "ENETRESET" "ENETUNREACH"
|
|
| 318 | - "ENFILE" "ENOBUFS" "ENODEV" "ENOENT" "ENOEXEC" "ENOMEM" "ENOPROTOOPT"
|
|
| 319 | - "ENOSPC" "ENOTBLK" "ENOTCONN" "ENOTDIR" "ENOTEMPTY" "ENOTSOCK" "ENOTTY"
|
|
| 320 | - "ENXIO" "EOPNOTSUPP" "EPERM" "EPFNOSUPPORT" "EPIPE" "EPROTONOSUPPORT"
|
|
| 321 | - "EPROTOTYPE" "ERANGE" "EREMOTE" "EROFS" "ESHUTDOWN" "ESOCKTNOSUPPORT"
|
|
| 322 | - "ESPIPE" "ESRCH" "ESUCCESS" "ETIMEDOUT" "ETOOMANYREFS" "ETXTBSY" "EUSERS"
|
|
| 323 | - "EWOULDBLOCK" "EXDEV" "F-GETFL" "F-GETOWN" "F-SETFL" "F-SETOWN" "FAPPEND"
|
|
| 759 | + "CHECK" "D-NAME" "D-RECLEN"
|
|
| 760 | + "F-GETFL" "F-GETOWN" "F-SETFL" "F-SETOWN" "FAPPEND"
|
|
| 324 | 761 | "FASYNC" "FD-SET" "FD-ZERO" "FNDELAY" "F_OK" "GID-T" "IT-INTERVAL"
|
| 325 | 762 | "IT-VALUE" "ITIMERVAL" "L_INCR" "L_SET" "L_XTND" "MAP_ANONYMOUS"
|
| 326 | 763 | "MAP_FIXED" "MAP_PRIVATE" "MAP_SHARED" "MS_ASYNC" "MS_INVALIDATE"
|
| ... | ... | @@ -368,7 +805,6 @@ |
| 368 | 805 | (:export "TCHARS"
|
| 369 | 806 | "LTCHARS"
|
| 370 | 807 | "D-NAMLEN"
|
| 371 | - |
|
| 372 | 808 |
|
| 373 | 809 | ;; run-program.lisp
|
| 374 | 810 | "SGTTYB"
|
| ... | ... | @@ -396,14 +832,8 @@ |
| 396 | 832 | "SGTTYB"
|
| 397 | 833 | |
| 398 | 834 | ;; Other symbols
|
| 399 | - "BLKCNT-T" "D-INO" "D-OFF" "EADV" "EBADE" "EBADFD" "EBADMSG" "EBADR"
|
|
| 400 | - "EBADRQC" "EBADSLT" "EBFONT" "ECHRNG" "ECOMM" "EDEADLOCK" "EDOTDOT"
|
|
| 401 | - "EIDRM" "EILSEQ" "EISNAM" "EL2HLT" "EL2NSYNC" "EL3HLT" "EL3RST" "ELIBACC"
|
|
| 402 | - "ELIBBAD" "ELIBEXEC" "ELIBMAX" "ELIBSCN" "ELNRNG" "EMULTIHOP" "ENAVAIL"
|
|
| 403 | - "ENOANO" "ENOCSI" "ENODATA" "ENOLCK" "ENOLINK" "ENOMSG" "ENONET" "ENOPKG"
|
|
| 404 | - "ENOSR" "ENOSTR" "ENOSYS" "ENOTNAM" "ENOTUNIQ" "EOVERFLOW" "EPROTO"
|
|
| 405 | - "EREMCHG" "EREMOTEIO" "ERESTART" "ESRMNT" "ESTALE" "ESTRPIPE" "ETIME"
|
|
| 406 | - "EUCLEAN" "EUNATCH" "EXFULL" "O_NOCTTY" "SIGSTKFLT"
|
|
| 835 | + "BLKCNT-T" "D-INO" "D-OFF"
|
|
| 836 | + "O_NOCTTY" "SIGSTKFLT"
|
|
| 407 | 837 | "SG-FLAGS"
|
| 408 | 838 | "TIOCGETP"
|
| 409 | 839 | "TIOCSETP"
|
| ... | ... | @@ -416,57 +846,10 @@ |
| 416 | 846 | (:export "D-INO"
|
| 417 | 847 | "D-OFF"
|
| 418 | 848 | "DIRECT"
|
| 419 | - "EADV"
|
|
| 420 | - "EBADE"
|
|
| 421 | - "EBADFD"
|
|
| 422 | - "EBADMSG"
|
|
| 423 | - "EBADR"
|
|
| 424 | - "EBADRQC"
|
|
| 425 | - "EBADSLT"
|
|
| 426 | - "EBFONT"
|
|
| 427 | - "ECANCELED"
|
|
| 428 | - "ECHRNG"
|
|
| 429 | - "ECOMM"
|
|
| 430 | - "EDEADLOCK"
|
|
| 431 | - "EIDRM"
|
|
| 432 | - "EILSEQ"
|
|
| 433 | - "EL2HLT"
|
|
| 434 | - "EL2NSYNC"
|
|
| 435 | - "EL3HLT"
|
|
| 436 | - "EL3RST"
|
|
| 437 | - "ELIBACC"
|
|
| 438 | - "ELIBBAD"
|
|
| 439 | - "ELIBEXEC"
|
|
| 440 | - "ELIBMAX"
|
|
| 441 | - "ELIBSCN"
|
|
| 442 | - "ELNRNG"
|
|
| 443 | - "EMULTIHOP"
|
|
| 444 | - "ENOANO"
|
|
| 445 | - "ENOCSI"
|
|
| 446 | - "ENODATA"
|
|
| 447 | - "ENOLCK"
|
|
| 448 | - "ENOLINK"
|
|
| 449 | - "ENOMSG"
|
|
| 450 | - "ENONET"
|
|
| 451 | - "ENOPKG"
|
|
| 452 | - "ENOSR"
|
|
| 453 | - "ENOSTR"
|
|
| 454 | - "ENOSYS"
|
|
| 455 | - "ENOTSUP"
|
|
| 456 | - "ENOTUNIQ"
|
|
| 457 | - "EOVERFLOW"
|
|
| 458 | - "EPROTO"
|
|
| 459 | - "EREMCHG"
|
|
| 460 | - "ERESTART"
|
|
| 461 | - "ESRMNT"
|
|
| 462 | - "ESTALE"
|
|
| 463 | - "ESTRPIPE"
|
|
| 464 | - "ETIME"
|
|
| 465 | - "EUNATCH"
|
|
| 466 | 849 | "EXECGRP"
|
| 467 | 850 | "EXECOTH"
|
| 468 | 851 | "EXECOWN"
|
| 469 | - "EXFULL"
|
|
| 852 | +
|
|
| 470 | 853 | "F-DUPFD"
|
| 471 | 854 | "F-GETFD"
|
| 472 | 855 | "F-SETFD"
|
| ... | ... | @@ -553,7 +936,15 @@ |
| 553 | 936 | "WRITEGRP"
|
| 554 | 937 | "WRITEOTH"
|
| 555 | 938 | "XMT1EN"
|
| 556 | - ))
|
|
| 939 | + )
|
|
| 940 | + )
|
|
| 941 | + |
|
| 942 | +;; Import all of the symbols from UNIX-ERRNO into UNIX and the export
|
|
| 943 | +;; them.
|
|
| 944 | +(ext:without-package-locks
|
|
| 945 | + (do-external-symbols (sym "ERRNO")
|
|
| 946 | + (shadowing-import sym "UNIX")
|
|
| 947 | + (export sym "UNIX")))
|
|
| 557 | 948 |
|
| 558 | 949 | (defpackage "FORMAT")
|
| 559 | 950 |
| ... | ... | @@ -1764,7 +1764,8 @@ |
| 1764 | 1764 | (progn
|
| 1765 | 1765 | (format t "in-buffer-length = ~D~%" in-buffer-length)
|
| 1766 | 1766 | (format t "in-length = ~D~%" (fd-stream-in-length stream))
|
| 1767 | - (format t "fd-stream-in-index = ~D~%" (fd-stream-in-index stream)))
|
|
| 1767 | + (format t "fd-stream-in-index = ~D~%" (fd-stream-in-index stream))
|
|
| 1768 | + (format t "posn = ~A~%" posn))
|
|
| 1768 | 1769 | (decf posn (- (fd-stream-in-length stream)
|
| 1769 | 1770 | (fd-stream-in-index stream))))
|
| 1770 | 1771 | #+nil
|
| ... | ... | @@ -1795,9 +1796,14 @@ |
| 1795 | 1796 | (setf (fd-stream-unread stream) nil) ;;@@
|
| 1796 | 1797 | #+unicode
|
| 1797 | 1798 | (progn
|
| 1799 | + ;; Clear out any pending input from the string buffer
|
|
| 1798 | 1800 | (setf (fd-stream-last-char-read-size stream) 0)
|
| 1799 | 1801 | (setf (fd-stream-string-index stream)
|
| 1800 | 1802 | (fd-stream-string-buffer-len stream)))
|
| 1803 | + ;; Mark the in-buffer as empty.
|
|
| 1804 | + (setf (fd-stream-in-index stream)
|
|
| 1805 | + (fd-stream-in-length stream))
|
|
| 1806 | + ;; Mark the ibuf as empty.
|
|
| 1801 | 1807 | (setf (fd-stream-ibuf-head stream) 0)
|
| 1802 | 1808 | (setf (fd-stream-ibuf-tail stream) 0)
|
| 1803 | 1809 | ;; Trash cached value for listen, so that we check next time.
|
| ... | ... | @@ -269,7 +269,7 @@ |
| 269 | 269 | |
| 270 | 270 | #+darwin
|
| 271 | 271 | (defvar *enable-darwin-path-normalization* nil
|
| 272 | - "When non-NIL, pathnames are on Darwin are normalized when created.
|
|
| 272 | + _N"When non-NIL, pathnames are on Darwin are normalized when created.
|
|
| 273 | 273 | Otherwise, the pathnames are unchanged.
|
| 274 | 274 | |
| 275 | 275 | This must be NIL during bootstrapping because Unicode is not yet
|
| ... | ... | @@ -2053,9 +2053,7 @@ |
| 2053 | 2053 | _N"Returns a string describing the error number which was returned by a
|
| 2054 | 2054 | UNIX system call."
|
| 2055 | 2055 | (declare (type integer error-number))
|
| 2056 | - (if (array-in-bounds-p *unix-errors* error-number)
|
|
| 2057 | - (svref *unix-errors* error-number)
|
|
| 2058 | - (format nil _"Unknown error [~d]" error-number)))
|
|
| 2056 | + (unix::unix-strerror error-number))
|
|
| 2059 | 2057 | |
| 2060 | 2058 | |
| 2061 | 2059 | ;;;; Lisp types used by syscalls.
|
| ... | ... | @@ -2975,3 +2973,14 @@ |
| 2975 | 2973 | (if (null-alien result)
|
| 2976 | 2974 | (values nil (unix-errno))
|
| 2977 | 2975 | (%file->name (cast result c-call:c-string)))))))
|
| 2976 | + |
|
| 2977 | +(defun unix-strerror (errno)
|
|
| 2978 | + _N"Returns a string that describes the error code Errno"
|
|
| 2979 | + (let ((result
|
|
| 2980 | + (alien-funcall
|
|
| 2981 | + (extern-alien "strerror"
|
|
| 2982 | + (function (* char) int))
|
|
| 2983 | + errno)))
|
|
| 2984 | + ;; Result from strerror can be localized so we need to decode
|
|
| 2985 | + ;; those octets to get a proper Lisp string.
|
|
| 2986 | + (string-decode (cast result c-string) :default))) |
| ... | ... | @@ -244,9 +244,10 @@ for SAPs when possible, so the consing overhead is generally minimal. |
| 244 | 244 | |
| 245 | 245 | \begin{defun}{system:}{sap-ref-8}{\args{\var{sap} \var{offset}}}
|
| 246 | 246 | \defunx[system:]{sap-ref-16}{\args{\var{sap} \var{offset}}}
|
| 247 | - \defunx[system:]{sap-ref-32}{\args{\var{sap} \var{offset}}}
|
|
| 248 | -
|
|
| 249 | - These functions return the 8, 16 or 32 bit unsigned integer at
|
|
| 247 | + \defunx[system:]{sap-ref-32}{\args{\var{sap} \var{offset}}
|
|
| 248 | + \defunx[system:]{sap-ref-64}{\args{\var{sap} \var{offset}}}
|
|
| 249 | + |
|
| 250 | + These functions return the 8, 16, 32 or 64 bit unsigned integer at
|
|
| 250 | 251 | \var{offset} from \var{sap}. The \var{offset} is always a byte
|
| 251 | 252 | offset, regardless of the number of bits accessed. \code{setf} may
|
| 252 | 253 | be used with the these functions to deposit values into virtual
|
| ... | ... | @@ -256,7 +257,8 @@ for SAPs when possible, so the consing overhead is generally minimal. |
| 256 | 257 | \begin{defun}{system:}{signed-sap-ref-8}{\args{\var{sap} \var{offset}}}
|
| 257 | 258 | \defunx[system:]{signed-sap-ref-16}{\args{\var{sap} \var{offset}}}
|
| 258 | 259 | \defunx[system:]{signed-sap-ref-32}{\args{\var{sap} \var{offset}}}
|
| 259 | -
|
|
| 260 | + \defunx[system:]{signed-sap-ref-64}{\args{\var{sap} \var{offset}}}
|
|
| 261 | + |
|
| 260 | 262 | These functions are the same as the above unsigned operations,
|
| 261 | 263 | except that they sign-extend, returning a negative number if the
|
| 262 | 264 | high bit is set.
|
| ... | ... | @@ -117,9 +117,12 @@ public domain. |
| 117 | 117 | * ~~#363~~ Version numbers added to files and directories. The
|
| 118 | 118 | distribution layout has changed.
|
| 119 | 119 | * ~~#364~~ Add interface to `mkdtemp` and `mkstemp`
|
| 120 | - * ~~#367~~ Add stream:string-count-octets to count octets in a string
|
|
| 120 | + * ~~#367~~ Add `stream:string-count-octets` to count octets in a string
|
|
| 121 | 121 | * ~~#369~~ Improve docstring for `unix::unix-setlocale`
|
| 122 | + * ~~#375~~ `unix-mkstemp` and `unix-mkdtemp` actually returns the
|
|
| 123 | + file names now.
|
|
| 122 | 124 | * ~~#379~~ Support GNU-style command-line option names
|
| 125 | + * ~~#382~~ Command-line options are case-sensitive
|
|
| 123 | 126 | * Other changes:
|
| 124 | 127 | * Improvements to the PCL implementation of CLOS:
|
| 125 | 128 | * Changes to building procedure:
|
| ... | ... | @@ -1284,10 +1284,6 @@ msgid "" |
| 1284 | 1284 | " UNIX system call."
|
| 1285 | 1285 | msgstr ""
|
| 1286 | 1286 | |
| 1287 | -#: src/code/unix.lisp
|
|
| 1288 | -msgid "Unknown error [~d]"
|
|
| 1289 | -msgstr ""
|
|
| 1290 | - |
|
| 1291 | 1287 | #: src/code/unix.lisp
|
| 1292 | 1288 | msgid ""
|
| 1293 | 1289 | "Perform the UNIX select(2) system call.\n"
|
| ... | ... | @@ -1454,3 +1450,7 @@ msgid "" |
| 1454 | 1450 | " returned."
|
| 1455 | 1451 | msgstr ""
|
| 1456 | 1452 | |
| 1453 | +#: src/code/unix.lisp
|
|
| 1454 | +msgid "Returns a string that describes the error code Errno"
|
|
| 1455 | +msgstr ""
|
|
| 1456 | + |
| ... | ... | @@ -9667,6 +9667,15 @@ msgid "" |
| 9667 | 9667 | " an otherwise undefined logical host."
|
| 9668 | 9668 | msgstr ""
|
| 9669 | 9669 | |
| 9670 | +#: src/code/pathname.lisp
|
|
| 9671 | +msgid ""
|
|
| 9672 | +"When non-NIL, pathnames are on Darwin are normalized when created.\n"
|
|
| 9673 | +" Otherwise, the pathnames are unchanged.\n"
|
|
| 9674 | +"\n"
|
|
| 9675 | +" This must be NIL during bootstrapping because Unicode is not yet\n"
|
|
| 9676 | +" available."
|
|
| 9677 | +msgstr ""
|
|
| 9678 | + |
|
| 9670 | 9679 | #: src/code/pathname.lisp
|
| 9671 | 9680 | msgid "A path specification, either a string, file-stream or pathname."
|
| 9672 | 9681 | msgstr ""
|
| ... | ... | @@ -476,7 +476,7 @@ sigsegv_handler(HANDLER_ARGS) |
| 476 | 476 | #endif
|
| 477 | 477 | if (gc_write_barrier(code->si_addr))
|
| 478 | 478 | return;
|
| 479 | - DPRINTF(0, (stderr, "sigsegv: PC: %p\n", SC_PC(os_context)));
|
|
| 479 | + DPRINTF(0, (stderr, "sigsegv: PC: %#lx\n", SC_PC(os_context)));
|
|
| 480 | 480 | |
| 481 | 481 | #ifdef RED_ZONE_HIT
|
| 482 | 482 | {
|
| ... | ... | @@ -9,7 +9,7 @@ |
| 9 | 9 | * interface to both elf and mach-o support. I (rtoy) was too lazy to
|
| 10 | 10 | * change the name to something more descriptive.
|
| 11 | 11 | */
|
| 12 | -#if !defined(_ELF_H_INCLUDED_)
|
|
| 12 | +#if !defined(ELF_H_INCLUDED)
|
|
| 13 | 13 | |
| 14 | 14 | #define ELF_H_INCLUDED
|
| 15 | 15 |
| ... | ... | @@ -36,19 +36,58 @@ |
| 36 | 36 | (file-length s))
|
| 37 | 37 | (delete-file *test-file*))))
|
| 38 | 38 | |
| 39 | -(define-test clear-output-1
|
|
| 40 | - (:tag :trac)
|
|
| 41 | - (assert-eql
|
|
| 42 | - 0
|
|
| 43 | - (ext:with-temporary-file (test-file)
|
|
| 44 | - (let ((s (open test-file
|
|
| 45 | - :direction :output
|
|
| 46 | - :if-exists :supersede)))
|
|
| 47 | - ;; Write a character to the (fully buffered) output
|
|
| 48 | - ;; stream. Clear the output and close the file. Nothing
|
|
| 49 | - ;; should have been written to the file.
|
|
| 50 | - (write-char #\a s)
|
|
| 51 | - (clear-output s)
|
|
| 52 | - (close s)
|
|
| 53 | - (setf s (open test-file))
|
|
| 54 | - (file-length s))))) |
|
| 39 | +(define-test file-position.1
|
|
| 40 | + (:tag :issues)
|
|
| 41 | + ;; Create a short test file
|
|
| 42 | + (let ((test-file (merge-pathnames #p"file-pos.txt" *test-path*)))
|
|
| 43 | + (with-open-file (s test-file
|
|
| 44 | + :direction :output
|
|
| 45 | + :if-exists :supersede)
|
|
| 46 | + (write-string "aaaaaa" s)
|
|
| 47 | + (write-char #\newline s))
|
|
| 48 | + (with-open-file (s test-file)
|
|
| 49 | + (read-line s)
|
|
| 50 | + (assert-true (file-position s 0))
|
|
| 51 | + (assert-equal (file-position s) 0))))
|
|
| 52 | + |
|
| 53 | +(define-test file-position.2
|
|
| 54 | + (:tag :issues)
|
|
| 55 | + ;; Create a test file just longer than the internal in-buffer length
|
|
| 56 | + ;; and the first line is more than 512 characters long.
|
|
| 57 | + (let ((test-file (merge-pathnames #p"file-pos.txt" *test-path*)))
|
|
| 58 | + (with-open-file (s test-file
|
|
| 59 | + :direction :output
|
|
| 60 | + :if-exists :supersede)
|
|
| 61 | + (write-string (make-string 512 :initial-element #\a) s)
|
|
| 62 | + (write-char #\newline s)
|
|
| 63 | + (write-string "zzzzz" s)
|
|
| 64 | + (write-char #\newline s))
|
|
| 65 | + (with-open-file (s test-file)
|
|
| 66 | + (read-line s)
|
|
| 67 | + (assert-true (file-position s 0))
|
|
| 68 | + (assert-equal (file-position s) 0))))
|
|
| 69 | + |
|
| 70 | +(define-test file-position.3
|
|
| 71 | + (:tag :issues)
|
|
| 72 | + ;; Create a test file just longer than the internal in-buffer
|
|
| 73 | + ;; length. This tests the case where the in-buffer does not have
|
|
| 74 | + ;; enough octets to form a complete character. (See comment in
|
|
| 75 | + ;; fd-stream-file-position.
|
|
| 76 | + (let ((test-file (merge-pathnames #p"file-pos.txt" *test-path*)))
|
|
| 77 | + (with-open-file (s test-file
|
|
| 78 | + :external-format :utf-8
|
|
| 79 | + :direction :output
|
|
| 80 | + :if-exists :supersede)
|
|
| 81 | + (write-char #\a s)
|
|
| 82 | + ;; STR is a string consisting of the single codepoint #x11000
|
|
| 83 | + ;; which is 4 octets when encoded using utf-8.
|
|
| 84 | + (let ((str (lisp::codepoints-string '(#x11000))))
|
|
| 85 | + (dotimes (k 128)
|
|
| 86 | + (write-string str s)))
|
|
| 87 | + (write-char #\newline s)
|
|
| 88 | + (write-string "zzzzz" s)
|
|
| 89 | + (write-char #\newline s))
|
|
| 90 | + (with-open-file (s test-file :external-format :utf-8)
|
|
| 91 | + (read-line s)
|
|
| 92 | + (assert-true (file-position s 0))
|
|
| 93 | + (assert-equal (file-position s) 0)))) |