The Life of an xll
An Excel add-in is a dynamic-link library (.dll) that contains some well-known functions. If you rename the suffix to .xll it will show up in the Excel file open filter.
When Excel opens an .xll it calls LoadLibrary and GetProcAddress to find xlAutoOpen and then calls it. You can write your own xlAutoOpen to register functions with Excel but this library implements that for you. All you need to do is instanciate an xll::AddIn object that tells Excel how to call the C/C++ function that you implement.
You can also use xll::Auto<Open> to have your functions called as long as they take no arguments and return an int, just like xlAutoOpen.