# 9.1rc1 problem running buildworld with rc2 src



## malco_2001 (Oct 9, 2012)

Running this from FreeBSD 9.1 RC1 to update to RC2

```
svn co svn://svn0.us-west.freebsd.org/base/stable/9 /usr/src
make buildworld
```
will generate this

```
cc  -O2 -pipe  -I/usr/src/lib/libc/include -I/usr/src/lib/libc/../../include -I/usr/src/lib/libc/amd64 -DNLS  -D__DBINTERFACE_PRIVATE -I/usr/src/lib/libc/../../contrib/gdtoa -DINET6 -I/usr/obj/usr/src/lib/libc -I/usr/src/lib/libc/resolv -D_ACL_PRIVATE -DPOSIX_MISTAKE -I/usr/src/lib/libc/../../contrib/tzcode/stdtime -I/usr/src/lib/libc/stdtime -I/usr/src/lib/libc/locale -DBROKEN_DES -DPORTMAP -DDES_BUILTIN -I/usr/src/lib/libc/rpc -DYP -DNS_CACHING -DSYMBOL_VERSIONING -std=gnu99 -fstack-protector -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c nsparser.c -o nsparser.o
cc1: warnings being treated as errors
/usr/src/lib/libc/net/nsparser.y: In function '_nsaddsrctomap':
/usr/src/lib/libc/net/nsparser.y:169: warning: implicit declaration of function 'free'
In file included from nsparser.c:398:
/usr/src/lib/libc/../../include/stdlib.h: At top level:
/usr/src/lib/libc/../../include/stdlib.h:93: warning: conflicting types for 'free'
/usr/src/lib/libc/net/nsparser.y:169: warning: previous implicit declaration of 'free' was here
*** [nsparser.o] Error code 1

Stop in /usr/src/lib/libc.
*** [lib/libc__L] Error code 1

Stop in /usr/src.
*** [libraries] Error code 1

Stop in /usr/src.
*** [_libraries] Error code 1

Stop in /usr/src.
*** [buildworld] Error code 1

Stop in /usr/src.
root@bsd91rc1:/usr/src #
```
I am able to build the src on a fresh install of rc2.  Has anyone else run into this?


----------



## SirDice (Oct 9, 2012)

Did you do a *make clean* first?

Can you also post /etc/make.conf and /etc/src.conf?

NB stable/9 will not get you 9.1-RC2. It will get you 9-STABLE, which is currently 9.1-PRERELEASE.


----------



## iamthewalrus (Oct 9, 2012)

I am having the same problem building world from 9.1-RC1. I have tried compiling off the svn pull as stated above
as well as the src.txz from ftp://ftp.freebsd.org/pub/FreeBSD/releases/amd64/amd64/9.1-RC2; both have the same result.
Currently I am building with clang, but buildworld errors out the same with or without it.
Every buildworld was made clean before compiling.

uname -a

```
FreeBSD saturn 9.1-RC1 FreeBSD 9.1-RC1 #0: Thu Aug  9 09:41:50 PDT 2012     root@build9x64.pcbsd.org:/usr/obj/builds/amd64/pcbsd-build90/fbsd-source/9.1/sys/GENERIC  amd64
```

/etc/make.conf

```
#Build with clang
CC=clang
CXX=clang++
CPP=clang-cpp
# This setting to build world without -Werror:
#NO_WERROR=
# This setting to build kernel without -Werror:
#WERROR=
# Don't forget this when using Jails!
NO_FSCHG=

# added by use.perl 2012-10-05 16:38:05
PERL_VERSION=5.14.2
```

/etc/src.conf
Does Not Exist​
Build error

```
clang  -O2 -pipe  -I/usr/src/lib/libc/include -I/usr/src/lib/libc/../../include -I/usr/src/lib/libc/amd64 -DNLS  -D__DBINTERFACE_PRIVATE -I/usr/src/lib/libc/../../contrib/gdtoa -DINET6 -I/usr/obj/usr/src/lib/libc -I/usr/src/lib/libc/resolv -D_ACL_PRIVATE -DPOSIX_MISTAKE -I/usr/src/lib/libc/../../contrib/tzcode/stdtime -I/usr/src/lib/libc/stdtime -I/usr/src/lib/libc/locale -DBROKEN_DES -DPORTMAP -DDES_BUILTIN -I/usr/src/lib/libc/rpc -DYP -DNS_CACHING -DSYMBOL_VERSIONING -std=gnu99 -Qunused-arguments -fstack-protector -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -Wno-empty-body -Wno-string-plus-int -Wno-tautological-compare -Wno-unused-value -Wno-parentheses-equality -Wno-unused-function -Wno-conversion -Wno-switch -Wno-switch-enum -c nsparser.c -o nsparser.o
/usr/src/lib/libc/net/nsparser.y:169:4: error: implicit declaration of function 'free' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
                        free((void*)elem);
                        ^
In file included from nsparser.c:398:
/usr/src/lib/libc/../../include/stdlib.h:93:7: error: conflicting types for 'free'
void     free(void *);
         ^
/usr/src/lib/libc/net/nsparser.y:169:4: note: previous implicit declaration is here
                        free((void*)elem);
                        ^
2 errors generated.
*** [nsparser.o] Error code 1

Stop in /usr/src/lib/libc.
*** [lib/libc__L] Error code 1

Stop in /usr/src.
*** [libraries] Error code 1

Stop in /usr/src.
*** [_libraries] Error code 1

Stop in /usr/src.
*** [buildworld] Error code 1

Stop in /usr/src.
```


----------



## iamthewalrus (Oct 9, 2012)

I also just tried a build from svn://svn0.us-west.freebsd.org/base/releng/9.1 and recieved the same error.


----------



## malco_2001 (Oct 9, 2012)

SirDice said:
			
		

> Did you do a *make clean* first?


Yes.  I have also tested this on a fresh install of 9.1 RC1 when I encountered problems with my existing installation of 9.1 RC1.



			
				SirDice said:
			
		

> Can you also post /etc/make.conf and /etc/src.conf?


There are no make.conf or src.conf files present on the fresh install.  For my existing install of 9.1 RC1 which I have also tried here is the make.conf:


```
# cat make.conf
# Uncomment this if you want to do port builds with no interaction
#BATCH=yes

# Keep KDE4 in /usr/local, fixes sharing of icons / mime and others
KDE4_PREFIX=/usr/local
# added by use.perl 2012-08-23 06:05:45
PERL_VERSION=5.14.2
```

I do not have an /etc/src.conf file present for my existing installation of 9.1 RC1.


----------



## malco_2001 (Oct 9, 2012)

I was unable to edit my post to correct my error.  Here is my make.conf.


```
# Uncomment this if you want to do port builds with no interaction
#BATCH=yes

# Keep KDE4 in /usr/local, fixes sharing of icons / mime and others
KDE4_PREFIX=/usr/local
# added by use.perl 2012-08-23 06:05:45
PERL_VERSION=5.14.2
```


----------



## malco_2001 (Oct 9, 2012)

After looking into this further I was not able to compile /usr/src even under 9.1 rc1 so the problem was not with the rc2 source after all.  The problem was fixed in rc2.  I was able to upgrade to rc2 by using freebsd-update(8).


----------

