Ticket #5270: runprefix.5.patch
File runprefix.5.patch, 8.2 KB (added by , 16 years ago) |
---|
-
configure
181 181 echo "" 182 182 echo " --enable-mac-bundle produce standalone OS X apps (e.g. mythfrontend.app)" 183 183 echo "" 184 echo " --runtime-prefix=PREFIX prefix to be used at runtime" 185 echo " (e.g. .. or /myth/latest)" 184 186 echo " --with-bindings=LIST install the bindings specified in the" 185 187 echo " comma-separated list" 186 188 echo " Supported bindings: perl, python" … … 1160 1162 CONFIG_DEFINES="" 1161 1163 CONFIG_INCLUDEPATH="" 1162 1164 PROFILEFLAGS="" 1165 RUNPREFIX=$PREFIX 1163 1166 audio_alsa="default" 1164 1167 audio_alsa_libs="-lasound" 1165 1168 audio_arts="default" … … 1395 1398 ;; 1396 1399 --enable-mac-bundle) enable mac_bundle 1397 1400 ;; 1401 --runtime-prefix=*) RUNPREFIX="$optval" 1402 ;; 1398 1403 --previous|--prev) 1399 1404 echo "No history of previous configure parameters." 1400 1405 ;; … … 2889 2894 echo "DistCC $distcc$distcc_txt" 2890 2895 echo "qmake $(which $qmake)" 2891 2896 echo "install prefix $PREFIX" 2897 echo "runtime prefix $RUNPREFIX" 2892 2898 <<BLOCK_QUOTE 2893 2899 echo "source path $source_path" 2894 2900 echo "C compiler $cc" … … 3075 3081 echo "#define FFMPEG_CONFIG_H" >> $TMPH 3076 3082 echo "#define FFMPEG_CONFIGURATION \"$FFMPEG_CONFIGURATION\"" >> $TMPH 3077 3083 3084 echo "RUNPREFIX=$RUNPREFIX" >> $MYTH_CONFIG_MAK 3078 3085 echo "PREFIX=$PREFIX" >> $MYTH_CONFIG_MAK 3079 3086 echo "LIBDIR=$libdir" >> $MYTH_CONFIG_MAK 3080 3087 <<BLOCK_QUOTE -
settings.pro
90 90 DEFINES += _GNU_SOURCE 91 91 DEFINES += _FILE_OFFSET_BITS=64 92 92 DEFINES += PREFIX=\\\"$${PREFIX}\\\" 93 DEFINES += LIBDIR=\\\"$${LIBDIR}\\\"94 93 95 94 # construct linking path 96 95 LOCAL_LIBDIR_X11 = -
docs/doxygen-architecture-document.cpp
525 525 <ol> 526 526 <li>GetInstallPrefix() returns the value of MCP's m_installprefix variable, 527 527 which is either the runtime env. var. $MYTHTVDIR or the compile-time var. 528 PREFIX. If these are relative paths, it is initialised relative to the528 RUNPREFIX. If these are relative paths, it is initialised relative to the 529 529 binary location. The value is used thus: 530 530 <ul> 531 531 <li>GetInstallPrefix() + /share/mythtv/ = GetShareDir(), GetFontsDir()</li> … … 542 542 <li>GetInstallPrefix() + /bin/ignyte</li> 543 543 <li>GetInstallPrefix() + /bin/mythfilldatabase</li> 544 544 <li>GetInstallPrefix() + /bin/mtd</li> 545 <li>GetInstallPrefix() + /lib/mythtv/ = GetLibraryDir()</li> 546 <li>GetInstallPrefix() + /lib/mythtv/plugins/ = GetPluginsDir()</li> 547 <li>GetInstallPrefix() + /lib/mythtv/filters/ = GetFiltersDir()</li> 545 548 </ul></li> 546 549 547 <li>GetLibraryDir() returns the value of MCP's m_installlibdir variable,548 which is always the LIBDIR compile-time var. Its value is only used for:549 <ul>550 <li>GetLibraryDir() + plugins/ = GetPluginsDir()</li>551 <li>GetLibraryDir() + filters/ = GetFiltersDir()</li>552 </ul></li>553 554 550 <li>GetConfDir() returns the value of the runtime env. var. $MYTHCONFDIR, 555 551 or $HOME/.mythtv.</li> 556 552 -
libs/libmyth/libmyth.pro
1 1 include ( ../../config.mak ) 2 2 include ( ../../settings.pro ) 3 3 4 isEmpty( LIBDIR ) { 5 LIBDIR = $${PREFIX}/lib 6 } 7 4 8 TEMPLATE = lib 5 9 TARGET = myth-$$LIBVERSION 6 10 CONFIG += thread dll … … 85 89 inc2.files = $${inc.files} 86 90 87 91 92 isEmpty( PREFIX ) { 93 PREFIX = /usr/local 94 } 95 isEmpty( RUNPREFIX ) { 96 RUNPREFIX = $$PREFIX 97 } 98 DEFINES += PREFIX=\"$${PREFIX}\" 99 DEFINES += RUNPREFIX=\"$${RUNPREFIX}\" 100 88 101 using_oss { 89 102 DEFINES += USING_OSS 90 103 SOURCES += audiooutputoss.cpp -
libs/libmyth/mythcontext.cpp
221 221 Settings *m_settings; ///< connection stuff, theme, button style 222 222 Settings *m_qtThemeSettings; ///< everything else theme-related 223 223 224 QString m_installprefix; ///< Compile-time PREFIX, or generated224 QString m_installprefix; ///< Compile-time RUNPREFIX, or generated 225 225 ///< from enviroment ($MYTHTVDIR or $cwd) 226 QString m_installlibdir; ///< Compile-time LIBDIR, or generated227 226 228 227 bool m_gui; ///< Should this context use GUI elements? 229 228 bool m_backend; ///< Is this host any sort of backend? … … 314 313 MythContextPrivate::MythContextPrivate(MythContext *lparent) 315 314 : parent(lparent), 316 315 m_settings(new Settings()), m_qtThemeSettings(new Settings()), 317 m_installprefix( PREFIX), m_installlibdir(LIBDIR),316 m_installprefix(RUNPREFIX), 318 317 m_gui(false), m_backend(false), m_themeloaded(false), 319 318 m_menuthemepathname(QString::null), m_themepathname(QString::null), 320 319 m_backgroundimage(NULL), … … 354 353 // executable directory. This can be fragile on Unix, so 355 354 // use relative PREFIX values with care. 356 355 357 VERBOSE(VB_IMPORTANT+VB_EXTRA, 358 "Relative PREFIX!\nappDir=" + prefixDir.canonicalPath() + 359 "\nprefix=" + m_installprefix + ", libdir=" + m_installlibdir); 356 VERBOSE(VB_IMPORTANT+VB_EXTRA, "Relative PREFIX!\nappDir=" + 357 prefixDir.canonicalPath() + "\nprefix=" + m_installprefix); 360 358 prefixDir.cd(m_installprefix); 361 359 m_installprefix = prefixDir.canonicalPath(); 362 363 // Not strictly necessary, but it tidies up the path:364 if (QDir(m_installlibdir).isRelative())365 {366 prefixDir = qApp->applicationDirPath();367 prefixDir.cd(m_installlibdir);368 m_installlibdir = prefixDir.canonicalPath();369 }370 360 } 371 else if (prefixDir.path().contains(".app/Contents/MacOS"))372 {373 prefixDir.cd("../Resources");374 if (QDir(prefixDir.canonicalPath() + "/bin").exists() ||375 QDir(prefixDir.canonicalPath() + "/share").exists())376 m_installprefix = prefixDir.canonicalPath();377 if (QDir(prefixDir.canonicalPath() + "/lib").exists())378 m_installlibdir = prefixDir.canonicalPath() + "/lib";379 }380 361 381 VERBOSE(VB_IMPORTANT, QString("Using runtime prefix = %1, libdir = %2") 382 .arg(m_installprefix).arg(m_installlibdir)); 362 VERBOSE(VB_IMPORTANT, "Using runtime prefix = " + m_installprefix); 383 363 } 384 364 385 365 MythContextPrivate::~MythContextPrivate() … … 1945 1925 1946 1926 QString MythContext::GetLibraryDir(void) 1947 1927 { 1948 return d->m_install libdir + "/mythtv/";1928 return d->m_installprefix + "/lib/mythtv/"; 1949 1929 } 1950 1930 1951 1931 QString MythContext::GetThemesParentDir(void) -
contrib/OSX/build/osx-packager.pl
483 483 'mythtv' 484 484 => [ 485 485 '--prefix=' . $PREFIX, 486 '--runtime-prefix=../Resources', 486 487 # To "cross compile" something for a lesser Mac: 487 488 #'--tune=G3', 488 489 #'--disable-altivec', -
contrib/Win32/build/win32-packager.pl
965 965 [ file => $mythtv.'mythtv/Makefile', 966 966 shell => ['source '.$unixmythtv.'qt'.$qtver.'_env.sh', 967 967 'cd '.$unixmythtv.'mythtv', 968 './configure --prefix='.$unixbuild. 968 './configure --prefix='.$unixbuild.' --runtime-prefix=..'. 969 969 ' --disable-dbox2 --disable-hdhomerun'. 970 970 ' --disable-iptv --disable-joystick-menu --disable-xvmc-vld'. 971 971 ' --disable-xvmc --enable-directx'.