From 400c8f50ac55fc560cd9a9e38a27bc09ff2ed43d Mon Sep 17 00:00:00 2001
From: Francois-Rene Rideau <tunes@google.com>
Date: Wed, 18 Nov 2015 16:14:42 -0500
Subject: [PATCH] Stop supporting old asdf/foo aliases for uiop.

A few are kept, for backward-compatibility with systems in quicklisp.
---
 uiop/backward-driver.lisp |  2 --
 uiop/common-lisp.lisp     |  9 +++++++--
 uiop/configuration.lisp   |  3 +--
 uiop/driver.lisp          |  8 ++++----
 uiop/filesystem.lisp      |  2 --
 uiop/image.lisp           |  2 --
 uiop/lisp-build.lisp      |  2 --
 uiop/os.lisp              |  2 --
 uiop/package.lisp         | 13 -------------
 uiop/pathname.lisp        |  3 +--
 uiop/run-program.lisp     |  3 +--
 uiop/stream.lisp          |  2 --
 uiop/utility.lisp         |  2 --
 13 files changed, 14 insertions(+), 39 deletions(-)

diff --git a/uiop/backward-driver.lisp b/uiop/backward-driver.lisp
index be93f840..3f4cd7c7 100644
--- a/uiop/backward-driver.lisp
+++ b/uiop/backward-driver.lisp
@@ -2,8 +2,6 @@
 ;;; Hacks for backward-compatibility of the driver
 
 (uiop/package:define-package :uiop/backward-driver
-  (:nicknames :asdf/backward-driver)
-  (:recycle :uiop/backward-driver :asdf/backward-driver :asdf)
   (:use :uiop/common-lisp :uiop/package :uiop/utility
    :uiop/pathname :uiop/stream :uiop/os :uiop/image
    :uiop/run-program :uiop/lisp-build :uiop/configuration)
diff --git a/uiop/common-lisp.lisp b/uiop/common-lisp.lisp
index 4df57ff1..cbfdfcb1 100644
--- a/uiop/common-lisp.lisp
+++ b/uiop/common-lisp.lisp
@@ -7,10 +7,9 @@
 ;;; from this package only common-lisp symbols are exported.
 
 (uiop/package:define-package :uiop/common-lisp
-  (:nicknames :uoip/cl :asdf/common-lisp :asdf/cl)
+  (:nicknames :uoip/cl)
   (:use :uiop/package)
   (:use-reexport #-genera :common-lisp #+genera :future-common-lisp)
-  (:recycle :uiop/common-lisp :uoip/cl :asdf/common-lisp :asdf/cl :asdf)
   #+allegro (:intern #:*acl-warn-save*)
   #+cormanlisp (:shadow #:user-homedir-pathname)
   #+cormanlisp
@@ -41,6 +40,12 @@
 
 #+allegro
 (eval-when (:load-toplevel :compile-toplevel :execute)
+  ;; We need to disable autoloading BEFORE any mention of package ASDF.
+  ;; In particular, there must NOT be a mention of package ASDF in the defpackage of this file
+  ;; or any previous file.
+  (setf excl::*autoload-package-name-alist*
+        (remove "asdf" excl::*autoload-package-name-alist*
+                :test 'equalp :key 'car))
   (defparameter *acl-warn-save*
     (when (boundp 'excl:*warn-on-nested-reader-conditionals*)
       excl:*warn-on-nested-reader-conditionals*))
diff --git a/uiop/configuration.lisp b/uiop/configuration.lisp
index 8541d5d8..a61a7ee9 100644
--- a/uiop/configuration.lisp
+++ b/uiop/configuration.lisp
@@ -2,8 +2,7 @@
 ;;;; Generic support for configuration files
 
 (uiop/package:define-package :uiop/configuration
-  (:nicknames :asdf/configuration)
-  (:recycle :uiop/configuration :asdf/configuration :asdf)
+  (:recycle :uiop/configuration :asdf/configuration) ;; necessary to upgrade from 2.27.
   (:use :uiop/common-lisp :uiop/utility
    :uiop/os :uiop/pathname :uiop/filesystem :uiop/stream :uiop/image :uiop/lisp-build)
   (:export
diff --git a/uiop/driver.lisp b/uiop/driver.lisp
index d0515282..51767bdf 100644
--- a/uiop/driver.lisp
+++ b/uiop/driver.lisp
@@ -2,7 +2,8 @@
 ;;;; Re-export all the functionality in UIOP
 
 (uiop/package:define-package :uiop/driver
-  (:nicknames :uiop :asdf/driver :asdf-driver :asdf-utils)
+  (:nicknames :uiop :asdf/driver) ;; asdf/driver is obsolete (uiop isn't);
+  ;; but asdf/driver is still used by swap-bytes, static-vectors.
   (:use :uiop/common-lisp)
    ;; NB: not reexporting uiop/common-lisp
    ;; which include all of CL with compatibility modifications on select platforms,
@@ -10,9 +11,8 @@
    ;; or :use (closer-common-lisp uiop), etc.
   (:use-reexport
    :uiop/package :uiop/utility
-   :uiop/os :uiop/pathname :uiop/stream :uiop/filesystem :uiop/image
-   :uiop/run-program :uiop/lisp-build
-   :uiop/configuration :uiop/backward-driver))
+   :uiop/os :uiop/pathname :uiop/filesystem :uiop/stream :uiop/image
+   :uiop/run-program :uiop/lisp-build :uiop/configuration :uiop/backward-driver))
 
 ;; Provide both lowercase and uppercase, to satisfy more people.
 (provide "uiop") (provide "UIOP")
diff --git a/uiop/filesystem.lisp b/uiop/filesystem.lisp
index 544ad0f9..5769c985 100644
--- a/uiop/filesystem.lisp
+++ b/uiop/filesystem.lisp
@@ -2,8 +2,6 @@
 ;;;; Portability layer around Common Lisp filesystem access
 
 (uiop/package:define-package :uiop/filesystem
-  (:nicknames :asdf/filesystem)
-  (:recycle :uiop/filesystem :asdf/pathname :asdf)
   (:use :uiop/common-lisp :uiop/package :uiop/utility :uiop/os :uiop/pathname)
   (:export
    ;; Native namestrings
diff --git a/uiop/image.lisp b/uiop/image.lisp
index 01b1bfa2..6b53acb0 100644
--- a/uiop/image.lisp
+++ b/uiop/image.lisp
@@ -2,8 +2,6 @@
 ;;;; Starting, Stopping, Dumping a Lisp image
 
 (uiop/package:define-package :uiop/image
-  (:nicknames :asdf/image)
-  (:recycle :uiop/image :asdf/image :xcvb-driver)
   (:use :uiop/common-lisp :uiop/package :uiop/utility :uiop/pathname :uiop/stream :uiop/os)
   (:export
    #:*image-dumped-p* #:raw-command-line-arguments #:*command-line-arguments*
diff --git a/uiop/lisp-build.lisp b/uiop/lisp-build.lisp
index 6a711250..892f7ae5 100644
--- a/uiop/lisp-build.lisp
+++ b/uiop/lisp-build.lisp
@@ -2,8 +2,6 @@
 ;;;; Support to build (compile and load) Lisp files
 
 (uiop/package:define-package :uiop/lisp-build
-  (:nicknames :asdf/lisp-build)
-  (:recycle :uiop/lisp-build :asdf/lisp-build :asdf)
   (:use :uiop/common-lisp :uiop/package :uiop/utility
    :uiop/os :uiop/pathname :uiop/filesystem :uiop/stream :uiop/image)
   (:export
diff --git a/uiop/os.lisp b/uiop/os.lisp
index 905d01ed..31e15837 100644
--- a/uiop/os.lisp
+++ b/uiop/os.lisp
@@ -2,8 +2,6 @@
 ;;;; Access to the Operating System
 
 (uiop/package:define-package :uiop/os
-  (:nicknames :asdf/os)
-  (:recycle :uiop/os :asdf/os :asdf)
   (:use :uiop/common-lisp :uiop/package :uiop/utility)
   (:export
    #:featurep #:os-unix-p #:os-macosx-p #:os-windows-p #:os-genera-p #:detect-os ;; features
diff --git a/uiop/package.lisp b/uiop/package.lisp
index cd713944..f4eecead 100644
--- a/uiop/package.lisp
+++ b/uiop/package.lisp
@@ -737,16 +737,3 @@ UNINTERN -- Remove symbols here from PACKAGE."
        #+(or clasp ecl gcl mkcl) (defpackage ,package (:use))
        (eval-when (:compile-toplevel :load-toplevel :execute)
          ,ensure-form))))
-
-;;;; Final tricks to keep various implementations happy.
-;; We want most such tricks in common-lisp.lisp,
-;; but these need to be done before the define-package form there,
-;; that we nevertheless want to be the very first form.
-(eval-when (:load-toplevel :compile-toplevel :execute)
-  #+allegro ;; We need to disable autoloading BEFORE any mention of package ASDF.
-  (setf excl::*autoload-package-name-alist*
-        (remove "asdf" excl::*autoload-package-name-alist*
-                :test 'equalp :key 'car)))
-
-;; Compatibility with whoever calls asdf/package
-(define-package :asdf/package (:use :cl :uiop/package) (:reexport :uiop/package))
diff --git a/uiop/pathname.lisp b/uiop/pathname.lisp
index 98129071..7ab75398 100644
--- a/uiop/pathname.lisp
+++ b/uiop/pathname.lisp
@@ -4,8 +4,7 @@
 ;; which all is necessary prior to any access the filesystem or environment.
 
 (uiop/package:define-package :uiop/pathname
-  (:nicknames :asdf/pathname)
-  (:recycle :uiop/pathname :asdf/pathname :asdf)
+  (:nicknames :asdf/pathname) ;; deprecated. Used by ceramic
   (:use :uiop/common-lisp :uiop/package :uiop/utility :uiop/os)
   (:export
    ;; Making and merging pathnames, portably
diff --git a/uiop/run-program.lisp b/uiop/run-program.lisp
index ef7b13e1..48cc2ef4 100644
--- a/uiop/run-program.lisp
+++ b/uiop/run-program.lisp
@@ -2,8 +2,7 @@
 ;;;; run-program initially from xcvb-driver.
 
 (uiop/package:define-package :uiop/run-program
-  (:nicknames :asdf/run-program)
-  (:recycle :uiop/run-program :asdf/run-program :xcvb-driver)
+  (:nicknames :asdf/run-program) ; OBSOLETE. Used by cl-sane, printv.
   (:use :uiop/common-lisp :uiop/package :uiop/utility
    :uiop/pathname :uiop/os :uiop/filesystem :uiop/stream)
   (:export
diff --git a/uiop/stream.lisp b/uiop/stream.lisp
index 70e3d261..71f83332 100644
--- a/uiop/stream.lisp
+++ b/uiop/stream.lisp
@@ -2,8 +2,6 @@
 ;;;; Utilities related to streams
 
 (uiop/package:define-package :uiop/stream
-  (:nicknames :asdf/stream)
-  (:recycle :uiop/stream :asdf/stream :asdf)
   (:use :uiop/common-lisp :uiop/package :uiop/utility :uiop/os :uiop/pathname :uiop/filesystem)
   (:export
    #:*default-stream-element-type*
diff --git a/uiop/utility.lisp b/uiop/utility.lisp
index c5bbe7fd..db3afc68 100644
--- a/uiop/utility.lisp
+++ b/uiop/utility.lisp
@@ -2,8 +2,6 @@
 ;;;; General Purpose Utilities for ASDF
 
 (uiop/package:define-package :uiop/utility
-  (:nicknames :asdf/utility)
-  (:recycle :uiop/utility :asdf/utility :asdf)
   (:use :uiop/common-lisp :uiop/package)
   ;; import and reexport a few things defined in :uiop/common-lisp
   (:import-from :uiop/common-lisp #:compatfmt #:loop* #:frob-substrings
-- 
GitLab