er... sí que se puede. Lo único que te has de asegurar de que el contenido que llegue finalmente al navegador sea puro javascript con sintaxis correcta, pero se puede hacer un include js a un txt, asp, php ....
 
Podeis hacer esta prueba 
pagina1.html  
Código:
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>prueba</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<script type="text/javascript" src="pagina2.asp"></script>
<script type="text/javascript">
alert(pepe)
</script>
</head>
<body>
</body>
</html>
  pagina2.asp  
o probar con un pagina2.php que contenga un  
var pepe = "<?php echo "pepe"; ?>" 
y funciona perfectamente  
 
  
Es muy util para usar includes js que debe cargar datos externos, bien de ficheros o desde bases de datos