Moved to meson

This commit is contained in:
Scoopta 2019-12-20 18:29:11 -08:00
parent 68f778e83a
commit d3c6d8019e
16 changed files with 37 additions and 343 deletions

View File

@ -4,8 +4,10 @@ packages:
- libwayland-dev
- libgtk-3-dev
- pkg-config
- meson
tasks:
- build: |
cd wofi/Release
make
cd wofi
meson build
ninja -C build

View File

@ -1,8 +1,7 @@
^\.cproject$
^\.project$
^\.settings$
^Debug/wofi$
^Release/wofi$
^build$
.+\.o$
.+\.d$
^\.hgrepos$

View File

@ -1,45 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
-include ../makefile.init
RM := rm -rf
# All of the sources participating in the build are defined here
-include sources.mk
-include src/subdir.mk
-include proto/subdir.mk
-include modes/subdir.mk
-include subdir.mk
-include objects.mk
ifneq ($(MAKECMDGOALS),clean)
ifneq ($(strip $(C_DEPS)),)
-include $(C_DEPS)
endif
endif
-include ../makefile.defs
# Add inputs and outputs from these tool invocations to the build variables
# All Target
all: wofi
# Tool invocations
wofi: $(OBJS) $(USER_OBJS)
@echo 'Building target: $@'
@echo 'Invoking: GCC C Linker'
gcc -fsanitize=address -rdynamic -pthread -o "wofi" $(OBJS) $(USER_OBJS) $(LIBS)
@echo 'Finished building target: $@'
@echo ' '
# Other Targets
clean:
-$(RM) $(EXECUTABLES)$(OBJS)$(C_DEPS) wofi
-@echo ' '
.PHONY: all clean dependents
-include ../makefile.targets

View File

@ -1,30 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
# Add inputs and outputs from these tool invocations to the build variables
C_SRCS += \
../modes/dmenu.c \
../modes/drun.c \
../modes/run.c
OBJS += \
./modes/dmenu.o \
./modes/drun.o \
./modes/run.o
C_DEPS += \
./modes/dmenu.d \
./modes/drun.d \
./modes/run.d
# Each subdirectory must supply rules for building sources it contributes
modes/%.o: ../modes/%.c
@echo 'Building file: $<'
@echo 'Invoking: GCC C Compiler'
gcc -D_GNU_SOURCE -DVERSION='"'"`hg identify`"'"' -I../inc -O0 -g3 -Wall -Wextra -c -fmessage-length=0 -fsanitize=address `pkg-config --cflags gtk+-3.0 gio-unix-2.0` -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@)" -o "$@" "$<"
@echo 'Finished building: $<'
@echo ' '

View File

@ -1,8 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
USER_OBJS :=
LIBS := -ldl -lgtk-3 -lgdk-3 -lgio-2.0 -lglib-2.0 -lpango-1.0 -lgobject-2.0 -lwayland-client -lgdk_pixbuf-2.0

View File

@ -1,27 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
# Add inputs and outputs from these tool invocations to the build variables
C_SRCS += \
../proto/wlr-layer-shell-unstable-v1-protocol.c \
../proto/xdg-shell-protocol.c
OBJS += \
./proto/wlr-layer-shell-unstable-v1-protocol.o \
./proto/xdg-shell-protocol.o
C_DEPS += \
./proto/wlr-layer-shell-unstable-v1-protocol.d \
./proto/xdg-shell-protocol.d
# Each subdirectory must supply rules for building sources it contributes
proto/%.o: ../proto/%.c
@echo 'Building file: $<'
@echo 'Invoking: GCC C Compiler'
gcc -D_GNU_SOURCE -DVERSION='"'"`hg identify`"'"' -I../inc -O0 -g3 -Wall -Wextra -c -fmessage-length=0 -fsanitize=address `pkg-config --cflags gtk+-3.0 gio-unix-2.0` -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@)" -o "$@" "$<"
@echo 'Finished building: $<'
@echo ' '

View File

@ -1,19 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
OBJ_SRCS :=
ASM_SRCS :=
C_SRCS :=
O_SRCS :=
S_UPPER_SRCS :=
EXECUTABLES :=
OBJS :=
C_DEPS :=
# Every subdirectory with source files must be described here
SUBDIRS := \
modes \
proto \
src \

View File

@ -1,39 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
# Add inputs and outputs from these tool invocations to the build variables
C_SRCS += \
../src/config.c \
../src/main.c \
../src/map.c \
../src/property_box.c \
../src/utils.c \
../src/wofi.c
OBJS += \
./src/config.o \
./src/main.o \
./src/map.o \
./src/property_box.o \
./src/utils.o \
./src/wofi.o
C_DEPS += \
./src/config.d \
./src/main.d \
./src/map.d \
./src/property_box.d \
./src/utils.d \
./src/wofi.d
# Each subdirectory must supply rules for building sources it contributes
src/%.o: ../src/%.c
@echo 'Building file: $<'
@echo 'Invoking: GCC C Compiler'
gcc -D_GNU_SOURCE -DVERSION='"'"`hg identify`"'"' -I../inc -O0 -g3 -Wall -Wextra -c -fmessage-length=0 -fsanitize=address `pkg-config --cflags gtk+-3.0 gio-unix-2.0` -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@)" -o "$@" "$<"
@echo 'Finished building: $<'
@echo ' '

View File

@ -8,12 +8,14 @@ If you're having issues with -i not showing images refer to https://todo.sr.ht/~
libwayland-dev
libgtk-3-dev
pkg-config
meson
## Building
hg clone https://hg.sr.ht/~scoopta/wofi
cd wofi/Release
make
cd wofi
meson build
ninja -C build
## Installing
sudo cp wofi /usr/bin
sudo cp build/wofi /usr/bin
## Uninstalling
sudo rm /usr/bin/wofi
## Bug Reports

View File

@ -1,45 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
-include ../makefile.init
RM := rm -rf
# All of the sources participating in the build are defined here
-include sources.mk
-include src/subdir.mk
-include proto/subdir.mk
-include modes/subdir.mk
-include subdir.mk
-include objects.mk
ifneq ($(MAKECMDGOALS),clean)
ifneq ($(strip $(C_DEPS)),)
-include $(C_DEPS)
endif
endif
-include ../makefile.defs
# Add inputs and outputs from these tool invocations to the build variables
# All Target
all: wofi
# Tool invocations
wofi: $(OBJS) $(USER_OBJS)
@echo 'Building target: $@'
@echo 'Invoking: GCC C Linker'
gcc -rdynamic -pthread -o "wofi" $(OBJS) $(USER_OBJS) $(LIBS)
@echo 'Finished building target: $@'
@echo ' '
# Other Targets
clean:
-$(RM) $(EXECUTABLES)$(OBJS)$(C_DEPS) wofi
-@echo ' '
.PHONY: all clean dependents
-include ../makefile.targets

View File

@ -1,30 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
# Add inputs and outputs from these tool invocations to the build variables
C_SRCS += \
../modes/dmenu.c \
../modes/drun.c \
../modes/run.c
OBJS += \
./modes/dmenu.o \
./modes/drun.o \
./modes/run.o
C_DEPS += \
./modes/dmenu.d \
./modes/drun.d \
./modes/run.d
# Each subdirectory must supply rules for building sources it contributes
modes/%.o: ../modes/%.c
@echo 'Building file: $<'
@echo 'Invoking: GCC C Compiler'
gcc -D_GNU_SOURCE -DVERSION='"'"`hg identify`"'"' -I../inc -O3 -Wall -Wextra -c -fmessage-length=0 `pkg-config --cflags gtk+-3.0 gio-unix-2.0` -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@)" -o "$@" "$<"
@echo 'Finished building: $<'
@echo ' '

View File

@ -1,8 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
USER_OBJS :=
LIBS := -ldl -lgtk-3 -lgdk-3 -lgio-2.0 -lglib-2.0 -lpango-1.0 -lgobject-2.0 -lwayland-client -lgdk_pixbuf-2.0

View File

@ -1,27 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
# Add inputs and outputs from these tool invocations to the build variables
C_SRCS += \
../proto/wlr-layer-shell-unstable-v1-protocol.c \
../proto/xdg-shell-protocol.c
OBJS += \
./proto/wlr-layer-shell-unstable-v1-protocol.o \
./proto/xdg-shell-protocol.o
C_DEPS += \
./proto/wlr-layer-shell-unstable-v1-protocol.d \
./proto/xdg-shell-protocol.d
# Each subdirectory must supply rules for building sources it contributes
proto/%.o: ../proto/%.c
@echo 'Building file: $<'
@echo 'Invoking: GCC C Compiler'
gcc -D_GNU_SOURCE -DVERSION='"'"`hg identify`"'"' -I../inc -O3 -Wall -Wextra -c -fmessage-length=0 `pkg-config --cflags gtk+-3.0 gio-unix-2.0` -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@)" -o "$@" "$<"
@echo 'Finished building: $<'
@echo ' '

View File

@ -1,19 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
OBJ_SRCS :=
ASM_SRCS :=
C_SRCS :=
O_SRCS :=
S_UPPER_SRCS :=
EXECUTABLES :=
OBJS :=
C_DEPS :=
# Every subdirectory with source files must be described here
SUBDIRS := \
modes \
proto \
src \

View File

@ -1,39 +0,0 @@
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
# Add inputs and outputs from these tool invocations to the build variables
C_SRCS += \
../src/config.c \
../src/main.c \
../src/map.c \
../src/property_box.c \
../src/utils.c \
../src/wofi.c
OBJS += \
./src/config.o \
./src/main.o \
./src/map.o \
./src/property_box.o \
./src/utils.o \
./src/wofi.o
C_DEPS += \
./src/config.d \
./src/main.d \
./src/map.d \
./src/property_box.d \
./src/utils.d \
./src/wofi.d
# Each subdirectory must supply rules for building sources it contributes
src/%.o: ../src/%.c
@echo 'Building file: $<'
@echo 'Invoking: GCC C Compiler'
gcc -D_GNU_SOURCE -DVERSION='"'"`hg identify`"'"' -I../inc -O3 -Wall -Wextra -c -fmessage-length=0 `pkg-config --cflags gtk+-3.0 gio-unix-2.0` -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@)" -o "$@" "$<"
@echo 'Finished building: $<'
@echo ' '

27
meson.build Normal file
View File

@ -0,0 +1,27 @@
project('wofi', 'c', version : 'v1.0', default_options : ['buildtype=release', 'warning_level=2'])
cc = meson.get_compiler('c')
inc = include_directories('inc')
gtk = dependency('gtk+-3.0')
gio = dependency('gio-unix-2.0')
threads = dependency('threads')
wayland = dependency('wayland-client')
dl = cc.find_library('dl')
add_project_arguments('-D_GNU_SOURCE', '-DVERSION="v1.0"', language : 'c')
add_project_link_arguments('-rdynamic', language : 'c')
executable('wofi',
'src/config.c',
'src/main.c',
'src/map.c',
'src/property_box.c',
'src/utils.c',
'src/wofi.c',
'modes/dmenu.c',
'modes/drun.c',
'modes/run.c',
'proto/wlr-layer-shell-unstable-v1-protocol.c',
'proto/xdg-shell-protocol.c',
include_directories : inc,
dependencies : [gtk, gio, threads, wayland, dl])