Skip to content
This repository was archived by the owner on Jun 9, 2022. It is now read-only.

Commit b452123

Browse files
author
syb0rg
committed
Make code position independent
1 parent 7ddab2c commit b452123

File tree

5 files changed

+11
-5
lines changed

5 files changed

+11
-5
lines changed

src/libsphinxad/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,5 @@ if (ALSA_FOUND)
2828
set(LIBS ${ALSA_LIBRARIES} CACHE INTERNAL "libs")
2929
endif()
3030

31-
add_library(libsphinxad OBJECT ${SOURCES})
31+
add_library(libsphinxad OBJECT ${SOURCES})
32+
set_property(TARGET libsphinxad PROPERTY POSITION_INDEPENDENT_CODE TRUE)

src/libsphinxbase/fe/CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,6 @@ SET(SOURCES fe_interface.c
1818
yin.c
1919
)
2020

21-
add_library(fe OBJECT ${SOURCES})
21+
add_library(fe OBJECT ${SOURCES})
22+
23+
set_property(TARGET fe PROPERTY POSITION_INDEPENDENT_CODE TRUE)

src/libsphinxbase/feat/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,5 @@ SET(SOURCES agc.c
55
lda.c
66
)
77

8-
add_library(feat OBJECT ${SOURCES})
8+
add_library(feat OBJECT ${SOURCES})
9+
set_property(TARGET feat PROPERTY POSITION_INDEPENDENT_CODE TRUE)

src/libsphinxbase/lm/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,5 @@ SET(SOURCES fsg_model.c
1010
ngrams_raw.c
1111
)
1212

13-
add_library(lm OBJECT ${SOURCES})
13+
add_library(lm OBJECT ${SOURCES})
14+
set_property(TARGET lm PROPERTY POSITION_INDEPENDENT_CODE TRUE)

src/libsphinxbase/util/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,4 +30,5 @@ if (WIN32)
3030
set(SOURCES ${SOURCES} errno.c)
3131
endif ()
3232

33-
add_library(util OBJECT ${SOURCES})
33+
add_library(util OBJECT ${SOURCES})
34+
set_property(TARGET util PROPERTY POSITION_INDEPENDENT_CODE TRUE)

0 commit comments

Comments
 (0)