Skip to content

Commit

Permalink
[server] separated usocket-server system; re-depend on portable-threa…
Browse files Browse the repository at this point in the history
…ds (server only) & split-sequence.
  • Loading branch information
binghe committed Oct 25, 2016
1 parent 72e478c commit a2b021b
Show file tree
Hide file tree
Showing 7 changed files with 22 additions and 339 deletions.
2 changes: 1 addition & 1 deletion CHANGES
Original file line number Diff line number Diff line change
Expand Up @@ -109,4 +109,4 @@
[TODO]

* New feature: CLISP support some advanced TCP features which CLISP's SOCKET interface not provide
* New feature: SOCKET-SHUTDOWN for TCP and UDP sockets.

4 changes: 2 additions & 2 deletions package.lisp
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
;;;; See the LICENSE file for licensing information.

(defpackage :usocket
(:use :common-lisp #+abcl :java)
(:use :common-lisp #+abcl :java
:split-sequence)
(:export #:*version*
#:*wildcard-host*
#:*auto-port*
Expand All @@ -25,7 +26,6 @@

#:socket-send ; udp function (send)
#:socket-receive ; udp function (receive)
#:socket-server ; udp server
#:socket-option ; 0.6.x

#:wait-for-input ; waiting for input-ready state (select() like)
Expand Down
7 changes: 4 additions & 3 deletions server.lisp
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
;;;; $Id$
;;;; $URL$

(in-package :usocket)

(eval-when (:compile-toplevel :load-toplevel :execute)
(use-package :portable-threads)
(export 'socket-server))

(defun socket-server (host port function &optional arguments
&key in-new-thread (protocol :stream)
;; for udp
Expand Down
3 changes: 0 additions & 3 deletions test/package.lisp
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
;;;; $Id$
;;;; $URL$

;;;; See the LICENSE file for licensing information.

(in-package :cl-user)
Expand Down
22 changes: 15 additions & 7 deletions usocket.asd
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,18 @@
;;;; See the LICENSE file for licensing information.

(defsystem usocket
:name "usocket"
:name "usocket (client)"
:author "Erik Enge & Erik Huelsmann"
:maintainer "Chun Tian (binghe) & Hans Huebner"
:version "0.6.6-dev"
:licence "MIT"
:description "Universal socket library for Common Lisp"
:depends-on (#+(or sbcl ecl) :sb-bsd-sockets)
:depends-on (#+(or sbcl ecl) :sb-bsd-sockets
:split-sequence)
:components ((:file "package")
(:module "vendor" :depends-on ("package")
:components (#+mcl (:file "kqueue")
#+mcl (:file "OpenTransportUDP")
(:file "spawn-thread")
(:file "split-sequence")))
#+mcl (:file "OpenTransportUDP")))
(:file "usocket" :depends-on ("vendor"))
(:file "condition" :depends-on ("usocket"))
(:module "backend" :depends-on ("condition")
Expand All @@ -32,9 +31,18 @@
#+openmcl (:file "openmcl")
#+(or ecl sbcl) (:file "sbcl")
#+scl (:file "scl")))
(:file "option" :depends-on ("backend"))
(:file "server" :depends-on ("backend" "option"))))
(:file "option" :depends-on ("backend"))))

(defsystem usocket-server
:name "usocket (server)"
:author "Chun Tian (binghe)"
:version "1.0"
:licence "MIT"
:description "Universal socket library for Common Lisp (server side)"
:depends-on (:usocket :portable-threads)
:components ((:file "server")))

(defmethod perform ((op test-op) (c (eql (find-system :usocket))))
(oos 'load-op :usocket-server)
(oos 'load-op :usocket-test)
(oos 'test-op :usocket-test))
78 changes: 0 additions & 78 deletions vendor/spawn-thread.lisp

This file was deleted.

Loading

0 comments on commit a2b021b

Please sign in to comment.