# mysql55-client ports installation



## arunkumar (Apr 28, 2011)

Hi all,

I just installed FreeBSD 8.2_RELEASE. I haven't updated the system. It is a fresh install from the cd. I am trying to install the mysql55-client port. But I face the following issue:


```
Scanning dependencies of target comp_err
[ 87%] Building C object extra/CMakeFiles/comp_err.dir/comp_err.c.o
Linking C executable comp_err
[ 87%] Built target comp_err
Scanning dependencies of target mysql_waitpid
[ 87%] Building C object extra/CMakeFiles/mysql_waitpid.dir/mysql_waitpid.c.o
Linking C executable mysql_waitpid
[ 87%] Built target mysql_waitpid
Scanning dependencies of target GenError
[ 87%] Generating ../include/mysqld_error.h, ../sql/share/english/errmsg.sys
Segmentation fault (core dumped)
*** Error code 139
1 error
*** Error code 2
1 error
*** Error code 2
1 error
*** Error code 1

Stop in /usr/ports/databases/mysql55-client.
*** Error code 1
```

Can someone help me with this? I also get the same error if I try to install the mysql55-server port too.

Rgds
arun


----------



## SirDice (Apr 28, 2011)

Use the standard GCC, not 4.4 or 4.6.


----------



## arunkumar (Apr 29, 2011)

I am using gcc version 4.2.1 20070719  [FreeBSD]. I am not sure if I have any other versions of gcc installed in my system. I did a [cmd=]gcc -v[/cmd] and it returned 4.2.1. How do I find out which gcc did the port use to compile mysql55-client?


----------



## SirDice (Apr 29, 2011)

Ok, that's good. Did you update the ports tree after you installed FreeBSD?

The ports tree that comes with the -RELEASE CDs tend to be old by the time you use it.

Also check /etc/make.conf and remove any CFLAGS or similar if they are there.


----------



## arunkumar (Apr 30, 2011)

Following is the content of my /etc/make.conf


```
[root@freebsd /etc]# cat make.conf
# added by use.perl 2011-04-24 19:32:44
PERL_VERSION=5.10.1
[root@freebsd /etc]#
```


Also my ports tree is the latest. I did a `csup -L 2 /my/sup-file`


----------



## Casper21 (May 7, 2011)

I'm having the same problem as arunkumar when installing mysql55-server from ports.  Fresh install, updated ports; not sure what's going wrong.  


```
[ 23%] Built target resolve_stack_dump
[ 23%] Built target resolveip
[ 23%] Built target mysql_tzinfo_to_sql
[ 23%] Generating ../include/mysqld_error.h, ../sql/share/english/errmsg.sys
Segmentation fault (core dumped)
*** Error code 139
1 error
*** Error code 2
1 error
*** Error code 2
1 error
*** Error code 1

Stop in /usr/ports/databases/mysql55-server.
*** Error code 1

Stop in /usr/ports/databases/mysql55-server.
```

Any ideas?


----------



## hortec_bsd (Aug 31, 2011)

I commented out CPUTYPE from make.conf and then it compiled fine even with gcc46. 

N.B. I did not use any compiler optimization flags in my make.conf.


----------



## kl12593 (Sep 13, 2011)

I got the same problem, even I have the simplest /etc/make.conf as below:

```
[root@www /etc]# cat make.conf
# added by use.perl 2011-09-13 21:32:44
PERL_VERSION=5.14.1
```

I executed [cmd=]portsnap fetch extract[/cmd] before [cmd=]make install clean[/cmd] under mysql55-server, so basically, I do not think this is the problem of mysql55, it seems cmake has the problem.

Any ideas to fix or workaround?

Many thanks.
Kerry


----------



## koljenovic (Jan 1, 2012)

I failed compilation a couple of times with error 139 (gcc 4.2.1), then tried this and succeeded:

```
cd /usr/ports/databases/mysql55-server
make BUILD_OPTIMIZED=no BUILD_STATIC=no
make install clean
```


----------



## dalescott (Jan 10, 2012)

Does anyone have a solution that's not described here? I get the same error building mysql55-client as the original poster (fresh 8.2-RELEASE install from DVD, then *freebsd-update fetch/install* and *portsnap fetch/install*). Apache22 was installed first from ports (without error). All combinations of BUILD_OPTIMIZED and BUILD_STATIC were tried, but error always same. Have default make.conf (trivial, as per posting by kl12593). Anyone?

Best regards,
Dale


----------



## SirDice (Jan 11, 2012)

FWIW I just finished building databases/mysql55-server with a ports tree updated on December 25th (MySQL hasn't been updated since). It builds just fine with the standard options on FreeBSD-8.2-STABLE (January 8).


----------



## Magreef (Feb 24, 2012)

Hi to all.

I had the same error at mysql-server55 installing, and reason was in SSL option for this port.

But now *I* try to install the cyrus-sasl2 port and exactly the same error. I looked at the options of the port, but couldn't find anything about SSL.

Any ideas?


----------



## Magreef (Feb 24, 2012)

It*'s* strange. But *I* will write the solution for me.


```
make buildworld
cd /usr/local/share/mysql/
chmode 777 english/
```

I don't know exactly which command was the solution, but anyway, *I* made only these two changes.

Then installation got over 89% and the system gives me a new error 
	
	



```
mysql-client55 version is old
```
 and *I* need to upgrade it. After re-installation of mysql-client55 everything is ok, and cyrus-sasl2 now installed on my freebsd FreeBSD 8.2.


----------



## zigfrid (Jul 6, 2012)

I had a same problem with installation of mysql55-server through ports.
I fixed it with 

```
chmod -R 777 /usr/ports/databases/mysql55-server/work/mysql-5.5.25
```


----------

