Work around for the c-lang-defconst must be used in a file error when requiring or loading php-mode (and possibly drupal-mode, which inherits from php-mode)

This commit is contained in:
Kienan Stewart 2012-11-23 12:21:29 -05:00
parent e2c2b2cb14
commit ca732de852
1 changed files with 7 additions and 2 deletions

View File

@ -32,8 +32,13 @@
;;(pymacs-load "ropemacs" "rope-")
;; PHP and Drupal-Modes
(require 'php-mode)
(require 'drupal-mode)
;; http://stackoverflow.com/questions/898063/making-php-mode-and-other-cc-mode-derived-modes-compatible-with-emacs-23
;; Use autoload for php-mode and drupal-mode to avoid occasionaly errors on some
;; systems when loading from init. See the above question on stack overflow
(autoload 'php-mode "php-mode" "Major mode for editing php code." t)
(autoload 'drupal-mode "drupal-mode" "Major mode for editing drupal php files." t)
;(require 'php-mode)
;(require 'drupal-mode)
(add-to-list 'auto-mode-alist '("\\.\\(module\\|test\\|install\\|theme\\)$" . drupal-mode))
(add-to-list 'auto-mode-alist '("\\.\\(php\\|inc\\)$" . php-mode))
(add-to-list 'auto-mode-alist '("\\.info" . conf-windows-mode))