diff --git a/etc/fslconf/fsl-devel.sh b/etc/fslconf/fsl-devel.sh
index 586895decc29bb906960d0a2f5f984fc479f53c6..a17d2c12b6abf7389b4efa7b3edb1d802ae89493 100644
--- a/etc/fslconf/fsl-devel.sh
+++ b/etc/fslconf/fsl-devel.sh
@@ -1,13 +1,39 @@
 # FSL configuration file for developers
-#  - to be sourced by the user, typically in .bashrc or equivalent
 #
-# Written by Mark Jenkinson
-#  FMRIB Analysis Group, University of Oxford
+# This file must be sourced in order to compile
+# Makefile-based FSL projects.
+#
+# $FSLDIR must be set before this script is called.
+#
+# Standard environment configuration for developing FSL is:
+#   export FSLDIR=/usr/local/fsl
+#   source $FSLDIR/etc/fslconf/fsl-devel.sh
+#
 
 # SHBASECOPYRIGHT
 
-FSLCONFDIR=$FSLDIR/config
 
-export FSLCONFDIR
+# If this is an official (fslinstaller-installed)
+# FSL installation, we activate the $FSLDIR conda
+# environment so that we have access to its compiler
+# toolchain (if one is installed).
+if [ -e $FSLDIR/share/fsl/base_environment ]; then
+  baseenv=$(cat $FSLDIR/share/fsl/base_environment)
+  source $baseenv/bin/activate $FSLDIR
+fi
+
+# FSLCONFDIR contains the FSL Makefile machinery
+# for compiling and installing FSL Makefile-based
+# projects.
+if [ ! -d "$FSLCONFDIR" ]; then
+  export FSLCONFDIR=$FSLDIR/config
+fi
+
+# FSLDEVDIR is an optional installation destination
+# for development, so that locally built projects
+# can be installed separately from FSLDIR.
+if [ ! -d "$FSLDEVDIR" ]; then
+  export FSLDEVDIR=$FSLDIR
+fi
 
 source $FSLDIR/etc/fslconf/fsl.sh