﻿<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ja">
	<id>https://wiki.blender.jp/index.php?action=history&amp;feed=atom&amp;title=Dev%3A2.5%2FSource%2FInstallation%2FUnix_FHS</id>
	<title>Dev:2.5/Source/Installation/Unix FHS - 版の履歴</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.blender.jp/index.php?action=history&amp;feed=atom&amp;title=Dev%3A2.5%2FSource%2FInstallation%2FUnix_FHS"/>
	<link rel="alternate" type="text/html" href="https://wiki.blender.jp/index.php?title=Dev:2.5/Source/Installation/Unix_FHS&amp;action=history"/>
	<updated>2026-06-02T03:16:12Z</updated>
	<subtitle>このウィキのこのページに関する変更履歴</subtitle>
	<generator>MediaWiki 1.31.0</generator>
	<entry>
		<id>https://wiki.blender.jp/index.php?title=Dev:2.5/Source/Installation/Unix_FHS&amp;diff=90669&amp;oldid=prev</id>
		<title>Yamyam: 1版 をインポートしました</title>
		<link rel="alternate" type="text/html" href="https://wiki.blender.jp/index.php?title=Dev:2.5/Source/Installation/Unix_FHS&amp;diff=90669&amp;oldid=prev"/>
		<updated>2018-06-28T18:43:26Z</updated>

		<summary type="html">&lt;p&gt;1版 をインポートしました&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;ja&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;← 古い版&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;2018年6月28日 (木) 18:43時点における版&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-notice&quot; lang=&quot;ja&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(相違点なし)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>Yamyam</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.blender.jp/index.php?title=Dev:2.5/Source/Installation/Unix_FHS&amp;diff=90668&amp;oldid=prev</id>
		<title>wiki&gt;Mindrones: moved Dev:2.5/Source/Unix FHS to Dev:2.5/Source/Installation/Unix FHS</title>
		<link rel="alternate" type="text/html" href="https://wiki.blender.jp/index.php?title=Dev:2.5/Source/Installation/Unix_FHS&amp;diff=90668&amp;oldid=prev"/>
		<updated>2010-04-21T16:09:26Z</updated>

		<summary type="html">&lt;p&gt;moved &lt;a href=&quot;/Dev:2.5/Source/Unix_FHS&quot; class=&quot;mw-redirect&quot; title=&quot;Dev:2.5/Source/Unix FHS&quot;&gt;Dev:2.5/Source/Unix FHS&lt;/a&gt; to &lt;a href=&quot;/Dev:2.5/Source/Installation/Unix_FHS&quot; title=&quot;Dev:2.5/Source/Installation/Unix FHS&quot;&gt;Dev:2.5/Source/Installation/Unix FHS&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;新規ページ&lt;/b&gt;&lt;/p&gt;&lt;div&gt;= Unix FHS =&lt;br /&gt;
&lt;br /&gt;
Blender 2.4x did not support a directory structure common on most unix installations, where application data files are stored in the user's home dir ~/.blender&lt;br /&gt;
&lt;br /&gt;
This page outlines how blender can fit into this filesystem layout while maintaining compatibility with a portable layout.&lt;br /&gt;
&lt;br /&gt;
* ~/.blender stays working, existing configurations wont need to change.&lt;br /&gt;
* An optional new DIR is defined for UNIX systems (not win/mac), for brevity will call it SYS-PATH&lt;br /&gt;
* This dir could be named as follows $PREFIX/share/blender/$VERSION&amp;lt;br&amp;gt;Eg.  /usr/local/share/blender/2.5&lt;br /&gt;
* When the SYS-PATH directory is found it will be used as the primary directory for scripts, language files, icons etc. (Otherwise ~/.blender will be used like it is now)&lt;br /&gt;
* Scripts scan SYS-PATH first (if it exists) then ~/.blender, other data files only use one path (SYS-PATH and fall back to ~/.blender)&amp;lt;br&amp;gt;. In most cases using data from both dirs at once is not needed, (you could conceivably want to access icon themes from ~/.blender &amp;amp; SYS-PATH, but don't think it's so important) However, scripts are an exception, On a typical linux package you'd have blender install all data files into /usr/share/blender/2.5 and then when users want to add their own scripts they can copy into /home/user/.blender/scripts.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Outcomes==&lt;br /&gt;
* improves out-of-box experience for users by not treating built-in files (eg, most of blender2.5s interface) as user settings/data.&lt;br /&gt;
* Less trouble to package blender (no scripts copying data to ~/.blender on startup).&lt;br /&gt;
* Keep support for existing &amp;quot;local&amp;quot; installs where blender can run without being installed.&lt;br /&gt;
* Packages will install all blender data in /usr/share/blender/2.5.x, casual users will not create a ~/.blender, however ~/.B.blend will still be saved into their home dir.&lt;br /&gt;
* Existing users who build and run blender don't need to change their configuration.&lt;br /&gt;
* Package managers upgrading blender will remove system scripts and replace with new ones, ~/.blender (if exists) is untouched.&lt;br /&gt;
&lt;br /&gt;
==Details==&lt;br /&gt;
* Use a compile time option, like ./configure --prefix=&amp;quot;/usr/local&amp;quot;&lt;br /&gt;
* $BLENDERPATH used like $PYTHONPATH, allow for non hard-coded SYS-PATH (Better for re-distribution where users don't install into /usr/share/.... etc., and don't copy scripts into ~/.blender). Typical usage this would not need setting.&lt;br /&gt;
* Can implement this as opt-in to initially, later can review making it default.&lt;br /&gt;
* adds an &amp;quot;install&amp;quot; target for cmake, scons uses the installation path.&lt;br /&gt;
&lt;br /&gt;
==Build Systems==&lt;br /&gt;
One problem with using the blender version number in the path is each build system needs to have the version number stored so the installation path can be made. Parsing the blender version is possible but not so nice.&lt;br /&gt;
&lt;br /&gt;
===CMake===&lt;br /&gt;
CMake creates a portable bundle initially, after this running &amp;quot;make install&amp;quot; will copy these files into the FHS directory structure on your system.&lt;br /&gt;
Running &amp;quot;make install&amp;quot; is still optional, the portable distribution will still run on its own.&lt;br /&gt;
&lt;br /&gt;
* CMAKE_INSTALL_PREFIX - the target path used for copying blender with &amp;quot;make install&amp;quot;.&amp;lt;br&amp;gt;eg. /usr, /usr/local, /opt/blender.&lt;br /&gt;
* BLENDER_VERSION - internal variable defined in CMakeLists.txt is used for creating the version string.&lt;br /&gt;
* WITH_INSTALL - must be enabled.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===SCons===&lt;br /&gt;
SCons needs to have WITH_BF_FHS enabled so running &amp;quot;scons&amp;quot; will create a unix layout in the BF_INSTALLDIR&lt;br /&gt;
eg:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;python&amp;quot;&amp;gt;&lt;br /&gt;
  scons WITH_BF_FHS=1 BF_INSTALLDIR=&amp;quot;/usr/local&amp;quot;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* BF_INSTALLDIR - the target path used for copying blender.&amp;lt;br&amp;gt;eg. /usr, /usr/local, /opt/blender.&amp;lt;br&amp;gt;Note that this path is normally set relative to blenders directory.&lt;br /&gt;
* WITH_BF_FHS boolean option enabled a FHS layout,&amp;lt;br&amp;gt;When enabled $BF_INSTALLDIR/bin/blender and BF_INSTALLDIR/share/2.5 will be used.&lt;br /&gt;
* BF_VERSION internal variable defined in ./tools/btools.py, used to make the version string.&lt;br /&gt;
* WITHOUT_BF_INSTALL must be disabled.&lt;br /&gt;
&lt;br /&gt;
===Make===&lt;br /&gt;
(TODO)&lt;br /&gt;
&lt;br /&gt;
==Implementation==&lt;br /&gt;
===BLENDERPATH===&lt;br /&gt;
* creator.c has a static variable called blender_path which is defined by the build system, as... $BLENDERPATH/share/$VERSION and can replace ~/.blender&lt;br /&gt;
&lt;br /&gt;
===BLI_gethome_folder===&lt;br /&gt;
* BLI_gethome_folder(folder, '''flag'''), The flag argument can be...&lt;br /&gt;
** BLI_GETHOME_LOCAL		relative location for portable binaries&lt;br /&gt;
** BLI_GETHOME_SYSTEM		fixed system location, or set from the BLENDERPATH env variable (UNIX only)&lt;br /&gt;
** BLI_GETHOME_USER		home folder ~/.blender&lt;br /&gt;
** BLI_GETHOME_ALL		All paths, order of checking is local, system and user&lt;br /&gt;
&lt;br /&gt;
===Scripts===&lt;br /&gt;
Scripts are currently searched for in 2 folders&lt;br /&gt;
* First over the system data path (BLENDERPATH, using BLI_GETHOME_SYSTEM)&lt;br /&gt;
* Second over LOCAL/USER script folders (whichever is found first)&lt;br /&gt;
&lt;br /&gt;
This means one of 2 configurations is found...&lt;br /&gt;
* local+user scripts OR...&lt;br /&gt;
* system+user scripts&lt;br /&gt;
&lt;br /&gt;
As mentioned before, when local scripts are found, system scripts are ignored.&lt;br /&gt;
&lt;br /&gt;
==TODO==&lt;br /&gt;
* update makefiles&lt;br /&gt;
* have locale translation files use BLI_gethome_folder&lt;br /&gt;
* have icon path use BLI_gethome_folder&lt;br /&gt;
* create ~/.blender when not found so scripts can save their configuration.&lt;br /&gt;
&lt;br /&gt;
[[Category:Script]]&lt;/div&gt;</summary>
		<author><name>wiki&gt;Mindrones</name></author>
		
	</entry>
</feed>