debian/0000755000000000000000000000000012265541126007172 5ustar debian/50picolisp.el0000644000000000000000000000163212265537350011511 0ustar ;; -*-emacs-lisp-*- ;; ;; Emacs startup file for the Debian picolisp package ;; ;; To avoid a dependency on emacsen for our modes and avoid having a ;; separate picolisp-el package, we don't byte-compile the .el ;; files, so we only need to add a source directory to load-path. (let ((package-dir "/usr/share/emacs/site-lisp/picolisp")) ;; If package-dir does not exist, the picolisp package must have ;; removed but not purged, and we should skip the setup. (when (file-directory-p package-dir) (if (fboundp 'debian-pkg-add-load-path-item) (debian-pkg-add-load-path-item package-dir) (setq load-path (cons package-dir load-path))) (autoload 'run-picolisp "inferior-picolisp") (autoload 'picolisp-mode "picolisp" "Major mode for editing picolisp files." t) (setq picolisp-program-name "/usr/lib/picolisp/bin/plmod") (add-to-list 'auto-mode-alist '("\\.l\\'" . picolisp-mode)))) debian/changelog0000644000000000000000000001732312265537350011056 0ustar picolisp (3.1.5.2-2) unstable; urgency=medium * Sync to tip. * debian/picolisp.install: - Include lib/phone.css - Install arch-indep files under /usr/share/picolisp * debian/source/lintian-overrides: - Override unknown architectures armel and armhf. -- Kan-Ru Chen (陳侃如) Wed, 15 Jan 2014 22:59:02 +0800 picolisp (3.1.5.2-1) unstable; urgency=medium * New upstream release. * Refresh patches. * debian/control: - Bump Standards-Version to 3.9.5. -- Kan-Ru Chen (陳侃如) Wed, 15 Jan 2014 00:41:33 +0800 picolisp (3.1.4.9-1) unstable; urgency=low * New upstream release. * Refresh patches. * debian/rules: - Checkout specific release tag directly. -- Kan-Ru Chen (陳侃如) Thu, 31 Oct 2013 18:19:34 +0800 picolisp (3.1.2.12-1) unstable; urgency=low * New upstream release. * Refresh patches. * debian/control: - Bump Standards-Version to 3.9.4. -- Kan-Ru Chen (陳侃如) Thu, 20 Jun 2013 21:52:27 +0800 picolisp (3.1.1.15-1) unstable; urgency=low * New upstream release. * Sync to upstream tip. -- Kan-Ru Chen (陳侃如) Wed, 06 Mar 2013 00:21:35 +0800 picolisp (3.1.1.1-1) unstable; urgency=low * New upstream release. * debian/copyright: - Update copyright for new files. * debian/rules: - Include `dpkg-buildflags --get CPPFLAGS'. -- Kan-Ru Chen (陳侃如) Thu, 06 Dec 2012 10:22:21 +0800 picolisp (3.1.0.7-1) unstable; urgency=low * New upstream release. * Sync to upstream tip. * debian/control: - Update Vcs-* url -- Kan-Ru Chen Mon, 25 Jun 2012 14:30:32 +0800 picolisp (3.1.0.4-1) unstable; urgency=low * New upstream release. * Sync to upstream tip. -- Kan-Ru Chen Wed, 02 May 2012 09:01:32 +0800 picolisp (3.0.9.7-1) unstable; urgency=low * New upstream release. * Sync to upstream tip. * Enable hardening flags on helper binaries. (Closes: #663355) * debian/control: - Build-Depends on lib32gcc1 for amd64 to workaround #667519 -- Kan-Ru Chen Sun, 08 Apr 2012 21:31:01 +0800 picolisp (3.0.9.4-1) unstable; urgency=low * New upstream release. * Sync to upstream tip. * debian/patches/picolisp_build_on_multi_cpu.patch: - Correctly append CFLAGS to upstream CFLAGS. Fixes FTBFS on armhf. Thanks to Peter Green and Hector Oron (Closes: #660324). * debian/copyright: - Update copyright-format to 1.0. * debian/control: - Bump Standards-Version to 3.9.3. -- Kan-Ru Chen Mon, 05 Mar 2012 22:41:16 +0800 picolisp (3.0.9.3-1) unstable; urgency=low * New upstream release. * Sync to upstream tip. -- Kan-Ru Chen Fri, 17 Feb 2012 23:07:13 +0800 picolisp (3.0.9.1-1) unstable; urgency=low * New upstream release. * debian/control: - Add hardening-includes to build dependency. * debian/rules: - Enable hardening flags. - Install bash_completion. -- Kan-Ru Chen Mon, 02 Jan 2012 11:25:29 +0800 picolisp (3.0.8.10-1) unstable; urgency=low * New upstream release. -- Kan-Ru Chen Sat, 17 Dec 2011 10:42:10 +0800 picolisp (3.0.8.7-1) unstable; urgency=low * New upstream release. -- Kan-Ru Chen Sun, 13 Nov 2011 17:15:44 +0800 picolisp (3.0.8.5-2) unstable; urgency=low * Sync to upstream tip with important fixes. -- Kan-Ru Chen Fri, 28 Oct 2011 00:07:36 +0800 picolisp (3.0.8.5-1) unstable; urgency=low * New upstream release. - Force linkage with libm, fix 64-bit build in Ubuntu. (LP: #874841) * Sync to upstream tip with IPv6 support. -- Kan-Ru Chen Thu, 27 Oct 2011 11:29:38 +0800 picolisp (3.0.8.1-2) unstable; urgency=low * Add back accidentally removed file to non-amd64 arch. -- Kan-Ru Chen Sun, 02 Oct 2011 18:47:24 +0800 picolisp (3.0.8.1-1) unstable; urgency=low * New upstream release. -- Kan-Ru Chen Sat, 01 Oct 2011 22:42:46 +0800 picolisp (3.0.7.7-2) unstable; urgency=low * Sync to upstream tip. - Fix FTBFS with -Wl,--as-needed flag. (LP: #831180) -- Kan-Ru Chen Wed, 07 Sep 2011 06:08:28 +0800 picolisp (3.0.7.7-1) unstable; urgency=low * New upstream release. * Sync to upstream tip. -- Kan-Ru Chen Sun, 04 Sep 2011 14:51:15 +0800 picolisp (3.0.7.6-2) unstable; urgency=low * Apply patches from upstream. - Fix 64-bit random seed initialization. -- Kan-Ru Chen Fri, 19 Aug 2011 18:40:16 +0800 picolisp (3.0.7.6-1) unstable; urgency=low * New upstream release. - Fix a bug in reading from a pipe from stdin. -- Kan-Ru Chen Fri, 19 Aug 2011 10:40:41 +0800 picolisp (3.0.7.4-1) unstable; urgency=low * New upstream release. * Sync to upstream tip. -- Kan-Ru Chen Sun, 24 Jul 2011 09:27:15 +0200 picolisp (3.0.7.2-2) unstable; urgency=low * Sync to upstream tip. * Drop two unused patches. -- Kan-Ru Chen Mon, 11 Jul 2011 17:48:35 +0800 picolisp (3.0.7.2-1) unstable; urgency=low * New upstream release. * Fix *OS should be "Linux" on Debian system. -- Kan-Ru Chen Sun, 10 Jul 2011 16:29:34 +0800 picolisp (3.0.7.1-1) unstable; urgency=low * New upstream release. -- Kan-Ru Chen Fri, 08 Jul 2011 01:32:42 +0800 picolisp (3.0.6.14-1) unstable; urgency=low * New upstream release. * Install plmod to usr/lib/picolisp/bin (Closes: #627451) -- Kan-Ru Chen Mon, 30 May 2011 22:33:54 +0800 picolisp (3.0.6.11-1) unstable; urgency=low * New upstream release. * Don't compress .l files. -- Kan-Ru Chen Fri, 13 May 2011 15:55:13 +0800 picolisp (3.0.6.10-2) unstable; urgency=low * Add missing build dependency. -- Kan-Ru Chen Thu, 12 May 2011 04:53:33 +0800 picolisp (3.0.6.10-1) unstable; urgency=low * New upstream release. * Import new picolisp.el from upstream. * Install additional supporting binaries to /usr/lib/picolisp/bin. * Stop shipping "simul/" and "rcsim/". * Add lintian overrides for OpenSSL linkage. -- Kan-Ru Chen Wed, 11 May 2011 15:44:30 +0800 picolisp (3.0.6.9-1) unstable; urgency=low * New upstream release. * With consensus of upstream, bundled applications now are installed to /usr/share/picolisp. * Fix typo in package description, thanks to Vincent Blut. (Closes: #624454) * Add any-armhf to arch list. (Closes: #623351) -- Kan-Ru Chen Mon, 09 May 2011 17:29:45 +0800 picolisp (3.0.6.5-2) unstable; urgency=low * Move bundled applications to /usr/lib/picolisp. * Fix shebangs for psh, replica and watchdog. -- Kan-Ru Chen Thu, 28 Apr 2011 14:09:35 +0800 picolisp (3.0.6.5-1) unstable; urgency=low * New upstream release. * Install img, loc, doc, src and src64 as required by upstream. * Fix mips, mipsel and armhf build. (Closes: #623351) * Bump Standards-Version to 3.9.2, no changes needed. -- Kan-Ru Chen Sun, 24 Apr 2011 16:20:39 +0800 picolisp (3.0.6.1-1) unstable; urgency=low * New upstream release. * Fix FTBFS on Armel and S/390. -- Kan-Ru Chen Wed, 13 Apr 2011 22:03:26 +0800 picolisp (3.0.5.23-2) unstable; urgency=low * Remove lib/z3d which only builds on 32-bit architecture and isn't used by any libraries. -- Kan-Ru Chen Sun, 13 Mar 2011 02:09:41 +0800 picolisp (3.0.5.23-1) unstable; urgency=low * Initial release (Closes: #533011) -- Kan-Ru Chen Fri, 11 Mar 2011 07:44:02 +0800 debian/clean0000644000000000000000000000004412265537350010201 0ustar bin/picolisp lib/ext lib/ht lib/z3d debian/compat0000644000000000000000000000000212265537350010374 0ustar 7 debian/control0000644000000000000000000000310212265537350010575 0ustar Source: picolisp Section: lisp Priority: optional Maintainer: Kan-Ru Chen (陳侃如) Build-Depends: debhelper (>= 7.0.50~), libssl-dev, hardening-includes, gcc-multilib [amd64], lib32gcc1 [amd64] Standards-Version: 3.9.5 Homepage: http://picolisp.com/ Vcs-Git: git://anonscm.debian.org/collab-maint/picolisp.git Vcs-Browser: http://anonscm.debian.org/gitweb/?p=collab-maint/picolisp.git;a=summary # Only supports amd64 on linux and solaris Package: picolisp Architecture: kopensolaris-amd64 solaris-amd64 amd64 any-i386 any-armel any-armeb any-arm any-avr32 any-hppa any-m32r any-m68k any-mips any-mipsel any-powerpc any-s390 any-sh3 any-sh3eb any-sh4 any-sh4eb any-sparc any-armhf Pre-Depends: dpkg (>= 1.17.5) Depends: ${shlibs:Depends}, ${misc:Depends} Description: Lisp interpreter and application server framework Pico Lisp can be viewed from two different aspects: As a general purpose programming language, and a dedicated application server framework. . As a programming language, Pico Lisp provides a 1-to-1 mapping of a clean and powerful Lisp derivate, to a simple and efficient virtual machine. It supports persistent objects as a first class data type, resulting in a database system of Entity/Relation classes and a Prolog-like query language tightly integrated into the system. . As an application server framework, Pico Lisp provides for database management (including multi-user synchronization, DB garbage collection journalling and replication), web interface integrated (and generated from) the application data model, and an application server. debian/copyright0000644000000000000000000001022012265537350011124 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: picolisp Source: http://software-lab.de/down.html Files: * Copyright: 2002-2011 Alexander Burger License: Expat Files: app/loc/* loc/* Copyright: 2002-2011, Alexander Burger 2008, Mansur Mamkin 2009, Armadillo 2010, Jon Kleiser, jon.kleiser@usit.uio.no License: Expat Files: lib/glyphlist.txt Copyright: 1997,1998,2002,2007 Adobe Systems Incorporated License: Permission is hereby granted, free of charge, to any person obtaining a copy of this documentation file to use, copy, publish, distribute, sublicense, and/or sell copies of the documentation, and to permit others to do the same, provided that: - No modification, editing or other alteration of this document is allowed; and - The above copyright notice and this permission notice shall be included in all copies of the documentation. . Permission is hereby granted, free of charge, to any person obtaining a copy of this documentation file, to create their own derivative works from the content of this document to use, copy, publish, distribute, sublicense, and/or sell the derivative works, and to permit others to do the same, provided that the derived work is not represented as being a copy or version of this document. . Adobe shall not be liable to any party for any loss of revenue or profit or for indirect, incidental, special, consequential, or other similar damages, whether based on tort (including without limitation negligence or strict liability), contract or other legal or equitable grounds even if Adobe has been advised or had reason to know of the possibility of such damages.Ê The Adobe materials are provided on an "AS IS" basis.Ê Adobe specifically disclaims all express, statutory, or implied warranties relating to the Adobe materials, including but not limited to those concerning merchantability or fitness for a particular purpose or non-infringement of any third party rights regarding the Adobe materials. Files: lib/el/*.el Copyright: 2009, Guillermo R. Palavecino License: GPL-2.0+ Files: lib/el/picolisp-wiki-mode.el Copyright: 2012, Thorsten Jolitz License: GPL-2.0+ Files: debian/* Copyright: 2011 Kan-Ru Chen License: Expat License: GPL-2.0+ This package is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. . This package is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. . You should have received a copy of the GNU General Public License along with this program. If not, see . On Debian systems, the complete text of the GNU General Public License version 2 can be found in "/usr/share/common-licenses/GPL-2". License: Expat Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: . The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. . THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. debian/patches/0000755000000000000000000000000012265537350010625 5ustar debian/patches/picolisp_build_on_multi_cpu.patch0000644000000000000000000000777512265537350017444 0ustar --- src/Makefile | 39 ++++++++++++++++++++++++++++----------- src64/Makefile | 50 ++++++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 76 insertions(+), 13 deletions(-) --- a/src/Makefile +++ b/src/Makefile @@ -7,13 +7,29 @@ picoFiles = main.c gc.c apply.c flow.c sym.c subr.c big.c io.c net.c tab.c -CFLAGS = -c -O2 -m32 -pipe \ +CFLAGS ?= +CFLAGS += -O2 -pipe \ -falign-functions -fomit-frame-pointer -fno-strict-aliasing \ -W -Wimplicit -Wreturn-type -Wunused -Wformat \ -Wuninitialized -Wstrict-prototypes \ -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 +OS ?= +LDFLAGS ?= +PICOLISP-FLAGS = -rdynamic +LIB-FLAGS = -lc -lm -ldl $(LDFLAGS) +DYNAMIC-LIB-FLAGS = -shared -export-dynamic +STRIP = : + +ifeq (amd64,$(CPU)) +CFLAGS += -m32 +PICOLISP-FLAGS += -m32 +DYNAMIC-LIB-FLAGS += -m32 +endif + +ifeq (,$(OS)) + ifeq ($(shell uname), Linux) OS = Linux PICOLISP-FLAGS = -m32 -rdynamic @@ -70,6 +86,7 @@ endif endif +endif picolisp: $(bin)/picolisp $(lib)/ext$(dll) $(lib)/ht$(dll) tools: $(bin)/lat1 $(bin)/utf2 $(bin)/balance @@ -78,8 +95,10 @@ all: picolisp tools gate .c.o: - gcc $(CFLAGS) -D_OS='"$(OS)"' $*.c + gcc $(CFLAGS) -c -D_OS='"$(OS)"' $*.c +ext.o ht.o z3d.o: + gcc $(CFLAGS) -c -fPIC -DPIC -D_OS='"$(OS)"' $*.c $(picoFiles:.c=.o) ext.o ht.o: pico.h main.o: vers.h @@ -107,35 +126,33 @@ $(lib)/ext$(dll): ext.o - gcc -o $(lib)/ext$(dll) $(DYNAMIC-LIB-FLAGS) ext.o $(DLL-DEFS) $(LCRYPT) + gcc $(CFLAGS) $(LDFLAGS) -o $(lib)/ext$(dll) $(DYNAMIC-LIB-FLAGS) ext.o $(DLL-DEFS) $(LCRYPT) $(STRIP) $(lib)/ext$(dll) $(lib)/ht$(dll): ht.o - gcc -o $(lib)/ht$(dll) $(DYNAMIC-LIB-FLAGS) ht.o $(DLL-DEFS) + gcc $(CFLAGS) $(LDFLAGS) -o $(lib)/ht$(dll) $(DYNAMIC-LIB-FLAGS) ht.o $(DLL-DEFS) $(STRIP) $(lib)/ht$(dll) - $(bin)/lat1: lat1.c - gcc -o $(bin)/lat1$(exe) lat1.c + gcc $(CFLAGS) $(LDFLAGS) -o $(bin)/lat1$(exe) lat1.c $(STRIP) $(bin)/lat1$(exe) $(bin)/utf2: utf2.c - gcc -o $(bin)/utf2$(exe) utf2.c + gcc $(CFLAGS) $(LDFLAGS) -o $(bin)/utf2$(exe) utf2.c $(STRIP) $(bin)/utf2$(exe) $(bin)/balance: balance.c - gcc -o $(bin)/balance$(exe) balance.c + gcc $(CFLAGS) $(LDFLAGS) -o $(bin)/balance$(exe) balance.c $(STRIP) $(bin)/balance$(exe) $(bin)/ssl: ssl.c - gcc -o $(bin)/ssl$(exe) ssl.c -lssl -lcrypto + gcc $(CFLAGS) $(LDFLAGS) -o $(bin)/ssl$(exe) ssl.c -lssl -lcrypto $(STRIP) $(bin)/ssl$(exe) $(bin)/httpGate: httpGate.c - gcc -o $(bin)/httpGate$(exe) httpGate.c -lssl -lcrypto + gcc $(CFLAGS) $(LDFLAGS) -o $(bin)/httpGate$(exe) httpGate.c -lssl -lcrypto $(STRIP) $(bin)/httpGate$(exe) - # Clean up clean: rm -f *.o --- a/src64/Makefile +++ b/src64/Makefile @@ -1,7 +1,7 @@ # 08jan13abu # (c) Software Lab. Alexander Burger -.SILENT: +# .SILENT: bin = ../bin lib = ../lib @@ -38,6 +38,50 @@ ARCH = emu STRIP = : +OS ?= +LDFLAGS ?= + +ifeq (Linux,$(OS)) + ifeq ($(MACHINE), x86_64) + SYS = .linux + FMT = .s + ARCH = x86-64 + AS = as + else + ifeq ($(MACHINE), ppc64) + SYS = .linux + FMT = .s + ARCH = ppc64 + AS = as -mppc64 -a64 + endif + endif + LD-MAIN = -Wl,--no-as-needed -rdynamic -lc -lm -ldl $(LDFLAGS) + LD-SHARED = -shared -export-dynamic $(LDFLAGS) + STRIP = : +else +ifeq (solaris,$(OS)) + SYS = .sunOs + FMT = .s + ARCH = x86-64 + AS = gas --64 + LD-MAIN = -m64 -lc -lm -ldl -lsocket -lnsl $(LDFLAGS) + LD-SHARED = -m64 -shared $(LDFLAGS) + STRIP = : +else +ifeq (kopensolaris,$(OS)) + SYS = .sunOs + FMT = .s + ARCH = x86-64 + AS = gas --64 + LD-MAIN = -m64 -lc -lm -ldl -lsocket -lnsl $(LDFLAGS) + LD-SHARED = -m64 -shared $(LDFLAGS) + STRIP = : +endif +endif +endif + +ifeq (,$(OS)) + ifeq ($(UNAME), Linux) OS = Linux ifeq ($(MACHINE), x86_64) @@ -87,6 +131,8 @@ endif endif +endif + baseFiles = version.l glob.l main.l \ gc.l apply.l flow.l sym.l subr.l big.l io.l db.l net.l err.l @@ -124,7 +170,7 @@ ### Compile ### sysdefs: sysdefs.c - $(CC) -o sysdefs -D_FILE_OFFSET_BITS=64 sysdefs.c + $(CC) -o sysdefs -D_FILE_OFFSET_BITS=64 $(CFLAGS) sysdefs.c $(LD-MAIN) $(STRIP) sysdefs emu.base.o: sysdefs emu.base.c debian/patches/picolisp_fix_manpage.patch0000644000000000000000000000035412265537350016030 0ustar --- a/man/man1/picolisp.1 +++ b/man/man1/picolisp.1 @@ -7,7 +7,7 @@ .B pil [arguments ...] [-] [arguments ...] [+] .br -.B /installpath/bin/picolisp +.B picolisp [arguments ...] [-] [arguments ...] [+] .SH DESCRIPTION .B PicoLisp debian/patches/picolisp_fix_shbang_path.patch0000644000000000000000000000305012265537350016672 0ustar --- bin/psh | 2 +- bin/replica | 3 +-- bin/watchdog | 2 +- misc/bigtest | 2 +- misc/chat | 2 +- misc/mailing | 2 +- src/mkVers | 2 +- 7 files changed, 7 insertions(+), 8 deletions(-) --- a/bin/psh +++ b/bin/psh @@ -1,4 +1,4 @@ -#!bin/picolisp lib.l +#!/usr/bin/picolisp /usr/lib/picolisp/lib.l # 06may11abu # (c) Software Lab. Alexander Burger --- a/bin/replica +++ b/bin/replica @@ -1,5 +1,4 @@ -#!bin/picolisp lib.l -# 03dec13abu +#!/usr/bin/picolisp /usr/lib/picolisp/lib.l # Use: bin/replica [dbs1 ..] # : bin/ssl 443 '/!replica' 60 --- a/bin/watchdog +++ b/bin/watchdog @@ -1,4 +1,4 @@ -#!bin/picolisp lib.l +#!/usr/bin/picolisp /usr/lib/picolisp/lib.l # 09mar08abu # (c) Software Lab. Alexander Burger # Use: bin/watchdog .. --- a/misc/bigtest +++ b/misc/bigtest @@ -1,4 +1,4 @@ -#!bin/picolisp lib.l +#!/usr/bin/picolisp /usr/lib/picolisp/lib.l # 25apr11abu # misc/bigtest --- a/misc/chat +++ b/misc/chat @@ -1,4 +1,4 @@ -#!bin/picolisp lib.l +#!/usr/bin/picolisp /usr/lib/picolisp/lib.l # 21dec05abu # *Port *Sock *Name --- a/misc/mailing +++ b/misc/mailing @@ -1,4 +1,4 @@ -#!bin/picolisp lib.l +#!/usr/bin/picolisp /usr/lib/picolisp/lib.l # 20may11abu # (c) Software Lab. Alexander Burger --- a/src/mkVers +++ b/src/mkVers @@ -1,4 +1,4 @@ -#!../bin/picolisp ../lib.l +#!/usr/bin/picolisp /usr/lib/picolisp/lib.l # 07mar11abu # (c) Software Lab. Alexander Burger debian/patches/picolisp_sync_to_tip.patch0000644000000000000000000002337412265537350016113 0ustar diff --git a/CHANGES b/CHANGES --- a/CHANGES +++ b/CHANGES @@ -1,9 +1,10 @@ * XXmar14 picoLisp-3.1.6 + Canvas pre-rendering * 31dec13 picoLisp-3.1.5 Phone GUI support 'prune' LRU scheme Bug in volatile properties 'cnt2' argument to 'gc' (64-bit) Improved UB-Tree support diff --git a/lib/canvas.js b/lib/canvas.js --- a/lib/canvas.js +++ b/lib/canvas.js @@ -9,130 +9,19 @@ function drawCanvas(id, dly, x, y) { req.open("POST", document.getElementsByTagName("BASE")[0].href + SesId + "!jsDraw?" + id + "&+" + dly + (y? "&+" + x + "&+" + y : x? "&" + x : "") ); req.responseType = "arraybuffer"; } catch (e) {return true;} req.onload = function() { - var lst = plio(new Uint8Array(req.response)); var ele = document.getElementById(id); - var cmd, i, j; - if (lst) { - var ctx = ele.getContext("2d"); - - for (i = 0; i < lst.length; ++i) { - switch ((cmd = lst[i])[0]) { // In sync with "@lib/canvas.l" - /*** Functions ***/ - case 1: - ctx.fillText(cmd[1], cmd[2], cmd[3]); - break; - case 2: - ctx.beginPath(); - ctx.moveTo(cmd[1], cmd[2]); - ctx.lineTo(cmd[3], cmd[4]); - ctx.closePath(); - ctx.stroke(); - break; - case 3: - ctx.clearRect(cmd[1], cmd[2], cmd[3], cmd[4]); - break; - case 4: - ctx.strokeRect(cmd[1], cmd[2], cmd[3], cmd[4]); - break; - case 5: - ctx.fillRect(cmd[1], cmd[2], cmd[3], cmd[4]); - break; - case 6: - ctx.beginPath(); - break; - case 7: - ctx.closePath(); - break; - case 8: - ctx.moveTo(cmd[1], cmd[2]); - break; - case 9: - ctx.lineTo(cmd[1], cmd[2]); - break; - case 10: - ctx.bezierCurveTo(cmd[1], cmd[2], cmd[3], cmd[4], cmd[5], cmd[6]); - break; - case 11: - ctx.moveTo(cmd[1], cmd[2]); - ctx.lineTo(cmd[3], cmd[4]); - break; - case 12: - ctx.rect(cmd[1], cmd[2], cmd[3], cmd[4]); - break; - case 13: - ctx.arc(cmd[1], cmd[2], cmd[3], cmd[4], cmd[5], cmd[6]); - break; - case 14: - ctx.stroke(); - break; - case 15: - ctx.fill(); - break; - case 16: - ctx.clip(); - break; - case 17: - if (cmd[3]) - for (j = 0; j < cmd[3].length; j += 2) - ctx.fillRect(cmd[3][j], cmd[3][j+1], cmd[1], cmd[2]); - break; - case 18: - ctx.drawImage(cmd[1], cmd[2], cmd[3]); - break; - case 19: - ctx.translate(cmd[1], cmd[2]); - break; - case 20: - ctx.rotate(cmd[1]); - break; - case 21: - ctx.scale(cmd[1], cmd[2]); - break; - case 22: - ctx.save(); - break; - case 23: - ctx.restore(); - break; - /*** Variables ***/ - case 24: - ctx.fillStyle = cmd[1]; - break; - case 25: - ctx.strokeStyle = cmd[1]; - break; - case 26: - ctx.globalAlpha = cmd[1]; - break; - case 27: - ctx.lineWidth = cmd[1]; - break; - case 28: - ctx.lineCap = cmd[1]; - break; - case 29: - ctx.lineJoin = cmd[1]; - break; - case 30: - ctx.miterLimit = cmd[1]; - break; - case 31: - ctx.globalCompositeOperation = cmd[1]; - break; - } - } - } + renderCanvas(ele, plio(new Uint8Array(req.response))); if (y) while (ele = ele.parentNode) { if (ele.tagName == "FORM") { post(ele, false, null, null); break; } } // if (dly == 0) @@ -144,8 +33,131 @@ function drawCanvas(id, dly, x, y) { } try {req.send(null);} catch (e) { req.abort(); return true; } return false; } + +function renderCanvas(cvs, lst) { + var ctx = cvs.getContext("2d"); + var cmd, i, j; + + for (i = 0; i < lst.length; ++i) { + switch ((cmd = lst[i])[0]) { // Sync with "@lib/canvas.l" + /*** Functions ***/ + case 1: // (csFillText Str X Y) + ctx.fillText(cmd[1], cmd[2], cmd[3]); + break; + case 2: // (csStrokeLine X1 Y1 X2 Y2) + ctx.beginPath(); + ctx.moveTo(cmd[1], cmd[2]); + ctx.lineTo(cmd[3], cmd[4]); + ctx.closePath(); + ctx.stroke(); + break; + case 3: // (csClearRect X Y DX DY) + ctx.clearRect(cmd[1], cmd[2], cmd[3], cmd[4]); + break; + case 4: // (csStrokeRect X Y DX DY) + ctx.strokeRect(cmd[1], cmd[2], cmd[3], cmd[4]); + break; + case 5: // (csFillRect X Y DX DY) + ctx.fillRect(cmd[1], cmd[2], cmd[3], cmd[4]); + break; + case 6: // (csBeginPath) + ctx.beginPath(); + break; + case 7: // (csClosePath) + ctx.closePath(); + break; + case 8: // (csMoveTo X Y) + ctx.moveTo(cmd[1], cmd[2]); + break; + case 9: // (csLineTo X Y) + ctx.lineTo(cmd[1], cmd[2]); + break; + case 10: // (csBezierCurveTo X1 Y1 X2 Y2 X Y) + ctx.bezierCurveTo(cmd[1], cmd[2], cmd[3], cmd[4], cmd[5], cmd[6]); + break; + case 11: // (csLine X1 Y1 X2 Y2) + ctx.moveTo(cmd[1], cmd[2]); + ctx.lineTo(cmd[3], cmd[4]); + break; + case 12: // (csRect X Y DX DY) + ctx.rect(cmd[1], cmd[2], cmd[3], cmd[4]); + break; + case 13: // (csArc X Y R A B F) + ctx.arc(cmd[1], cmd[2], cmd[3], cmd[4], cmd[5], cmd[6]); + break; + case 14: // (csStroke) + ctx.stroke(); + break; + case 15: // (csFill) + ctx.fill(); + break; + case 16: // (csClip) + ctx.clip(); + break; + case 17: // (csDef Key DX DY Lst) + if (!cvs.pre) + cvs.pre = new Array(); + var buf = cvs.pre[cmd[1]] = document.createElement('canvas'); + buf.width = cmd[2]; + buf.height = cmd[3]; + renderCanvas(buf, cmd[4]); + break; + case 18: // (csDraw Key X Y) + ctx.drawImage(cvs.pre[cmd[1]], cmd[2], cmd[3]); + break; + case 19: // (csDrawDots DX DY Lst) + if (cmd[3]) + for (j = 0; j < cmd[3].length; j += 2) + ctx.fillRect(cmd[3][j], cmd[3][j+1], cmd[1], cmd[2]); + break; + case 20: // (csDrawImage Img X Y) + ctx.drawImage(cmd[1], cmd[2], cmd[3]); + break; + case 21: // (csTranslate X Y) + ctx.translate(cmd[1], cmd[2]); + break; + case 22: // (csRotate A) + ctx.rotate(cmd[1]); + break; + case 23: // (csScale X Y) + ctx.scale(cmd[1], cmd[2]); + break; + case 24: // (csSave) + ctx.save(); + break; + case 25: // (csRestore) + ctx.restore(); + break; + /*** Variables ***/ + case 26: // (csFillStyle V) + ctx.fillStyle = cmd[1]; + break; + case 27: // (csStrokeStyle V) + ctx.strokeStyle = cmd[1]; + break; + case 28: // (csGlobalAlpha V) + ctx.globalAlpha = cmd[1]; + break; + case 29: // (csLineWidth V) + ctx.lineWidth = cmd[1]; + break; + case 30: // (csLineCap V) + ctx.lineCap = cmd[1]; + break; + case 31: // (csLineJoin V) + ctx.lineJoin = cmd[1]; + break; + case 32: // (csMiterLimit V) + ctx.miterLimit = cmd[1]; + break; + case 33: // (csGlobalCompositeOperation V) ) + ctx.globalCompositeOperation = cmd[1]; + break; + } + } +} diff --git a/lib/canvas.l b/lib/canvas.l --- a/lib/canvas.l +++ b/lib/canvas.l @@ -1,9 +1,9 @@ -# 05nov13abu +# 04jan14abu # (c) Software Lab. Alexander Burger (allow "!jsDraw" ) (push1 '*JS (allow "@lib/plio.js") (allow "@lib/canvas.js")) # Canvas Commands (for (Opc . L) (quote # In sync with "@lib/canvas.js" @@ -19,16 +19,18 @@ (csLineTo X Y) (csBezierCurveTo X1 Y1 X2 Y2 X Y) (csLine X1 Y1 X2 Y2) (csRect X Y DX DY) (csArc X Y R A B F) (csStroke) (csFill) (csClip) + (csDef Key DX DY Lst) + (csDraw Key X Y) (csDrawDots DX DY Lst) (csDrawImage Img DX DY) (csTranslate X Y) (csRotate A) (csScale X Y) (csSave) (csRestore) ### Variables ### @@ -48,17 +50,17 @@ (cons 'list Opc @) (list Opc) ) ) ) ) ) (de (Id DX DY Alt) (prin "" Alt "" ) ) (de jsDraw (Id Dly X Y) (http1 "application/octet-stream" 0) (let Lst (drawCanvas Id Dly X Y) (prinl "Content-Length: " (bytes Lst) "^M^J^M") (pr Lst) ) ) debian/patches/series0000644000000000000000000000017012265537350012040 0ustar picolisp_fix_manpage.patch picolisp_build_on_multi_cpu.patch picolisp_fix_shbang_path.patch picolisp_sync_to_tip.patch debian/picolisp.doc-base0000644000000000000000000000050212265537350012414 0ustar Document: picolisp Title: The PicoLisp Reference Author: Software Lab. Alexander Burger Abstract: This document describes the concepts, data types, and kernel functions of the PicoLisp system. Section: Programming/Lisp Format: HTML Index: /usr/share/doc/picolisp/doc/index.html Files: /usr/share/doc/picolisp/doc/*.html debian/picolisp.docs0000644000000000000000000000003312265537350011666 0ustar README CREDITS doc/ doc64/ debian/picolisp.install0000644000000000000000000000240012265537350012404 0ustar bin/picolisp usr/bin bin/pil usr/bin img/* usr/share/picolisp/img loc/* usr/share/picolisp/loc lib/*.css usr/share/picolisp/lib lib/*.l usr/share/picolisp/lib lib/*.txt usr/share/picolisp/lib lib/*.js usr/share/picolisp/lib lib/*.ps usr/share/picolisp/lib lib/map usr/share/picolisp/lib lib/ext usr/lib/picolisp/bin lib/ht usr/lib/picolisp/bin lib/el/*.el usr/share/emacs/site-lisp/picolisp dbg.l usr/share/picolisp ext.l usr/share/picolisp lib.css usr/share/picolisp lib.l usr/share/picolisp test usr/share/picolisp bin/psh usr/lib/picolisp/bin bin/watchdog usr/lib/picolisp/bin bin/replica usr/lib/picolisp/bin bin/httpGate usr/lib/picolisp/bin bin/ssl usr/lib/picolisp/bin bin/lat1 usr/lib/picolisp/bin bin/utf2 usr/lib/picolisp/bin bin/balance usr/lib/picolisp/bin app usr/share/picolisp games usr/share/picolisp misc usr/share/picolisp debian/50picolisp.el etc/emacs/site-start.d debian/picolisp.links0000644000000000000000000000132612265537350012064 0ustar usr/lib/picolisp/bin/ext usr/share/picolisp/lib/ext usr/lib/picolisp/bin/ht usr/share/picolisp/lib/ht usr/share/doc/picolisp/doc usr/lib/picolisp/doc usr/share/doc/picolisp/doc64 usr/lib/picolisp/doc64 usr/share/picolisp/dbg.l usr/lib/picolisp/dbg.l usr/share/picolisp/ext.l usr/lib/picolisp/ext.l usr/share/picolisp/img usr/lib/picolisp/img usr/share/picolisp/lib usr/lib/picolisp/lib usr/share/picolisp/lib.css usr/lib/picolisp/lib.css usr/share/picolisp/lib.l usr/lib/picolisp/lib.l usr/share/picolisp/loc usr/lib/picolisp/loc usr/share/picolisp/src usr/lib/picolisp/src usr/share/picolisp/src64 usr/lib/picolisp/src64 usr/share/picolisp/test usr/lib/picolisp/test debian/picolisp.lintian-overrides0000644000000000000000000000006012265537350014374 0ustar picolisp: possible-gpl-code-linked-with-openssl debian/picolisp.maintscript0000644000000000000000000000067412265537350013306 0ustar dir_to_symlink /usr/lib/picolisp/test ../../share/picolisp/test 3.1.5.2-2~ dir_to_symlink /usr/lib/picolisp/src64 ../../share/picolisp/src64 3.1.5.2-2~ dir_to_symlink /usr/lib/picolisp/src ../../share/picolisp/src 3.1.5.2-2~ dir_to_symlink /usr/lib/picolisp/loc ../../share/picolisp/loc 3.1.5.2-2~ dir_to_symlink /usr/lib/picolisp/lib ../../share/picolisp/lib 3.1.5.2-2~ dir_to_symlink /usr/lib/picolisp/img ../../share/picolisp/img 3.1.5.2-2~ debian/picolisp.manpages0000644000000000000000000000004312265537350012532 0ustar man/man1/pil.1 man/man1/picolisp.1 debian/rules0000755000000000000000000000441212265537350010257 0ustar #!/usr/bin/make -f # -*- makefile -*- # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 DEB_HOST_ARCH_CPU := $(shell dpkg-architecture -qDEB_HOST_ARCH_CPU) DEB_HOST_ARCH_OS := $(shell dpkg-architecture -qDEB_HOST_ARCH_OS) include /usr/share/hardening-includes/hardening.make export CPPFLAGS=$(shell dpkg-buildflags --get CPPFLAGS) export CFLAGS=$(shell dpkg-buildflags --get CFLAGS) export LDFLAGS=$(shell dpkg-buildflags --get LDFLAGS) # PIE disabled on amd64 because it's mostly written in assembly and # already handles PIC when needed. The codes aren't compiled with # gcc so enable -fPIE is meaningless. CFLAGS_NO_PIE := $(CFLAGS) \ $(filter-out $(HARDENING_DISABLE_PIE_CFLAGS_FILTER),$(HARDENING_CFLAGS)) LDFLAGS_NO_PIE := $(LDFLAGS) \ $(filter-out $(HARDENING_DISABLE_PIE_LDFLAGS_FILTER),$(HARDENING_LDFLAGS)) CFLAGS += $(HARDENING_CFLAGS_PIC) \ $(filter-out $(HARDENING_DISABLE_PIE_CFLAGS_FILTER),$(HARDENING_CFLAGS)) \ $(HARDENING_CPPFLAGS) \ $(NULL) LDFLAGS += $(HARDENING_LDFLAGS) -Wl,-z,noexecstack override_dh_auto_build: chmod -x app/loc/no ifeq (amd64,$(DEB_HOST_ARCH_CPU)) mv src64/tags src64/tags.orig make -C src OS=Linux CPU=amd64 picolisp make -C src OS=Linux tools gate make -C src64 OS=Linux CFLAGS="$(CFLAGS_NO_PIE)" LDFLAGS="$(LDFLAGS_NO_PIE)" else make -C src OS=Linux CPU=$(DEB_HOST_ARCH_CPU) picolisp tools gate endif mkdir -p build/bash_completion.d cp lib/bash_completion build/bash_completion.d/pil # build time utilities -rm src64/sysdeps override_dh_auto_install: dh_install build/bash_completion.d/pil etc/bash_completion.d dh_install -X.o src usr/share/picolisp dh_install -X.o src64 usr/share/picolisp override_dh_auto_clean: make -C src clean make -C src64 clean -rm bin/ssl bin/httpGate bin/lat1 bin/utf2 bin/balance -mv src64/tags.orig src64/tags -rm -rf build override_dh_compress: dh_compress -X.l %: dh $@ VER?=3.0.7.1 get-orig-source: rm -rf picolisp-$(VER).orig hg clone https://picolisp.googlecode.com/hg/#v$(VER) picolisp-$(VER).orig rm -r picolisp-$(VER).orig/.hg picolisp-$(VER).orig/.hgtags GZIP=--best tar -cz --owner root --group root --mode a+rX \ -f picolisp_$(VER).orig.tar.gz \ picolisp-$(VER).orig rm -r picolisp-$(VER).orig debian/source/0000755000000000000000000000000012265537350010476 5ustar debian/source/format0000644000000000000000000000001412265537350011704 0ustar 3.0 (quilt) debian/source/include-binaries0000644000000000000000000000004512265537350013635 0ustar doc/family64.tgz ersatz/picolisp.jar debian/source/lintian-overrides0000644000000000000000000000014012265537350014052 0ustar picolisp source: unknown-architecture any-armel picolisp source: unknown-architecture any-armhf debian/watch0000644000000000000000000000007712265537350010233 0ustar version=3 http://software-lab.de/down.html picoLisp-(.*)\.tgz