Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Makefile fixes #4

Merged
merged 2 commits into from

2 participants

Kaushik Srenevasan marius a. eriksen
Kaushik Srenevasan
Collaborator
  • Move OSX specific linker switches to PLATFORM_LDFLAGS.
  • Make JAVA_HOME overridable on the command line.
marius a. eriksen mariusae merged commit 1f00f90 into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Feb 1, 2013
  1. Kaushik Srenevasan

    - Move OSX specific linker switches to PLATFORM_LDFLAGS.

    kaushiks authored
    - Make JAVA_HOME overridable on the commandline.
  2. Kaushik Srenevasan
This page is out of date. Refresh to see the latest.
Showing with 6 additions and 5 deletions.
  1. +6 −5 Makefile
11 Makefile
View
@@ -2,13 +2,14 @@ CC=gcc
OS=$(shell uname -s | tr '[A-Z]' '[a-z]')
ifeq ("$(OS)", "darwin")
-JAVA_HOME=$(shell /usr/libexec/java_home)
-JAVA_HEADERS=/System/Library/Frameworks/JavaVM.framework/Versions/A/Headers
-#JAVA_HEADERS=/Developer/SDKs/MacOSX10.6.sdk/System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/Headers/
+JAVA_HOME?=$(shell /usr/libexec/java_home)
+JAVA_HEADERS?=/System/Library/Frameworks/JavaVM.framework/Versions/A/Headers
+#JAVA_HEADERS?=/Developer/SDKs/MacOSX10.6.sdk/System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/Headers/
+PLATFORM_LDFLAGS=-mimpure-text
endif
ifeq ("$(OS)", "linux")
-JAVA_HOME=/usr/java/default/
+JAVA_HOME?=/usr/java/default/
JAVA_HEADERS=$(JAVA_HOME)/include -I$(JAVA_HOME)/include/linux
endif
@@ -16,7 +17,7 @@ CFLAGS=-Ijava_crw_demo -fno-strict-aliasing \
-fPIC -fno-omit-frame-pointer -W -Wall -Wno-unused -Wno-parentheses \
-I$(JAVA_HEADERS) -Iinclude
LDFLAGS=-fno-strict-aliasing -fPIC -fno-omit-frame-pointer \
- -static-libgcc -mimpure-text -shared
+ -static-libgcc -shared $(PLATFORM_LDFLAGS)
all: libgcprof.jnilib GcProf.class
Something went wrong with that request. Please try again.