Raphael | 6508be1 | 2009-10-11 22:32:49 -0700 | [diff] [blame^] | 1 | # Copyright 2009 The Android Open Source Project |
| 2 | # |
| 3 | # Android.mk for sdklauncher |
| 4 | # |
| 5 | # The "SDK Launcher" is for Windows only. |
| 6 | # This simple .exe will sit at the root of the Windows SDK |
| 7 | # and currently simply executes tools\android.bat. |
| 8 | # Eventually it should simply replace the batch file. |
| 9 | |
| 10 | ifeq ($(HOST_OS),windows) |
| 11 | |
| 12 | LOCAL_PATH:= $(call my-dir) |
| 13 | |
| 14 | include $(CLEAR_VARS) |
| 15 | |
| 16 | LOCAL_SRC_FILES := \ |
| 17 | sdklauncher.c |
| 18 | |
| 19 | LOCAL_CFLAGS += -Wall -Wno-unused-parameter |
| 20 | LOCAL_CFLAGS += -D_XOPEN_SOURCE -D_GNU_SOURCE -DSH_HISTORY |
| 21 | LOCAL_MODULE := sdklauncher |
| 22 | |
| 23 | # Link the Windows icon file as well into the executable, based on the technique |
| 24 | # used in external/qemu/Makefile.android. |
| 25 | # |
| 26 | INTERMEDIATE := $(call intermediates-dir-for,EXECUTABLES,$(LOCAL_MODULE),true) |
| 27 | ANDROID_ICON_OBJ := android_icon.o |
| 28 | ANDROID_ICON_PATH := $(LOCAL_PATH)/images |
| 29 | $(ANDROID_ICON_PATH)/$(ANDROID_ICON_OBJ): $(ANDROID_ICON_PATH)/android_icon.rc |
| 30 | windres $< -I $(ANDROID_ICON_PATH) -o $@ |
| 31 | |
| 32 | # seems to be the only way to add an object file that was not generated from |
| 33 | # a C/C++/Java source file to our build system. and very unfortunately, |
| 34 | # $(TOPDIR)/$(LOCALPATH) will always be prepended to this value, which forces |
| 35 | # us to put the object file in the source directory... |
| 36 | # |
| 37 | LOCAL_PREBUILT_OBJ_FILES += images/$(ANDROID_ICON_OBJ) |
| 38 | |
| 39 | include $(BUILD_HOST_EXECUTABLE) |
| 40 | |
| 41 | $(call dist-for-goals,droid,$(LOCAL_BUILT_MODULE)) |
| 42 | |
| 43 | endif |