Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 71922
b: refs/heads/master
c: 991b7d6
h: refs/heads/master
v: v3
  • Loading branch information
Kyle McMartin committed Oct 18, 2007
1 parent 2d8f5a6 commit 8bec315
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 39 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 9611f61eb5baf22b6b6ed46c2c196c10e1fade6a
refs/heads/master: 991b7d6e6ffe9373dca7269a5d0213c1545dee1f
62 changes: 24 additions & 38 deletions trunk/arch/parisc/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,26 +19,27 @@
NM = sh $(srctree)/arch/parisc/nm
CHECKFLAGS += -D__hppa__=1

MACHINE := $(shell uname -m)
ifeq ($(MACHINE),parisc*)
NATIVE := 1
endif

ifdef CONFIG_64BIT
CROSS_COMPILE := $(shell if [ -x /usr/bin/hppa64-linux-gnu-gcc ]; then \
echo hppa64-linux-gnu-; else echo hppa64-linux-; fi)
UTS_MACHINE := parisc64
CHECKFLAGS += -D__LP64__=1 -m64
else
MACHINE := $(subst 64,,$(shell uname -m))
ifneq ($(MACHINE),parisc)
CROSS_COMPILE := hppa-linux-
endif
WIDTH := 64
CROSS_COMPILE := hppa64-linux-gnu-
else # 32-bit
WIDTH :=
endif

FINAL_LD=$(CROSS_COMPILE)ld --warn-common --warn-section-align
# attempt to help out folks who are cross-compiling
ifeq ($(NATIVE),1)
CROSS_COMPILE := hppa$(WIDTH)-linux-
endif

OBJCOPY_FLAGS =-O binary -R .note -R .comment -S

ifneq ($(call cc-ifversion, -lt, 0303, "bad"),)
$(error Sorry, GCC v3.3 or above is required.)
endif

cflags-y := -pipe

# These flags should be implied by an hppa-linux configuration, but they
Expand Down Expand Up @@ -73,31 +74,8 @@ libs-y += arch/parisc/lib/

drivers-$(CONFIG_OPROFILE) += arch/parisc/oprofile/

PALO := $(shell if which palo; then : ; \
elif [ -x /sbin/palo ]; then echo /sbin/palo; \
fi)

palo: vmlinux
@if [ -x $PALO ]; then \
echo 'ERROR: Please install palo first (apt-get install palo)';\
echo 'or build it from source and install it somewhere in your $$PATH';\
false; \
fi
@if [ ! -f ./palo.conf ]; then \
cp arch/parisc/defpalo.conf palo.conf; \
echo 'A generic palo config file (./palo.conf) has been created for you.'; \
echo 'You should check it and re-run "make palo".'; \
echo 'WARNING: the "lifimage" file is now placed in this directory by default!'; \
false; \
fi
$(PALO) -f ./palo.conf

oldpalo: vmlinux
export TOPDIR=`pwd`; \
unset STRIP LDFLAGS CPP CPPFLAGS AFLAGS CFLAGS CC LD; cd ../palo && make lifimage

# Shorthands for known targets not supported by parisc, use palo as default
Image zImage bzImage: palo
# Shorthands for known targets not supported by parisc, use vmlinux as default
Image zImage bzImage: vmlinux

kernel_install: vmlinux
sh $(src)/arch/parisc/install.sh \
Expand All @@ -110,9 +88,17 @@ MRPROPER_FILES += palo.conf

define archhelp
@echo '* vmlinux - Uncompressed kernel image (./vmlinux)'
@echo ' palo - Bootable image (./lifimage)'
@echo ' install - Install kernel using'
@echo ' (your) ~/bin/installkernel or'
@echo ' (distribution) /sbin/installkernel or'
@echo ' copy to $$(INSTALL_PATH)'
endef

# we require gcc 3.3 or above to compile the kernel
archprepare: checkbin
checkbin:
@if test "$(call cc-version)" -lt "0303"; then \
echo -n "Sorry, GCC v3.3 or above is required to build " ; \
echo "the kernel." ; \
false ; \
fi

0 comments on commit 8bec315

Please sign in to comment.