# FreeBSD on the PowerMac G-series



## sossego (May 3, 2010)

*[ Post number 30 in this thread contains new insights and should be read as the first post in this thread -> http://forums.freebsd.org/showthread.php?p=124420#post124420 - Mod. ]*

FreeBSD is a rich and robust operating system with its origins in UNIX which was began when Dennis Ritchie decided to port a game called Space Traveler to a PDP7. From here, he, Ken Thomson, and Rudd Carnady would develop a hierarchal system that would define the computing industry. Forty-one years have passed since that decision was made and UNIX has branched off into different operating systems. It has become a standard within itself.
          FreeBSD was born from a project based on AT&T UNIX and has developed into a stable and trustworthy operating system. With a kernel and userland bound together as a single system, FreeBSD can be installed on anything from routers to supercomputers, from Desktops to laptops, and from PDAs to embedded devices. It is used by all walks of life. From the research scientist to the cafe owner, from government agencies to small cafes, FreeBSD is available as an Open and Free operating system in many languages.
     In the early nineteen nineties, Apple, IBM, and Motorola formed an alliance into which the creation of the POWER architecture became one of the first RISC processors to be used by the general public for personal use. The load-store mechanism of the Power cpu allows it to "predict" the next set of commands, making it efficient in executing code. It is no wonder why Apple, Genesi, IBM, and others have preferred this chip in previous and/or current products.
     Today, we shall combine the efficiency of this processor with the stability of FreeBSD by installing FreeBSD 9.0 PowerPC SNAPSHOT on a Blue & White G3.You will need the following equipment.
1) An Apple G3 or G4 with New World Open Firmware, a 60G ATA hard disk, 386M RAM, a working CD-RW/DVD-ROM, and the rest of the tower plus monitor, mouse,  and keyboard.
2) A Debian PowerPC Install disk. The Net install image or business card will do.
3) An Ubuntu PPC live CD. "Hoary Hedgehog" 5.0x is what I used. There are also live images available from the Debian live project if you wish to use one.
4) Disc 1 of 9.0 PowerPC SNAPSHOT.
5) Lots of patience.
    Let us begin, shall we.
 Start by burning all three discs with your favorite CD burning program. My preference is to use k3b. Either with the G3/4 or on another computer, place the SNAPSHOT Disc 1 in the tray and close it. Do not let the disc be autmoatically mounted. You are going to create a directory and mount the disc through the command line.
Open a terminal and issue the following commands.

```
$mkdir /home/$USER/cdrom
$su
Password:
# mount -t cd9660 -o ro /dev/$CDROM /home/$USER/cdrom
```
Copy the hfs1.boot image to your home directory and change the permissions.

```
# cp /home/$USER/cdrom/path/to/hfs1.boot /home/$USER && chmod 0666 /home/$USER/hfs1.boot
# cd 
# umount /dev/$CDROM
# rmdir /home/$USER/cdrom
# exit
$ exit
```

Email yourself the hfs1.boot file. You will need it later during the exercise.

  Place the Debian install cd into the drive of the G3/4 and reboot the computer while holding down the Option and Alt buttons. Immediately press the O and F buttons while still holding down the others until you see the white background of the Open Firmware Forth prompt. Issue the following commands.

```
> setenv boot-device cd:0
> mac-boot
```
let the system boot and fill in all applicable data until you arrive at the partitioning screen. Choose the following: Whole disk, automatic partitioning, and all files in one partition. Now look at the table and delete the / and swap partitions. You should be left with the APM and New World Boot Block areas. Create  the following partitions with the following values. Use ext3 as the default non-swap areas.
a) 2600M mounted as /
b) 1G as swap
c) 2200M mounted as /tmp
d) 2200M mounted as /var
e) 25G mounted as /usr
f) the remaining area mounted as /home.
Commit the changes to the disk and let Debian begin downloading the distribution. Immediately shutoff the computer and restart it in the Open Firmware Forth prompt.  Remove the Debian CD and place the SNAPSHOT disc 1 into the tray. Issue the same commands to set the cd as the first boot device followed by the 
	
	



```
>mac-boot
```
 command. let the CD load and fill in all applicable data. When you come to the root menu, set the networking up first. You may need to add a value to hostname. For mine, I chose "tima.tiza." After setting this value and bringing up your network, return to the root menu and choose the fixit option. Enter this submenu and choose the shell. Immediately switch over to tty4 and begin by issuing the following commands.


```
gpart show ad0
```
 Notice that / is the second and not first partition. Issue the following commands.

```
gpart modify -i2 -t freebsd ad0
gpart modify -i3 -t freebsd-swap ad0
gpart modify -i4 -t freebsd ad0
gpart modify -i5 -t freebsd ad0
gpart modify -i6 -t freebsd ad0
gpart modify -i7 -t freebsd ad0
```
Anytime during this you may check the partitions with 
	
	



```
gpart show ad0
```
 When you are finished exit and return to the root menu. Use disklabel to edit the names of the partitions. You must choose a partition with C and then give it a value. Your list should be in the following order: /, swap, /tmp, /var, /usr, /home.  Now you will choose the distribution set. Choose minimum and the CD(media) as the source. When you have finished installing, set up all srvices as usual, create a user with wheel privileges, enter the root password and finish. Do not install the ports system, that will come later. REboot the G3/4 and enter the Open Firmware Forth prompt again. Remove the SNAPSHOT disc 1 and place in the livecd. Let it boot and the Desktop come up. Open firefox and guide yourself to the email where you had uploaded the hfs1.boot file. Download it to the Desktop and quit the browser. Open a terminal and issue the following sets of commands.

```
$ sudo -s
# ls /dev
(hdc is the hard disk)
# fdisk /dev/hdc
p:
(/dev/hdc2 is the boot partition.)
q:
# dd if=/home/ubuntu/Desktop/hfs1.boot of=/dev/hdc2
# exit
$ exit
```

Reboot the computer and be sure to remove the disk.
Let the system start and log in as the normal user. You will create a directory from which the rest of the system can be obtained. Place the SNAPSHOT disc 1 into the drive, close it, and issue the following commands.

```
$ mkdir cdrom
$ su
Password:
# mount -t cd9660 -o ro /dev/acd0 cdrom/
# cd 9*
(Here you can either enter each directory and install or use the following. Do not reinstall the base set or kernel.)
# sh $DIRECTORY/install.sh
```
 Be sure to cd to / and unmount the disc. Remove it.
  Because you are using another processor architecture, you must set the flags in make.conf. I have a G3/750 so a few of these values will be different. Look for the proper flags for your G4.

```
vi /etc/make.conf
(Add the following values under the decleration of the PERL version)
CPUTYPE?=powerpc
CFLAGS= -mcpu=G3 -Os -mmultiple -mstring -fno-strict-aliasing -pipe
```
 You will now setup Xorg. Pciutils mustbe installed first.

```
# cd /usr/ports/sysutls/pciutils
# make install clean
```
 You are going to setup Xorg. Remember that when it comes to drivers for your card, choose only the card that you have installed.

```
# cd /usr/ports/x11/xorg && make install clean
```
Now you must "turn off" the frame buffer.

```
sysctl hw.ofwfb.relax_mmap=1
```
Set up the database.

```
/usr/libexec/locate.updatedb
```
Set up subversion.

```
# cd /usr/ports/devel/subversion
# make install clean
```
Setting up the actual xorg.conf file takes a few tweaks.

```
# cd
# Xorg -configure -retro
```
Use vi to edit the new xorg.conf.new file in your /root directory. Add the following values to the Server Layout Section.

```
Option "UseFBDev" "False"
```


----------



## sossego (May 3, 2010)

Copy xorg.conf.new to xorg.conf

```
# cp /root/xorg.conf.new /etc/X11/xorg.conf
```
 Edit May 5, 2010: Wait on the following to be in ports. 
{Now we will setup firefox and install libxul to be used later.

```
# cd /usr/ports/www/libxul
# rm -rf *
# svn co https://trillian.chruetertee.ch/svn/freebsd-gecko/branches/experimental/www/libxul-devl
# cd libxul-devel
# make -j 2 && make install && make clean
```
  The build took between eight and nine hours. I fell asleep waiting. You may want to do something else during this time. Once the build has fin ished, return to the G3/4 and install firefox.

```
# cd /usr/ports/www/firefox
# rm -rf *
# svn co https://trillian.chruetertee.ch/svn/freebsd-gecko/trunk/www/firefox/
# cd firefox 
# make -j2
```

This will take a few hours. You can take it easy. Return to the G3/4. Firefox needs to be "set up" before you can install it.

```
cd work/moz*/browser
# sh confvars.sh
# cd /usr/ports/www/firefox/firefox
# make -j2 && make install && make clean
```
}

Edit May 5, 2010: The above was built with an experimental build. I will add according to ports status.

Reboot your computer and do a system check.
When the boot menu comes up, hit the spacebar and enter the following at the prompt: 
	
	



```
boot -s
```
Run fsck over each partition that is UFS2.

```
# fsck -y /dev/ad0s3
# fsck -y /dev/ad0s5
# fsck -y /dev/ad0s6
# fsck -y /dev/ad0s7
# fsck -y /dev/ad0s8
# exit
```

Login as your regular user and startx.
Until it is fixed, please remember the following.
1) You are limited to only using TWM.
2) You cannot switch ttys after starting your X session.
3) The mouse must remain in the firefox window while using firefox. If it leaves, it can get "caught" in a terminal and you will have to do a hard reboot.
4) There is a firmware issue which has not yet been resolved. When you leave an X session you must switch to another tty then switch back to tty0. there will be no working monitor but still type in the following commands.

```
$ su
Password:
# halt -p
(Or if you want to reboot)
# reboot
```
.

 I had some problems with firefox, so I  rewrote this howto using vi on the G3. 


 I would like to thank the FreeBSD developers- especially FreeBSD-gecko and the FreeBSD PowerPC team- along with the BSD communities for their help, patience, and understanding through this project.


----------



## sossego (May 3, 2010)

Xorg.conf if someone wants to use it.

```
Section "ServerLayout"
	Identifier     "X.org Configured"
	Screen      0  "Screen0" 0 0
	InputDevice    "Mouse0" "CorePointer"
	InputDevice    "Keyboard0" "CoreKeyboard"
        Option         "AllowEmptyInput"    "Off"
        Option          "UseFBDev"  "False"
EndSection

Section "Files"
	ModulePath   "/usr/local/lib/xorg/modules"
	FontPath     "/usr/local/lib/X11/fonts/misc/"
	FontPath     "/usr/local/lib/X11/fonts/TTF/"
	FontPath     "/usr/local/lib/X11/fonts/OTF"
	FontPath     "/usr/local/lib/X11/fonts/Type1/"
	FontPath     "/usr/local/lib/X11/fonts/100dpi/"
	FontPath     "/usr/local/lib/X11/fonts/75dpi/"
EndSection

Section "Module"
	Load  "extmod"
	Load  "record"
	Load  "dbe"
	Load  "glx"
	Load  "dri"
	Load  "dri2"
EndSection

Section "InputDevice"
	Identifier  "Keyboard0"
	Driver      "kbd"
EndSection

Section "InputDevice"
	Identifier  "Mouse0"
	Driver      "mouse"
	Option	    "Protocol" "auto"
	Option	    "Device" "/dev/sysmouse"
	Option	    "ZAxisMapping" "4 5 6 7"
EndSection

Section "Monitor"
	Identifier   "Monitor0"
	VendorName   "Monitor Vendor"
        HorizSync    30-85
        VertRefresh  48-160
	ModelName    "StudioDsply1"
EndSection

Section "Device"
        ### Available Driver options are:-
        ### Values: <i>: integer, <f>: float, <bool>: "True"/"False",
        ### <string>: "String", <freq>: "<f> Hz/kHz/MHz"
        ### [arg]: arg optional
        #Option     "NoAccel"            	# [<bool>]
        #Option     "SWcursor"           	# [<bool>]
        #Option     "Dac6Bit"            	# [<bool>]
        #Option     "Dac8Bit"            	# [<bool>]
        #Option     "DMAForXv"           	# [<bool>]
        #Option     "ForcePCIMode"       	# [<bool>]
        #Option     "CCEPIOMode"         	# [<bool>]
        #Option     "CCENoSecurity"      	# [<bool>]
        #Option     "CCEusecTimeout"     	# <i>
        #Option     "AGPMode"            	# <i>
        #Option     "AGPSize"            	# <i>
        #Option     "RingSize"           	# <i>
        #Option     "BufferSize"         	# <i>
        #Option     "EnablePageFlip"     	# [<bool>]
        #Option     "Display"            	# <str>
        #Option     "PanelWidth"         	# <i>
        #Option     "PanelHeight"        	# <i>
        #Option     "ProgramFPRegs"      	# [<bool>]
         Option     "UseFBDev"                   "False"	
        #Option     "VideoKey"           	# <i>
        #Option     "ShowCache"          	# [<bool>]
        #Option     "VGAAccess"          	# [<bool>]
	Identifier  "Card0"
	Driver      "r128"
	VendorName  "ATI Technologies Inc"
	BoardName   "Rage 128 RE/SG"
	BusID       "PCI:0:16:0"
EndSection

Section "Screen"
	Identifier "Screen0"
	Device     "Card0"
	Monitor    "Monitor0"
	SubSection "Display"
		Viewport   0 0
		Depth     1
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     4
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     8
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     15
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     16
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     24
	EndSubSection
EndSection
```

uname -a 
	
	



```
FreeBSD tima.tiza 9.0-20100418-SNAP FreeBSD 9.0-20100418-SNAP #0: Sun Apr 18 06:51:02 UTC 2010     root@dynode.isc.freebsd.org:/usr/obj/usr/src/sys/GENERIC  powerpc
```


----------



## sossego (May 4, 2010)

We are going to add a window manager, a faster browser, and a text editor. 

```
$ su 
Password: 
# cd /usr/ports/www/dillo2 
# make  -j 1 && make install && make clean 
# cp /usr/local/etc/dillo/dillorc /home/$USER/.dillo/ 
# chown $USER dillorc
```
Now for the editor.  

```
# cd /usr/ports/editors/scite 
# make -j 1 && make install && make clean
```
Time for the window manager.  

```
# cd /usr/ports/x11-wm/enlightenment 
# make -j 1 && make install && make clean
```
Time to set it all up.  The default resolution is 1600x1200. 
You are going to want to edit a few lines in dillorc.  

```
# exit (It's about time we left root.)
```
Let's enter X and begin the editing process. 

```
$ cd $ /usr/local/bin/startx
```
 Do not choose the login term to do this.  

```
$ cd /home/$USER/.dillo $ SciTE 
(Use the drop down menu and choose "All files".
```
Suggestions for values in dillorc:
 Font size from 10 to 20. 
Font size factor leave at 1. 
Send http referrer heading as none. Privacy is a must. 
Download directory.  

```
$ mkdir /home/$USER/dillo_downloads
```
Set the download directory to the value above. 
Set all other values to what you want. 
You'll have to save the file as dillorc2. 
Now let's apply our changes  

```
$ pwd (Should be /home/$USER/.dillo) 
$ rm dillorc $ mv dillorc2 dillorc
```
We will "pre-start" enlightenment.   

```
$ /usr/local/bin/enlightenment_start
```
It's going to die but that's okay.  
Let's set it up to be started much easier.  

```
$ SciTE
```
You are going to create a new file. 
Enter the following values. 

```
/usr/local/bin/startx /usr/local/bin/enlightenment_start
```
Save the file as gui.sh .  

When next you turn on your G3/4, you can use


```
$ sh gui.sh
```

to start your X session.

Just remember what I mentioned earlier about X and the firmware.  
Even though you can't see it, 
the commands can still be and will still be enabled once you hit enter.


----------



## sossego (May 5, 2010)

Note May 5, 2010: If you are having troubles building firefox because svn doesn't allow access, then wait. The howto will be updated and noted according to ports. The update and edit dates will be noted for each change. Older entries will be in brackets followed by before and after edit/update changes.


----------



## sossego (May 5, 2010)

Note May 5, 2010: I have libxul-devel and xulrunner if you need them. You may ask me for my BSD/Linux only email and I will give it to you.
Write me from the address you want the items sent to and I will reply within a day or two.
I also have the firefox 3.6.3,1 build from earlier if you need that.


----------



## sossego (Jun 21, 2010)

You can install kde4 on the PowerPC with a few exceptions.
Do not install kdeedu because ocaml is x86 dependent.
You may also need to set the path for kdelibs when installing kde3.x.


----------



## sossego (Dec 14, 2010)

Note that agp has issues and that such a system run great as a server. Until it is dealt with, try to remain with pci graphics. If you do decide to use agp and wish to build the modules- There is some trouble with drm, check the mailing lists for discussions.- use the 9.0 snapshot.


----------



## sossego (Jan 12, 2011)

If you are using the PowerPC snapshot 9 for the 32 bit architecture, you will need to update your ports tree to the latest version.


----------



## sossego (Jan 16, 2011)

Here goes.

On Powermacs with agp graphics cards.


```
# cd /usr/src/sys/modules/agp
# make install clean
# kldload agp
```

Edit /boot/defaults/loader.conf

```
agp_load="NO"
```
should be

```
agp_load="YES"
```

Try making the resolution as high as possible. I'm not sure if multiple modes are able.

Oh, and thanks to tingo for the encouragement.


----------



## sossego (Jan 17, 2011)

I currently am running lxde on the machine.
Current problems are:
The mouse pointer will go to the upper left corner of the screen when I physically lift the mouse.
Xxxterm would not completely exit.

Since neither of these occured on the previous- make that a few hours ago- run with fluxbox, 
I'll say that lxde may not be the desktop you want to try.
After kazehakase finishes building, I'll try another wm/desktop session manager.


----------



## tingo (Jan 17, 2011)

Just one small correction: you shouldn't edit files in */defaults/* directories; instead, edit the correct file. so for /boot/defaults/loader.conf, that would be /boot/loader.conf. If such a file doesn't exist, create it. Hope this helps.


----------



## sossego (Jan 17, 2011)

He's right on that one.

For installing bash, there may be a break in the build.
When this happens, do the following:

```
# cd work/bash*
# ./configure
# gmake && gmake install clean
# cd /usr/ports/shells/bash
# make install clean
```


----------



## sossego (Jan 17, 2011)

If any port build breaks, try the following:
1) Cd to the work directory then to the application directory.

```
# cd work/<application name>
```
2) Configure with gmake.

```
# ./configure && gmake && gmake install clean
```
3) Return to the port parent directory.

```
# cd .. && cd ..
```
4) Rerun make

```
# make install clean
```
5) Update the system.

```
# /usr/libexec/locate.updatedb
```

I've borked the kazehakase install process somewhere.


Since the kernel of the snapshot has witnessed enabled, you may want to rebuild it with that option disabled. 
Be sure to:
1) Have the kernel parameters in /boot/defaults/loader.conf set to the defaults.
2) Follow the handbook instructions for rebuilding the kernel.
3) Backup the old kernel.

After it finishes, you will need to reboot. Before you do, write down the exact location of the new kernel.

4) Reboot the machine.
5) Halt the boot process by hitting the space bar.
6) Type "help" at the console.
7) Look for the option for loading the kernel.
8) Follow the directions.


----------



## tingo (Jan 21, 2011)

sossego said:
			
		

> Here goes.
> 
> On Powermacs with agp graphics cards.
> 
> ...



Question: when you `# kldload agp`, do you get output related to that on console and / or in /var/log/messages?
I just tried on my PowerMac G4 (which now runs 8.2-prerelease), and I didn't get any output after loading agp, and `# Xorg -configure -retro` still hangs the machine.


----------



## sossego (Jan 21, 2011)

Add the Modelines.

Give me a sec to login from the G4.


----------



## sossego (Jan 21, 2011)

Here is my /etc/X11/xorg.conf from the G4. Use it as a guide to compare it with your own.

It built for me using the snapshot 9 that I constantly mention.

I'll need to edit .xinitrc to use fluxbox because Xfce4 and lxde are strange.
Once I do, I'll post the full dmesg here.
Hold on again.


```
Section "ServerLayout"
	Identifier     "X.org Configured"
	Screen      0  "Screen0" 0 0
	InputDevice    "Mouse0" "CorePointer"
	InputDevice    "Keyboard0" "CoreKeyboard"
        Option         "UseFBDev"  "False"
        Option         "AllowEmptyInput"  "Off"
EndSection

Section "Files"
	ModulePath   "/usr/local/lib/xorg/modules"
	FontPath     "/usr/local/lib/X11/fonts/misc/"
	FontPath     "/usr/local/lib/X11/fonts/TTF/"
	FontPath     "/usr/local/lib/X11/fonts/OTF"
	FontPath     "/usr/local/lib/X11/fonts/Type1/"
	FontPath     "/usr/local/lib/X11/fonts/100dpi/"
	FontPath     "/usr/local/lib/X11/fonts/75dpi/"
EndSection

Section "Module"
	Load  "extmod"
	Load  "record"
	Load  "dbe"
	Load  "glx"
	Load  "dri"
	Load  "dri2"
EndSection

Section "InputDevice"
	Identifier  "Keyboard0"
	Driver      "kbd"
EndSection

Section "InputDevice"
	Identifier  "Mouse0"
	Driver      "mouse"
	Option	    "Protocol" "auto"
	Option	    "Device" "/dev/sysmouse"
	Option	    "ZAxisMapping" "4 5 6 7"
EndSection

Section "Monitor"
	Identifier   "Monitor0"
	VendorName   "DELL"
	ModelName    "D1025TM"
        HorizSync    30.0-85.0
        VertRefresh  50.0-120.0
EndSection

Section "Device"
        ### Available Driver options are:-
        ### Values: <i>: integer, <f>: float, <bool>: "True"/"False",
        ### <string>: "String", <freq>: "<f> Hz/kHz/MHz"
        ### [arg]: arg optional
        #Option     "NoAccel"            	# [<bool>]
        #Option     "SWcursor"           	# [<bool>]
        #Option     "Dac6Bit"            	# [<bool>]
        #Option     "Dac8Bit"            	# [<bool>]
        #Option     "BusType"            	# [<str>]
        #Option     "CPPIOMode"          	# [<bool>]
        #Option     "CPusecTimeout"      	# <i>
        Option     "AGPMode"                    "4"	
        #Option     "AGPFastWrite"       	# [<bool>]
        Option     "AGPSize"                   "64"	
        #Option     "GARTSize"           	# <i>
        #Option     "RingSize"           	# <i>
        Option     "BufferSize"                 "2"	
        #Option     "EnableDepthMoves"   	# [<bool>]
        #Option     "EnablePageFlip"     	# [<bool>]
        #Option     "NoBackBuffer"       	# [<bool>]
        #Option     "DMAForXv"           	# [<bool>]
        #Option     "FBTexPercent"       	# <i>
        #Option     "DepthBits"          	# <i>
        #Option     "PCIAPERSize"        	# <i>
        #Option     "AccelDFS"           	# [<bool>]
        #Option     "IgnoreEDID"         	# [<bool>]
        #Option     "CustomEDID"         	# [<str>]
        #Option     "DisplayPriority"    	# [<str>]
        #Option     "PanelSize"          	# [<str>]
        #Option     "ForceMinDotClock"   	# <freq>
        Option     "ColorTiling"        	"True"
        #Option     "VideoKey"           	# <i>
        #Option     "RageTheatreCrystal" 	# <i>
        #Option     "RageTheatreTunerPort" 	# <i>
        #Option     "RageTheatreCompositePort" 	# <i>
        #Option     "RageTheatreSVideoPort" 	# <i>
        #Option     "TunerType"          	# <i>
        #Option     "RageTheatreMicrocPath" 	# <str>
        #Option     "RageTheatreMicrocType" 	# <str>
        #Option     "ScalerWidth"        	# <i>
        #Option     "RenderAccel"        	# [<bool>]
        #Option     "SubPixelOrder"      	# [<str>]
        #Option     "ClockGating"        	# [<bool>]
        #Option     "VGAAccess"          	# [<bool>]
        #Option     "ReverseDDC"         	# [<bool>]
        #Option     "LVDSProbePLL"       	# [<bool>]
        #Option     "AccelMethod"        	# <str>
        #Option     "DRI"                	# [<bool>]
        #Option     "ConnectorTable"     	# <str>
        #Option     "DefaultConnectorTable" 	# [<bool>]
        #Option     "DefaultTMDSPLL"     	# [<bool>]
        #Option     "MacModel"           	# <str>
        #Option     "TVDACLoadDetect"    	# [<bool>]
        #Option     "ForceTVOut"         	# [<bool>]
        #Option     "TVStandard"         	# <str>
        #Option     "IgnoreLidStatus"    	# [<bool>]
        #Option     "DefaultTVDACAdj"    	# [<bool>]
        #Option     "Int10"              	# [<bool>]
        #Option     "EXAVSync"           	# [<bool>]
        #Option     "ATOMTVOut"          	# [<bool>]
        #Option     "R4xxATOM"           	# [<bool>]
        #Option     "ForceLowPowerMode"  	# [<bool>]
        #Option     "DynamicPM"          	# [<bool>]
        #Option     "NewPLL"             	# [<bool>]
        #Option     "ZaphodHeads"        	# <str>
	Identifier  "Card0"
	Driver      "ati"
	VendorName  "ATI Technologies Inc"
	BoardName   "Radeon RV200 QW [Radeon 7500]"
	BusID       "PCI:0:16:0"
EndSection

Section "Screen"
	Identifier "Screen0"
	Device     "Card0"
	Monitor    "Monitor0"
	SubSection "Display"
		Viewport   0 0
		Depth     1
                Modes      "1024x768" "1280x1024"
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     4
                Modes      "1024x768" "1280x1024"
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     8
                Modes      "1024x768" "1280x1024"
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     15
                Modes      "1024x768" "1280x1024"
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     16
                Modes      "1024x768" "1280x1024"
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     24
                Modes      "1024x768" "1280x1024"
	EndSubSection
EndSection
```

Maybe it will help you some.


----------



## tingo (Jan 21, 2011)

Or perhaps the problem is that my G4 doesn't have an AGP gfx card?

```
root@kg-g4# pciconf -lv | grep -A4 vga
vgapci0@pci0:0:16:0:	class=0x030000 card=0xa5b80208 chip=0x011010de rev=0xa1 hdr=0x00
    vendor     = 'NVIDIA Corporation'
    device     = 'NVIDIA GeForce2 MX/MX 400 (NV11)'
    class      = display
    subclass   = VGA
```

As long as running Xorg hangs my machine, editing xorg.conf will never help.


----------



## sossego (Jan 21, 2011)

Use pastebinit to upload your xorg.conf.new from /root and I'll see if there is anything that i can do to help further.
You may also want to post a pastebinit of /var/log/Xorg.0.log, dmesg, and /root/xorg.conf.new to the ppc mailing lists.

You can rerun with

```
/usr/local/bin/Xorg -logverbose -9 -verbose 9 -logfile <make a logfile in /root or /home/$USER> -config -retro
```

or test your output  with 
	
	



```
-config /root/xorg.conf.new
```
 instead of the retro option.

I know that it is a *beep**beep**beep**beep**beep* to get it working. Trust me, it took a while for the G3 to work and just a few days ago for the G4 to work.


----------



## tingo (Jan 22, 2011)

There is nothing to see; Xorg never wrote anything to the xorg.conf.new file:

```
root@kg-g4# ls -l /root/xorg.conf.new
-rw-r--r--  1 root  wheel  0 Jan 21 23:43 /root/xorg.conf.new
```
That is the problem; Xorg hangs to machine (locks it hard) when it is started; there isn't even any output in /var/log/messages.


----------



## wblock@ (Jan 22, 2011)

tingo said:
			
		

> There is nothing to see; Xorg never wrote anything to the xorg.conf.new file:
> 
> ```
> root@kg-g4# ls -l /root/xorg.conf.new
> ...



Add

```
Option "Log" "sync"
```
to the ServerLayout section.


----------



## sossego (Jan 22, 2011)

Tingo, install pastebinit from the ports and then

```
$ /usr/local/bin/pastebinit -b http://slexy.org -i /var/log/Xorg.0.log
```

Output dmesg to a file on the user's home directory and send it.


```
$ cd
$ dmesg|tee dmesg-output.txt
$ /usr/local/bin/pastebinit -b http://slexy.org -i dmesg-output.txt
```

Run the initial Xorg from root once more and then log it.


```
# cd
# /usr/local/bin/Xorg -config -retro
```

I adjusted the flags for the card because I searched for whatever would make it properly work. Your card will have different flags.

Look to see if agp is in your kernel directory.

Post the kldstat here.

When you restart the machine. Hit the space bar and type boot -s at the command prompt.
Follow that with 
	
	



```
fsck -y && exit
```

When X hangs, the system still works.
Hold down ctrl + alt + f1 an then hit ctrl + c.
Xorg will be stopped. For assurance, hit ctrl + c once more.
Type in reboot and then enter.

It will reboot.

Post the slexy view links here and we'll try to work through it with you.


----------



## tingo (Jan 22, 2011)

wblock, sossego - you make good suggestions. There is only one problem; the machine is locked hard. As soon as I press enter on the Xorg... command line, the machine locks up. It doesn't even switch to another vty first. Hard, as in "completely unresponsive". It doesn't react to input at all. I have ssh'ed in from another machine; that shell is dead. I've tried ctrl-alt-f1 (and  the others) even if the first console is still visible; no reaction. The /var/log/Xorg.log file isn't even created, and nothing is written in /var/log/messages (not even if I boot verbose). dmesg output for both normal and verbose is available at: http://sites.google.com/site/tingox/powermac_g4_freebsd


----------



## sossego (Jan 22, 2011)

```
boot -s
```


```
fsck -y && exit
```

Don't start Xorg.

```
dmesg|tail
```

Post the possible error here. Your disk may be locking up or a possible board error.

Also, since I am not running FreeBSD right now, look at the man pages for Xorg and related to see if there is still the probe only option and then use it.


----------



## tingo (Jan 22, 2011)

No; if I don't try to run Xorg, the machine works fine (in fact it is running portupgrade right now). I will try the Xorg -probeonly later, but I guess that it will lock the machine too.


----------



## wblock@ (Jan 22, 2011)

tingo said:
			
		

> wblock, sossego - you make good suggestions. There is only one problem; the machine is locked hard.



The Log Sync option should have it sync the logs before it crashes, so there may be something in them after a restart.


----------



## sossego (Jan 29, 2011)

This entire tutorial was a waste of my time and everyone else's. 

In the device section, you have to allow AGP.

I thought that making this and keeping it updated when I had a problem would be beneficial to others,
now I realize how stupid it seems now.

This entire thread should be removed.


----------



## tingo (Jan 29, 2011)

How do you allow AGP?
(FWIW, I also learn from my mistakes, not only from doing things right. In that light; I think this section should be here. You could update the first post with the correct information perhaps)


----------



## sossego (Jan 31, 2011)

http://forums.freebsd.org/showpost.php?p=120401&postcount=17


Look in [Section "Device]

I've read the mailing list about the fan fix.

Hmm, try an SSH session into the G4 and run 

```
/usr/local/bin/Xorg -configure -retro
```
 from there.
Save verbose and logverbose to the /home/$USER/name-of-file.txt.


Gnome-terminal can be set to unlimited history if you need to see- and copy- the output.


----------



## sossego (Feb 23, 2011)

This is a quicker method of installing based upon information from tingo/tingox and 
the mailing lists. It is for systems dedicated solely to FreeBSD as the only OS on the drive(s).

Resource: http://sites.google.com/site/tingox/powermac_g4_freebsd

See the FreeBSD PowerPC page for compatible hardware. http://www.freebsd.org/platforms/ppc.html

Suggested minimum requirements.
PowerPC system with 400MHz processor, 384M RAM, 40G hard drive.
Be sure that the system has Open Firmware version 3.x or higher.

Media needed.

A FreeBSD disk one iso for the powerpc architecture. ftp://ftp.freebsd.org/pub/FreeBSD/snapshots/201102/

Booting.
 Prepare the media by burning the image to disc.
 Boot the machine and hold down the left option key. You should see an icon of a harddrive.
Open the tray and place the disc in it. Select the CD when the icon appears then the arrow
to start the process.
>>> If your firmware hasn't been updated, you will need to boot using ctrl+option+O+F.
Open the tray and insert the CD. Close the tray.

```
> setenv boot-device cd
>mac-boot
```
 Let the CD boot. Select what applies to you.

Partitioning.
At the main menu, select Fixit. Hit enter. Select 5 for shell. Hit enter.
CTRL+ALT+F4.


```
gpart show
```
If your system has two or more disks, then choose the one you want to use.


```
gpart -delete -i <partition number> ad<disk number>
```
This will delete all partitions.


```
gpart add -s 800K -t '!Apple_Bootstrap' ad<disk number>
gpart add -s <size> -t freebsd-ufs ad<disk number>
gpart add -s <size> -t freebsd-swap ad<disk number>
gpart add -s <size> -t freebsd-ufs ad<disk number>
<etc>
```

You will need a minimum of three partitons: appleboot, freebsd-ufs, and swap.

Exit and CTRL+ALT+F1

Installing.
Use X and enter to return to the main menu. Choose standard.
Select the created partitions with C. For the first: filesystem, / as mountpoint.
For the second: swap. The remaining partitions- if any- can be labeled accordingly.

Hit Q. Select the minimal installation. Hit X and enter.
Media type is CD/DVD.

Hit enter. When prompted for a new shell, enter yes.

Post Installation.
After the congratulations, select yes for configuration.
I chose no for everything except ssh.
Set the time zone.
Setup the user accounts. Be sure to add "wheel" to the group membership of the default user.
Setup root password.
No, do not add ports.

Setup networking by returning to the main screen.
Select post configuration. Select networking. Select devices.
If you have a router, just make up a name. A direct connection should have all defaults filled.

Return to the main menu.
Select fixit. Select shell. CTRL+ALT+F4


```
dd if=/boot/boot1.hfs of=/dev/ad<disk number>s2
```

CTRL+ALT+F1

Exit install and reboot.

Follow the rest of the howto.

If you have trouble using gpart for deleting partitions, use the method listed below.


----------



## sossego (Mar 22, 2011)

http://forums.freebsd.org/showthread.php?t=22384

I will be adding kde4 and gnome3 packages soon. Older packages will be updated.

This should have been posted here originally. Apologies.


----------



## sossego (Mar 29, 2011)

You may want to enable huge stack size and floating point exception when building any version of python for ppc.


----------



## sossego (Aug 4, 2011)

If the mouse cursor gets caught, add the following to the xorg.conf file:


```
Option         "UseSIGIO"   "False"
```

This solution came from Matt H on the OpenBSD PPC mailing list.


----------



## Marcov (Aug 6, 2011)

*Where does the Debian come in?*

I read post #30, but if I understand it correctly that whole bit is using the FreeBSD CD, and the part table is now made using FreeBSD, and apparantly so is the boot<x>.hfs.

Where do you still need the Debian CD? 


P.s. target is a mini 1.25GHz/512MB/40GB/airport/bluetooth.


----------



## sossego (Aug 6, 2011)

You use the Debian CDs when you want more than one OS on the disk and are partitioning the disk for such. 
Post #30 was researched after the initial tutorial had been typed and posted. I read through tingo's website and decided that his description of how he partitioned would be good for a system dedicated to FreeBSD. 
So, if it is a dedicated machine go to post 30. If it is being shared with another OS- start at the beginning.

Post #30 has been corrected.


----------



## sossego (Aug 7, 2011)

The xorg.conf for an iMac G4 800MHz:

```
Section "ServerLayout"
	Identifier     "X.org Configured"
	Screen      0  "Screen0" 0 0
	InputDevice    "Mouse0" "CorePointer"
	InputDevice    "Keyboard0" "CoreKeyboard"
        Option         "AllowEmptyInput"  "Off"
        Option         "UseFBDev"   "False"
        Option         "UseSIGIO"   "False"
EndSection

Section "Files"
	ModulePath   "/usr/local/lib/xorg/modules"
	FontPath     "/usr/local/lib/X11/fonts/misc/"
	FontPath     "/usr/local/lib/X11/fonts/TTF/"
	FontPath     "/usr/local/lib/X11/fonts/OTF"
	FontPath     "/usr/local/lib/X11/fonts/Type1/"
	FontPath     "/usr/local/lib/X11/fonts/100dpi/"
	FontPath     "/usr/local/lib/X11/fonts/75dpi/"
EndSection

Section "Module"
	Load  "extmod"
	Load  "record"
	Load  "dbe"
	Load  "glx"
	Load  "dri"
	Load  "dri2"
EndSection

Section "InputDevice"
	Identifier  "Keyboard0"
	Driver      "kbd"
EndSection

Section "InputDevice"
	Identifier  "Mouse0"
	Driver      "mouse"
	Option	    "Protocol" "auto"
	Option	    "Device" "/dev/sysmouse"
	Option	    "ZAxisMapping" "4 5 6 7"
EndSection

Section "Monitor"
	Identifier   "Monitor0"
	VendorName   "Monitor Vendor"
	ModelName    "Monitor Model"
        HorizSync    59-63
        VertRefresh  50-160
EndSection

Section "Device"
        ### Available Driver options are:-
        ### Values: <i>: integer, <f>: float, <bool>: "True"/"False",
        ### <string>: "String", <freq>: "<f> Hz/kHz/MHz"
        ### [arg]: arg optional
        #Option     "SWcursor"           	# [<bool>]
        #Option     "HWcursor"           	# [<bool>]
        #Option     "NoAccel"            	# [<bool>]
        #Option     "ShadowFB"           	# [<bool>]
        #Option     "UseFBDev"           	# [<bool>]
        #Option     "Rotate"             	# [<str>]
        #Option     "VideoKey"           	# <i>
        #Option     "FlatPanel"          	# [<bool>]
        #Option     "FPDither"           	# [<bool>]
        #Option     "CrtcNumber"         	# <i>
        #Option     "FPScale"            	# [<bool>]
        #Option     "FPTweak"            	# <i>
        #Option     "DualHead"           	# [<bool>]
	Identifier  "Card0"
	Driver      "nv"
	VendorName  "nVidia Corporation"
	BoardName   "NV11 [GeForce2 MX/MX 400]"
	BusID       "PCI:0:16:0"
EndSection

Section "Screen"
	Identifier "Screen0"
	Device     "Card0"
	Monitor    "Monitor0"
	SubSection "Display"
		Viewport   0 0
		Depth     1
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     4
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     8
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     15
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     16
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     24
	EndSubSection
EndSection
```


----------



## Marcov (Aug 9, 2011)

Btw, regarding post #30, I had a feeling that sysinstall didn't properly get updated with the results of gpart in a emergency shell. 

I notice that the description doesn't add a command to sync the partition table or so, or to restart sysinstall. Maybe it should (but I'm not reinstalling to test :_)

I managed to finish install anyway, but installed without using swap, probably because in both cases partition nrs were the same. (but since the swap was an extra partition I couldn't enable it till after reboot)


----------



## sossego (Aug 14, 2011)

Markov, apologies for the late reply; but, sysinstall is secondary when installing on machines with PowerPC & POWER chips. When you can, give us a quick synopsis of how you did the install.

Other news:
I'm creating another repository on googlecode with packages. Since I am having some trouble with httplib.py, those packages which do not have a large amount according to first letter will be in normal tbz format, any others will be group bundled in tar.gz packages.

http://code.google.com/p/freebsd-powerpc-9-0-current-updated-packages

Just so you know it's me, the wiki page will contain a few of my frustrations.


----------



## rockula (Aug 28, 2011)

Boy, I came across this site after trying to figure out what to do with my old Mac Mini 1.42ghz that I have lying around. I haven't used it in years, and it's all packaged up in the original box and shipping box even! I bought a really nice PC Monitor that even has a HD Tuner built in, two HDMI ports, component video, SPDIF out, and USB. I'm using it for my XBox Slim. But I thought maybe I could put that Mac Mini I have to use and use it for my office and home iTunes libraries, if I hooked up a 1TB external to it. 

I then got to thinking that I coud use it as a media center for movies, etc. But if I remember correctly, it can barely playback online videos for some reason. So, searching brought me to FreeBSD... but I must admit, I'm still not even sure what it is! This thread is like reading ancient text to me! LOL. 

My question is... will using FreeBSD allow me to get smoother video playback from my Mac Mini... or is it limited to the vid card with nothing I can do about it to make it better? As one guy said, I don't need to watch picture perfect 1080p DVD's on it... but if I could watch AVI, DViX, or Mkv files on it, I'd be thrilled.

I also have a Western Digital TV, but it's not the HD version. I could use the component vid though. It is picky about what it plays back. To be able to watch Hulu, Youtube, or Netflix would be cool. Plus my Xbox Slim is connected to it too. Problem is, it's mostly set up for the Xbox, and not in my living room for comfortable viewing, etc.

I could probably get $175-$200 for that Mini... but I sure would love to have a headless server... because too many times I try to access music that is on my work Mac, not at home. I have to FTP in to my computer at work to DL it. Another nice thing about this, is if I hooked it up at work, my IP is static there, but not so at home. However, my speeds at home are twice as fast. Tough call!

Thanks!
Jason


----------



## tingo (Aug 29, 2011)

FWIW, my Mac mini G4 1.42 GHz running OS X 10.4 works fine for playback of anything SD content. It does not handle HD content. I haven't tried FreeBSD on it, so I can't say if there is a difference in performance vs. OS X.


----------



## rockula (Aug 29, 2011)

That was going to be one of my questions... what OS is the fastest on the Mac Mini 1.42ghz. I was guessing that 10.4 would be about the best. I'm thinking 10.5 will run on it though. Might make it run slower though. So, SD is ok, and sites like Youtube, Xfinity will play back ok? Is it because of the limitation of the video card ya think?

I haven't seen a new Mini in long time... but I'm assuming that they are a different form factor all together, therefore you couldn't put an Intel mobo inside of the 1.42ghz case. I wonder if you could buy an External Blu-Ray player for it, or put a Blu-Ray drive inside of it? My guess is that the mobo won't support it.

I'd rather just sell it before investing a bunch of money in this one. Mine has the 5400rpm hdd too. I bet that if I put a 7200rpm HDD in it, that could help. Memory is maxed of course.

Thanks!
Jason


----------



## tingo (Sep 4, 2011)

I haven't tried Youtube on it, and I don't know what "Xfinity" is, so I couldn't tell you. A quick test with some Youtube music videos in Firefox show that they work, at least.

The machine is slow, it could be the video card, the hard drive, the chipset or something else.


----------



## rockula (Sep 4, 2011)

Just so I don't come off like a perv.... Xfinity is Comcast Cable's online site where you can watch anything online that you could watch at home or On Demand (as long as you are a subscriber and only the packages you subscribe to).

J


----------



## sossego (Sep 4, 2011)

Youtube does not play on FreeBSD Power(PC). You will either need to use qemu- which can be a cpu hog- or you need to setup tunneling into an i386/amd64 machine and watch videos remotely.

Tingo, what's the kernel hz you have set? Did you rebuild the kernel? Are you using a light desktop such as xfce4, a "box" manager, or some other?

Rendering is done by the CPU not the GPU on Power(PC). 


What's the fastest OS on the mac mini with Power(PC)?
That depends on how you have it setup. OpenBSD and FreeBSD worked for me. OpenBSD doesn't exactly compile packages well on some lowend machines. Linux works but, you have to slim it down or it becomes hoggish with the CPU. I haven't tried NetBSD- first boot problems.


----------



## tingo (Sep 5, 2011)

@sossego: see post 40. My mini doesn't run FreeBSD, it runs OS X.


----------



## sossego (Sep 6, 2011)

Okay.
Have you ever thought about using an external drive through one usb port and having the mouse-though-keyboard on the other?


----------



## Zylabon (Jan 14, 2012)

Hi all
I have an old eMac G4 this one

and all the xorg.conf above didn't worked for me. (I tried to brute force my xorg.conf)â€¦ Anyway!
This screen is not recognized by xorg out of the box. This worked for me:

```
Section "ServerLayout"
	Identifier     "X.org Configured"
	Screen      0  "Screen0" 0 0
	InputDevice    "Mouse0" "CorePointer"
	InputDevice    "Keyboard0" "CoreKeyboard"
EndSection

Section "Files"
	ModulePath   "/usr/local/lib/xorg/modules"
	FontPath     "/usr/local/lib/X11/fonts/misc/"
	FontPath     "/usr/local/lib/X11/fonts/TTF/"
	FontPath     "/usr/local/lib/X11/fonts/OTF"
	FontPath     "/usr/local/lib/X11/fonts/Type1/"
	FontPath     "/usr/local/lib/X11/fonts/100dpi/"
	FontPath     "/usr/local/lib/X11/fonts/75dpi/"
EndSection

Section "Module"
	Load  "extmod"
	Load  "record"
	Load  "dbe"
	Load  "glx"
	Load  "dri"
	Load  "dri2"
EndSection

Section "InputDevice"
	Identifier  "Keyboard0"
	Driver      "kbd"
EndSection

Section "InputDevice"
	Identifier  "Mouse0"
	Driver      "mouse"
	Option	    "Protocol" "auto"
	Option	    "Device" "/dev/sysmouse"
	Option	    "ZAxisMapping" "4 5 6 7"
EndSection

Section "Monitor"
	Identifier   "Monitor0"
	VendorName   "Monitor Vendor"
        HorizSync    30-85
        VertRefresh  48-160
	Modeline "1280x960_72.00" 124.54 1280 1368 1504 1728 960 961 964 1001 -HSync +Vsync
	ModelName    "StudioDsply1"
EndSection
Section "Device"

        Option     "UseFBDev" "False"
	Identifier  "Card0"
	Driver      "nv"
	VendorName  "nVidia Corporation"
	BoardName   "NV11 [GeForce2 MX/MX 400]"
	BusID       "PCI:0:16:0"
EndSection

Section "Screen"
	Identifier "Screen0"
	Device     "Card0"
	Monitor    "Monitor0"
	SubSection "Display"
		Viewport   0 0
		Modes	"1280x960_72.00"
		Depth     1
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Modes	"1280x960_72.00"
		Depth     4
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Modes	"1280x960_72.00"
		Depth     8
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Modes	"1280x960_72.00"
		Depth     15
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Modes	"1280x960_72.00"
		Depth     16
	EndSubSection
	SubSection "Display"
		Viewport   0 0
		Depth     24
		Modes	"1280x960_72.00"
	EndSubSection
EndSection
```

I would be so glad to find this on the internet before doing so many tests.


----------



## sossego (Feb 28, 2012)

Before you run *make index* from ports, be sure to edit /usr/ports/audio/beast/Makefile and comment out the section for checking SSE. This work around comes from danfe.

Rebuilding the kernel requires at the least the following steps.

 Edit /usr/share/examples/cvsup/standard-supfile with the following parameters if they are not already set: 

```
tag=.
```
 and, of course, the cvs server set.
 Csup the source code.
 [cmd=]cd /usr/src/usr.sbin/config[/cmd]
 Run [cmd=]make && make install && make clean[/cmd]
This will take care of the version error for config(8).

Be sure to see the handbook for properly creating a new kernel.


----------



## pkubaj (Feb 29, 2012)

sossego said:
			
		

> Youtube does not play on FreeBSD Power(PC). You will either need to use qemu- which can be a cpu hog- or you need to setup tunneling into an i386/amd64 machine and watch videos remotely.
> 
> Tingo, what's the kernel hz you have set? Did you rebuild the kernel? Are you using a light desktop such as xfce4, a "box" manager, or some other?
> 
> ...


I know it's kind of old topic, but out of curiosity - won't multimedia/minitube work with YT?


----------



## sossego (Feb 29, 2012)

I did not know about that port. 
Since the FreeBSD Power(PC) porting effort is steadily growing, would anyone be willing to work on using it for multimedia software? Pkubaj, the only problem that I- not really sure about the others- have had is that the Xorg-server seems to lag behind when you move the cursor around. You need to find the right spot and park the cursor. I've seen youtube through html5 running Debian Lenny and Squeeze on my iMac G4. It doesn't run so well. 

 You will definitely need the following so that the application will run good.
1. CPU needs to be 500MHz at the least. Going with a G4 would help a bit.
2. Have your RAM at 512M or more. I'm hoping you already have your swap setup at 512M at least. 
3. Blackbox and Fluxbox work good. Enlightenment is Okay. KDE4 is not the way to go for something like; neither are Gnome nor Xfce4.

That should make a good test environment. It will be a limited test environment but enough to get results.


----------



## sossego (Mar 6, 2012)

For those running [cmd=]make index[/cmd] in /usr/ports:


```
cd /usr/ports/audio/beast
vi Makefile
```
Use the hash/pound sign to edit out the reference to SSE checking.
After this, it should work properly.


----------



## sossego (Mar 11, 2012)

If you are using ports and would like to use packages instead:


```
pkg_delete -a
```

http://www.freebsd.org/doc/handbook/shells.html


```
echo $SHELL
```
If your shell is csh or tcsh then

```
setenv PACKAGESITE ftp://ftp.freebsd.org/pub/FreeBSD/ports/powerpc/packages-9-stable/All
```
 For sh you can edit .shrc and use PACKAGESITE=ftp://ftp.freebsd.org/pub/FreeBSD/ports/powerpc/packages-9-stable/All

Please prepare your powerpc by  pkg_adding perl and python prior to the reinstallment of previous packages.


----------



## sossego (Mar 29, 2012)

If you are having trouble building world then please follow the mailing lists. There is an active effort in using clang. Justin Hibbits is working on the clang errors, Brooks Davis is in charge of clang/llvm; if you have the time and are willing to help with clang/llvm on powerpc(64), then please contact both.
jhibbits@freebsd.org Justin Hibbits
brooks@freebsd.org Brooks Davis

A partial solution is to build each part in src- as applicable to your system- until you get to the error. This will present you with a 9.0/10.0 system to build the kernel.

If you wish to help the FreeBSD powerpc(64) port, then the following are the ones to contact:
Grehan@freebsd.org Peter Grehan, port/project maintainer
nwhitehorn@freebsd.org Nathan Whitehorn
and Justin Hibbits. Both Justin Hibbits and Nathan Whitehorn are source commiters.

danfe@freebsd.org Alexey Dokuchaev has a lot of experience. I suggest that you ask advanced questions with him on the cc list.


----------



## sossego (Apr 1, 2012)

Alright, peoples, here are the current updates.

There is progress with buildworld on Tinderbox.
If you are careful, then you may set /boot/loader.conf with the following variable: 

```
kern.hz="1500"
```
or

```
kern.hz="2000"
```
or

```
kern.hz="2500"
```
Do so at your own discretion. 

Okay, now back to the tutorial.
Anyone that has anything to add to this tutorial, you are welcome to do so. Please let everyone know the environment, methods, and reasons why. 

I am also willing to create a single document tutorial to submit to the FreeBSD POWER(PC) maintainers. It will be upgradeable. For such a tutorial, xorg.conf, loader.conf, and rc.conf variable for different systems will need to be submitted in order that all are able to have a stable system. This will bring more clarity.


----------



## sossego (Mar 15, 2013)

I'm posting this because of the response on an i386. Believe me it is relevant.

Okay, whenever the 
	
	



```
kern.hzâ‰¥2500
```
 the tick rate will increase by one and more as the value of the hertz rate increases. 

Implementing a real-time kernel is something that I know very little about. 

Setting the value at 2000 to 2250 will not hurt. 

This has been discussed on the mailing lists- concerning kernel hertz and frequency-and there is a patch available. Increasing the kernel hertz rate decreases latency to a certain degree. 

A tip on distributing the work load:
If you have two or more machines which we assume are all PowerPC/POWER(32/64) you can use NFS and export a portion of /usr/local from one machine to another. 
One machine can run the windowing and desktop while another has the applications.

Combine this with a higher but safe kernel hertz rate and you should have a nice set up.

Be sure to read on how to properly set up NFS sharing between machines.


----------



## sossego (Mar 30, 2013)

In /etc/X11/xorg.conf change


```
Option "AllowEmptyInput" "Off"
```

to


```
Option  "AutoAddDevices" "Off"
```


----------



## vlotho (Jan 30, 2016)

very good tutorial, but what would be the changes to make for a powerpc g5 quad, please?


----------



## sossego (Apr 20, 2016)

I have not had a chance to work with a 64bit POWER system.


----------

