shithub: openh264

Download patch

ref: 99faf1ec4a47c5362a6bde552d6097166e2fda16
parent: 59dae50b1069dbd532226ea024a3ba3982ab4386
parent: cf92e8d6208af51fb55ed61554b135585ed33c1b
author: Ethan Hugg <[email protected]>
date: Tue Dec 10 04:36:42 EST 2013

Merge pull request #8 from ekr/assembly_enable

Merged first cut of new make system.

--- /dev/null
+++ b/Makefile
@@ -1,0 +1,62 @@
+UNAME=$(shell uname | tr A-Z a-z)
+LIBPREFIX=lib
+LIBSUFFIX=a
+ROOTDIR=$(PWD)
+
+# Configurations
+ifeq ($(BUILDTYPE), Release)
+CFLAGS += -O3
+USE_ASM = Yes
+else
+CFLAGS = -g
+USE_ASM = No
+endif
+
+ifeq ($(USE_ASM),Yes)
+  CFLAGS += -DX86_ASM 
+endif
+
+include build/platform-$(UNAME).mk
+
+CFLAGS += -DNO_DYNAMIC_VP -DHAVE_CACHE_LINE_ALIGN
+LDFLAGS +=
+ASMFLAGS += -DNO_DYNAMIC_VP -DNOPREFIX 
+
+
+#### No user-serviceable parts below this line
+INCLUDES = -Icodec/api/svc
+ASM_INCLUDES = -Iprocessing/src/asm/
+
+DECODER_INCLUDES = \
+    -Icodec/decoder/core/inc \
+    -Icodec/decoder/plus/inc
+
+ENCODER_INCLUDES = \
+    -Icodec/encoder/core/inc \
+    -Icodec/encoder/plus/inc \
+    -Icodec/WelsThreadLib/api
+
+PROCESSING_INCLUDES = \
+    -Icodec/encoder/core/inc \
+    -Icodec/encoder/plus/inc
+
+H264DEC_INCLUDES = $(DECODER_INCLUDES) -Icodec/console/dec/inc
+H264DEC_LDFLAGS = -L. -ldecoder
+
+H264ENC_INCLUDES = $(ENCODER_INCLUDES) -Icodec/console/enc/inc
+H264ENC_LDFLAGS = -L. -lencoder -lprocessing
+
+all:	libraries binaries
+
+clean:
+	rm -f $(OBJS) $(LIBRARIES) $(BINARIES)
+
+
+include codec/decoder/targets.mk
+include codec/encoder/targets.mk
+include processing/targets.mk
+include codec/console/dec/targets.mk
+include codec/console/enc/targets.mk
+
+
+
--- /dev/null
+++ b/build/mktargets.py
@@ -1,0 +1,104 @@
+#!/usr/bin/python
+import sys
+import argparse
+import os
+
+parser = argparse.ArgumentParser(description="Make helper parser")
+parser.add_argument("--directory", dest="directory", required=True)
+parser.add_argument("--library", dest="library", help="Make a library")
+parser.add_argument("--binary", dest="binary", help="Make a binary")
+parser.add_argument("--exclude", dest="exclude", help="Exclude file", action="append")
+PREFIX=None
+LIBRARY=None
+BINARY=None
+EXCLUDE=[]
+
+def make_o(x):
+    return os.path.splitext(x)[0] + ".o"
+
+def write_cpp_rule(f, x):
+    src = "$(%s_SRCDIR)/%s"%(PREFIX, x)
+    dst = "$(%s_SRCDIR)/%s"%(PREFIX, make_o(x))
+    
+    f.write("%s: %s\n"%(dst, src))
+    f.write('\t$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(' + PREFIX + '_CFLAGS) $(' + PREFIX + '_INCLUDES) -c -o ' + dst + ' ' + src + '\n');
+    f.write("\n")
+
+def write_asm_rule(f, x):
+    src = "$(%s_SRCDIR)/%s"%(PREFIX, x)
+    dst = "$(%s_SRCDIR)/%s"%(PREFIX, make_o(x))
+    
+    f.write("%s: %s\n"%(dst, src))
+    f.write('\t$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(' + PREFIX + '_ASMFLAGS) $(' + PREFIX + '_ASM_INCLUDES) -o ' + dst + ' ' + src + '\n');
+    f.write("\n")
+
+
+def find_sources():
+    cpp_files = []
+    asm_files = []
+    print EXCLUDE
+    for dir in os.walk("."):
+        for file in dir[2]:
+            if not file in EXCLUDE:
+                if os.path.splitext(file)[1] == '.cpp':
+                    cpp_files.append(os.path.join(dir[0], file))
+                if os.path.splitext(file)[1] == '.asm':
+                    asm_files.append(os.path.join(dir[0], file))
+    return [cpp_files, asm_files]
+
+
+args = parser.parse_args()
+
+if args.library is not None:
+    PREFIX=args.library.upper()
+elif args.binary is not None:
+    PREFIX=args.binary.upper()
+else:
+    sys.stderr.write("Must provide either library or binary")
+    sys.exit(1)
+
+if args.exclude is not None:
+    EXCLUDE = args.exclude
+(cpp, asm) = find_sources()
+
+
+
+f = open("targets.mk", "w")
+f.write("%s_PREFIX=%s\n"%(PREFIX, PREFIX))
+f.write("%s_SRCDIR=%s\n"%(PREFIX, args.directory))
+
+f.write("%s_CPP_SRCS=\\\n"%(PREFIX))
+for c in cpp:
+    f.write("\t$(%s_SRCDIR)/%s\\\n"%(PREFIX, c))
+f.write("\n")    
+f.write("%s_OBJS += $(%s_CPP_SRCS:.cpp=.o)\n"%(PREFIX, PREFIX))
+
+f.write("ifeq ($(USE_ASM), Yes)\n");
+f.write("%s_ASM_SRCS=\\\n"%(PREFIX))
+for c in asm:
+    f.write("\t$(%s_SRCDIR)/%s\\\n"%(PREFIX, c))
+f.write("\n")
+f.write("%s_OBJS += $(%s_ASM_SRCS:.asm=.o)\n"%(PREFIX, PREFIX))
+f.write("endif\n\n")
+
+f.write("OBJS += $(%s_OBJS)\n"%PREFIX)
+
+for c in cpp:
+    write_cpp_rule(f, c)
+
+for a in asm:
+    write_asm_rule(f, a)
+
+if args.library is not None:
+    f.write("$(LIBPREFIX)%s.$(LIBSUFFIX): $(%s_OBJS)\n"%(args.library, PREFIX));
+    f.write("\trm -f $(LIBPREFIX)%s.$(LIBSUFFIX)\n"%args.library)
+    f.write("\tar cr $@ $(%s_OBJS)\n"%PREFIX);
+    f.write("\n");
+    f.write("libraries: $(LIBPREFIX)%s.$(LIBSUFFIX)\n"%args.library);
+    f.write("LIBRARIES += $(LIBPREFIX)%s.$(LIBSUFFIX)\n"%args.library);
+
+if args.binary is not None:
+    f.write("%s: $(%s_OBJS) $(LIBS) $(%s_LIBS)\n"%(args.binary, PREFIX, PREFIX))
+    f.write("\t$(CXX) -o $@  $(%s_OBJS) $(%s_LDFLAGS) $(%s_LIBS) $(LDFLAGS) $(LIBS)\n\n"%(PREFIX, PREFIX, PREFIX))
+    f.write("binaries: %s\n"%args.binary);
+    f.write("BINARIES += %s\n"%args.binary);
--- /dev/null
+++ b/build/mktargets.sh
@@ -1,0 +1,7 @@
+#!/bin/sh
+(cd codec/decoder; python ../../build/mktargets.py --directory codec/decoder --library decoder --exclude StdAfx.cpp)
+(cd codec/encoder; python ../../build/mktargets.py --directory codec/encoder --library encoder --exclude DllEntry.cpp)
+(cd processing; python ../build/mktargets.py --directory processing --library processing --exclude wels_process.cpp --exclude WelsVideoProcessor.cpp)
+
+(cd codec/console/dec; python ../../../build/mktargets.py --directory codec/console/dec --binary h264dec --exclude dec_console.h --exclude load_bundle_functions.cpp)
+(cd codec/console/enc; python ../../../build/mktargets.py --directory codec/console/enc --binary h264enc --exclude enc_console.h --exclude bundlewelsenc.cpp)
--- /dev/null
+++ b/build/platform-darwin.mk
@@ -1,0 +1,5 @@
+USE_ASM = No  # We don't have ASM working on Mac yet
+ASM = nasm
+CFLAGS += -arch i386 -fPIC
+LDFLAGS += -arch i386 -ldl -lpthread
+ASMFLAGS += -f macho --prefix _
--- /dev/null
+++ b/build/platform-linux.mk
@@ -1,0 +1,5 @@
+ASM = nasm
+CFLAGS += -m32 -fPIC -DLINUX -D__NO_CTYPE
+LDFLAGS += -m32 -ldl -lpthread
+ASMFLAGS += -f elf
+
--- a/codec/console/dec/src/h264dec.cpp
+++ b/codec/console/dec/src/h264dec.cpp
@@ -52,9 +52,6 @@
 typedef void_t (*PDestroyDecoderFunc)(ISVCDecoder* pDecoder);
 
 
-#if defined(__APPLE__)
-#include "dec_console.h"
-#endif
 using namespace std;
 
 //using namespace WelsDec;
@@ -346,11 +343,7 @@
 }
 
 
-#if !defined(__APPLE__)
 int32_t main(int32_t iArgC, char* pArgV[])
-#else
-int32_t DecoderMain(int32_t iArgC, char * pArgV[])
-#endif
 {
 	ISVCDecoder *pDecoder = NULL;
 
@@ -488,18 +481,6 @@
 	}
 
 
-#elif defined(__APPLE__)
-
-
-	bool flag_load_bundle = load_bundle_welsdec();
-	
-	get_functions_address_create_decoder(&pDecoder);
-	
-	if (flag_load_bundle == false) {
-		printf( "Create Decoder failed.\n" );
-		return NULL;
-	}	
-
 #else
 
 
@@ -535,8 +516,6 @@
 		
 #if defined(_MSC_VER)
 		pDestroyDecoderFunc( pDecoder );
-#elif defined(__APPLE__)
-		get_functions_address_free_decoder(pDecoder);
 #else
 		DestroyDecoder(pDecoder);
 #endif
--- /dev/null
+++ b/codec/console/dec/targets.mk
@@ -1,0 +1,29 @@
+H264DEC_PREFIX=H264DEC
+H264DEC_SRCDIR=codec/console/dec
+H264DEC_CPP_SRCS=\
+	$(H264DEC_SRCDIR)/./src/d3d9_utils.cpp\
+	$(H264DEC_SRCDIR)/./src/h264dec.cpp\
+	$(H264DEC_SRCDIR)/./src/read_config.cpp\
+
+H264DEC_OBJS += $(H264DEC_CPP_SRCS:.cpp=.o)
+ifeq ($(USE_ASM), Yes)
+H264DEC_ASM_SRCS=\
+
+H264DEC_OBJS += $(H264DEC_ASM_SRCS:.asm=.o)
+endif
+
+OBJS += $(H264DEC_OBJS)
+$(H264DEC_SRCDIR)/./src/d3d9_utils.o: $(H264DEC_SRCDIR)/./src/d3d9_utils.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(H264DEC_CFLAGS) $(H264DEC_INCLUDES) -c -o $(H264DEC_SRCDIR)/./src/d3d9_utils.o $(H264DEC_SRCDIR)/./src/d3d9_utils.cpp
+
+$(H264DEC_SRCDIR)/./src/h264dec.o: $(H264DEC_SRCDIR)/./src/h264dec.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(H264DEC_CFLAGS) $(H264DEC_INCLUDES) -c -o $(H264DEC_SRCDIR)/./src/h264dec.o $(H264DEC_SRCDIR)/./src/h264dec.cpp
+
+$(H264DEC_SRCDIR)/./src/read_config.o: $(H264DEC_SRCDIR)/./src/read_config.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(H264DEC_CFLAGS) $(H264DEC_INCLUDES) -c -o $(H264DEC_SRCDIR)/./src/read_config.o $(H264DEC_SRCDIR)/./src/read_config.cpp
+
+h264dec: $(H264DEC_OBJS) $(LIBS) $(H264DEC_LIBS)
+	$(CXX) -o $@  $(H264DEC_OBJS) $(H264DEC_LDFLAGS) $(H264DEC_LIBS) $(LDFLAGS) $(LIBS)
+
+binaries: h264dec
+BINARIES += h264dec
--- /dev/null
+++ b/codec/console/enc/targets.mk
@@ -1,0 +1,25 @@
+H264ENC_PREFIX=H264ENC
+H264ENC_SRCDIR=codec/console/enc
+H264ENC_CPP_SRCS=\
+	$(H264ENC_SRCDIR)/./src/read_config.cpp\
+	$(H264ENC_SRCDIR)/./src/welsenc.cpp\
+
+H264ENC_OBJS += $(H264ENC_CPP_SRCS:.cpp=.o)
+ifeq ($(USE_ASM), Yes)
+H264ENC_ASM_SRCS=\
+
+H264ENC_OBJS += $(H264ENC_ASM_SRCS:.asm=.o)
+endif
+
+OBJS += $(H264ENC_OBJS)
+$(H264ENC_SRCDIR)/./src/read_config.o: $(H264ENC_SRCDIR)/./src/read_config.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(H264ENC_CFLAGS) $(H264ENC_INCLUDES) -c -o $(H264ENC_SRCDIR)/./src/read_config.o $(H264ENC_SRCDIR)/./src/read_config.cpp
+
+$(H264ENC_SRCDIR)/./src/welsenc.o: $(H264ENC_SRCDIR)/./src/welsenc.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(H264ENC_CFLAGS) $(H264ENC_INCLUDES) -c -o $(H264ENC_SRCDIR)/./src/welsenc.o $(H264ENC_SRCDIR)/./src/welsenc.cpp
+
+h264enc: $(H264ENC_OBJS) $(LIBS) $(H264ENC_LIBS)
+	$(CXX) -o $@  $(H264ENC_OBJS) $(H264ENC_LDFLAGS) $(H264ENC_LIBS) $(LDFLAGS) $(LIBS)
+
+binaries: h264enc
+BINARIES += h264enc
--- /dev/null
+++ b/codec/decoder/targets.mk
@@ -1,0 +1,154 @@
+DECODER_PREFIX=DECODER
+DECODER_SRCDIR=codec/decoder
+DECODER_CPP_SRCS=\
+	$(DECODER_SRCDIR)/./core/src/au_parser.cpp\
+	$(DECODER_SRCDIR)/./core/src/bit_stream.cpp\
+	$(DECODER_SRCDIR)/./core/src/cpu.cpp\
+	$(DECODER_SRCDIR)/./core/src/deblocking.cpp\
+	$(DECODER_SRCDIR)/./core/src/decode_mb_aux.cpp\
+	$(DECODER_SRCDIR)/./core/src/decode_slice.cpp\
+	$(DECODER_SRCDIR)/./core/src/decoder.cpp\
+	$(DECODER_SRCDIR)/./core/src/decoder_core.cpp\
+	$(DECODER_SRCDIR)/./core/src/decoder_data_tables.cpp\
+	$(DECODER_SRCDIR)/./core/src/expand_pic.cpp\
+	$(DECODER_SRCDIR)/./core/src/fmo.cpp\
+	$(DECODER_SRCDIR)/./core/src/get_intra_predictor.cpp\
+	$(DECODER_SRCDIR)/./core/src/manage_dec_ref.cpp\
+	$(DECODER_SRCDIR)/./core/src/mc.cpp\
+	$(DECODER_SRCDIR)/./core/src/mem_align.cpp\
+	$(DECODER_SRCDIR)/./core/src/memmgr_nal_unit.cpp\
+	$(DECODER_SRCDIR)/./core/src/mv_pred.cpp\
+	$(DECODER_SRCDIR)/./core/src/parse_mb_syn_cavlc.cpp\
+	$(DECODER_SRCDIR)/./core/src/pic_queue.cpp\
+	$(DECODER_SRCDIR)/./core/src/rec_mb.cpp\
+	$(DECODER_SRCDIR)/./core/src/utils.cpp\
+	$(DECODER_SRCDIR)/./plus/src/welsCodecTrace.cpp\
+	$(DECODER_SRCDIR)/./plus/src/welsDecoderExt.cpp\
+
+DECODER_OBJS += $(DECODER_CPP_SRCS:.cpp=.o)
+ifeq ($(USE_ASM), Yes)
+DECODER_ASM_SRCS=\
+	$(DECODER_SRCDIR)/./core/asm/asm_inc.asm\
+	$(DECODER_SRCDIR)/./core/asm/block_add.asm\
+	$(DECODER_SRCDIR)/./core/asm/cpuid.asm\
+	$(DECODER_SRCDIR)/./core/asm/dct.asm\
+	$(DECODER_SRCDIR)/./core/asm/deblock.asm\
+	$(DECODER_SRCDIR)/./core/asm/expand_picture.asm\
+	$(DECODER_SRCDIR)/./core/asm/intra_pred.asm\
+	$(DECODER_SRCDIR)/./core/asm/mb_copy.asm\
+	$(DECODER_SRCDIR)/./core/asm/mc_chroma.asm\
+	$(DECODER_SRCDIR)/./core/asm/mc_luma.asm\
+	$(DECODER_SRCDIR)/./core/asm/memzero.asm\
+
+DECODER_OBJS += $(DECODER_ASM_SRCS:.asm=.o)
+endif
+
+OBJS += $(DECODER_OBJS)
+$(DECODER_SRCDIR)/./core/src/au_parser.o: $(DECODER_SRCDIR)/./core/src/au_parser.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/au_parser.o $(DECODER_SRCDIR)/./core/src/au_parser.cpp
+
+$(DECODER_SRCDIR)/./core/src/bit_stream.o: $(DECODER_SRCDIR)/./core/src/bit_stream.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/bit_stream.o $(DECODER_SRCDIR)/./core/src/bit_stream.cpp
+
+$(DECODER_SRCDIR)/./core/src/cpu.o: $(DECODER_SRCDIR)/./core/src/cpu.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/cpu.o $(DECODER_SRCDIR)/./core/src/cpu.cpp
+
+$(DECODER_SRCDIR)/./core/src/deblocking.o: $(DECODER_SRCDIR)/./core/src/deblocking.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/deblocking.o $(DECODER_SRCDIR)/./core/src/deblocking.cpp
+
+$(DECODER_SRCDIR)/./core/src/decode_mb_aux.o: $(DECODER_SRCDIR)/./core/src/decode_mb_aux.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/decode_mb_aux.o $(DECODER_SRCDIR)/./core/src/decode_mb_aux.cpp
+
+$(DECODER_SRCDIR)/./core/src/decode_slice.o: $(DECODER_SRCDIR)/./core/src/decode_slice.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/decode_slice.o $(DECODER_SRCDIR)/./core/src/decode_slice.cpp
+
+$(DECODER_SRCDIR)/./core/src/decoder.o: $(DECODER_SRCDIR)/./core/src/decoder.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/decoder.o $(DECODER_SRCDIR)/./core/src/decoder.cpp
+
+$(DECODER_SRCDIR)/./core/src/decoder_core.o: $(DECODER_SRCDIR)/./core/src/decoder_core.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/decoder_core.o $(DECODER_SRCDIR)/./core/src/decoder_core.cpp
+
+$(DECODER_SRCDIR)/./core/src/decoder_data_tables.o: $(DECODER_SRCDIR)/./core/src/decoder_data_tables.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/decoder_data_tables.o $(DECODER_SRCDIR)/./core/src/decoder_data_tables.cpp
+
+$(DECODER_SRCDIR)/./core/src/expand_pic.o: $(DECODER_SRCDIR)/./core/src/expand_pic.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/expand_pic.o $(DECODER_SRCDIR)/./core/src/expand_pic.cpp
+
+$(DECODER_SRCDIR)/./core/src/fmo.o: $(DECODER_SRCDIR)/./core/src/fmo.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/fmo.o $(DECODER_SRCDIR)/./core/src/fmo.cpp
+
+$(DECODER_SRCDIR)/./core/src/get_intra_predictor.o: $(DECODER_SRCDIR)/./core/src/get_intra_predictor.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/get_intra_predictor.o $(DECODER_SRCDIR)/./core/src/get_intra_predictor.cpp
+
+$(DECODER_SRCDIR)/./core/src/manage_dec_ref.o: $(DECODER_SRCDIR)/./core/src/manage_dec_ref.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/manage_dec_ref.o $(DECODER_SRCDIR)/./core/src/manage_dec_ref.cpp
+
+$(DECODER_SRCDIR)/./core/src/mc.o: $(DECODER_SRCDIR)/./core/src/mc.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/mc.o $(DECODER_SRCDIR)/./core/src/mc.cpp
+
+$(DECODER_SRCDIR)/./core/src/mem_align.o: $(DECODER_SRCDIR)/./core/src/mem_align.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/mem_align.o $(DECODER_SRCDIR)/./core/src/mem_align.cpp
+
+$(DECODER_SRCDIR)/./core/src/memmgr_nal_unit.o: $(DECODER_SRCDIR)/./core/src/memmgr_nal_unit.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/memmgr_nal_unit.o $(DECODER_SRCDIR)/./core/src/memmgr_nal_unit.cpp
+
+$(DECODER_SRCDIR)/./core/src/mv_pred.o: $(DECODER_SRCDIR)/./core/src/mv_pred.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/mv_pred.o $(DECODER_SRCDIR)/./core/src/mv_pred.cpp
+
+$(DECODER_SRCDIR)/./core/src/parse_mb_syn_cavlc.o: $(DECODER_SRCDIR)/./core/src/parse_mb_syn_cavlc.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/parse_mb_syn_cavlc.o $(DECODER_SRCDIR)/./core/src/parse_mb_syn_cavlc.cpp
+
+$(DECODER_SRCDIR)/./core/src/pic_queue.o: $(DECODER_SRCDIR)/./core/src/pic_queue.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/pic_queue.o $(DECODER_SRCDIR)/./core/src/pic_queue.cpp
+
+$(DECODER_SRCDIR)/./core/src/rec_mb.o: $(DECODER_SRCDIR)/./core/src/rec_mb.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/rec_mb.o $(DECODER_SRCDIR)/./core/src/rec_mb.cpp
+
+$(DECODER_SRCDIR)/./core/src/utils.o: $(DECODER_SRCDIR)/./core/src/utils.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./core/src/utils.o $(DECODER_SRCDIR)/./core/src/utils.cpp
+
+$(DECODER_SRCDIR)/./plus/src/welsCodecTrace.o: $(DECODER_SRCDIR)/./plus/src/welsCodecTrace.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./plus/src/welsCodecTrace.o $(DECODER_SRCDIR)/./plus/src/welsCodecTrace.cpp
+
+$(DECODER_SRCDIR)/./plus/src/welsDecoderExt.o: $(DECODER_SRCDIR)/./plus/src/welsDecoderExt.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(DECODER_CFLAGS) $(DECODER_INCLUDES) -c -o $(DECODER_SRCDIR)/./plus/src/welsDecoderExt.o $(DECODER_SRCDIR)/./plus/src/welsDecoderExt.cpp
+
+$(DECODER_SRCDIR)/./core/asm/asm_inc.o: $(DECODER_SRCDIR)/./core/asm/asm_inc.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(DECODER_ASMFLAGS) $(DECODER_ASM_INCLUDES) -o $(DECODER_SRCDIR)/./core/asm/asm_inc.o $(DECODER_SRCDIR)/./core/asm/asm_inc.asm
+
+$(DECODER_SRCDIR)/./core/asm/block_add.o: $(DECODER_SRCDIR)/./core/asm/block_add.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(DECODER_ASMFLAGS) $(DECODER_ASM_INCLUDES) -o $(DECODER_SRCDIR)/./core/asm/block_add.o $(DECODER_SRCDIR)/./core/asm/block_add.asm
+
+$(DECODER_SRCDIR)/./core/asm/cpuid.o: $(DECODER_SRCDIR)/./core/asm/cpuid.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(DECODER_ASMFLAGS) $(DECODER_ASM_INCLUDES) -o $(DECODER_SRCDIR)/./core/asm/cpuid.o $(DECODER_SRCDIR)/./core/asm/cpuid.asm
+
+$(DECODER_SRCDIR)/./core/asm/dct.o: $(DECODER_SRCDIR)/./core/asm/dct.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(DECODER_ASMFLAGS) $(DECODER_ASM_INCLUDES) -o $(DECODER_SRCDIR)/./core/asm/dct.o $(DECODER_SRCDIR)/./core/asm/dct.asm
+
+$(DECODER_SRCDIR)/./core/asm/deblock.o: $(DECODER_SRCDIR)/./core/asm/deblock.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(DECODER_ASMFLAGS) $(DECODER_ASM_INCLUDES) -o $(DECODER_SRCDIR)/./core/asm/deblock.o $(DECODER_SRCDIR)/./core/asm/deblock.asm
+
+$(DECODER_SRCDIR)/./core/asm/expand_picture.o: $(DECODER_SRCDIR)/./core/asm/expand_picture.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(DECODER_ASMFLAGS) $(DECODER_ASM_INCLUDES) -o $(DECODER_SRCDIR)/./core/asm/expand_picture.o $(DECODER_SRCDIR)/./core/asm/expand_picture.asm
+
+$(DECODER_SRCDIR)/./core/asm/intra_pred.o: $(DECODER_SRCDIR)/./core/asm/intra_pred.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(DECODER_ASMFLAGS) $(DECODER_ASM_INCLUDES) -o $(DECODER_SRCDIR)/./core/asm/intra_pred.o $(DECODER_SRCDIR)/./core/asm/intra_pred.asm
+
+$(DECODER_SRCDIR)/./core/asm/mb_copy.o: $(DECODER_SRCDIR)/./core/asm/mb_copy.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(DECODER_ASMFLAGS) $(DECODER_ASM_INCLUDES) -o $(DECODER_SRCDIR)/./core/asm/mb_copy.o $(DECODER_SRCDIR)/./core/asm/mb_copy.asm
+
+$(DECODER_SRCDIR)/./core/asm/mc_chroma.o: $(DECODER_SRCDIR)/./core/asm/mc_chroma.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(DECODER_ASMFLAGS) $(DECODER_ASM_INCLUDES) -o $(DECODER_SRCDIR)/./core/asm/mc_chroma.o $(DECODER_SRCDIR)/./core/asm/mc_chroma.asm
+
+$(DECODER_SRCDIR)/./core/asm/mc_luma.o: $(DECODER_SRCDIR)/./core/asm/mc_luma.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(DECODER_ASMFLAGS) $(DECODER_ASM_INCLUDES) -o $(DECODER_SRCDIR)/./core/asm/mc_luma.o $(DECODER_SRCDIR)/./core/asm/mc_luma.asm
+
+$(DECODER_SRCDIR)/./core/asm/memzero.o: $(DECODER_SRCDIR)/./core/asm/memzero.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(DECODER_ASMFLAGS) $(DECODER_ASM_INCLUDES) -o $(DECODER_SRCDIR)/./core/asm/memzero.o $(DECODER_SRCDIR)/./core/asm/memzero.asm
+
+$(LIBPREFIX)decoder.$(LIBSUFFIX): $(DECODER_OBJS)
+	rm -f $(LIBPREFIX)decoder.$(LIBSUFFIX)
+	ar cr $@ $(DECODER_OBJS)
+
+libraries: $(LIBPREFIX)decoder.$(LIBSUFFIX)
+LIBRARIES += $(LIBPREFIX)decoder.$(LIBSUFFIX)
--- a/codec/encoder/core/src/wels_preprocess.cpp
+++ b/codec/encoder/core/src/wels_preprocess.cpp
@@ -50,11 +50,16 @@
 #include "encoder_context.h"
 #include "utils.h"
 
+#ifdef NO_DYNAMIC_VP
+EResult WELSAPI CreateVpInterface  (void **ppCtx, int iVersion);
+EResult WELSAPI DestroyVpInterface  (void **ppCtx, int iVersion);
+#endif
 
 namespace WelsSVCEnc {
 
 #define WelsSafeDelete(p) if(p){ delete (p); (p) = NULL; }
 
+
 //***** entry API declaration ************************************************************************//
 typedef EResult (WELSAPI *pfnCreateVpInterface)  (void **, int );
 typedef EResult (WELSAPI *pfnDestroyVpInterface) (void * , int );
@@ -87,6 +92,8 @@
 CWelsLib::CWelsLib(void *pEncCtx)
 {
 	m_pInterface[0] = m_pInterface[1] = NULL;
+
+#ifndef NO_DYNAMIC_VP
 #if defined(WIN32)
 	const str_t WelsVPLib[] = "welsvp.dll";
 	HMODULE shModule = LoadLibrary(WelsVPLib);
@@ -111,6 +118,7 @@
 #endif
 
 	m_pVpLib = (void *)shModule;
+#endif
 }
 
 CWelsLib::~CWelsLib()
@@ -136,6 +144,7 @@
 void* CWelsLib::QueryFunction(const str_t *pName)
 {
 	void *pFunc = NULL;
+
 	if (m_pVpLib)
 	{
 #if defined(WIN32)
@@ -158,13 +167,22 @@
 
 int32_t CWelsLib::CreateIface(void **ppEncCtx)
 {
+#ifndef NO_DYNAMIC_VP
 	if (m_pVpLib)
 	{
+
+#endif
 		pfnCreateVpInterface  pCreateVpInterface  = NULL;
 		pfnDestroyVpInterface pDestroyVpInterface = NULL;
 
+#ifndef NO_DYNAMIC_VP
 		pCreateVpInterface  = (pfnCreateVpInterface)  QueryFunction("CreateVpInterface");
 		pDestroyVpInterface = (pfnDestroyVpInterface) QueryFunction("DestroyVpInterface");
+#else
+		pCreateVpInterface  = CreateVpInterface;
+		// TODO([email protected]): This cast corrects a signature difference... This is a potential real problem
+		pDestroyVpInterface = (pfnDestroyVpInterface)DestroyVpInterface;
+#endif
 
 		m_pInterface[0] = (void *)pCreateVpInterface;
 		m_pInterface[1] = (void *)pDestroyVpInterface;
@@ -171,10 +189,12 @@
 
 		if (m_pInterface[0] && m_pInterface[1])
 			pCreateVpInterface(ppEncCtx, WELSVP_INTERFACE_VERION);
+#ifndef NO_DYNAMIC_VP
 	}
 	else
 	{
 	}	
+#endif
 
 	return ppEncCtx ? 0 : 1;
 }
--- /dev/null
+++ b/codec/encoder/targets.mk
@@ -1,0 +1,214 @@
+ENCODER_PREFIX=ENCODER
+ENCODER_SRCDIR=codec/encoder
+ENCODER_CPP_SRCS=\
+	$(ENCODER_SRCDIR)/./core/src/au_set.cpp\
+	$(ENCODER_SRCDIR)/./core/src/cpu.cpp\
+	$(ENCODER_SRCDIR)/./core/src/deblocking.cpp\
+	$(ENCODER_SRCDIR)/./core/src/decode_mb_aux.cpp\
+	$(ENCODER_SRCDIR)/./core/src/encode_mb_aux.cpp\
+	$(ENCODER_SRCDIR)/./core/src/encoder.cpp\
+	$(ENCODER_SRCDIR)/./core/src/encoder_data_tables.cpp\
+	$(ENCODER_SRCDIR)/./core/src/encoder_ext.cpp\
+	$(ENCODER_SRCDIR)/./core/src/expand_pic.cpp\
+	$(ENCODER_SRCDIR)/./core/src/get_intra_predictor.cpp\
+	$(ENCODER_SRCDIR)/./core/src/mc.cpp\
+	$(ENCODER_SRCDIR)/./core/src/md.cpp\
+	$(ENCODER_SRCDIR)/./core/src/memory_align.cpp\
+	$(ENCODER_SRCDIR)/./core/src/mv_pred.cpp\
+	$(ENCODER_SRCDIR)/./core/src/nal_encap.cpp\
+	$(ENCODER_SRCDIR)/./core/src/picture_handle.cpp\
+	$(ENCODER_SRCDIR)/./core/src/property.cpp\
+	$(ENCODER_SRCDIR)/./core/src/ratectl.cpp\
+	$(ENCODER_SRCDIR)/./core/src/ref_list_mgr_svc.cpp\
+	$(ENCODER_SRCDIR)/./core/src/sample.cpp\
+	$(ENCODER_SRCDIR)/./core/src/set_mb_syn_cavlc.cpp\
+	$(ENCODER_SRCDIR)/./core/src/slice_multi_threading.cpp\
+	$(ENCODER_SRCDIR)/./core/src/svc_base_layer_md.cpp\
+	$(ENCODER_SRCDIR)/./core/src/svc_enc_slice_segment.cpp\
+	$(ENCODER_SRCDIR)/./core/src/svc_encode_mb.cpp\
+	$(ENCODER_SRCDIR)/./core/src/svc_encode_slice.cpp\
+	$(ENCODER_SRCDIR)/./core/src/svc_mode_decision.cpp\
+	$(ENCODER_SRCDIR)/./core/src/svc_motion_estimate.cpp\
+	$(ENCODER_SRCDIR)/./core/src/svc_set_mb_syn_cavlc.cpp\
+	$(ENCODER_SRCDIR)/./core/src/utils.cpp\
+	$(ENCODER_SRCDIR)/./core/src/wels_preprocess.cpp\
+	$(ENCODER_SRCDIR)/./plus/src/welsCodecTrace.cpp\
+	$(ENCODER_SRCDIR)/./plus/src/welsEncoderExt.cpp\
+
+ENCODER_OBJS += $(ENCODER_CPP_SRCS:.cpp=.o)
+ifeq ($(USE_ASM), Yes)
+ENCODER_ASM_SRCS=\
+	$(ENCODER_SRCDIR)/./core/asm/asm_inc.asm\
+	$(ENCODER_SRCDIR)/./core/asm/coeff.asm\
+	$(ENCODER_SRCDIR)/./core/asm/cpuid.asm\
+	$(ENCODER_SRCDIR)/./core/asm/dct.asm\
+	$(ENCODER_SRCDIR)/./core/asm/deblock.asm\
+	$(ENCODER_SRCDIR)/./core/asm/expand_picture.asm\
+	$(ENCODER_SRCDIR)/./core/asm/intra_pred.asm\
+	$(ENCODER_SRCDIR)/./core/asm/intra_pred_util.asm\
+	$(ENCODER_SRCDIR)/./core/asm/mb_copy.asm\
+	$(ENCODER_SRCDIR)/./core/asm/mc_chroma.asm\
+	$(ENCODER_SRCDIR)/./core/asm/mc_luma.asm\
+	$(ENCODER_SRCDIR)/./core/asm/memzero.asm\
+	$(ENCODER_SRCDIR)/./core/asm/quant.asm\
+	$(ENCODER_SRCDIR)/./core/asm/satd_sad.asm\
+	$(ENCODER_SRCDIR)/./core/asm/score.asm\
+	$(ENCODER_SRCDIR)/./core/asm/vaa.asm\
+
+ENCODER_OBJS += $(ENCODER_ASM_SRCS:.asm=.o)
+endif
+
+OBJS += $(ENCODER_OBJS)
+$(ENCODER_SRCDIR)/./core/src/au_set.o: $(ENCODER_SRCDIR)/./core/src/au_set.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/au_set.o $(ENCODER_SRCDIR)/./core/src/au_set.cpp
+
+$(ENCODER_SRCDIR)/./core/src/cpu.o: $(ENCODER_SRCDIR)/./core/src/cpu.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/cpu.o $(ENCODER_SRCDIR)/./core/src/cpu.cpp
+
+$(ENCODER_SRCDIR)/./core/src/deblocking.o: $(ENCODER_SRCDIR)/./core/src/deblocking.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/deblocking.o $(ENCODER_SRCDIR)/./core/src/deblocking.cpp
+
+$(ENCODER_SRCDIR)/./core/src/decode_mb_aux.o: $(ENCODER_SRCDIR)/./core/src/decode_mb_aux.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/decode_mb_aux.o $(ENCODER_SRCDIR)/./core/src/decode_mb_aux.cpp
+
+$(ENCODER_SRCDIR)/./core/src/encode_mb_aux.o: $(ENCODER_SRCDIR)/./core/src/encode_mb_aux.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/encode_mb_aux.o $(ENCODER_SRCDIR)/./core/src/encode_mb_aux.cpp
+
+$(ENCODER_SRCDIR)/./core/src/encoder.o: $(ENCODER_SRCDIR)/./core/src/encoder.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/encoder.o $(ENCODER_SRCDIR)/./core/src/encoder.cpp
+
+$(ENCODER_SRCDIR)/./core/src/encoder_data_tables.o: $(ENCODER_SRCDIR)/./core/src/encoder_data_tables.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/encoder_data_tables.o $(ENCODER_SRCDIR)/./core/src/encoder_data_tables.cpp
+
+$(ENCODER_SRCDIR)/./core/src/encoder_ext.o: $(ENCODER_SRCDIR)/./core/src/encoder_ext.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/encoder_ext.o $(ENCODER_SRCDIR)/./core/src/encoder_ext.cpp
+
+$(ENCODER_SRCDIR)/./core/src/expand_pic.o: $(ENCODER_SRCDIR)/./core/src/expand_pic.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/expand_pic.o $(ENCODER_SRCDIR)/./core/src/expand_pic.cpp
+
+$(ENCODER_SRCDIR)/./core/src/get_intra_predictor.o: $(ENCODER_SRCDIR)/./core/src/get_intra_predictor.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/get_intra_predictor.o $(ENCODER_SRCDIR)/./core/src/get_intra_predictor.cpp
+
+$(ENCODER_SRCDIR)/./core/src/mc.o: $(ENCODER_SRCDIR)/./core/src/mc.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/mc.o $(ENCODER_SRCDIR)/./core/src/mc.cpp
+
+$(ENCODER_SRCDIR)/./core/src/md.o: $(ENCODER_SRCDIR)/./core/src/md.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/md.o $(ENCODER_SRCDIR)/./core/src/md.cpp
+
+$(ENCODER_SRCDIR)/./core/src/memory_align.o: $(ENCODER_SRCDIR)/./core/src/memory_align.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/memory_align.o $(ENCODER_SRCDIR)/./core/src/memory_align.cpp
+
+$(ENCODER_SRCDIR)/./core/src/mv_pred.o: $(ENCODER_SRCDIR)/./core/src/mv_pred.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/mv_pred.o $(ENCODER_SRCDIR)/./core/src/mv_pred.cpp
+
+$(ENCODER_SRCDIR)/./core/src/nal_encap.o: $(ENCODER_SRCDIR)/./core/src/nal_encap.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/nal_encap.o $(ENCODER_SRCDIR)/./core/src/nal_encap.cpp
+
+$(ENCODER_SRCDIR)/./core/src/picture_handle.o: $(ENCODER_SRCDIR)/./core/src/picture_handle.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/picture_handle.o $(ENCODER_SRCDIR)/./core/src/picture_handle.cpp
+
+$(ENCODER_SRCDIR)/./core/src/property.o: $(ENCODER_SRCDIR)/./core/src/property.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/property.o $(ENCODER_SRCDIR)/./core/src/property.cpp
+
+$(ENCODER_SRCDIR)/./core/src/ratectl.o: $(ENCODER_SRCDIR)/./core/src/ratectl.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/ratectl.o $(ENCODER_SRCDIR)/./core/src/ratectl.cpp
+
+$(ENCODER_SRCDIR)/./core/src/ref_list_mgr_svc.o: $(ENCODER_SRCDIR)/./core/src/ref_list_mgr_svc.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/ref_list_mgr_svc.o $(ENCODER_SRCDIR)/./core/src/ref_list_mgr_svc.cpp
+
+$(ENCODER_SRCDIR)/./core/src/sample.o: $(ENCODER_SRCDIR)/./core/src/sample.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/sample.o $(ENCODER_SRCDIR)/./core/src/sample.cpp
+
+$(ENCODER_SRCDIR)/./core/src/set_mb_syn_cavlc.o: $(ENCODER_SRCDIR)/./core/src/set_mb_syn_cavlc.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/set_mb_syn_cavlc.o $(ENCODER_SRCDIR)/./core/src/set_mb_syn_cavlc.cpp
+
+$(ENCODER_SRCDIR)/./core/src/slice_multi_threading.o: $(ENCODER_SRCDIR)/./core/src/slice_multi_threading.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/slice_multi_threading.o $(ENCODER_SRCDIR)/./core/src/slice_multi_threading.cpp
+
+$(ENCODER_SRCDIR)/./core/src/svc_base_layer_md.o: $(ENCODER_SRCDIR)/./core/src/svc_base_layer_md.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/svc_base_layer_md.o $(ENCODER_SRCDIR)/./core/src/svc_base_layer_md.cpp
+
+$(ENCODER_SRCDIR)/./core/src/svc_enc_slice_segment.o: $(ENCODER_SRCDIR)/./core/src/svc_enc_slice_segment.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/svc_enc_slice_segment.o $(ENCODER_SRCDIR)/./core/src/svc_enc_slice_segment.cpp
+
+$(ENCODER_SRCDIR)/./core/src/svc_encode_mb.o: $(ENCODER_SRCDIR)/./core/src/svc_encode_mb.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/svc_encode_mb.o $(ENCODER_SRCDIR)/./core/src/svc_encode_mb.cpp
+
+$(ENCODER_SRCDIR)/./core/src/svc_encode_slice.o: $(ENCODER_SRCDIR)/./core/src/svc_encode_slice.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/svc_encode_slice.o $(ENCODER_SRCDIR)/./core/src/svc_encode_slice.cpp
+
+$(ENCODER_SRCDIR)/./core/src/svc_mode_decision.o: $(ENCODER_SRCDIR)/./core/src/svc_mode_decision.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/svc_mode_decision.o $(ENCODER_SRCDIR)/./core/src/svc_mode_decision.cpp
+
+$(ENCODER_SRCDIR)/./core/src/svc_motion_estimate.o: $(ENCODER_SRCDIR)/./core/src/svc_motion_estimate.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/svc_motion_estimate.o $(ENCODER_SRCDIR)/./core/src/svc_motion_estimate.cpp
+
+$(ENCODER_SRCDIR)/./core/src/svc_set_mb_syn_cavlc.o: $(ENCODER_SRCDIR)/./core/src/svc_set_mb_syn_cavlc.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/svc_set_mb_syn_cavlc.o $(ENCODER_SRCDIR)/./core/src/svc_set_mb_syn_cavlc.cpp
+
+$(ENCODER_SRCDIR)/./core/src/utils.o: $(ENCODER_SRCDIR)/./core/src/utils.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/utils.o $(ENCODER_SRCDIR)/./core/src/utils.cpp
+
+$(ENCODER_SRCDIR)/./core/src/wels_preprocess.o: $(ENCODER_SRCDIR)/./core/src/wels_preprocess.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./core/src/wels_preprocess.o $(ENCODER_SRCDIR)/./core/src/wels_preprocess.cpp
+
+$(ENCODER_SRCDIR)/./plus/src/welsCodecTrace.o: $(ENCODER_SRCDIR)/./plus/src/welsCodecTrace.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./plus/src/welsCodecTrace.o $(ENCODER_SRCDIR)/./plus/src/welsCodecTrace.cpp
+
+$(ENCODER_SRCDIR)/./plus/src/welsEncoderExt.o: $(ENCODER_SRCDIR)/./plus/src/welsEncoderExt.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(ENCODER_CFLAGS) $(ENCODER_INCLUDES) -c -o $(ENCODER_SRCDIR)/./plus/src/welsEncoderExt.o $(ENCODER_SRCDIR)/./plus/src/welsEncoderExt.cpp
+
+$(ENCODER_SRCDIR)/./core/asm/asm_inc.o: $(ENCODER_SRCDIR)/./core/asm/asm_inc.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/asm_inc.o $(ENCODER_SRCDIR)/./core/asm/asm_inc.asm
+
+$(ENCODER_SRCDIR)/./core/asm/coeff.o: $(ENCODER_SRCDIR)/./core/asm/coeff.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/coeff.o $(ENCODER_SRCDIR)/./core/asm/coeff.asm
+
+$(ENCODER_SRCDIR)/./core/asm/cpuid.o: $(ENCODER_SRCDIR)/./core/asm/cpuid.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/cpuid.o $(ENCODER_SRCDIR)/./core/asm/cpuid.asm
+
+$(ENCODER_SRCDIR)/./core/asm/dct.o: $(ENCODER_SRCDIR)/./core/asm/dct.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/dct.o $(ENCODER_SRCDIR)/./core/asm/dct.asm
+
+$(ENCODER_SRCDIR)/./core/asm/deblock.o: $(ENCODER_SRCDIR)/./core/asm/deblock.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/deblock.o $(ENCODER_SRCDIR)/./core/asm/deblock.asm
+
+$(ENCODER_SRCDIR)/./core/asm/expand_picture.o: $(ENCODER_SRCDIR)/./core/asm/expand_picture.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/expand_picture.o $(ENCODER_SRCDIR)/./core/asm/expand_picture.asm
+
+$(ENCODER_SRCDIR)/./core/asm/intra_pred.o: $(ENCODER_SRCDIR)/./core/asm/intra_pred.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/intra_pred.o $(ENCODER_SRCDIR)/./core/asm/intra_pred.asm
+
+$(ENCODER_SRCDIR)/./core/asm/intra_pred_util.o: $(ENCODER_SRCDIR)/./core/asm/intra_pred_util.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/intra_pred_util.o $(ENCODER_SRCDIR)/./core/asm/intra_pred_util.asm
+
+$(ENCODER_SRCDIR)/./core/asm/mb_copy.o: $(ENCODER_SRCDIR)/./core/asm/mb_copy.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/mb_copy.o $(ENCODER_SRCDIR)/./core/asm/mb_copy.asm
+
+$(ENCODER_SRCDIR)/./core/asm/mc_chroma.o: $(ENCODER_SRCDIR)/./core/asm/mc_chroma.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/mc_chroma.o $(ENCODER_SRCDIR)/./core/asm/mc_chroma.asm
+
+$(ENCODER_SRCDIR)/./core/asm/mc_luma.o: $(ENCODER_SRCDIR)/./core/asm/mc_luma.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/mc_luma.o $(ENCODER_SRCDIR)/./core/asm/mc_luma.asm
+
+$(ENCODER_SRCDIR)/./core/asm/memzero.o: $(ENCODER_SRCDIR)/./core/asm/memzero.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/memzero.o $(ENCODER_SRCDIR)/./core/asm/memzero.asm
+
+$(ENCODER_SRCDIR)/./core/asm/quant.o: $(ENCODER_SRCDIR)/./core/asm/quant.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/quant.o $(ENCODER_SRCDIR)/./core/asm/quant.asm
+
+$(ENCODER_SRCDIR)/./core/asm/satd_sad.o: $(ENCODER_SRCDIR)/./core/asm/satd_sad.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/satd_sad.o $(ENCODER_SRCDIR)/./core/asm/satd_sad.asm
+
+$(ENCODER_SRCDIR)/./core/asm/score.o: $(ENCODER_SRCDIR)/./core/asm/score.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/score.o $(ENCODER_SRCDIR)/./core/asm/score.asm
+
+$(ENCODER_SRCDIR)/./core/asm/vaa.o: $(ENCODER_SRCDIR)/./core/asm/vaa.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(ENCODER_ASMFLAGS) $(ENCODER_ASM_INCLUDES) -o $(ENCODER_SRCDIR)/./core/asm/vaa.o $(ENCODER_SRCDIR)/./core/asm/vaa.asm
+
+$(LIBPREFIX)encoder.$(LIBSUFFIX): $(ENCODER_OBJS)
+	rm -f $(LIBPREFIX)encoder.$(LIBSUFFIX)
+	ar cr $@ $(ENCODER_OBJS)
+
+libraries: $(LIBPREFIX)encoder.$(LIBSUFFIX)
+LIBRARIES += $(LIBPREFIX)encoder.$(LIBSUFFIX)
--- a/processing/src/asm/vaa.asm
+++ b/processing/src/asm/vaa.asm
@@ -481,6 +481,7 @@
 
 ; , 6/7/2010
 
+%ifndef NO_DYNAMIC_VP
 WELS_EXTERN AnalysisVaaInfoIntra_sse2
 ;***********************************************************************
 ;	int32_t AnalysisVaaInfoIntra_sse2(	uint8_t *pDataY, const int32_t linesize );
@@ -566,7 +567,7 @@
 	pop edx
 	pop ebx
 	ret
-
+        
 WELS_EXTERN AnalysisVaaInfoIntra_ssse3
 ;***********************************************************************
 ;	int32_t AnalysisVaaInfoIntra_ssse3(	uint8_t *pDataY, const int32_t linesize );
@@ -652,8 +653,9 @@
 	pop edx
 	pop ebx
 	ret
-	
+%endif
 	
+	
 
 WELS_EXTERN abs_difference_mbrow_sse2
 ;*************************************************************************************************************
@@ -1584,4 +1586,4 @@
 %undef		tmp_edi
 %undef		pushsize
 %undef		localsize
-	ret
\ No newline at end of file
+	ret
--- a/processing/src/common/WelsFrameWork.cpp
+++ b/processing/src/common/WelsFrameWork.cpp
@@ -93,8 +93,12 @@
 
 CVpFrameWork::CVpFrameWork(uint32_t uiThreadsNum, EResult &eReturn)
 {
-	int32_t iCoreNum = 0;
+	int32_t iCoreNum = 1;
+#ifndef X86_ASM
+	uint32_t uiCPUFlag = 0;
+#else
 	uint32_t uiCPUFlag = WelsCPUFeatureDetect(&iCoreNum);
+#endif
 
 	for (int32_t i = 0; i < MAX_STRATEGY_NUM; i++)
 	{
--- /dev/null
+++ b/processing/targets.mk
@@ -1,0 +1,126 @@
+PROCESSING_PREFIX=PROCESSING
+PROCESSING_SRCDIR=processing
+PROCESSING_CPP_SRCS=\
+	$(PROCESSING_SRCDIR)/./src/adaptivequantization/AdaptiveQuantization.cpp\
+	$(PROCESSING_SRCDIR)/./src/backgounddetection/BackgroundDetection.cpp\
+	$(PROCESSING_SRCDIR)/./src/common/cpu.cpp\
+	$(PROCESSING_SRCDIR)/./src/common/memory.cpp\
+	$(PROCESSING_SRCDIR)/./src/common/thread.cpp\
+	$(PROCESSING_SRCDIR)/./src/common/util.cpp\
+	$(PROCESSING_SRCDIR)/./src/common/WelsFrameWork.cpp\
+	$(PROCESSING_SRCDIR)/./src/common/WelsFrameWorkEx.cpp\
+	$(PROCESSING_SRCDIR)/./src/complexityanalysis/ComplexityAnalysis.cpp\
+	$(PROCESSING_SRCDIR)/./src/denoise/denoise.cpp\
+	$(PROCESSING_SRCDIR)/./src/denoise/denoise_filter.cpp\
+	$(PROCESSING_SRCDIR)/./src/downsample/downsample.cpp\
+	$(PROCESSING_SRCDIR)/./src/downsample/downsamplefuncs.cpp\
+	$(PROCESSING_SRCDIR)/./src/imagerotate/imagerotate.cpp\
+	$(PROCESSING_SRCDIR)/./src/imagerotate/imagerotatefuncs.cpp\
+	$(PROCESSING_SRCDIR)/./src/scenechangedetection/SceneChangeDetection.cpp\
+	$(PROCESSING_SRCDIR)/./src/scenechangedetection/SceneChangeDetectionCommon.cpp\
+	$(PROCESSING_SRCDIR)/./src/testbed/stdafx.cpp\
+	$(PROCESSING_SRCDIR)/./src/vaacalc/vaacalcfuncs.cpp\
+	$(PROCESSING_SRCDIR)/./src/vaacalc/vaacalculation.cpp\
+
+PROCESSING_OBJS += $(PROCESSING_CPP_SRCS:.cpp=.o)
+ifeq ($(USE_ASM), Yes)
+PROCESSING_ASM_SRCS=\
+	$(PROCESSING_SRCDIR)/./src/asm/asm_inc.asm\
+	$(PROCESSING_SRCDIR)/./src/asm/cpuid.asm\
+	$(PROCESSING_SRCDIR)/./src/asm/denoisefilter.asm\
+	$(PROCESSING_SRCDIR)/./src/asm/downsample_bilinear.asm\
+	$(PROCESSING_SRCDIR)/./src/asm/intra_pred.asm\
+	$(PROCESSING_SRCDIR)/./src/asm/sad.asm\
+	$(PROCESSING_SRCDIR)/./src/asm/vaa.asm\
+
+PROCESSING_OBJS += $(PROCESSING_ASM_SRCS:.asm=.o)
+endif
+
+OBJS += $(PROCESSING_OBJS)
+$(PROCESSING_SRCDIR)/./src/adaptivequantization/AdaptiveQuantization.o: $(PROCESSING_SRCDIR)/./src/adaptivequantization/AdaptiveQuantization.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/adaptivequantization/AdaptiveQuantization.o $(PROCESSING_SRCDIR)/./src/adaptivequantization/AdaptiveQuantization.cpp
+
+$(PROCESSING_SRCDIR)/./src/backgounddetection/BackgroundDetection.o: $(PROCESSING_SRCDIR)/./src/backgounddetection/BackgroundDetection.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/backgounddetection/BackgroundDetection.o $(PROCESSING_SRCDIR)/./src/backgounddetection/BackgroundDetection.cpp
+
+$(PROCESSING_SRCDIR)/./src/common/cpu.o: $(PROCESSING_SRCDIR)/./src/common/cpu.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/common/cpu.o $(PROCESSING_SRCDIR)/./src/common/cpu.cpp
+
+$(PROCESSING_SRCDIR)/./src/common/memory.o: $(PROCESSING_SRCDIR)/./src/common/memory.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/common/memory.o $(PROCESSING_SRCDIR)/./src/common/memory.cpp
+
+$(PROCESSING_SRCDIR)/./src/common/thread.o: $(PROCESSING_SRCDIR)/./src/common/thread.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/common/thread.o $(PROCESSING_SRCDIR)/./src/common/thread.cpp
+
+$(PROCESSING_SRCDIR)/./src/common/util.o: $(PROCESSING_SRCDIR)/./src/common/util.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/common/util.o $(PROCESSING_SRCDIR)/./src/common/util.cpp
+
+$(PROCESSING_SRCDIR)/./src/common/WelsFrameWork.o: $(PROCESSING_SRCDIR)/./src/common/WelsFrameWork.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/common/WelsFrameWork.o $(PROCESSING_SRCDIR)/./src/common/WelsFrameWork.cpp
+
+$(PROCESSING_SRCDIR)/./src/common/WelsFrameWorkEx.o: $(PROCESSING_SRCDIR)/./src/common/WelsFrameWorkEx.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/common/WelsFrameWorkEx.o $(PROCESSING_SRCDIR)/./src/common/WelsFrameWorkEx.cpp
+
+$(PROCESSING_SRCDIR)/./src/complexityanalysis/ComplexityAnalysis.o: $(PROCESSING_SRCDIR)/./src/complexityanalysis/ComplexityAnalysis.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/complexityanalysis/ComplexityAnalysis.o $(PROCESSING_SRCDIR)/./src/complexityanalysis/ComplexityAnalysis.cpp
+
+$(PROCESSING_SRCDIR)/./src/denoise/denoise.o: $(PROCESSING_SRCDIR)/./src/denoise/denoise.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/denoise/denoise.o $(PROCESSING_SRCDIR)/./src/denoise/denoise.cpp
+
+$(PROCESSING_SRCDIR)/./src/denoise/denoise_filter.o: $(PROCESSING_SRCDIR)/./src/denoise/denoise_filter.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/denoise/denoise_filter.o $(PROCESSING_SRCDIR)/./src/denoise/denoise_filter.cpp
+
+$(PROCESSING_SRCDIR)/./src/downsample/downsample.o: $(PROCESSING_SRCDIR)/./src/downsample/downsample.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/downsample/downsample.o $(PROCESSING_SRCDIR)/./src/downsample/downsample.cpp
+
+$(PROCESSING_SRCDIR)/./src/downsample/downsamplefuncs.o: $(PROCESSING_SRCDIR)/./src/downsample/downsamplefuncs.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/downsample/downsamplefuncs.o $(PROCESSING_SRCDIR)/./src/downsample/downsamplefuncs.cpp
+
+$(PROCESSING_SRCDIR)/./src/imagerotate/imagerotate.o: $(PROCESSING_SRCDIR)/./src/imagerotate/imagerotate.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/imagerotate/imagerotate.o $(PROCESSING_SRCDIR)/./src/imagerotate/imagerotate.cpp
+
+$(PROCESSING_SRCDIR)/./src/imagerotate/imagerotatefuncs.o: $(PROCESSING_SRCDIR)/./src/imagerotate/imagerotatefuncs.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/imagerotate/imagerotatefuncs.o $(PROCESSING_SRCDIR)/./src/imagerotate/imagerotatefuncs.cpp
+
+$(PROCESSING_SRCDIR)/./src/scenechangedetection/SceneChangeDetection.o: $(PROCESSING_SRCDIR)/./src/scenechangedetection/SceneChangeDetection.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/scenechangedetection/SceneChangeDetection.o $(PROCESSING_SRCDIR)/./src/scenechangedetection/SceneChangeDetection.cpp
+
+$(PROCESSING_SRCDIR)/./src/scenechangedetection/SceneChangeDetectionCommon.o: $(PROCESSING_SRCDIR)/./src/scenechangedetection/SceneChangeDetectionCommon.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/scenechangedetection/SceneChangeDetectionCommon.o $(PROCESSING_SRCDIR)/./src/scenechangedetection/SceneChangeDetectionCommon.cpp
+
+$(PROCESSING_SRCDIR)/./src/testbed/stdafx.o: $(PROCESSING_SRCDIR)/./src/testbed/stdafx.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/testbed/stdafx.o $(PROCESSING_SRCDIR)/./src/testbed/stdafx.cpp
+
+$(PROCESSING_SRCDIR)/./src/vaacalc/vaacalcfuncs.o: $(PROCESSING_SRCDIR)/./src/vaacalc/vaacalcfuncs.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/vaacalc/vaacalcfuncs.o $(PROCESSING_SRCDIR)/./src/vaacalc/vaacalcfuncs.cpp
+
+$(PROCESSING_SRCDIR)/./src/vaacalc/vaacalculation.o: $(PROCESSING_SRCDIR)/./src/vaacalc/vaacalculation.cpp
+	$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(PROCESSING_CFLAGS) $(PROCESSING_INCLUDES) -c -o $(PROCESSING_SRCDIR)/./src/vaacalc/vaacalculation.o $(PROCESSING_SRCDIR)/./src/vaacalc/vaacalculation.cpp
+
+$(PROCESSING_SRCDIR)/./src/asm/asm_inc.o: $(PROCESSING_SRCDIR)/./src/asm/asm_inc.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(PROCESSING_ASMFLAGS) $(PROCESSING_ASM_INCLUDES) -o $(PROCESSING_SRCDIR)/./src/asm/asm_inc.o $(PROCESSING_SRCDIR)/./src/asm/asm_inc.asm
+
+$(PROCESSING_SRCDIR)/./src/asm/cpuid.o: $(PROCESSING_SRCDIR)/./src/asm/cpuid.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(PROCESSING_ASMFLAGS) $(PROCESSING_ASM_INCLUDES) -o $(PROCESSING_SRCDIR)/./src/asm/cpuid.o $(PROCESSING_SRCDIR)/./src/asm/cpuid.asm
+
+$(PROCESSING_SRCDIR)/./src/asm/denoisefilter.o: $(PROCESSING_SRCDIR)/./src/asm/denoisefilter.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(PROCESSING_ASMFLAGS) $(PROCESSING_ASM_INCLUDES) -o $(PROCESSING_SRCDIR)/./src/asm/denoisefilter.o $(PROCESSING_SRCDIR)/./src/asm/denoisefilter.asm
+
+$(PROCESSING_SRCDIR)/./src/asm/downsample_bilinear.o: $(PROCESSING_SRCDIR)/./src/asm/downsample_bilinear.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(PROCESSING_ASMFLAGS) $(PROCESSING_ASM_INCLUDES) -o $(PROCESSING_SRCDIR)/./src/asm/downsample_bilinear.o $(PROCESSING_SRCDIR)/./src/asm/downsample_bilinear.asm
+
+$(PROCESSING_SRCDIR)/./src/asm/intra_pred.o: $(PROCESSING_SRCDIR)/./src/asm/intra_pred.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(PROCESSING_ASMFLAGS) $(PROCESSING_ASM_INCLUDES) -o $(PROCESSING_SRCDIR)/./src/asm/intra_pred.o $(PROCESSING_SRCDIR)/./src/asm/intra_pred.asm
+
+$(PROCESSING_SRCDIR)/./src/asm/sad.o: $(PROCESSING_SRCDIR)/./src/asm/sad.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(PROCESSING_ASMFLAGS) $(PROCESSING_ASM_INCLUDES) -o $(PROCESSING_SRCDIR)/./src/asm/sad.o $(PROCESSING_SRCDIR)/./src/asm/sad.asm
+
+$(PROCESSING_SRCDIR)/./src/asm/vaa.o: $(PROCESSING_SRCDIR)/./src/asm/vaa.asm
+	$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(PROCESSING_ASMFLAGS) $(PROCESSING_ASM_INCLUDES) -o $(PROCESSING_SRCDIR)/./src/asm/vaa.o $(PROCESSING_SRCDIR)/./src/asm/vaa.asm
+
+$(LIBPREFIX)processing.$(LIBSUFFIX): $(PROCESSING_OBJS)
+	rm -f $(LIBPREFIX)processing.$(LIBSUFFIX)
+	ar cr $@ $(PROCESSING_OBJS)
+
+libraries: $(LIBPREFIX)processing.$(LIBSUFFIX)
+LIBRARIES += $(LIBPREFIX)processing.$(LIBSUFFIX)