PREBUILT=/home/user/android-ndk-r5b/toolchains/arm-eabi-4.4.0 PLATFORM=/home/user/android-ndk-r5b/platforms/android-3/arch-arm export CC="/home/user/android-ndk-r5b/toolchains/arm-eabi-4.4.0/prebuilt/linux-x86/bin/arm-eabi-gcc" export CFLAGS="-fPIC -DANDROID -nostdlib" export ANDROID_ROOT="/home/user/android-ndk-r5b" export LDFLAGS="-Wl,-rpath-link=$ANDROID_ROOT/platforms/android-3/arch-arm/usr/lib/ -L$ANDROID_ROOT/platforms/android-3/arch-arm/usr/lib/" export CPPFLAGS="-I$ANDROID_ROOT/platforms/android-3/arch-arm/usr/include/" export LIBS="-lc " ./configure --host=arm-eabi
export LDFLAGS="-Wl,-rpath-link=$ANDROID_ROOT/build/platforms/android-3/arch-arm/usr/lib/ -L$ANDROID_ROOT/build/platforms/android-3/arch-arm/usr/lib/ -L../../libs/armeabi/"
export LIBS="-lc -logg"
LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := libogg LOCAL_C_INCLUDES := $(LOCAL_PATH) \ $(LOCAL_PATH)/../include/ LOCAL_SRC_FILES := framing.c bitwise.c include $(BUILD_SHARED_LIBRARY) #
LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := libvorbis LOCAL_C_INCLUDES := $(LOCAL_PATH) \ $(LOCAL_PATH)/../include \ $(LOCAL_PATH)/../../libogg/include # headers libogg LOCAL_SRC_FILES := mdct.c smallft.c block.c envelope.c window.c lsp.c \ lpc.c analysis.c synthesis.c psy.c info.c \ floor1.c floor0.c\ res0.c mapping0.c registry.c codebook.c sharedbook.c\ lookup.c bitrate.c\ LOCAL_SHARED_LIBRARIES := libogg # LOCAL_LDLIBS := -ldl -lGLESv1_CM -llog include $(BUILD_SHARED_LIBRARY)
LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := libFLAC LOCAL_C_INCLUDES := $(LOCAL_PATH)/libFLAC/include/ \ $(LOCAL_PATH)/../include/ \ $(LOCAL_PATH)/../../libogg/include/ \ $(LOCAL_PATH)/../../vorbis/include/ \ $(LOCAL_PATH)/share/include/ \ $(LOCAL_PATH)/share/utf8/ \ $(LOCAL_PATH)/../include/ \ $(LOCAL_PATH)/../include/share/ \ $(LOCAL_PATH)/share/replaygain_synthesis/include/ \ $(LOCAL_PATH)/../../libogg/include/ \ $(LOCAL_PATH)/../../vorbis/include/ \ $(LOCAL_PATH)/metaflac/include/ \ $(LOCAL_PATH)/../include/ \ $(LOCAL_PATH)/../include/share \ $(LOCAL_PATH)/../../libogg/include/ \ $(LOCAL_PATH)/../../vorbis/include/ \ $(LOCAL_PATH)/flac/ \ $(LOCAL_PATH)/../include/ \ $(LOCAL_PATH)/../../libogg/include/ \ $(LOCAL_PATH)/../../vorbis/include/ \ LOCAL_SRC_FILES := libFLAC/bitmath.c \ libFLAC/bitreader.c \ libFLAC/bitwriter.c \ libFLAC/cpu.c \ libFLAC/crc.c \ libFLAC/fixed.c \ libFLAC/float.c \ libFLAC/format.c \ libFLAC/lpc.c \ libFLAC/md5.c \ libFLAC/memory.c \ libFLAC/metadata_iterators.c \ libFLAC/metadata_object.c \ libFLAC/stream_decoder.c \ libFLAC/stream_encoder.c \ libFLAC/stream_encoder_framing.c \ libFLAC/window.c \ libFLAC/ogg_decoder_aspect.c \ libFLAC/ogg_encoder_aspect.c \ libFLAC/ogg_helper.c \ libFLAC/ogg_mapping.c \ share/getopt/getopt.c share/getopt/getopt1.c \ share/grabbag/cuesheet.c \ share/grabbag/file.c \ share/grabbag/picture.c \ share/grabbag/replaygain.c \ share/grabbag/seektable.c \ share/replaygain_analysis/replaygain_analysis.c \ share/replaygain_synthesis/replaygain_synthesis.c \ share/utf8/charset.c share/utf8/iconvert.c share/utf8/utf8.c \ metaflac/main.c \ metaflac/operations.c \ metaflac/operations_shorthand_cuesheet.c \ metaflac/operations_shorthand_picture.c \ metaflac/operations_shorthand_seektable.c \ metaflac/operations_shorthand_streaminfo.c \ metaflac/operations_shorthand_vorbiscomment.c \ metaflac/options.c \ metaflac/usage.c \ metaflac/utils.c \ flac/analyze.c \ flac/decode.c \ flac/encode.c \ flac/foreign_metadata.c \ flac/local_string_utils.c \ flac/utils.c \ flac/vorbiscomment.c \ LOCAL_SHARED_LIBRARIES := libogg libvorbis LOCAL_LDLIBS := -ldl -lGLESv1_CM -llog include $(BUILD_SHARED_LIBRARY)
/home/user/workspace/w/testOGG/jni/flac-1.2.1/src/libFLAC/format.c:60: error: 'VERSION' undeclared here (not in a function)
/home/user/workspace/w/testOGG/jni/flac-1.2.1/src/libFLAC/format.c:66: error: expected ',' or ';' before 'VERSION'
make: *** [/home/user/workspace/w/testOGG/obj/local/armeabi/objs/FLAC/libFLAC/format.o] 1
#define VERSION "1.2.1"
Install : libFLAC.so => libs/armeabi/libFLAC.so
Install : libogg.so => libs/armeabi/libogg.so
Install : libvorbis.so => libs/armeabi/libvorbis.so
Source: https://habr.com/ru/post/119693/
All Articles