Create User Modules

Important Notes

Creating a User Module

After installing software in your $HOME directory as explained above (please read the important notes), and before using it, a user module file needs to be created. 

On Rider, all module files are written in Lua. You do not need to have programing experience with Lua to create a module file: we will use the template below.

Steps for installing the module

Please make sure that you read and follow carefully these instructions. Otherwise, your user module may not work.

We will use the following example:

Suppose that we have installed the software Bison with version 3.0.4. Then the installation directory would be:

/home/<case_ID>/.usr/local/bison/3.0.4

To use this version of Bison, we need to create the module file like this:

The module file should be ready for use.

If you want the software accessible to the group: 


Other Commands for Adapting the Module

The system version indicated here does not include this version of CXXABI_1.3.8, however, this library is present on the system in an updated version. To resolve the problem, the LD_LIBRARY_PATH variable needs to include a reference to the newer version. This can be accomplished by loading the gcc/6.3.0 module, or in the Intel hierarchy, loading 'base', and 'gcc/6' modules. Finally, then the user module file can be modified by means of the process listed above, that is:  load("base","gcc/6")

Alternatively, the LD_LIBRARY_PATH variable may be set in the modulefile to directly reference the library directory.

User Modulefile Template

-- -*- PKG_NAME Module File -*-

local pkgName = myModuleName()

local pkgVersion = myModuleVersion()

local pkgNameVer = myModuleFullName()

local base = pathJoin(os.getenv("HOME"),".usr/local", pkgNameVer)

whatis("Name: "..pkgName)

whatis("Version: "..pkgVersion)

whatis("Category: library,software")

whatis("Description: package description")

prepend_path("PATH",pathJoin(base,"bin"))

prepend_path("CPLUS_INCLUDE_PATH",pathJoin(base,"include"))

prepend_path("C_INCLUDE_PATH",pathJoin(base,"include"))

prepend_path("LD_LIBRARY_PATH",pathJoin(base,"lib"))

prepend_path("LIBRARY_PATH",pathJoin(base,"lib"))

prepend_path("PKG_CONFIG_PATH",pathJoin(base,"lib/pkgconfig"))

Issues or Questions ?

Contact us at hpc-supportATcase.edu