Ticket #6 (closed enhancement: fixed)
Patch which allow to build out of source tree
| Reported by: | jet | Owned by: | |
|---|---|---|---|
| Priority: | major | Keywords: | |
| Cc: |
Description
Patch which allows to build crtmpserver out of source tree (out of crtmpserver/builders/cmake)
Attachments
Change History
Changed 18 months ago by jet
-
attachment
CMakeLists.txt.patch
added
comment:1 Changed 16 months ago by shiretu
- Status changed from new to closed
- Resolution set to wontfix
I have created scripts for packaging the binaries for various operating systems. Location is:
builders/cmake/packing
The most important thing inside those scripts is the -rpath inside the libraries. It will be location independent so you can copy the resulted distribution on a clean (production, no devel tools) server in any location you want.
comment:2 Changed 16 months ago by jet
But if we want to use some IDE like kdevelop we can't use it cause IDE can not process command "cmake" due to LUA libs not found. Anyway in cmake style we must build project in separated dir then source dir. So tipically we must create directory "build" (or something like this) "cd" to it and run "cmake ../". In this way lua defines not found cause path in "builders/cmake/CMakeLists.txt" is absolute-relative.
comment:3 Changed 16 months ago by shiretu
- Status changed from closed to reopened
- Resolution wontfix deleted
In that case, I will try to apply that patch only if it doesn't interfere with other stuff.
Ticket will be re-opened
comment:4 Changed 16 months ago by jet
Most of all, I want to draw your attention to next error(while try to rebuild defines):
jet@fame:~/work/original-rtmpd/builders/cmake$ mkdir build jet@fame:~/work/original-rtmpd/builders/cmake$ cd build/ jet@fame:~/work/original-rtmpd/builders/cmake/build$ cmake ../ -- The C compiler identification is GNU -- The CXX compiler identification is GNU -- Check for working C compiler: /usr/bin/gcc -- Check for working C compiler: /usr/bin/gcc -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working CXX compiler: /usr/bin/c++ -- Check for working CXX compiler: /usr/bin/c++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Looking for openssl headers - found -- Looking for openssl library - found -- Looking for crypto library - found -- Looking for dl -- Looking for libdl headers - found -- Looking for libdl library - found -- We have support for precompiled headers -- Check if the system is big endian -- Searching 16 bit integer -- Looking for sys/types.h -- Looking for sys/types.h - found -- Looking for stdint.h -- Looking for stdint.h - found -- Looking for stddef.h -- Looking for stddef.h - found -- Check size of unsigned short -- Check size of unsigned short - done -- Using unsigned short -- Check if the system is big endian - little endian -- We have a Linux-2.6.32-5-amd64 system -- We need to rebuild the defines lua: cannot open ../../constants/constants.lua: No such file or directory -- Configuring done -- Generating done -- Build files have been written to: /home/jet/work/original-rtmpd/builders/cmake/build jet@fame:~/work/original-rtmpd/builders/cmake/build$
In patch path to constants.lua is made source-tree relative, and also some absolute pathes is made relative to source-tree (I mean cmake constant src dir)

patch to CMakeLists.txt