Theos

Latest version: v0.0.1

Safety actively analyzes 683322 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 2

2.5

* **Various build error fixes:**
Fixes an error when building with Xcode 10 (pull request 348). Fixes build errors on WSL (pull request 353). Fixes an error when building `.xmi` files. Fixes an error at the stripping stage when making a release build.
* **dm.pl is now always used on iOS.**
dm.pl was previously only required to use Theos on the Electra jailbreak, as its newer version of dpkg no longer supports building packages using the lzma compression algorithm. This is now unified with other build platforms so dm.pl is always used.
* **Improvements to building Swift code:**
Some build errors were fixed. Makedeps support was added. NIC templates for Swift projects were added. (Pull requests 347)
* **Fixes a logic issue with the `[instance]_USE_SUBSTRATE` variable.**
If you are using `[instance]_USE_SUBSTRATE = no`, please transition to using `[instance]_LOGOS_DEFAULT_GENERATOR = internal`. As use of this seems to be nonexistent in GitHub and Google searches, this was not considered a breaking change.
* **Fixes Theos not using the `ldid` binary from the toolchain if it exists.**
If you have a copy of `ldid` in your `$PATH`, that will take precedence over the toolchain’s copy of `ldid`.
* **Theos now generates debug symbols on Linux/Cygwin/iOS, and for release builds.** (Pull request 350)
This can be used with tools such as lldb and Instruments, and third-party crash reporting services.

2.4

The major changes:

* **Cleans up/unifies logic that was previously duplicated for each build platform and target platform.** (Pull request 291)
Due to the structure of Theos’s multi-platform support, a fix made, for instance, to building for iOS on a Mac might not have been applied to all the other platform combinations (say, building for iOS on Linux, or building for macOS on a Mac). This logic has all been merged into a few central scripts to prevent discrepancies in future.
* **Updates Swift support for Swift 4 and the new libswift packages.** (Pull request 278)
Due to sandbox issues with iOS 11, the libswift package has moved to /usr/lib/libswift. The `${LIBSWIFT}` magic word can be used in a `control` file to expand to the correct Swift package name/version dependency, and `${LIBSWIFT_VERSION}` expands to the version on its own.
* **Works around permission issues on Windows Subsystem for Linux.** (Pull request 258)
We recommend using Windows 10 build 17063 or newer (currently Insider build; stable release rumored to be soonish) which resolves the permission issues. We [still support](https://github.com/theos/theos/wiki/Installation) back to 14393 (Anniversary Update) but will slowly be increasing this minimum requirement to encourage you to upgrade to the latest, which has substantially improved since the initial Anniversary Update release of WSL.
* **Cleans up `Prefix.pch`.**
We are discouraging dependency on Theos’s [prefix header](https://github.com/theos/theos/blob/master/Prefix.pch). Using `ADDITIONAL_CFLAGS += -DTHEOS_LEAN_AND_MEAN` will disable almost all of Prefix.pch. This requires you to import Foundation and/or UIKit yourself, as well as other fixes that were automatically imported by the prefix header. HBLog macros have been moved to `<HBLog.h>`. The imports for AppKit and Cocoa on macOS were removed entirely. Prefix.pch is no longer imported at all for Swift.

The minor-ish changes:

* **Adds a `libgcc_s.1.tbd` file, resolving an “undefined symbols” error when building for ARMv6 with the Xcode 9 toolchain.** (Pull request 291)
* **Fixes the Logos internal generator using `_disused` in one place, causing a build error as this macro comes from substrate.h.**
* **Fixes the Logos internal generator not being able to hook `-dealloc`.**
* **Re-introduces Makedeps support.** (Pull request 291)
This makes Make aware of the dependencies of your source files, such as headers. This allows you to, for instance, write a rule in your Makefile that generates a header just before it’s required.
* **Splits Logos and NIC into their own separate Git repositories.** (Issue 247)
This has no noticeable difference to Theos users, but it allows Logos and NIC to be tracked separately from Theos itself, and also makes it easier for Logos to be integrated with other build systems such as Xcode.
* **Moves the Theos update script to `$THEOS/bin/update-theos`.**
`make update-theos` now calls this script, so both will work.
* **Adds a `COLOR=0` option to disable ANSI escapes (color) in output, including in output from Clang.**
* **Various other cleanup derived from rpetrich’s fork.** (Pull request 291)

2.3

* Implements support for parallel building. Theos will automatically use all available logical CPU cores (aka CPU threads) to build multiple files at once. There are still spots that will feel slow, but otherwise you should see [a reasonable improvement](https://twitter.com/theosdev/status/941284409629478913). (Pull request #225)
The version of Make included with macOS is too old for this feature, so this will be disabled unless you install the latest GNU Make. You can do this with Homebrew:
shellsession
$ brew install make
$ ln -s gmake $(brew --prefix)/bin/make

* Fixes `ld: malformed file: unknown key 'flags'` error when linking against the libraries that were updated in Theos 2.2. (Issue 277)
* dm.pl: Sets all files in the package to be owned by `root:wheel`, to normalise all files/directories to have correct ownership. (Issue 202)

2.2

* Integrates generation of debug symbol files (.dSYM) when building for iOS on macOS. This allows symbols to be displayed by lldb, Xcode, Instruments, etc, and links those symbols and offsets to exact lines in your source code.
(.dSYM files are automatically found by these tools via Spotlight. If the symbols aren’t found, make sure Spotlight is working and not blocked from indexing your project folder.)
* Updates libactivator, libapplist, Cephei, libflipswitch, libprefs, Opener, librocketbootstrap library definitions to the latest versions.
* Cleans up the iOS private headers and adds a bunch of new headers. (Mostly contributed by Shade-Zepheri. Thanks!)
* Changes `HBLog…()` macros to directly use the new `os_log()`-based logging system when building using the iOS 10.0 SDK or newer with deployment target set to iOS 10.0 or newer.
This also means that `HBLogDebug()` calls will now be compiled into release builds when `os_log()` is in use. os_log is designed to be very fast, and debug logs are ignored unless a tool such as macOS’s Console or `deviceconsole` is watching the log stream. (Unfortunately it’d be complicated to detect for `os_log()` and use it if available. These macros are designed to be helpful but still very simple. This is the best compromise I could come up with.)

2.1.1

* dm.pl: Fixes the hashbang line on the perl script, so the `perl` on your path is used. (Issue 273)
If Perl was installed from Homebrew, you’d install the dependency modules using its copy of `cpan`, but dm.pl always executed with the macOS copy of `perl`. It now uses whichever `perl` is found on your `$PATH`; hopefully the same one as `cpan`.
* Fixes the post-install script losing its executable bit, breaking the automatic cloning of the dm.pl submodule and installation of `IO::Compress::Lzma`.
* Fixes the post-install script printing an error from `uname`.
It was using `uname -o`, which is not supported by macOS’s BSD `uname`, instead of `uname -s`. This didn’t break the script, as it was being used to check for iOS, and Telesphoreo uses GNU uname.

2.1.0

* Switch the deb package builder from dpkg-deb to dm.pl, a Perl reimplementation of `dpkg-deb -b`. (Issue 211)
dm.pl has flags compatible with dpkg-deb, so you can also use it directly if needed. Worth noting its default compression format is `gzip` (dpkg-deb’s has been `xz` for a long time; previously was `gzip`). Theos will still manually specify `-Zlzma`, so packages built via Theos will compress with lzma.
There is (unfortunately) a binary dependency which provides bindings for liblzma to Perl. If that’s gibberish to you, don’t worry, it’ll be installed when you run `make update-theos`. The instructions to install it manually while installing Theos from scratch has been [added to the Install page](https://git.io/theosinstall). It’s the best compromise I could come up with and I don’t want any pre-built binaries in Theos. If someone has a smarter solution than mine I’d love to discuss it.
* Adds preliminary support for Swift on Linux.
The official Swift release for Linux from [swift.org](https://swift.org/download/#releases) works for cross-compiling to iOS, macOS, etc. but there are a few patches needed. Will be followed-up in a future Theos release.
* Guard most of Prefix.pch in `!defined(THEOS_LEAN_AND_MEAN)`.
You can define this with `ADDITIONAL_CFLAGS += -DTHEOS_LEAN_AND_MEAN` or similar if you don’t want the majority of what’s in [Prefix.pch](https://github.com/theos/theos/blob/master/Prefix.pch) to be imported, including the implicit importing of Foundation and UIKit. These really shouldn’t have ever been added to Prefix.pch, but they can’t be removed without breaking projects. Consider using this in your own projects.

Page 1 of 2

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.