Skip to content

Commit

Permalink
Merge branch 'master' into Eeems-patch-2
Browse files Browse the repository at this point in the history
  • Loading branch information
Eeems authored Feb 3, 2024
2 parents d00d763 + 3ed1bad commit 9f52a91
Show file tree
Hide file tree
Showing 2,653 changed files with 59,562 additions and 29,380 deletions.
48 changes: 0 additions & 48 deletions .github/workflows/nix.yml

This file was deleted.

98 changes: 50 additions & 48 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,37 +11,76 @@ MAKEFLAGS := --jobs=$(shell nproc)
DIST=$(CURDIR)/release
BUILD=$(CURDIR)/.build


ifneq ($(filter sentry,$(FEATURES)),)
OBJ += sentry
RELOBJ += $(DIST)/opt/lib/libsentry.so
DEFINES += 'DEFINES+="SENTRY"'
DEFINES += DEFINES+="SENTRY"
endif

OBJ += $(BUILD)/oxide/Makefile

clean:
rm -rf $(DIST) $(BUILD)
clean-base:
rm -rf $(DIST) $(BUILD)/oxide

release: clean build $(RELOBJ)
mkdir -p $(DIST)
clean: clean-base
rm -rf $(BUILD)

release: clean-base build $(DIST)
# Force sentry makefile to regenerate so that install targets get when being build in toltecmk
cd $(BUILD)/oxide/shared/sentry && make qmake
# Force liboxide makefile to regenerate so that install targets get when being build in toltecmk
cd $(BUILD)/oxide/shared/liboxide && make qmake
INSTALL_ROOT=$(DIST) $(MAKE) --output-sync=target -C $(BUILD)/oxide install

build: $(BUILD) $(OBJ)
build: $(OBJ)
$(MAKE) --output-sync=target -C $(BUILD)/oxide all

package: REV="~r$(shell git rev-list --count HEAD).$(shell git rev-parse --short HEAD)"
package:
package: version.txt $(DIST) $(BUILD)/package/oxide.tar.gz
toltecmk \
--verbose \
-w $(BUILD)/package/build \
-d $(BUILD)/package/dist \
$(BUILD)/package
cp -a $(BUILD)/package/dist/rmall/*.ipk $(DIST)

version.txt:
if [ -d .git ];then \
echo $(REV) > version.txt; \
else \
echo "~manual" > version.txt; \
fi;

$(DIST):
mkdir -p $(DIST)

$(BUILD):
mkdir -p $(BUILD)

$(BUILD)/.nobackup: $(BUILD)
touch $(BUILD)/.nobackup

$(BUILD)/oxide: $(BUILD)/.nobackup
mkdir -p $(BUILD)/oxide

$(BUILD)/oxide/Makefile: $(BUILD)/oxide
cd $(BUILD)/oxide && qmake -r $(DEFINES) $(CURDIR)

$(BUILD)/package:
mkdir -p $(BUILD)/package
rm -rf $(BUILD)/package/build

$(BUILD)/package/package: $(BUILD)/package
sed "s/~VERSION~/`cat version.txt`/" ./package > $(BUILD)/package/package

PKG_OBJ = oxide.pro Makefile
PKG_OBJ += $(wildcard applications/**)
PKG_OBJ += $(wildcard assets/**)
PKG_OBJ += $(wildcard interfaces/**)
PKG_OBJ += $(wildcard qmake/**)
PKG_OBJ += $(wildcard shared/**)
PKG_OBJ += $(wildcard tests/**)

$(BUILD)/package/oxide.tar.gz: $(BUILD)/package/package $(PKG_OBJ)
rm -f $(BUILD)/package/oxide.tar.gz
tar \
--exclude='$(CURDIR)/.git' \
--exclude='$(BUILD)' \
Expand All @@ -53,43 +92,6 @@ package:
interfaces \
qmake \
shared \
tests \
oxide.pro \
Makefile
toltecmk \
--verbose \
-w $(BUILD)/package/build \
-d $(BUILD)/package/dist \
$(BUILD)/package
mkdir -p $(DIST)
cp -a $(BUILD)/package/dist/rmall/*.ipk $(DIST)

sentry: $(BUILD)/sentry/libsentry.so

$(BUILD):
mkdir -p $(BUILD)

$(BUILD)/.nobackup: $(BUILD)
touch $(BUILD)/.nobackup

$(BUILD)/oxide: $(BUILD)/.nobackup
mkdir -p $(BUILD)/oxide

$(BUILD)/oxide/Makefile: $(BUILD)/oxide
cd $(BUILD)/oxide && qmake -r $(DEFINES) $(CURDIR)/oxide.pro

$(BUILD)/sentry/libsentry.so: $(BUILD)/.nobackup
cd shared/sentry && cmake -B $(BUILD)/sentry/src \
-DBUILD_SHARED_LIBS=ON \
-DSENTRY_INTEGRATION_QT=ON \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-DSENTRY_PIC=OFF \
-DSENTRY_BACKEND=breakpad \
-DSENTRY_BREAKPAD_SYSTEM=OFF \
-DSENTRY_EXPORT_SYMBOLS=ON \
-DSENTRY_PTHREAD=ON
cd shared/sentry && cmake --build $(BUILD)/sentry/src --parallel
cd shared/sentry && cmake --install $(BUILD)/sentry/src --prefix $(BUILD)/sentry --config RelWithDebInfo

$(DIST)/opt/lib/libsentry.so: sentry
mkdir -p $(DIST)/opt/lib
cp -a $(BUILD)/sentry/lib/libsentry.so $(DIST)/opt/lib/
7 changes: 0 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,3 @@ You can find other (likely outdated) [videos here](https://github.com/Eeems/oxid
1. Install [toltecmk](https://pypi.org/project/toltecmk/)
2. Run `make package`
3. The ipk files can be found in the `dist/` folder

### Nix
Works on x86_64-linux or macOS via [nix-docker](https://github.com/LnL7/nix-docker).

```ShellSession
$ nix-build --argstr system 'x86_64-linux'
```
4 changes: 0 additions & 4 deletions applications/desktop-file-edit/desktop-file-edit.pro
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ QT += dbus
CONFIG += c++11 console
CONFIG -= app_bundle

DEFINES += QT_DEPRECATED_WARNINGS
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0

SOURCES += \
edit.cpp \
main.cpp
Expand All @@ -20,4 +17,3 @@ target.path = /opt/bin
INSTALLS += target

include(../../qmake/liboxide.pri)
include(../../qmake/sentry.pri)
4 changes: 0 additions & 4 deletions applications/desktop-file-install/desktop-file-install.pro
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ QT += dbus
CONFIG += c++11 console
CONFIG -= app_bundle

DEFINES += QT_DEPRECATED_WARNINGS
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0

SOURCES += \
../desktop-file-edit/edit.cpp \
main.cpp
Expand All @@ -20,4 +17,3 @@ target.path = /opt/bin
INSTALLS += target

include(../../qmake/liboxide.pri)
include(../../qmake/sentry.pri)
4 changes: 0 additions & 4 deletions applications/desktop-file-validate/desktop-file-validate.pro
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ QT += dbus
CONFIG += c++11 console
CONFIG -= app_bundle

DEFINES += QT_DEPRECATED_WARNINGS
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0

SOURCES += \
main.cpp

Expand All @@ -18,4 +15,3 @@ target.path = /opt/bin
INSTALLS += target

include(../../qmake/liboxide.pri)
include(../../qmake/sentry.pri)
4 changes: 0 additions & 4 deletions applications/gio/gio.pro
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ QT += dbus
CONFIG += c++11 console
CONFIG -= app_bundle

DEFINES += QT_DEPRECATED_WARNINGS
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0

SOURCES += \
common.cpp \
main.cpp
Expand All @@ -29,4 +26,3 @@ target.path = /opt/bin
INSTALLS += target

include(../../qmake/liboxide.pri)
include(../../qmake/sentry.pri)
4 changes: 0 additions & 4 deletions applications/inject_evdev/inject_evdev.pro
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ QT += dbus
CONFIG += c++11 console
CONFIG -= app_bundle

DEFINES += QT_DEPRECATED_WARNINGS
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0

SOURCES += \
main.cpp

Expand All @@ -18,4 +15,3 @@ target.path = /opt/bin
INSTALLS += target

include(../../qmake/liboxide.pri)
include(../../qmake/sentry.pri)
Loading

0 comments on commit 9f52a91

Please sign in to comment.