Skip to content

Commit

Permalink
build: consolidate PIC flags
Browse files Browse the repository at this point in the history
should fix X86_32 build

git-svn-id: http://svn.mythtv.org/svn/trunk@25598 7dbf422c-18fa-0310-86e9-fd20926502f2
  • Loading branch information
jannau committed Aug 9, 2010
1 parent 62d7b2c commit da7a7fe
Show file tree
Hide file tree
Showing 12 changed files with 6 additions and 26 deletions.
2 changes: 1 addition & 1 deletion mythtv/libs/libavcodec/libavcodec.pro
Expand Up @@ -25,7 +25,7 @@ debug:contains(ARCH_X86_32, yes) {
} }
# gcc-4.2 and newer can not compile with PIC on x86 # gcc-4.2 and newer can not compile with PIC on x86
contains(ARCH_X86_32, yes) { contains(ARCH_X86_32, yes) {
QMAKE_CFLAGS_SHLIB = QMAKE_CFLAGS -= -fPIC -DPIC
} }


!profile:QMAKE_CFLAGS_DEBUG += -O !profile:QMAKE_CFLAGS_DEBUG += -O
Expand Down
2 changes: 1 addition & 1 deletion mythtv/libs/libavutil/libavutil.pro
Expand Up @@ -16,7 +16,7 @@ DEFINES += HAVE_AV_CONFIG_H
# Debug mode on x86 must compile without -fPIC # Debug mode on x86 must compile without -fPIC
# otherwise gcc runs out of registers. # otherwise gcc runs out of registers.
debug:contains(ARCH_X86_32, yes) { debug:contains(ARCH_X86_32, yes) {
QMAKE_CFLAGS_SHLIB = QMAKE_CFLAGS -= -fPIC -DPIC
} }


QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2) QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2)
Expand Down
3 changes: 0 additions & 3 deletions mythtv/libs/libmythbluray/libmythbluray.pro
Expand Up @@ -10,9 +10,6 @@ INCLUDEPATH += . ../../
INCLUDEPATH += ./bdnav INCLUDEPATH += ./bdnav
INCLUDEPATH += ../libmythdb INCLUDEPATH += ../libmythdb


#build position independent code since the library is linked into a shared library
QMAKE_CFLAGS += -fPIC -DPIC

DEFINES += HAVE_CONFIG_H DLOPEN_CRYPTO_LIBS DEFINES += HAVE_CONFIG_H DLOPEN_CRYPTO_LIBS


# DEFINES += LOG_DEBUG TRACE # DEFINES += LOG_DEBUG TRACE
Expand Down
3 changes: 0 additions & 3 deletions mythtv/libs/libmythdvdnav/libmythdvdnav.pro
Expand Up @@ -10,9 +10,6 @@ INCLUDEPATH += . ../../
INCLUDEPATH += ./dvdnav INCLUDEPATH += ./dvdnav
INCLUDEPATH += ../libmythdb INCLUDEPATH += ../libmythdb


#build position independent code since the library is linked into a shared library
QMAKE_CFLAGS += -fPIC -DPIC

# for -ldl # for -ldl
LIBS += $$EXTRA_LIBS LIBS += $$EXTRA_LIBS


Expand Down
3 changes: 0 additions & 3 deletions mythtv/libs/libmythfreesurround/libmythfreesurround.pro
Expand Up @@ -6,9 +6,6 @@ CONFIG += thread staticlib warn_off


INCLUDEPATH += ../libavcodec ../libmythdb .. ../.. INCLUDEPATH += ../libavcodec ../libmythdb .. ../..


#build position independent code since the library is linked into a shared library
QMAKE_CXXFLAGS += -fPIC -DPIC

QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2) QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2)


# Input # Input
Expand Down
2 changes: 1 addition & 1 deletion mythtv/libs/libmythmpeg2/libmythmpeg2.pro
Expand Up @@ -6,7 +6,7 @@ CONFIG += thread staticlib warn_off
CONFIG -= qt CONFIG -= qt


#build position independent code since the library is linked into a shared library #build position independent code since the library is linked into a shared library
QMAKE_CFLAGS += -fPIC -DPIC -fno-common QMAKE_CFLAGS += -fno-common


QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2) QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2)


Expand Down
3 changes: 0 additions & 3 deletions mythtv/libs/libmythnvctrl/libmythnvctrl.pro
Expand Up @@ -7,9 +7,6 @@ CONFIG -= qt


INCLUDEPATH += ../ ../../ INCLUDEPATH += ../ ../../


#build position independent code since the library is linked into a shared library
QMAKE_CFLAGS += -fPIC -DPIC

DEFINES += HAVE_AV_CONFIG_H DEFINES += HAVE_AV_CONFIG_H


QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2) QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2)
Expand Down
3 changes: 0 additions & 3 deletions mythtv/libs/libmythsamplerate/libmythsamplerate.pro
Expand Up @@ -7,9 +7,6 @@ CONFIG -= qt


INCLUDEPATH += ../ ../../ INCLUDEPATH += ../ ../../


#build position independent code since the library is linked into a shared library
QMAKE_CFLAGS += -fPIC -DPIC

DEFINES += HAVE_AV_CONFIG_H DEFINES += HAVE_AV_CONFIG_H


QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2) QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2)
Expand Down
3 changes: 0 additions & 3 deletions mythtv/libs/libmythsoundtouch/libmythsoundtouch.pro
Expand Up @@ -7,9 +7,6 @@ CONFIG -= qt


INCLUDEPATH += ../../libs/libavcodec ../.. INCLUDEPATH += ../../libs/libavcodec ../..


#build position independent code since the library is linked into a shared library
QMAKE_CXXFLAGS += -fPIC -DPIC

# Like libavcodec, debug mode on x86 runs out of registers on some GCCs. # Like libavcodec, debug mode on x86 runs out of registers on some GCCs.
!profile:QMAKE_CXXFLAGS_DEBUG += -O !profile:QMAKE_CXXFLAGS_DEBUG += -O


Expand Down
3 changes: 2 additions & 1 deletion mythtv/libs/libpostproc/libpostproc.pro
Expand Up @@ -18,7 +18,8 @@ DEFINES += HAVE_AV_CONFIG_H
# Debug mode on x86 must compile without -fPIC # Debug mode on x86 must compile without -fPIC
# otherwise gcc runs out of registers. # otherwise gcc runs out of registers.
debug:contains(ARCH_X86_32, yes) { debug:contains(ARCH_X86_32, yes) {
QMAKE_CFLAGS_SHLIB = -O1 QMAKE_CFLAGS -= -fPIC -DPIC
QMAKE_CFLAGS += -O1
} }


QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2) QMAKE_CLEAN += $(TARGET) $(TARGETA) $(TARGETD) $(TARGET0) $(TARGET1) $(TARGET2)
Expand Down
2 changes: 1 addition & 1 deletion mythtv/libs/libswscale/libswscale.pro
Expand Up @@ -14,7 +14,7 @@ debug:contains(ARCH_X86_32, yes) {
} }
# gcc-4.2 and newer can not compile with PIC on x86 # gcc-4.2 and newer can not compile with PIC on x86
contains(ARCH_X86_32, yes) { contains(ARCH_X86_32, yes) {
QMAKE_CFLAGS_SHLIB = QMAKE_CFLAGS -= -fPIC -DPIC
} }




Expand Down
3 changes: 0 additions & 3 deletions mythtv/settings.pro
Expand Up @@ -92,9 +92,6 @@ profile:CONFIG += debug


QMAKE_CXXFLAGS += $$CONFIG_DIRECTFB_CXXFLAGS QMAKE_CXXFLAGS += $$CONFIG_DIRECTFB_CXXFLAGS


QMAKE_CFLAGS_SHLIB = -DPIC -fPIC
QMAKE_CXXFLAGS_SHLIB = -DPIC -fPIC

# Allow compilation with Qt Embedded, if Qt is compiled without "-fno-rtti" # Allow compilation with Qt Embedded, if Qt is compiled without "-fno-rtti"
QMAKE_CXXFLAGS -= -fno-exceptions -fno-rtti QMAKE_CXXFLAGS -= -fno-exceptions -fno-rtti


Expand Down

0 comments on commit da7a7fe

Please sign in to comment.