[MXS-305] Do not build packages into / with make package Created: 2015-08-10 Updated: 2015-09-17 Resolved: 2015-08-16 |
|
| Status: | Closed |
| Project: | MariaDB MaxScale |
| Component/s: | Core |
| Affects Version/s: | 1.2.0 |
| Fix Version/s: | 1.2.1 |
| Type: | Bug | Priority: | Minor |
| Reporter: | Simon J Mudd | Assignee: | markus makela |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Note: when building and trying to make a package I get this error: [smudd@localhost build]$ make package CMake Error at /home/smudd/github.com/mariadb-corporation/MaxScale/build/cmake_install.cmake:76 (FILE): CPack Error: Error when generating package: maxscale Note: how this is trying to build into root. I'm running as a non-root user and therefore this fails. When building packages you should be able to build into a "buildroot" and then install files relative to that directory. I've not looked at the package build process but this is obviously not being done. It pushes people to change to the root user which then populates/overwrites data in real directories which should not be done. Having build other rpm packages most other software allows for stuff to be built into a "buildroot" for package building and then the files are collected from there. The same process should happen here as otherwise doing make package is going to possibly destroy your running system. Given you've said you want to build this as a package the only way the files should be installed is with the package manager not via the cmake installer. |
| Comments |
| Comment by markus makela [ 2015-08-16 ] |
|
Fixed by setting the CPACK_SET_DESTDIR variable to true. This disables relocation of RPM packages but allows for non-root users to do packaging and prevents file installation during packaging. |