[CMAKE]: Make the default install prefix be /usr/local
Signed-off-by: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
This commit is contained in:
parent
bd4e74162c
commit
19ca955ec6
|
@ -21,7 +21,7 @@ set(CMAKE_BUILD_TYPE debug)
|
|||
|
||||
find_package(DWARF REQUIRED)
|
||||
|
||||
_set_fancy(LIB_INSTALL_DIR "${EXEC_INSTALL_PREFIX}/usr/${__LIB}" "libdir")
|
||||
_set_fancy(LIB_INSTALL_DIR "${EXEC_INSTALL_PREFIX}${CMAKE_INSTALL_PREFIX}/${__LIB}" "libdir")
|
||||
|
||||
set(dwarves_LIB_SRCS dwarves.c)
|
||||
add_library(dwarves SHARED ${dwarves_LIB_SRCS})
|
||||
|
@ -61,10 +61,11 @@ add_executable(prefcnt ${prefcnt_SRCS})
|
|||
target_link_libraries(prefcnt dwarves)
|
||||
|
||||
install(TARGETS codiff ctracer dtagnames pahole pdwtags
|
||||
pfunct pglobal prefcnt RUNTIME DESTINATION /usr/bin)
|
||||
pfunct pglobal prefcnt RUNTIME DESTINATION
|
||||
${CMAKE_INSTALL_PREFIX}/bin)
|
||||
install(TARGETS dwarves LIBRARY DESTINATION ${LIB_INSTALL_DIR})
|
||||
install(FILES dwarves.h DESTINATION /usr/include)
|
||||
install(FILES ostra/ostra-cg DESTINATION /usr/bin)
|
||||
install(FILES dwarves.h DESTINATION ${CMAKE_INSTALL_PREFIX}/include)
|
||||
install(FILES ostra/ostra-cg DESTINATION ${CMAKE_INSTALL_PREFIX}/bin)
|
||||
install(FILES ostra/python/ostra.py DESTINATION ${LIB_INSTALL_DIR}/ctracer/python)
|
||||
install(FILES lib/Makefile lib/ctracer_jprobe.c
|
||||
lib/ctracer_relay.c lib/ctracer_relay.h
|
||||
|
|
12
README
12
README
|
@ -3,8 +3,11 @@ Build instructions:
|
|||
1. install cmake
|
||||
2. mkdir build
|
||||
3. cd build
|
||||
4. cmake ..
|
||||
5. make
|
||||
4. cmake -D__LIB=lib ..
|
||||
5. make install
|
||||
|
||||
Default is to be installed on /usr/local, see rpm spec file for
|
||||
installing on other places.
|
||||
|
||||
Known to work scenarios:
|
||||
|
||||
|
@ -17,3 +20,8 @@ Debian Unstable:
|
|||
|
||||
cmake 2.4.5-1
|
||||
libdw-dev 0.123-2
|
||||
|
||||
Fedora Core 6:
|
||||
|
||||
cmake 2.4.5-2.fc6
|
||||
elfutils-devel 0.126-1.fc6
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
Name: dwarves
|
||||
Version: 0
|
||||
Release: 18
|
||||
Release: 19
|
||||
License: GPL
|
||||
Summary: Dwarf Tools
|
||||
Group: Base
|
||||
|
@ -48,7 +48,7 @@ DWARF processing library development files
|
|||
%setup -q -c -n %{name}-%{version}
|
||||
|
||||
%build
|
||||
cmake -D __LIB=%{_lib} .
|
||||
cmake -D__LIB=%{_lib} -DCMAKE_INSTALL_PREFIX=/usr .
|
||||
make
|
||||
|
||||
%install
|
||||
|
|
Loading…
Reference in New Issue