While Colmap itself is licensed with the permissive BSD license, the LSD dependency is AGPL. This basically means that any binary stemming from the codebase is AGPL as well, and thus cannot be used e.g. commercially. Other optional dependencies look okay (please correct me if I am wrong, e.g. CGAL can be turned off).
In this pull request I added the option to exclude LSD (similarly as can be done for CGAL). This affects the model_orientation_aligner module by removing the MANHATTAN-WORLD option.
The PR is related to issue #752. A possible alternative could be to use OpenCV solution (see the issue above and https://github.com/opencv/opencv/blob/2cd330486ec4597eab49c1575fc4a6603f205a6a/modules/imgproc/src/lsd.cpp#L167). OpenCV excluded this part for while, the re-added LSD after its crucial part https://github.com/rafael-grompone-von-gioi/binomial_nfa had been relincesed. I have also contacted the author of LSD (https://github.com/theWorldCreator/LSD) but got no response.