在makefile的帮助下编译后权限被拒绝

Geo*_*nic 3 c linux makefile permission-denied

当我尝试运行我的程序时,我得到了这个:bash:./ supermarket:权限被拒绝

可执行文件显示为二进制文件,对用户具有读写权限但没有执行权限

这是我的makefile的代码可以搞清楚是什么问题?

OBJS    = supermarket.o cashier.o customer.o 
SOURCE  = supermarket.c cashier.c customer.c 
HEADER  = struct.h
OUT     = supermarket cashier customer
CC  = gcc
FLAGS   = -lrt -g -c 

#LIBS   = -lm
# -g option enables debugging mode 
# -c flag generates object code for separate files
# -lm math library
# -lrt semaphores

all: supermarket cashier customer

supermarket: supermarket.c
    $(CC) $(FLAGS) supermarket.c -o supermarket 

cashier: cashier.c
    $(CC) $(FLAGS) cashier.c -o cashier 

customer: customer.c
    $(CC) $(FLAGS) customer.c -o customer

# clean house
clean:
    rm -f $(OBJS) $(OUT)
# do a bit of accounting
count:
    wc $(SOURCE) $(HEADER)
Run Code Online (Sandbox Code Playgroud)

Kev*_*vin 6

FLAGS   = -lrt -g -c 
Run Code Online (Sandbox Code Playgroud)

具体来说,是-c旗帜.它会在对象阶段停止编译,因此你的supermarket,cashiercustomer"可执行文件"实际上是没有通常扩展的目标文件.