+;;; Make certain variables equivalent to coding-system aliases
+(defun dontusethis-set-value-file-name-coding-system-handler (sym args fun harg handlers)
+ (define-coding-system-alias 'file-name (or (car args) 'binary)))
+
+(dontusethis-set-symbol-value-handler
+ 'file-name-coding-system
+ 'set-value
+ 'dontusethis-set-value-file-name-coding-system-handler)
+
+(defun dontusethis-set-value-terminal-coding-system-handler (sym args fun harg handlers)
+ (define-coding-system-alias 'terminal (or (car args) 'binary)))
+
+(dontusethis-set-symbol-value-handler
+ 'terminal-coding-system
+ 'set-value
+ 'dontusethis-set-value-terminal-coding-system-handler)
+
+(defun dontusethis-set-value-keyboard-coding-system-handler (sym args fun harg handlers)
+ (define-coding-system-alias 'keyboard (or (car args) 'binary)))
+
+(dontusethis-set-symbol-value-handler
+ 'keyboard-coding-system
+ 'set-value
+ 'dontusethis-set-value-keyboard-coding-system-handler)
+
+(unless (boundp 'file-name-coding-system)
+ (setq file-name-coding-system nil))
+
+(when (not (featurep 'mule))
+ ;; these are so that gnus and friends work when not mule
+ (copy-coding-system 'undecided 'iso-8859-1)
+ (copy-coding-system 'undecided 'iso-8859-2)
+
+ (define-coding-system-alias 'ctext 'binary))
+