kopia lustrzana https://github.com/kgoba/ft8_lib
Move fft and ft8 to libs/libfft and libs/libft8, compiled as shared object lib(.so)
rodzic
ee9567ab1d
commit
a762e4597a
|
@ -0,0 +1,17 @@
|
|||
SUBDIRS := libfft
|
||||
SUBDIRS += libft8
|
||||
|
||||
|
||||
|
||||
all install:
|
||||
echo $(SUBDIRS)
|
||||
@for i in `echo $(SUBDIRS)`; do \
|
||||
$(MAKE) -C $$i $@ || exit 1; \
|
||||
done
|
||||
|
||||
|
||||
clean mrproper:
|
||||
@for i in `echo $(SUBDIRS)`; do \
|
||||
$(MAKE) -C $$i $@ || exit 1; \
|
||||
done
|
||||
|
|
@ -0,0 +1,53 @@
|
|||
|
||||
RM = rm
|
||||
MKDIR = mkdir
|
||||
|
||||
OBJDIR = obj
|
||||
SODIR = bin
|
||||
SRCDIR = src
|
||||
LIBS = libfft.so
|
||||
LIBSA = libfft.a
|
||||
LIBFILE = libfft.so.0.0
|
||||
OUTFILE = $(SODIR)/$(LIBFILE)
|
||||
|
||||
LDFLAGS = -shared -Wl,-soname,$(LIBFILE)
|
||||
|
||||
INC = -I./include
|
||||
|
||||
CFLAGS += -fPIC -w
|
||||
|
||||
SRCS := $(wildcard *.c $(SRCDIR)/*.c)
|
||||
OBJS := $(patsubst %.c, $(OBJDIR)/%.o, $(notdir ${SRCS}))
|
||||
|
||||
|
||||
$(OBJDIR)/%.o : $(SRCDIR)/%.c
|
||||
$(CXX) -c -o "$(OBJDIR)/$(*F).o" $(INC) $(CFLAGS) "$<"
|
||||
|
||||
all: $(OUTFILE)
|
||||
|
||||
$(OUTFILE): $(OBJDIR) $(OBJS)
|
||||
$(CXX) -o "$(OUTFILE)" $(OBJS) $(LDFLAGS)
|
||||
ln -sf $(LIBFILE) $(SODIR)/$(LIBS)
|
||||
|
||||
|
||||
$(OBJDIR):
|
||||
$(MKDIR) -p "$(OBJDIR)"
|
||||
$(MKDIR) -p "$(SODIR)"
|
||||
|
||||
|
||||
rebuild: cleanall all
|
||||
|
||||
clean:
|
||||
$(RM) -f $(OUTFILE)
|
||||
$(RM) -f $(OBJS)
|
||||
$(RM) -rf $(OBJDIR)
|
||||
$(RM) -rf $(SODIR)
|
||||
|
||||
|
||||
cleanall: clean
|
||||
|
||||
|
||||
install:
|
||||
$(INSTALL) -D $(OUTFILE) /usr/lib/$(LIBFILE)
|
||||
|
||||
|
|
@ -0,0 +1,53 @@
|
|||
|
||||
RM = rm
|
||||
MKDIR = mkdir
|
||||
|
||||
OBJDIR = obj
|
||||
SODIR = bin
|
||||
SRCDIR = src
|
||||
LIBS = libft8.so
|
||||
LIBSA = libft8.a
|
||||
LIBFILE = libft8.so.0.0
|
||||
OUTFILE = $(SODIR)/$(LIBFILE)
|
||||
|
||||
LDFLAGS = -shared -Wl,-soname,$(LIBFILE)
|
||||
|
||||
INC = -I./include
|
||||
|
||||
CFLAGS += -fPIC -w
|
||||
|
||||
SRCS := $(wildcard *.c $(SRCDIR)/*.c)
|
||||
OBJS := $(patsubst %.c, $(OBJDIR)/%.o, $(notdir ${SRCS}))
|
||||
|
||||
|
||||
$(OBJDIR)/%.o : $(SRCDIR)/%.c
|
||||
$(CXX) -c -o "$(OBJDIR)/$(*F).o" $(INC) $(CFLAGS) "$<"
|
||||
|
||||
all: $(OUTFILE)
|
||||
|
||||
$(OUTFILE): $(OBJDIR) $(OBJS)
|
||||
$(CXX) -o "$(OUTFILE)" $(OBJS) $(LDFLAGS)
|
||||
ln -sf $(LIBFILE) $(SODIR)/$(LIBS)
|
||||
|
||||
|
||||
$(OBJDIR):
|
||||
$(MKDIR) -p "$(OBJDIR)"
|
||||
$(MKDIR) -p "$(SODIR)"
|
||||
|
||||
|
||||
rebuild: cleanall all
|
||||
|
||||
clean:
|
||||
$(RM) -f $(OUTFILE)
|
||||
$(RM) -f $(OBJS)
|
||||
$(RM) -rf $(OBJDIR)
|
||||
$(RM) -rf $(SODIR)
|
||||
|
||||
|
||||
cleanall: clean
|
||||
|
||||
|
||||
install:
|
||||
$(INSTALL) -D $(OUTFILE) /usr/lib/$(LIBFILE)
|
||||
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
#include "constants.h"
|
||||
#include "ft8_constants.h"
|
||||
|
||||
// Costas sync tone pattern
|
||||
const uint8_t kFT8_Costas_pattern[7] = {3, 1, 4, 0, 6, 5, 2};
|
|
@ -1,5 +1,5 @@
|
|||
#include "crc.h"
|
||||
#include "constants.h"
|
||||
#include "ft8_crc.h"
|
||||
#include "ft8_constants.h"
|
||||
|
||||
#define TOPBIT (1u << (FT8_CRC_WIDTH - 1))
|
||||
|
|
@ -1,8 +1,8 @@
|
|||
#include "decode.h"
|
||||
#include "constants.h"
|
||||
#include "crc.h"
|
||||
#include "ldpc.h"
|
||||
#include "unpack.h"
|
||||
#include "ft8_decode.h"
|
||||
#include "ft8_constants.h"
|
||||
#include "ft8_crc.h"
|
||||
#include "ft8_ldpc.h"
|
||||
#include "ft8_unpack.h"
|
||||
|
||||
#include <stdbool.h>
|
||||
#include <math.h>
|
|
@ -1,6 +1,6 @@
|
|||
#include "encode.h"
|
||||
#include "constants.h"
|
||||
#include "crc.h"
|
||||
#include "ft8_encode.h"
|
||||
#include "ft8_constants.h"
|
||||
#include "ft8_crc.h"
|
||||
|
||||
#include <stdio.h>
|
||||
|
|
@ -9,8 +9,8 @@
|
|||
// codeword[i] = log ( P(x=0) / P(x=1) )
|
||||
//
|
||||
|
||||
#include "ldpc.h"
|
||||
#include "constants.h"
|
||||
#include "ft8_ldpc.h"
|
||||
#include "ft8_constants.h"
|
||||
|
||||
#include <stdio.h>
|
||||
#include <math.h>
|
|
@ -1,5 +1,5 @@
|
|||
#include "pack.h"
|
||||
#include "text.h"
|
||||
#include "ft8_pack.h"
|
||||
#include "ft8_text.h"
|
||||
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
|
@ -365,4 +365,4 @@ int main()
|
|||
return 0;
|
||||
}
|
||||
|
||||
#endif
|
||||
#endif
|
|
@ -1,4 +1,4 @@
|
|||
#include "text.h"
|
||||
#include "ft8_text.h"
|
||||
|
||||
#include <string.h>
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
#include "unpack.h"
|
||||
#include "text.h"
|
||||
#include "ft8_unpack.h"
|
||||
#include "ft8_text.h"
|
||||
|
||||
#include <string.h>
|
||||
|
Ładowanie…
Reference in New Issue