drummer/go.sh
Arnaud G. GIBERT 8844bd636f - Add utils.h & utils.c files,
- Implement DR_Kit_Id_Convert() and DR_Bank_Program_Id_Convert(),
- Implement UI title label and id_bank_program label update,
- Add GPL3 license file & file headers.
2024-04-14 16:17:19 +02:00

46 lines
1.7 KiB
Bash
Executable File

#!/bin/bash
common_src_list="libnode.c utils.c datastruct.c"
main_src_list="drummer.c"
common_lv2_src_list="lv2_utils.c"
lv2_src_list="lv2_plugin.c lv2_ui.c"
# gtk_includes="-I/usr/include/gtk-3.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pango-1.0 -I/usr/include/harfbuzz -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/atk-1.0"
gtk_includes="-I/usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include/ -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/harfbuzz -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/atk-1.0"
includes="-I/usr/include/libxml2 ${gtk_includes}"
cflags="-DGTK_DISABLE_DEPRECATED"
for module in ${common_src_list} ${main_src_list} ${common_lv2_src_list} ${lv2_src_list}
do
cmd="gcc -g -c ${cflags} -I. ${includes} -o ${module//.c/.o} -fPIC ${module}"
echo ${cmd}
eval ${cmd}
done
common_libs="-ldl -lpthread -lxml2 -lz -llzma -lm -lsndfile -lsamplerate"
main_libs=""
lv2_libs=""
cmd="gcc -g -o drummer ${common_src_list//.c/.o} ${main_src_list//.c/.o} -fPIC ${common_libs} ${main_libs}"
echo ${cmd}
eval ${cmd}
cmd="gcc -g -o drummer.so ${common_src_list//.c/.o} ${common_lv2_src_list//.c/.o} lv2_plugin.o -shared -fPIC ${common_libs} ${lv2_libs}"
echo ${cmd}
eval ${cmd}
cmd="gcc -g -o drummer_ui.so ${common_src_list//.c/.o} ${common_lv2_src_list//.c/.o} lv2_ui.o -shared -fPIC ${common_libs} ${lv2_libs}"
echo ${cmd}
eval ${cmd}
cmd="./drummer-mkttl"
#echo ${cmd}
#eval ${cmd}
#gcc -g -I . -L . -shared -o drummer.so -fPIC drummer.c
#gcc -g -I. -I/usr/include/libxml2 -o xpath -fPIC -ldl -lxml2 -lz -llzma -lm xpath.c