Skip to content

Commit

Permalink
* Connect ar(1) to the build and make it default ar. Rename GNU
Browse files Browse the repository at this point in the history
binutils ar and ranlib to gar and granlib, respectively.

* Introduce a temporary variable WITH_GNUAR as a safety net.
When buildworld with -DWITH_GNUAR, GNU binutils ar and ranlib
will install as default ones and 'BSD' ar will be disabled.

* Bump __FreeBSD_version to reflect the import of 'BSD' ar(1).

Approved by:		 jkoshy (mentor)
  • Loading branch information
Kai Wang authored and Kai Wang committed Feb 21, 2008
1 parent 741ac35 commit d0e2aba
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 1 deletion.
5 changes: 5 additions & 0 deletions gnu/usr.bin/binutils/ar/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,12 @@

.PATH: ${SRCDIR}/binutils ${SRCDIR}/binutils/doc

.if defined(WITH_GNUAR)
PROG= ar
.else
PROG= gar
MAN= ar.1
.endif
SRCS= ar.c not-ranlib.c
CFLAGS+= -D_GNU_SOURCE
CFLAGS+= -I${.CURDIR}/${RELTOP}/libbinutils
Expand Down
5 changes: 5 additions & 0 deletions gnu/usr.bin/binutils/ranlib/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,12 @@

.PATH: ${SRCDIR}/binutils ${SRCDIR}/binutils/doc

.if defined(WITH_GNUAR)
PROG= ranlib
.else
PROG= granlib
MAN= ranlib.1
.endif
SRCS= ar.c is-ranlib.c
CFLAGS+= -D_GNU_SOURCE
CFLAGS+= -I${.CURDIR}/${RELTOP}/libbinutils
Expand Down
2 changes: 1 addition & 1 deletion sys/sys/param.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
* is created, otherwise 1.
*/
#undef __FreeBSD_version
#define __FreeBSD_version 800021 /* Master, propagated to newvers */
#define __FreeBSD_version 800022 /* Master, propagated to newvers */

#ifndef LOCORE
#include <sys/types.h>
Expand Down
4 changes: 4 additions & 0 deletions usr.bin/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,10 @@ SUBDIR= alias \
${_ypmatch} \
${_ypwhich}

.if !defined(WITH_GNUAR)
SUBDIR+= ar
.endif

.if ${MACHINE_ARCH} != "arm"
_truss= truss
.endif
Expand Down

0 comments on commit d0e2aba

Please sign in to comment.