Compare commits

...

1268 Commits

Author SHA1 Message Date
csoler
f6ed95ee2f updated RS to latest master 2026-09-13 11:34:20 +02:00
csoler
b578bd031e
Merge pull request #3311 from defnax/fix-toaster-position
🐞Fix: to use available screen geometry for toasters and fix stack spacing
2026-09-12 17:37:39 +02:00
csoler
e43d23f1af
Merge pull request #3314 from thunder2/get-main-executable-path
Moved Windows specific code for getting main executable path from ret…
2026-09-11 20:09:55 +02:00
csoler
360da46e96
Merge pull request #3290 from defnax/account-creation-service
⚙️Added account creation for retroshare service - v2
2026-09-11 20:09:27 +02:00
thunder2
419bac9eb0 Moved Windows specific code for getting main executable path from retroshare-service.cc to an own file as function getMainExecutablePath 2026-09-11 14:23:05 +02:00
defnax
c84cbbc4cb Fix: to use available screen geometry for toasters and fix stack spacing
The bottom of the desktop is now the top of the taskbar, so even with the default value, the toaster sits cleanly above the taskbar.
2026-09-10 22:20:28 +02:00
defnax
f1db29079a Fix terminal prompts and formatting
- Left-pad profile indices with leading zeros to align with node list
- Clarify prompts: use "profile name" instead of "Username" and "node to that profile" instead of "of it"
- Update terms to use "Node ID" and "Profile ID"
- Initialize webui_pass2 to empty string
- Report unexpected error in switches for CreateAccountResult::Unknown
2026-09-10 21:38:45 +02:00
defnax
3a7b465321 define explicit enum values for CreateAccountResult 2026-09-10 21:20:54 +02:00
csoler
01bc50edb3
Merge pull request #3306 from jolavillette/fix/gui-applicationfilepath-non-windows
gui/main: fix non-Windows build, applicationFilePath declared under WINDOWS_SYS only
2026-09-05 13:40:11 +02:00
jolavillette
52cefc693e gui/main: fix Linux/macOS build, applicationFilePath was declared under WINDOWS_SYS only
Commit e63584843 declared applicationFilePath inside the WINDOWS_SYS
block but uses it unconditionally to fill conf.main_executable_path,
so every non-Windows GUI build fails with 'applicationFilePath was
not declared in this scope'. Declare it at function scope, seeded
from argv[0] (the previous non-Windows behaviour); Windows still
overrides it with QCoreApplication::applicationFilePath().

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-09-04 07:53:07 +02:00
csoler
799d4c9197
Merge pull request #3281 from thunder2/fix-tor
Fix tor
2026-09-03 22:32:07 +02:00
csoler
03daec3e2a
Merge pull request #3297 from jolavillette/fix/distant-chat-locally-closed-event
Distant chat window: close it when the conversation is closed from another client
2026-09-03 18:48:09 +02:00
csoler
21c981a430
Merge pull request #3299 from jolavillette/fix/sharemanager-friend-event-reset
ShareManager: stop discarding pending edits on every friend-list event
2026-08-31 10:12:45 +02:00
jolavillette
040d19c946 ShareManager: stop discarding pending edits on every friend-list event
The "Configure shared directories" dialog edits a local copy of the
shared directories and only commits it when Apply is pressed. Since
0ce2dd848 it reloads that copy from the core on *any* FRIEND_LIST event,
while the intent was only to follow friend-group changes. NODE_CONNECTED,
NODE_STATUS_CHANGED, NODE_STATE_STRING_CHANGED... fire every few seconds
as soon as a friend is online, so a directory added or removed in the
dialog reverts to the saved state before the user can press Apply.

Only react to GROUP_ADDED/REMOVED/CHANGED, and on those refresh the group
names column (dropping groups that no longer exist) instead of reloading
everything. Also do not reload when showYourself() is called while the
dialog is already open, for the same reason.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-31 05:47:37 +02:00
jolavillette
ea97a7437d Distant chat window: close it when the conversation is closed from another client
A distant chat started from the web UI pops the desktop chat window for
its tunnel (the core sends itself a "[Starting distant chat" message).
Leaving that conversation from the web UI then left the window as it was:
green LED, "You can talk", and on close the offer to end a conversation
the core no longer had -- closeEvent() ignored the false answer of
getDistantChatStatus() and read a default-initialised status.

On the new RsDistantChatEventCode::TUNNEL_STATUS_LOCALLY_CLOSED
(libretroshare fix/distant-chat-locally-closed-event) the window closes,
as it does when the conversation is ended from the window itself. And
closeEvent() asks no confirmation and calls no close for a tunnel the
core does not know any more.
2026-08-30 09:20:37 +02:00
jolavillette
6622cb9526 service: harden the terminal account creation
Follow-up to "Added account creation for retroshare service", touching
only that feature's own paths.

**-U create could only mint a brand-new PGP profile.** A null RsPgpId was
always passed to createLocationV2(), so a user who already has a profile,
sees it in the -U list output and picks [c] silently got a second
identity: their friends no longer recognise them and every certificate
has to be exchanged again. createLocationV2() takes pgpId as in/out and
reuses it when non-null (rsinit.cc:2247), and it explicitly accepts an
empty pgpName in that case (rsinit.cc:2243), so the profiles known to
RsAccounts::GetPGPLogins() are now listed first and reusing one just adds
this machine as another node. The prompt spells out what a new profile
costs.

**Ctrl-C at a prompt reported the wrong thing.** On glibc signal()
installs the handler with SA_RESTART, so the read blocked behind getline
is restarted and keepRunning is only seen once the user also presses
Enter. Control then fell out of the selector with prefUserString still
"list", RsPeerId("list") null, and the user who had just cancelled was
told their location id was invalid, with exit -EINVAL. Cancelling now
returns 0. doTerminalCreateAccount() returns a three-state result so a
deliberate abort is no longer reported as a failure, and the failure
paths use -RsInit::ERR_* instead of a bare -1 (exit 255).

**-U list failed on a non-tty even when accounts existed.** It returned
ERR_NO_AVAILABLE_ACCOUNT whenever stdin was not a terminal, while the
option is documented as a way to list accounts and retroshare-webui's
README puts it in the first-start flow. It now prints the list and
returns 0, keeping the error for the case it names: nothing to list. The
[c] line moved below that check, so a non-interactive run no longer
advertises an option it then refuses.

**Every prompt is bounded.** A terminal dying mid-prompt -- an ssh
session dropping, a container losing its tty -- turns each following read
into an immediate EOF, and all these loops re-ask on empty or mismatched
input. Three attempts then a clear message. This also covers the -W web
interface password loop, which had the same shape before this feature
existed.

**A passphrase is no longer asked of an absent terminal.** The
PASSWORD_REQUESTED handler now checks for an interactive stdin first, so
-U <hexid> under systemd or docker fails with a readable message instead
of prompting nothing.

Selections are trimmed, so "1 " and a CRLF line are no longer rejected as
invalid, and MAX_PROMPT_ATTEMPTS sits outside the terminal-login guard
because the web interface password prompt has its own build option.
Compile-checked in all four RS_SERVICE_TERMINAL_LOGIN /
RS_SERVICE_TERMINAL_WEBUI_PASSWORD combinations, warning-free.

Note that the underlying spin is a libretroshare bug: rs_getpass() stored
getchar()'s EOF in an unsigned char, where -1 becomes 0xFF and never ends
the loop. Fixed separately in libretroshare; the bounds here are useful
on their own and do not depend on it.
2026-08-28 13:50:32 +02:00
defnax
411ef267ad Added fallback option when no account available 2026-08-28 13:50:32 +02:00
defnax
be884ded91 Added account creation for retroshare service 2026-08-28 13:50:31 +02:00
csoler
f8553d2fd9
Merge pull request #3276 from csoler/v0.6-IdentityDialog3
fixed warning message about identities with insecure fingerprint
2026-08-28 12:21:25 +02:00
csoler
5bbe63e4d4
Merge pull request #3292 from jolavillette/fix/eliditemdelegate-font-inherit
gui: let RSElidedItemDelegate inherit the view font from the model font
2026-08-28 11:14:46 +02:00
csoler
5a4c943b96
Merge pull request #3272 from jolavillette/fix/securityitem-sslonly-accept-button
Fix "Accept friend request" button persisting after SSL-only friend added
2026-08-28 10:45:40 +02:00
csoler
fd69cff8d7
Merge pull request #3263 from jolavillette/fix/voip-preview-aspect-ratio
fix(voip): keep aspect ratio in camera preview
2026-08-28 10:42:50 +02:00
jolavillette
4a1799db76 fix(voip): keep aspect ratio in camera preview
The self-view preview in Preferences/VOIP scaled camera frames into the
display widget with Qt::IgnoreAspectRatio, forcing them into a 4:3 box.
Non-4:3 cameras (e.g. 16:9) were therefore stretched vertically.

Use Qt::KeepAspectRatio, matching the sibling showFrameOff() which
already scales the placeholder icon correctly.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-16 18:24:46 +02:00
jolavillette
f0a5a4687f Fix "Accept friend request" button persisting after SSL-only friend added
In the Activity feed, accepting an unknown peer (no PGP key in keyring)
adds it as an SSL-only friend via addSslOnlyFriend(), which sets
skip_pgp_signature_validation instead of the PGP-keyring accept_connection
flag. SecurityItem::updateItem() only tested details.accept_connection to
decide button visibility, so for an accepted SSL-only friend the condition
stayed false and the "Accept friend request" button kept being shown (and
"Remove friend" stayed hidden), even though the peer was already a friend.

Treat skip_pgp_signature_validation == true as accepted too, since that
flag is only set for a peer already present in the friend list.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-16 18:24:35 +02:00
jolavillette
61e647081c gui: let RSElidedItemDelegate inherit the view font from the model font
The delegate took the Qt::FontRole of the model and assigned it to the style option as
is, replacing the font of the view instead of merging into it. A font stored in a model
usually only carries the one attribute the caller wanted to change — most of the time
bold — and expects family and size to keep coming from the view. Assigning it whole
dropped those items back to the application font, ignoring the font size configured in
the settings, which FontSizeHandler puts on the view.

That is easy to trigger: QTreeWidgetItem::font() returns a default constructed font when
the item has no Qt::FontRole yet, so the familiar "read the font, set it bold, write it
back" turned the whole list into the application font. On a remote X display where the
desktop font is 9pt and the RetroShare font size is 11pt, the list visibly shrank.

Merge with QFont::resolve() instead, which keeps only the attributes the model really
set and takes the rest from the view — the same merge QStyledItemDelegate::initStyleOption()
performs. Same change in the tooltip path of editorEvent(), which recomputes the elision
with that font. sizeHint() was already using the merged font from initStyleOption(), so
rows were being measured with one font and painted with another.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-16 18:23:58 +02:00
csoler
6160b39dab
Merge pull request #3271 from defnax/distantchat-popup-fix
💬 Fixed to not popup distant chat on incoming chat
2026-08-16 14:16:35 +02:00
csoler
48c60e1cdb
Merge pull request #3210 from jolavillette/FixSearchColumnWidthPersistence
GUI: persist search results column widths across restarts
2026-08-13 18:13:47 +02:00
jolavillette
9119058c48 GUI: persist search results column widths across restarts 2026-08-07 01:12:19 +02:00
csoler
682cde9fbd
Merge pull request #3274 from jolavillette/fix/gxs-mark-all-read-nofreeze
Fix UI freeze on "mark all as read/unread" for forums, channels and boards
2026-08-06 21:46:57 +02:00
jolavillette
1b99beebc5 Address review: pointer hand-off to the workers, event-driven board update
- GxsForumModel / PostedPostsModel: hand the id list to the background
  worker through a pointer deleted after the call, so the lambda capture
  does not deep copy it.
- PostedPostsModel: setAllMsgReadStatus() no longer updates the model
  directly. The batched READ_STATUS_CHANGED event now carries the
  affected ids and their new state (libretroshare side), and the event
  handler applies them locally — so a batch initiated by another
  frontend (e.g. webUI) updates the board view exactly the same way,
  and no post is re-read from the database.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
jolavillette
ebac1481f0 Revert "gui(forums): opt-in latency probes on the read/unread and loading path"
Profiling code removed from the PR, as requested in review of the sibling
PRs. This reverts commit 8845aa4636e630977f4a6817e8a267735e128e28.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
jolavillette
dea2f28dd9 gui(forums): opt-in latency probes on the read/unread and loading path
Set RS_GUI_PROFILE to a threshold in milliseconds (0 reports
everything) to get one line per measured operation on stderr, plus a
50 ms watchdog on the GUI thread that reports every stall of the event
loop wherever the blocking code lives, naming the last probed
operation. This is what located the actual freeze of the read/unread
path (a whole-model dataChanged() measured at 1072 ms) after several
plausible-from-code-reading fixes had failed to: the numbers say where
the time goes instead of a story explaining where it might go.

All probes are inert unless the environment variable is set.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
jolavillette
5cbcd962dd gui(forums): re-read the group on SUBSCRIBE_STATUS_CHANGED instead of flipping the flag
The event means the subscription status changed, not that it was
toggled: guessing the new value by inverting the current flag goes
wrong as soon as one event is duplicated, lost, or refers to a state
the widget already holds. When the guess lands on 'unsubscribed', the
widget silently refuses to mark posts read or unread (the very first
check of markMsgAsReadUnread) until the next group reload puts the flag
right again. updateGroupData() was already called anyway; let it be the
only writer of the flag.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
jolavillette
b0ca91c825 gui(forums): drop the expanded-items save/restore around read-status changes
setMsgReadStatus() only emits dataChanged(); it never resets the model
nor changes its layout, so the expanded items and the current index
survive it untouched. Saving and restoring them on every toggle was
pure overhead, and an expensive one: the restore walks every expanded
item and pays, for each, a linear scan of the post array plus a linear
scan of the view items -- quadratic work on the GUI thread for a single
post marked read or unread on a large forum.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
jolavillette
243c417bfc GxsForumModel: size the read-status view refresh on rows, not message ids
280e51f53 restricted the dataChanged() refresh to the affected post
unless more than 5 messages changed, in which case it refreshes the
whole view. But changed_msgs counts message ids, and a post carries one
id per stored version of itself, all sharing one read status: marking a
single post read or unread on a post edited 46 times queued 47 ids and
triggered the whole-model refresh. Measured on a 8259 post forum: one
click, one row repainted, 1072 ms of frozen GUI in the dataChanged()
handling; with this fix the same click costs about 1 ms.

Count the changed rows separately and size the refresh on that.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
jolavillette
3860f76dc1 gui(forums): create reload timer before setGroupId (fix ctor SIGSEGV)
The coalescing timer was allocated near the end of the constructor, but
setGroupId(forumId) is called earlier and synchronously reaches
groupIdChanged() -> updateDisplay(true) -> mDeferredReloadTimer->stop(),
dereferencing the still-uninitialised pointer and crashing the moment a forum
was opened. Allocate the timer right after setupUi(), before setGroupId().

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
jolavillette
839293f84d gui(forums): coalesce full-forum reloads to stop sync-burst UI freezes
handleEvent_main_thread() ran a full updateDisplay(true) (updateForum ->
getForumPostsHierarchy -> setPosts full reset -> proxy re-sort/re-filter ->
tree rebuild) for every incoming GXS event. A sync batch delivers many
NEW_MESSAGE events back to back, so the forum was reloaded once per post,
freezing the UI for seconds and resetting the model out from under the user's
current selection (and racing the async read-status persistence, making a
just-read post pop back to bold).

Route those events through a single-shot QTimer (300 ms) that is restarted on
each event, so a whole burst collapses into one reload once the events settle.
An explicit reload (forum switch) cancels any pending deferred one.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
jolavillette
78ff5d66e6 GxsForumModel: fix malformed model reset dropping freshly-arrived posts
setPosts() called beginResetModel()/endResetModel() *before* swapping mPosts,
so endResetModel() fired while the model still exposed the previous hierarchy,
then emitted an extra beginInsertRows()/endInsertRows() on top of the reset.
That double-signalling left the view/proxy row->source mapping stale, so a
post that had just arrived could map to an invalid source index: selecting it
neither displayed its content nor cleared its unread (bold) state.

Bracket the actual data swap with beginResetModel()/endResetModel() and drop
the bogus row-insertion signal; a full reset already tells the views to
re-query everything. Same anti-pattern as the channels grid-empty-on-new-post
fix.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
jolavillette
8959b45087 gui(forums): keep single-post read latency low via unitary markRead
Routing every read through the batched markRead(grpId, vector, read) also
routed single interactive reads (selecting/opening one post) through its
waitToken(): the READ_STATUS_CHANGED event, and thus the forum-list unread
counter refresh, was only emitted once the DB write completed, adding
~100ms plus one GXS tick of latency versus the previous behaviour.

Send a single changed message through the per-message markRead(pair),
which emits the event immediately, and keep the batched call only for
larger sets (mark-all, with-children, versioned posts) where deferring the
single event until completion is what avoids the freeze.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
jolavillette
2816dfd9f6 gui(forums): fix slow post navigation by restricting dataChanged refresh to affected post and parents 2026-08-01 23:16:08 +02:00
jolavillette
e5ed16c805 Channels/Posted models: never freeze the UI on "mark all as read"
GxsChannelPostsModel and PostedPostsModel spawned one detached std::thread (and
got one event) per post on "mark all as read/unread", freezing the UI on large
channels/boards - the same problem just fixed for forums, and worse here given
the much larger channel/board databases.

Both now collect the affected message ids and issue a single background batch
call (setMessageReadStatus / setPostReadStatus with a vector) plus a single view
refresh. PostedPostsModel additionally updates its local model up front (it
previously relied entirely on the per-message events).

Requires the matching libretroshare bulk overloads.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
jolavillette
f4463dd17f GxsForumModel: never freeze the UI on "mark all as read"
recursSetMsgReadStatus() used to spawn one detached std::thread per changed
post (each blocking up to 5s in markRead) and emit one dataChanged() per post.
On a forum with thousands of unread posts this created thousands of threads
and signals driven from the GUI thread, freezing (and sometimes crashing) the
UI - the reported symptom being an hour-long hourglass on an 8000-post forum.

Now the recursion only collects the affected message ids and updates the
in-memory model; setMsgReadStatus() then issues a single background batch call
(rsGxsForums->markRead(group, ids, read)) and a single view refresh. The GUI
thread does O(n) in-memory work plus one thread and one signal, so it stays
responsive no matter how large the forum is.

Requires the matching libretroshare bulk markRead() overload.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-01 23:16:08 +02:00
csoler
ec9ab70561
Merge pull request #3280 from jolavillette/perf/gxs-channel-loading
GUI: stop copying and sorting the channel post array in the Qt thread
2026-08-01 21:10:36 +02:00
jolavillette
0e31d5fed0 GUI: remove the profiling probes from the channel post model
Requested in review: the RS_GXS_PROFILE instrumentation of update_posts()
and setPosts() served to measure the freeze and verify the fix, but it
should not stay in the optimised code. The libretroshare profiling header
is no longer included.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-01 14:31:38 +02:00
jolavillette
28e7f791ff GUI: stop copying and sorting the channel post array in the Qt thread
setPosts() runs in the Qt thread, through postToObject(). It copied the whole
post array a fourth time and then sorted it there, so for a channel with a few
thousand posts the interface was frozen for the duration of both.

Move the sort into the loader thread in update_posts(), where the array is
already sitting after the service call, and have setPosts() take its argument
by rvalue reference so the array is moved in rather than copied. The sort is
kept in setPosts() as a safety net: on an already ordered array it only runs
comparisons and moves nothing.

Combined with the libretroshare side making posts movable, the array is now
handed from the data store to the model without a single deep copy of a
thumbnail.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-07-31 22:34:12 +02:00
jolavillette
54d4c791aa GUI: profile the channel post model loading
Complements the GXS side instrumentation (libretroshare, gxs/rsgxsprofiler.h)
with the two phases that happen in the GUI: the service calls made from the
loader thread in update_posts(), and the model update in setPosts(), which
runs in the Qt thread and is what actually freezes the interface.

setPosts() reports its three phases separately (array copy, sort, view update)
since they have very different causes.

Enabled by the same RS_GXS_PROFILE environment variable, off by default.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-07-31 22:34:12 +02:00
csoler
2bf991418d
Merge pull request #3284 from jolavillette/fix/feedreader-mark-all-unread
FeedReader: add "Mark all as unread" alongside "Mark all as read"
2026-07-30 14:34:04 +02:00
thunder2
2c9fcd0c57 Moved tor data directory for gui to account directory so that we can run multiple tor instances simultaneously 2026-07-27 19:07:57 +02:00
thunder2
9e92faad7c Use “GetModuleFileName” instead of argv[0] for the name of the executable file on Windows, as argv[0] does not always contain the full path 2026-07-27 19:07:57 +02:00
thunder2
e635848438 Use “QCoreApplication::applicationFilePath” instead of argv[0] for the name of the executable file, as argv[0] does not always contain the full path on Windows 2026-07-27 11:15:16 +02:00
jolavillette
2cd7c21aa6 gui(feedreader): add "Mark all as unread" alongside "Mark all as read"
The FeedReader message widget already offered "Mark all as read"
(toolbar button + context menu) but had no way to mark every visible
message as unread again. Add the symmetric "Mark all as unread" entry
to the message context menu.

Factor the shared iterate-over-visible-items logic out of
markAllAsReadMsg() into setAllMsgAsReadUnread(bool read); the read and
unread slots now just call it. Like the existing "mark all as read", the
action honours the current filter (acts on non-hidden rows only) and
goes through the existing per-message setMessageRead() path, so no
backend change is required.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-25 13:31:47 +02:00
Gioacchino Mazzurco
086184ad21
Fix GitLab mirror failing on GitHub PR refs
The mirror workflow cloned with --mirror and pushed all refs, including
GitHub's refs/pull/* and upstream/pr/*, which GitLab rejects as hidden
refs ("deny updating a hidden ref" on upstream/pr/3213), failing the
whole push. Clone --bare and push only refs/heads/* and refs/tags/*
with --prune, keeping deletion sync while never touching PR refs.
2026-07-23 18:10:46 +02:00
Gioacchino Mazzurco
76ba160ad1
Merge pull request #3269 from jolavillette/docs/build-cmake
Docs/build cmake
2026-07-23 17:56:14 +02:00
Gioacchino Mazzurco
0500db415c
Merge pull request #3243 from jolavillette/fix/cmake-qt6-detection
GUI CMake: reliably select Qt6 (with Qt5 fallback)
2026-07-23 17:03:03 +02:00
csoler
d57ecdeea7 fixed warning message about identities with insecure fingerprint 2026-07-18 20:42:03 +02:00
jolavillette
941a1ec6bd docs: add packaging and deployment section for Windows/MSYS2 in BUILD-cmake.md
Document portable archive creation (7-Zip / ZIP fallback), setup installer generation using NSIS, and how to execute and configure the deploy-windows.sh script.
2026-07-15 13:34:59 +02:00
jolavillette
70b1861e24 docs: add RS_USE_NATIVE_DIALOGS=ON to Windows build commands
Qt's non-native file/directory dialogs hang on Windows.
Using the OS native dialogs avoids the problem.
2026-07-13 15:29:25 +02:00
jolavillette
2759abca68 docs(BUILD): document version numbering (git describe derivation)
Explain how RS_GUI_VERSION, the libRetroShare version and RS_LIB_VERSION_HASH
are each derived from git describe at configure time, the exact commands to
read them without building, the --dirty submodule-pointer gotcha, the --long
always-suffixed libretroshare format, and the non-git fallback.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-12 12:47:37 +02:00
jolavillette
b3f137e580 docs(BUILD): checkout rapidjson fix commit after submodule init (GCC>=13)
The super-project pins rapidjson at f54b0e47, whose GenericStringRef::operator=
assigns to the const member `length`. That fails to compile on modern
toolchains (Debian 13 / GCC 14: "assignment of read-only member 'length'").
Add a note after the submodule init step telling testers to check out the
upstream fix 9bd618f5 (PR #719 on Tencent/rapidjson master).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-10 13:46:33 +02:00
jolavillette
6c16de174a docs(BUILD): add Debug build section for Linux (gdb symbols + ASan)
New 'Debug build (Linux)' subsection: CMAKE_BUILD_TYPE=Debug with -g3 -O0 -fno-omit-frame-pointer for full symbols and exact backtraces, a Qt6 note, a RelWithDebInfo caveat, the gdb invocation with the real binary path (Build-cmake/retroshare-gui/retroshare), and an AddressSanitizer variant for use-after-free / heap bugs.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-09 23:51:44 +02:00
defnax
7f15e396ac Fixed to not popup distant chat on incoming chat 2026-07-09 09:30:53 +02:00
jolavillette
923fe3338a fix(cmake): reliably prefer Qt6 over Qt5 in GUI detection
find_package(QT NAMES Qt6 Qt5 ...) does not honour the NAMES order on
distros that ship Qt5 and Qt6 side by side in the same prefix (Debian/
Ubuntu multiarch /usr/lib/<arch>/cmake): CMake globs the sibling
Qt5*/Qt6* config dirs and stops at whichever <name>Config.cmake it
reaches first, which is filesystem-order dependent and routinely lands
on Qt5 even though Qt6 is listed first.

Probe Qt6 explicitly (find_package(Qt6 QUIET COMPONENTS Core)) and fall
back to Qt5. This makes the Qt6 preference deterministic and also makes
-DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON work as a reliable Qt5-force switch.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-08 22:12:14 +02:00
jolavillette
063fb607f9 docs(BUILD): require RS_SERVICE_TERMINAL_WEBUI_PASSWORD=ON for the service WebUI
RS_WEBUI=ON alone builds the WebUI machinery, but retroshare-service then
has no way to turn it on: enableWebUI defaults to false and only the -W
flag ever sets it, and -W/-B are gated behind
RS_SERVICE_TERMINAL_WEBUI_PASSWORD (a cmake_dependent_option requiring
RS_WEBUI=ON). Document the flag and add it to every build command block.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-08 22:12:02 +02:00
jolavillette
762d4d5fd9 docs(BUILD): auto-detect CPU count for the Windows build
Windows hard-coded -j3; nproc is available in MSYS2, so use -j$(nproc) like
Linux. Added a note that MinGW C++ compilation is RAM-hungry and may need a
manually lower -j on low-memory machines (the reason for the old -j3 cap).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-08 22:12:02 +02:00
jolavillette
8af7995d7d docs(BUILD): drop inline # comments from copy-paste blocks
zsh interactive (interactive_comments off by default) rejects # in pasted
command lines. Moved the explanations to prose; the bash blocks are now
paste-clean.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-08 22:12:02 +02:00
jolavillette
d0fb9d749e fix(docs): exclude Qt kegs from macOS include/lib harvest
The blanket -I$(brew --prefix)/opt/*/include harvest pulled BOTH qt (Qt6)
and qt@5 headers into the same translation unit when both are installed,
causing Qt5/Qt6 header collisions ("Qt major version not 6 or 7",
qGetPtrHelper exception-spec mismatch). Skip every qt* keg in the harvest
loop on macOS; Qt is provided explicitly via Qt6_DIR / Qt5_DIR.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-08 22:12:02 +02:00
jolavillette
e735aaf18c docs: add BUILD-cmake.md with CMake build instructions (Qt5/Qt6)
Per-platform (Linux/macOS/Windows) CMake build commands for the
super-project, documenting Qt5 vs Qt6 selection and the
-DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON Qt5-force switch.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-08 22:12:02 +02:00
csoler
3081f530ca
Merge pull request #3258 from csoler/v0.6-IdentityDialog3
added warning for identities using deprecated signature format
2026-07-08 21:33:51 +02:00
csoler
c11ae6b071
Merge pull request #3252 from jolavillette/FilterChatSystemMessages
filter joined/left system messages in chat rooms
2026-07-07 21:56:38 +02:00
jolavillette
711589283a filter joined/left system messages in chat rooms 2026-07-06 22:07:44 +02:00
Gioacchino Mazzurco
bb47e094b3
Merge pull request #3265 from jolavillette/fix/gui-own-version-macros
fix(gui): give RetroShare GUI its own version, independent from libretroshare
2026-07-05 18:20:38 +02:00
csoler
d7b9e03528
Merge pull request #3264 from jolavillette/gxstrans-normalize-date-format
Gxstrans normalize date format
2026-07-04 20:44:50 +02:00
jolavillette
dd5add516e fix(gui): give RetroShare GUI its own version, independent from libretroshare
The GUI reported RS_HUMAN_READABLE_VERSION (a libretroshare macro) as "the
RetroShare version". In the CMake build libretroshare exports RS_MAJOR_VERSION
as a PUBLIC define, so the GUI inherited the engine's version and displayed it
as its own: About showed the same number for both.

Give the GUI its own version, as discussed:

- Add retroshare-gui/src/rsguiversion.h defining RS_GUI_VERSION with a built-in
  default, so every build path (including qmake/Android) compiles even without
  version injection.
- Inject RS_GUI_VERSION from 'git describe' of the super-project in both CMake
  (retroshare-gui/CMakeLists.txt) and qmake (retroshare.pri).
- RsApplication::retroshareVersion() now returns the GUI's own version instead
  of libretroshare's.
- About (HelpDialog) shows the GUI version at the top; libretroshare's version
  is listed among the other libraries, like any dependency. AboutWidget already
  displayed both lines and is now correct automatically.

libretroshare needs no change: it already exposes its own version through
RsInit::libRetroShareVersion() in both build systems.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-04 11:40:36 +02:00
jolavillette
2b1fb920af gui: replace GxsTransportStatistics 4s auto-refresh with manual Refresh
The RsAutoUpdatePage(4000) base class polled getGroupStatistics() every
4 seconds. That call issues blocking GXS token requests (up to 5s per
group) and had no anti-reentrancy guard, so background refreshes piled
up, saturated the GXS queue and froze the whole UI.

Revert to MainPage and drive updates on demand instead:
 - a Refresh button
 - showEvent(), so the page refreshes when navigated to
 - settingsChanged(), kept so a date-format change re-renders

Date normalization (formatDateTime) is preserved.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-04 11:14:17 +02:00
jolavillette
6e6e1403be gui: format dates in GxsTransportStatistics using DateTime and enable auto-update 2026-07-04 09:47:06 +02:00
csoler
af44d4c0e6
Merge pull request #3261 from RetroShare/revert-3254-colored-links-v5
Revert "Added colored links feature"
2026-07-03 23:22:20 +02:00
csoler
6ec6de5d0f
Revert "Added colored links feature" 2026-07-03 23:13:00 +02:00
csoler
6a9c354a85
Merge pull request #3254 from defnax/colored-links-v5
Added colored links feature
2026-07-03 22:51:29 +02:00
csoler
348c9e7e94
Merge pull request #3256 from jolavillette/fix/shared-files-popular-files-crash
fix(SharedFiles): stop SIGSEGV when toggling "Popular files" after a search
2026-07-03 18:25:26 +02:00
csoler
874b320ae3 added a warning for channels to be re-edited due to admin signature checking problem 2026-07-03 16:36:03 +02:00
csoler
a17464c316 added warning for identities using deprecated signature format 2026-07-02 22:17:43 +02:00
jolavillette
874d204b85 fix(SharedFiles): stop SIGSEGV when toggling "Popular files" after a search
Searching a keyword and then clicking "Popular files" crashed in
QSortFilterProxyModel::parent() (via rowsAboutToBeRemoved).

SFDSortFilterProxyModel::setUploadedOnly() called invalidateFilter(),
which runs Qt's incremental filter_changed row-removal path over the
currently-mapped tree. After a search the tree is fully expanded and
carries live persistent proxy indexes; removing an interior directory
node frees the child mapping structs those indexes still point at, and
the removal bookkeeping then dereferences freed memory -> SIGSEGV. The
plain-search path never crashed because it is always preceded by a full
model reset; the "Popular files" toggle was the only path that
re-filtered without one (deliberately, to avoid a slow re-crawl).

Use invalidate() instead: it rebuilds the whole proxy mapping via the
layoutAboutToBeChanged/layoutChanged protocol, which remaps persistent
indexes safely and never emits rowsAboutToBeRemoved. It rebuilds only
the proxy mapping (lazy, near-instant) and does not re-crawl the source
model, so the performance the toggle path was protecting is preserved.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-02 20:08:38 +02:00
defnax
460afb7824
fix qt6 compile 2026-06-27 15:33:28 +02:00
defnax
177141a042 Fix qt6 compile 2026-06-27 15:07:34 +02:00
defnax
74b8ebd31a Added colored links feature
Fixed to not send the color, only locally
2026-06-27 14:42:55 +02:00
csoler
d20c783769
Merge pull request #3245 from jolavillette/fix/qt6-qdatetime-settime_t
Qt6: replace removed QDateTime::setTime_t() with setSecsSinceEpoch()
2026-06-25 13:40:22 +02:00
csoler
78aa3f4d14
Merge pull request #3241 from jolavillette/fix/rsgraphwidget-area-fill
fix(gui): RSGraphWidget area fill — close polygon on a flat baseline
2026-06-24 09:25:20 +02:00
csoler
d788d23204
Merge pull request #3231 from jolavillette/fix/macos-camera-mic-permissions
fix(macos): add camera & microphone usage descriptions to Info.plist
2026-06-23 18:14:38 +02:00
csoler
07197c8bff
Merge pull request #3240 from csoler/v0.6-FeedItem2
Add a TLS attempt item to display connections without certificates in a separate more appropriate item.
2026-06-22 23:12:14 +02:00
jolavillette
0c0ad41f77 fix(gui): replace QDateTime::setTime_t with setSecsSinceEpoch for Qt6
QDateTime::setTime_t() was deprecated in Qt 5.8 and removed in Qt6.
setSecsSinceEpoch() exists since Qt 5.8 so the GUI keeps building
against both Qt5 and Qt6.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-20 18:14:53 +02:00
jolavillette
5ce0460ee3 fix(macos): add camera & microphone usage descriptions to Info.plist
macOS 10.14+ terminates the app with SIGABRT when it accesses the camera or microphone without the matching usage-description keys in the bundle's Info.plist. Any VOIP audio/video call therefore crashes on macOS as soon as the capture device is opened (AVCaptureDeviceInput via QVideoInputDevice::start()).

Add NSCameraUsageDescription and NSMicrophoneUsageDescription so the system shows the standard permission prompt instead of aborting the process.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-19 23:37:43 +02:00
csoler
4dca624abf updated CMakeLists to TLSItem 2026-06-19 09:47:10 +02:00
jolavillette
2c8210ce29 fix(gui): RSGraphWidget area fill — close polygon on a flat baseline
The PLAIN (area) paint style closed the fill polygon by prepending only the
bottom-right corner, so the polygon's closing edge ran from the bottom-right
corner straight to the leftmost data point. Whenever that leftmost point was
high, this drew a spurious diagonal across the whole graph, with the real curve
clipped above and/or below it.

Close the area along a flat baseline instead: add a baseline point under the
first (leftmost) and last (rightmost) data points, guarded on a non-empty set.

This affects every area-style RSGraph, but it is most visible in the VOIP
plugin's config-panel "Required bandwidth" graph: the value swings widely
(x264 variable bitrate) so the leftmost point is often high, making the
diagonal appear intermittently there.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-18 23:18:43 +02:00
csoler
09f8d90b12 fixed file header 2026-06-17 18:40:36 +02:00
csoler
89a1f5482c removed spurious yml file from 3213 2026-06-17 18:39:15 +02:00
csoler
fc696f8dae merging with upstream/master 2026-06-17 18:33:04 +02:00
csoler
b307edc5d6 added TlsItem files 2026-06-17 18:27:46 +02:00
csoler
431848066f fixed a few bugs in TlsAttempt feed item 2026-06-17 18:20:22 +02:00
Gioacchino Mazzurco
5374a746e2
Merge pull request #3235 from defnax/update-workflows
update workflows
2026-06-17 11:46:16 +02:00
Gioacchino Mazzurco
a06d1f0781
Merge pull request #3239 from jolavillette/fix/posted-metatype-rspostedpost
Fix missing Q_DECLARE_METATYPE include in Posted board widgets
2026-06-17 11:44:58 +02:00
jolavillette
d0c008c375 Fix missing Q_DECLARE_METATYPE include in Posted board widgets
Commit 724db9ae6 ("Fix duplicated MOC declaration") consolidated
Q_DECLARE_METATYPE(RsPostedPost) into PostedItem.h and removed the
in-file declarations that PostedListWidgetWithModel.cpp and
PostedPostsModel.cpp previously carried. But both translation units
use QVariant with RsPostedPost (value<>() / fromValue()) and neither
includes PostedItem.h, directly or transitively, so the build broke
with:

  error: static assertion failed: Type is not registered, please use
  the Q_DECLARE_METATYPE macro to make it known to Qt's meta-object
  system

Add the missing #include "PostedItem.h" to both files so the metatype
declaration is visible in those TUs.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-17 09:33:11 +02:00
Gioacchino Mazzurco
c418d75609
Fix and upgrade GitlabCI 2026-06-17 01:31:19 +02:00
Gioacchino Mazzurco
1d7a5ca8b0
Fix WEBUI dependent option value in gui and service 2026-06-16 23:35:30 +02:00
csoler
de1db9b083 added new feed item for TLS connection attempts 2026-06-16 23:25:31 +02:00
Gioacchino Mazzurco
724db9ae6a
Fix duplicated MOC declaration 2026-06-16 21:51:34 +02:00
Gioacchino Mazzurco
f3be330773
Merge pull request #3237 from jolavillette/qt6-cmake-compat
Qt6 compatibility for the CMake build (version-agnostic Qt5/Qt6)

There are a few minor issue to fix, but leave those for after we merge Qt6 support, and merge this AS IS before is too late
2026-06-16 19:44:46 +02:00
Gioacchino Mazzurco
eff56b8d30
Merge pull request #3229 from jolavillette/CMakeMigration-Modular-CrossPlatform
Port to CMake modular and cross platform

There are a few minor issue to fix, but leave those for after we merge Qt6 support, and merge this AS IS before is too late
2026-06-16 19:27:22 +02:00
csoler
719d6095f4
Merge pull request #3196 from defnax/improve.emoticons
[Emoticons] Added search & remember recent smileys
2026-06-16 09:09:52 +02:00
defnax
f454639087 added sizepolicy 2026-06-15 21:36:23 +02:00
csoler
df4561ec81
Merge pull request #3202 from defnax/boards-picture-navigation
[Boards] Added navigation for boards picture viewer
2026-06-15 20:49:07 +02:00
jolavillette
f3e5f8541d refactor(cmake): rename "monorepo" -> super-project terminology
The root build is a modular super-project: libretroshare, retroshare-gui,
retroshare-service, retroshare-friendserver and plugins are each a standalone
CMake project that the top-level CMakeLists.txt only aggregates (and they live
in separate git repos pulled as submodules). Rename project(retroshare-monorepo)
-> project(retroshare-superproject) and reword the CI header comments. Purely
cosmetic: the old name was referenced nowhere.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 19:41:45 +02:00
jolavillette
5ced3c66a7 ci(cmake): add Windows and macOS Qt6 CMake build workflows
Qt6 counterparts of windows-cmake.yml and macos-cmake.yml: build the tree
against Qt6 on UCRT64 (qt6-* incl. qt6-5compat) and macOS (Homebrew 'qt'). Both
keep plugins OFF since VOIP/FeedReader are not yet Qt6-ported. Completes the
Qt6 CMake CI matrix (Ubuntu already green).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 17:19:09 +02:00
jolavillette
819433027a fix(gui): guard GXS-id Q_DECLARE_METATYPE for Qt5 only (Qt6 AUTOMOC)
Under Qt6 + CMake the build failed compiling mocs_compilation.cpp with
'specialization of QMetaTypeId<...> after instantiation' for RsGxsId,
RsGxsGroupId and RsGxsMessageId.

CMake AUTOMOC concatenates every moc_*.cpp into a single translation unit; in
Qt6 these complete types get their QMetaTypeId implicitly instantiated by one
moc section, so the explicit Q_DECLARE_METATYPE in a later section becomes an
illegal re-specialization. qmake compiles each moc separately and never hits
this. Qt6 auto-registers complete types with the metatype system, so the
declaration is redundant there; guard it to Qt5 only. No behavior change on
Qt5; QVariant and queued connections keep working on Qt6 via auto-registration.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 16:58:11 +02:00
jolavillette
0f15a9eec5 ci(cmake): add Ubuntu Qt6 CMake build workflow
Qt6 counterpart of ubuntu-cmake.yml: builds the tree against Qt6 on
ubuntu-24.04 to exercise the version-agnostic Qt detection. Plugins kept OFF
since VOIP (Qt5 QtMultimedia API) and FeedReader (Qt5-hardcoded CMake) are not
yet ported.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 16:41:41 +02:00
jolavillette
f75315b0ff build(cmake): make retroshare-gui Qt detection version-agnostic (Qt5/Qt6)
Replace the hardcoded find_package(Qt5 ...) / Qt5:: links with the standard
QT NAMES Qt6 Qt5 pattern driven by ${QT_VERSION_MAJOR}, so the same tree builds
against both Qt5 and Qt6. On Qt6 add Core5Compat (for QRegExp et al.) and skip
QtX11Extras (idle_platform.cpp already uses QNativeInterface there; X11/Xss are
linked directly). Drop the dead 'if(NOT Qt6_FOUND) qt5_wrap_ui' double-wrap and
keep a single versionless qt_wrap_ui call.

The C++ sources are already Qt6-guarded upstream; this only wires Qt6 into the
CMake build. VOIP/FeedReader plugins are out of scope (still Qt5-only).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 16:41:41 +02:00
jolavillette
aa22a42d32 ci(cmake): add concurrency guard, bump checkout v5, use Ninja everywhere
- ubuntu-cmake: add concurrency cancel-in-progress (stop run pile-up per push)
- all 3: actions/checkout@v4 -> @v5 (Node 24; clears the Node 20 deprecation)
- ubuntu + macos: build with -G Ninja for consistency with Windows and a
  slightly faster build (ninja already present on Ubuntu; add brew ninja on macOS)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 13:09:09 +02:00
jolavillette
4683a595ef ci(windows-cmake): -Wno-template-body for GCC 16 (rapidjson 1.1.0)
Build reached 863/906 then failed in the FeedReader plugin: GCC 16's new
-Wtemplate-body diagnoses rapidjson 1.1.0's GenericStringRef::operator=
(assigns const members, never instantiated) as a hard error. FeedReader
includes rapidjson via -I (warnings active) unlike other targets that use
-isystem. Disable the check for the whole Windows build.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 10:48:40 +02:00
jolavillette
43bd9c2b1a ci(windows-cmake): use native UCRT64 doxygen for JSON API generator
The MSYS base /usr/bin/doxygen.exe treats CMake's Windows-style OUTPUT_DIRECTORY
(D:/...) as relative, producing a bogus mixed path and failing the jsonapi
generator. Use the native-Windows mingw-w64-ucrt-x86_64-doxygen instead, which
understands D:/ drive paths.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 10:18:38 +02:00
jolavillette
e09c0fef5b ci(windows-cmake): force-include cstring/cstdint for GCC 16 strictness
MSYS2 now ships GCC 16.1, which dropped many transitive includes. The pinned
librnp commit uses strlen() without <cstring>, so it failed to build
(crypto/mem.cpp: 'strlen' was not declared). Force-include the standard
string/stdint headers for the whole Windows build as a non-intrusive
workaround.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 10:09:39 +02:00
jolavillette
d2ef3c9335 ci(cmake): disable RS_FORUM_DEEP_INDEX (Xapian) on all platforms
Deep index is currently disabled in the project (Xapian unused; it will be
re-enabled via the ForumContentSearchFTS5 branch). Forcing it ON pulled
Xapian, which broke the Windows build: the MSYS2 xapian-core package ships
no import lib, so linking libretroshare.dll failed on a missing
/ucrt64/lib/libxapian.dll.a. Set RS_FORUM_DEEP_INDEX=OFF and drop the xapian
dependency everywhere so the CIs reflect the real config.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 10:01:00 +02:00
jolavillette
dd0bd44f94 ci: add Windows (MSYS2 UCRT64) CMake workflow building the full tree
CMake counterpart of the legacy qmake ci-ucrt64.yml, but builds the whole
tree (service/friendserver/sam3/rnp/plugins all ON) with Ninja and a shared
libretroshare, mirroring the user's validated local Windows command.
Submodules init without --remote (like the Linux/macOS CMake CIs).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 09:50:45 +02:00
jolavillette
0abb7888fd ci(macos-cmake): point find_package(Qt5) at keg-only qt@5
Configure failed because the broad CMAKE_PREFIX_PATH put the Homebrew
prefix ahead of qt@5, so find_package(Qt5) picked a broken Qt5 config
(referencing a non-existent mkspecs/macx-clang). Put qt@5 first and set
Qt5_DIR explicitly, matching the local build_retroshare.sh approach.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 09:27:56 +02:00
jolavillette
2a79b50b32 ci: add macOS CMake workflow building the full tree from root
CMake counterpart of the legacy qmake ci-macOS.yml, but builds the whole
tree (service/friendserver/sam3/rnp/plugins all ON) on macos-14 / Qt5,
using the user's validated Homebrew -I/-L flag harvesting plus
CMAKE_PREFIX_PATH so find_package() locates keg-only qt@5/botan@2/etc.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 09:22:56 +02:00
jolavillette
dd93c5a9f1 ci(ubuntu-cmake): install ffmpeg dev libs for the VOIP plugin
CMake configure failed at plugins/VOIP/CMakeLists.txt (pkg_check_modules
REQUIRED libavcodec/libavutil). Add libavcodec-dev and libavutil-dev.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 08:01:33 +02:00
jolavillette
8ef5f5f6cf ci: add Ubuntu CMake workflow building the full tree from root
Adds .github/workflows/ubuntu-cmake.yml as the CMake counterpart to the
legacy qmake CI. Builds the whole super-project from the top-level
CMakeLists.txt (libretroshare + gui + service + friendserver + plugins,
JSON API / WebUI on) on ubuntu-22.04 / Qt5.

Submodules are initialised without --remote so libretroshare stays on the
pinned CMake-enabled commit; librnp is fetched recursively for src/libsexpp.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 07:49:06 +02:00
jolavillette
e41eb4884e Merge branch 'master' into CMakeMigration-Modular-CrossPlatform
# Conflicts:
#	supportlibs/libsam3
2026-06-15 00:20:57 +02:00
Gioacchino Mazzurco
f5c7727561
Restore accidentally bumped supportlibs submodules 2026-06-14 22:08:41 +02:00
defnax
abfef2c8e7 update workflows
remove not needed ucrt flow
2026-06-14 21:39:19 +02:00
jolavillette
fa1e2903e7 Merge branch 'master' into CMakeMigration-Modular-CrossPlatform
Submodule pointer conflicts resolved by aligning with master:
- libretroshare  -> cafaaa19 (master; already contains this branch's CMake work)
- retroshare-webui -> a28d77fe (master)
- supportlibs/libsam3 kept at 6b61f1c (ahead of master, fast-forward)
2026-06-14 20:14:21 +02:00
Gioacchino Mazzurco
ee61aa58f0
Purge retroshare-service stale Android code 2026-06-14 16:24:55 +02:00
Gioacchino Mazzurco
912e096bda
Fix G10h4ck contributions copyright attribution 2026-06-14 16:10:56 +02:00
Gioacchino Mazzurco
1f8dda1d99
Update submodules 2026-06-14 15:53:03 +02:00
Gioacchino Mazzurco
50b8967ecc
Add github workflow to automatically sync to gitlab.com repo 2026-06-14 15:50:30 +02:00
jolavillette
0a227baa5d Merge remote-tracking branch 'origin/master' into CMakeMigration-Modular-CrossPlatform 2026-06-13 10:08:39 +02:00
csoler
6a021501e5
Merge pull request #3234 from jolavillette/fix/gxsforums-refresh-post-after-edit
gui(forums): refresh the post view immediately after editing a message
2026-06-12 19:29:54 +02:00
jolavillette
7771902b52 gui(forums): refresh the post view immediately after editing a message
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-11 21:21:40 +02:00
defnax
713d0fedc2 add space 2026-06-07 13:10:09 +02:00
defnax
ccf5116274 Added mIP to uniqueIdentifier(9
Hide not needed Labels for RS_FEED_ITEM_SEC_BAD_CERTIFICATE
2026-06-07 10:33:49 +02:00
csoler
ce5ea5c9eb
Merge pull request #3194 from defnax/improve-usage-stats
Improve Usage stats & added circle links
2026-06-06 22:15:21 +02:00
defnax
f44fe73eb7 fix naming 2026-06-06 22:05:30 +02:00
defnax
61a1d6a971 fix groupid 2026-06-06 21:43:18 +02:00
csoler
9a7c913ef2
Merge pull request #3205 from defnax/fiximport-friendslistwithgroup
[Fix] Fixed import Friends list with groups 🐞
2026-06-06 21:35:59 +02:00
defnax
a5f24fdceb Fix requested changes 2026-06-06 20:25:43 +02:00
jolavillette
0d83fd26dc build(friendserver): link OpenSSL again (needed via inlined libretroshare headers)
Removing OpenSSL from the friendserver in the previous round was wrong: although
friendserver sources don't #include <openssl/...> directly, friendserver.cc pulls
in libretroshare public headers whose inline functions call the OpenSSL EVP API
(EVP_DigestUpdate, ...). libretroshare links OpenSSL PRIVATE and is built shared on
Windows, so those symbols are not propagated to consumers — the link then fails
with "undefined reference to EVP_DigestUpdate" on MinGW. Link OpenSSL here again.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-06 19:01:11 +02:00
jolavillette
a53e1e919e build(gui): exclude libsam3.a from re-exported symbols (fixes Ninja Windows build)
With the Ninja generator on Windows, the GUI (-Wl,--export-all-symbols) re-exports
the symbols of the static libs it links; libsam3.a was missing from --exclude-libs,
so plugins that also link libsam3.a (FeedReader) failed with "multiple definition
of sam3GenerateKeys". The MSYS Makefiles generator does not hit this, but adding
libsam3.a to --exclude-libs keeps Ninja builds working too.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-06 19:01:10 +02:00
jolavillette
d4a20720ae build(macos): detect Qt version for the deploy archive name
deploy-macos.sh hardcoded QT_VERSION="UnknownQt", producing archive names like
...-Qt-UnknownQt.dmg. Query qmake (and the keg-only Homebrew qt@5 qmake) to put
the real Qt version in the name, mirroring deploy-windows.sh; fall back to
"UnknownQt" only if nothing is found.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-06 17:31:56 +02:00
defnax
7784a62f89 Added defines for wire code
Fix navigate to use gxsgroupid
2026-06-06 14:08:08 +02:00
jolavillette
28ff5a6d33 build: move deploy scripts under build_scripts/<platform>/
Following the removal of the orchestrator Makefile, the canonical build is now
plain CMake on the top-level CMakeLists.txt (e.g. cmake -B Build-cmake -S .
-DRS_PLUGINS=ON && cmake --build Build-cmake; on Windows add -G "MSYS Makefiles"
-DRS_LIBRETROSHARE_STATIC=OFF -DRS_LIBRETROSHARE_SHARED=ON).

Move the packaging scripts into their matching build_scripts/ sub-directories and
make them independent of the Makefile and of the invocation directory:
- deploy-macos.sh   -> build_scripts/OSX/deploy-macos.sh
- deploy-windows.sh -> build_scripts/Windows-msys2/deploy-windows.sh
Each script now cd's to the repository root from its own location and reads the
build directory from BUILD_DIR (default Build-cmake) instead of assuming it.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-06 12:34:07 +02:00
jolavillette
30f38cf1b5 gui: use nullptr instead of 0 in PluginManager::pluginWidget
Review feedback: prefer nullptr over 0 for the QWidget* return.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 21:12:24 +02:00
jolavillette
4955741dae build(macos): fix CFBundleExecutable to match the renamed GUI binary
The GUI executable was renamed to "retroshare-gui" (RUNTIME_OUTPUT_NAME), but the
macOS bundle Info.plist still declared CFBundleExecutable=retroshare, so macdeployqt
(and Finder) looked for Contents/MacOS/retroshare and failed with
"Could not find bundle binary". Point it at retroshare-gui.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 18:57:37 +02:00
jolavillette
d1785479c8 build(cmake): address 2nd review round (deps, naming, per-target hacks)
Reply to G10h4ck's second review pass on the CMake migration PR.

- FeedReader: revert the waitForToken interface->helper rename. libretroshare
  defines WIN32_LEAN_AND_MEAN PUBLIC, inherited by the plugin on Windows, so
  <windows.h> no longer pulls in the "interface" macro; the rename is unneeded.
- retroshare-gui: name the GUI executable "retroshare-gui" on all platforms
  (RUNTIME_OUTPUT_NAME); clarify that the TARGET define is the single-instance
  socket name, not the executable name.
- retroshare-gui: gate -Wno-deprecated(-declarations) behind a new
  RS_WARN_DEPRECATED option, mirroring libretroshare.
- retroshare-gui: document direct deps (sam3, X11/XScreenSaver idle detection,
  _FILE_OFFSET_BITS) and the librnp-transitive deps (botan, json-c, z, bz2).
- root: move the global Windows UNICODE/_UNICODE definition and the GCC>=15
  error downgrade out of the global scope into per-target settings (bitdht,
  and the legacy C submodules), applied after the subdirectories are added.
- root: document why the sam3 target is defined once at the top level.
- deploy-macos.sh / deploy-windows.sh: keep them (deployment is a first-class
  step), document why the macdeployqt/windeployqt glue is needed, and update
  the bundle/executable names for the rename (retroshare-gui).
- Stop tracking the convenience Makefile and build_retroshare.sh (CMake builds
  everything itself); they remain available locally as untracked files.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 18:14:18 +02:00
jolavillette
ac5190d90d build(cmake): address reviewer feedback and drop unrelated cosmetic changes
Reply to the build-system review on the CMake migration PR.

CMake:
- retroshare-gui: bump project version 0.6.6 -> 0.6.7; restore
  CMAKE_VERBOSE_MAKEFILE ON for development builds; reword
  RS_USE_NATIVE_DIALOGS description without referring to qmake; document
  why AUTOUIC is OFF and why the qmake_info.h shim exists.
- retroshare-gui: fix circles option name mismatch (if(RS_GXS_CIRCLES) ->
  if(RS_GXSCIRCLES)) so RS_USE_CIRCLES is actually defined.
- VOIP, friendserver: drop OpenSSL (and ZLIB/BZip2 for friendserver) which
  are not used directly and come transitively through libretroshare; keep
  ws2_32 for the friendserver (direct Winsock use in network.cc) and drop
  winmm/iphlpapi/mswsock.
- FeedReader: document OpenSSL as a direct dependency and the Windows-only
  plugin link requirement.
- VOIP: document __STDC_CONSTANT_MACROS (required by the libav headers).

Source (kept, now with justifying comments; required to build cross-platform):
- p3FeedReader: parameter renamed interface -> helper ("interface" is a
  reserved Windows SDK macro).
- PluginsPage, PluginManager, PluginManagerWidget, GxsGroupDialog: compile
  fixes exposed by the modular build.

Reverted unrelated cosmetic renames (back to master, dropped from the PR):
- MessageComposer.cpp (grp2), RsNetUtil.cpp (lst2).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 14:47:47 +02:00
jolavillette
c425487bbb Merge remote-tracking branch 'upstream/master' into CMakeMigration-Modular-CrossPlatform 2026-06-04 16:47:44 +02:00
jolavillette
d26f959551 build: improve Makefile help/show-config, harden deploy-windows.sh 2026-06-04 15:22:53 +02:00
jolavillette
1456679914 Build: unify librnp into libretroshare; fix GUI librnp link
- Makefile / build_retroshare.sh: drop the standalone librnp step
  (now built inside libretroshare), use cmake --build for portability.
- retroshare-gui: link the librnp library target instead of the rnp
  executable (fixes Windows configure) and drop obsolete librnp link dirs.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-03 13:21:00 +02:00
jolavillette
20f416119c macOS: restore Qt5Svg link specifically for macdeployqt framework packaging 2026-06-02 21:59:08 +02:00
jolavillette
0a00032aa5 macOS: fix plugins deployment and SVG icons support 2026-06-02 21:40:48 +02:00
jolavillette
90c04aa2f1 build: default to Release build type 2026-06-02 21:32:36 +02:00
jolavillette
f196e47cda build: add Windows deployment automation script 2026-06-02 19:33:01 +02:00
jolavillette
9822e011a5 macOS: Add proper bundle creation, deployment script, and Qt5 prefix fixes 2026-06-02 19:31:52 +02:00
csoler
153a2fc401 updated libretroshare to latest commit 2026-06-02 18:14:40 +02:00
jolavillette
d93f07fea6 Fix Windows build: force shared library compilation for libretroshare and remove linker workarounds 2026-06-02 14:42:40 +02:00
csoler
bd58953ca2
Merge pull request #3224 from jolavillette/FeedReader/FixWindowsMSYS2XmlTextExtractionTruncation
Fix FeedReader text truncation on Windows MSYS2 by forcing UTF-8 and improving XML extraction
2026-06-02 14:41:26 +02:00
jolavillette
7b643c7805 fix(windows): resolve sam3 socket errors and plugin linking multiple definitions 2026-06-01 19:04:42 +02:00
jolavillette
e6d8909b0a fix(build): restore global C++17 and macOS plugin linker flags 2026-06-01 18:48:04 +02:00
jolavillette
72cb4eabd2 fix(build): globally enable I2P SAMv3 support by default and link GUI to sam3 2026-06-01 12:58:11 +02:00
jolavillette
6e61ed2e77 build: make Makefile options cache-aware to support conditional plugin compilation 2026-06-01 09:58:21 +02:00
jolavillette
68fe4256c6 fix(build): enforce global C++17 and enable macOS dynamic lookup for plugins 2026-06-01 09:55:58 +02:00
jolavillette
9b03dd9c54 Merge branch 'master' into CMakeMigration-Modular-Windows-MacOS 2026-05-31 20:50:27 +02:00
jolavillette
c290a7eadf build: optimize orchestrator with DRY options, show-config caching and robust quoting 2026-05-31 20:49:42 +02:00
jolavillette
839e838dcf fix(build): allow disabling RS_JSON_API option when GUI is enabled 2026-05-31 20:49:36 +02:00
jolavillette
1d476241e8 Build: Support dynamic macOS M1 compilation in Makefile and add build helper script 2026-05-31 16:37:23 +02:00
jolavillette
83b6304eea Fix MacOS compilation 2026-05-31 14:12:45 +02:00
defnax
1fd71d6094
Merge branch 'RetroShare:master' into fix-sslrequest 2026-05-27 08:14:53 +02:00
csoler
0e9c79e4a5
Merge pull request #3204 from defnax/wire-groupcount
[Wire] Added to show which posts are new & read function
2026-05-25 15:35:14 +02:00
jolavillette
d59ce80ed0 Revert "FeedReader: keep XML_TEXT_NODE test to prevent undefined behavior in getContent()"
This reverts commit 4be95c236e.
2026-05-25 11:08:06 +02:00
csoler
98fe51ce73
Merge pull request #3087 from jolavillette/AddTableViewInRttStatistics
Add table view in rtt statistics
2026-05-25 10:19:29 +02:00
jolavillette
a5f0e01248 Merge branch 'master' into CMakeMigration-Modular-Windows 2026-05-25 10:08:41 +02:00
jolavillette
7500d8f8b4 Fix: integrate upstream rsRtt->getPongResults() check to avoid conflict 2026-05-25 10:06:10 +02:00
jolavillette
593efd723f various fixes and improvements following cyrils comments 2026-05-25 10:06:10 +02:00
jolavillette
4c4cfbb48a disable table update when widget is hidden or tab inactive 2026-05-25 10:06:10 +02:00
jolavillette
714c5caa36 Restore graph view and use O(N) QHash lookup for the table view 2026-05-25 10:06:10 +02:00
jolavillette
10595b9596 Replace RTT graph with a sortable table view: Name, RTT, ID, IP 2026-05-25 10:06:10 +02:00
jolavillette
4be95c236e FeedReader: keep XML_TEXT_NODE test to prevent undefined behavior in getContent() 2026-05-25 07:17:17 +02:00
jolavillette
25b79662ea Fix FeedReader text truncation on Windows MSYS2 by forcing UTF-8 and improving XML extraction 2026-05-25 07:17:16 +02:00
csoler
ea605d4142
Merge pull request #3222 from jolavillette/FixForumReadStatus
gui: Fix forum read status refresh issues by updating all columns and correcting parent loop
2026-05-24 17:01:36 +02:00
csoler
56ab914b1f
Merge pull request #3221 from jolavillette/FeedReader/FixTooLargeRSSFeedPosts
Fix FeedReader: truncate oversized feed messages to prevent deserialization failure on startup
2026-05-24 16:25:34 +02:00
jolavillette
34220b3417 gui: Fix forum read status refresh issues by updating all columns and correcting parent loop 2026-05-24 11:10:18 +02:00
jolavillette
9da2af5844 FeedReader: extract RSS message size correction to correctMsgSize 2026-05-24 11:09:16 +02:00
jolavillette
079967dcf7 Fix FeedReader: truncate oversized feed messages to prevent deserialization failure on startup 2026-05-24 11:09:16 +02:00
jolavillette
ab561c673e Merge branch 'CMakeMigration-Modular' into CMakeMigration-Modular-Windows 2026-05-24 02:58:33 +02:00
jolavillette
d77d958231 Merge branch 'master' into CMakeMigration-Modular 2026-05-24 02:58:26 +02:00
jolavillette
a689fa4042 Merge branch 'CMakeMigration-Modular' into CMakeMigration-Modular-Windows 2026-05-24 02:40:23 +02:00
jolavillette
ecbc0aba54 Makefile: add interactive help target explaining targets and options 2026-05-24 02:40:16 +02:00
jolavillette
a7608b3561 Makefile: add command line options validation and support for RS_FORUM_DEEP_INDEX 2026-05-24 02:40:07 +02:00
jolavillette
1018d6c751 Makefile: use modern CMake syntax and rename build directory to Build-cmake 2026-05-24 02:39:59 +02:00
jolavillette
4ec8bafec7 plugins & friendserver: explicitly link OpenSSL to resolve dynamic library dependencies 2026-05-24 02:05:50 +02:00
csoler
fcb56e2c5c
Merge pull request #3191 from dbear496/patch-1
Enable RNP lib option in CMakeLists.txt
2026-05-23 20:51:29 +02:00
csoler
82fabb04ee
Merge pull request #3203 from defnax/fix-navigationtocomments
[Fix] Fixed channels comments navigation 🐞
2026-05-23 19:16:43 +02:00
csoler
60a343c4a0
Merge pull request #3215 from defnax/fix-photos
Fix photos compile
2026-05-23 18:49:52 +02:00
jolavillette
3273f40db9 build(cmake): hide console on Windows in Release 2026-05-23 08:31:19 +02:00
jolavillette
7dac424db8 build(cmake): include retroshare_win.rc for Windows build icon 2026-05-23 07:44:03 +02:00
jolavillette
81e67f5103 gui: Add RS_PLUGINS option to enable modular plugin builds 2026-05-22 13:43:57 +02:00
jolavillette
75d916c1f1 gui: Fix dynamic export table and symbol exclusions for Windows plugins 2026-05-22 13:43:24 +02:00
jolavillette
6cab9e4fce gui: Resolve import library name collisions on Windows 2026-05-22 13:43:08 +02:00
jolavillette
324111e991 build: remove unsafe allow-multiple-definition hack 2026-05-22 12:07:56 +02:00
jolavillette
5341b777d3 build: set build dir to Build-cmake and auto-detect MSYS Makefiles on Windows 2026-05-22 09:51:21 +02:00
jolavillette
c0a3eb38b0 build: define WINDOWS_SYS for FeedReader and VOIP plugins on Windows 2026-05-22 04:41:04 +02:00
jolavillette
01552ed04e build: fix GUI export limit by excluding library symbols on Windows 2026-05-22 04:41:04 +02:00
jolavillette
6ce1588354 build: enable dynamic exports and allow multiple definitions on Windows 2026-05-22 04:41:04 +02:00
jolavillette
765a398659 win32: fix plugin compilation by enabling exports on GUI and linking plugins privately to retroshare and retroshare-gui on Windows 2026-05-21 14:04:57 +02:00
jolavillette
67ff1268ed Merge branch 'CMakeMigration-Modular' into CMakeMigration-Modular-Windows 2026-05-21 11:47:40 +02:00
jolavillette
110bdfa850 voip: fix CMake crash by moving target compile definitions after target is declared 2026-05-21 11:44:26 +02:00
jolavillette
04947a0a90 service: fix WebUI FetchContent path fallback when submodule is missing 2026-05-21 11:43:24 +02:00
jolavillette
942e902d70 build: fix GUI include path ordering to avoid Windows case-insensitive conflict 2026-05-21 10:57:58 +02:00
jolavillette
a23452eb96 Merge branch 'CMakeMigration-Modular' into CMakeMigration-Modular-Windows 2026-05-21 08:25:09 +02:00
jolavillette
31151d462e build: scope macOS directories to service target, improve GUI local lib resolution 2026-05-21 08:22:11 +02:00
jolavillette
25e4b5c039 Merge branch 'CMakeMigration-Modular' into CMakeMigration-Modular-Windows 2026-05-21 07:50:03 +02:00
jolavillette
b5df468af7 cmake: modernize directory scopes and complete cmark integration in retroshare-gui 2026-05-21 07:48:44 +02:00
jolavillette
fb381f9dda Merge branch 'CMakeMigration-Modular' into CMakeMigration-Modular-Windows 2026-05-21 04:20:23 +02:00
jolavillette
e3c75aed62 build: scope compile options to targets, fix cmark detection bug 2026-05-21 04:08:58 +02:00
jolavillette
43614c559f Merge branch 'CMakeMigration-Modular' into CMakeMigration-Modular-Windows 2026-05-20 19:40:51 +02:00
jolavillette
48b9267f4f build: clean up duplicate RNP and retroshare linking in service and friendserver 2026-05-20 19:39:44 +02:00
jolavillette
a969528119 build(cmake): fix Windows compilation by defining global Unicode mapping and GCC 15 compatibility flags in root CMakeLists.txt 2026-05-20 17:29:26 +02:00
jolavillette
a7ea0f0c70 build(cmake): define custom retroshare-webui target for Windows builds using MSYS2 sh 2026-05-20 16:54:12 +02:00
jolavillette
3d81ef6eca Build: WIN32: normalize WebUI directory path to fix absolute resolution 2026-05-20 14:24:24 +02:00
jolavillette
645d841761 Build: add robust MinGW link groups for Windows targets 2026-05-20 09:58:53 +02:00
jolavillette
219931e331 Fix Windows compile: rename local variables colliding with Windows API macros 2026-05-20 09:58:48 +02:00
jolavillette
70a5715556 Build: Generate qmake_info.h under CMake binary directory to fix clean build 2026-05-20 09:58:27 +02:00
jolavillette
d8f1267124 build(cmake): integrate FeedReader and VOIP plugins as optional targets 2026-05-20 09:58:22 +02:00
jolavillette
ff60b62868 Optimize monorepo unified build paths, Botan package lookups, and Makefile orchestrator 2026-05-20 09:58:17 +02:00
jolavillette
a6c9695168 Optimize monorepo unified build paths and Botan package lookups 2026-05-19 07:57:53 +02:00
jolavillette
28d2f66ca6 build: implement modular orchestrator Makefile and resolve GUI cross-folder AUTOUIC issues 2026-05-18 18:00:32 +02:00
jolavillette
4bd02cf0bb build(cmake): implement modular build system and align service dependencies 2026-05-18 16:04:01 +02:00
defnax
1de6e926d5 Fix photos compile 2026-05-04 22:34:33 +02:00
defnax
1070f39ad0 Fix workflows by saurabh 2026-05-01 12:52:36 +02:00
defnax
c2aa157104 Fixed SecurityItem 2026-05-01 11:59:03 +02:00
defnax
65b16c30d3 Removed fixe size
* Added vertical spacer
2026-04-25 21:47:02 +02:00
defnax
d4ab2ffea0 Fixed read status 2026-04-25 14:12:47 +02:00
defnax
209a482a17 Added to store & load the sort filter 2026-04-22 21:07:23 +02:00
defnax
c83766ad91 Fixed import Friends list with groups 2026-04-21 18:03:48 +02:00
defnax
13a46c5d57 Added to show which posts are new & read function 2026-04-20 22:57:23 +02:00
csoler
6b5947b73e
Merge pull request #3192 from defnax/wire-groupcount
[Wire] Added to count Wire group box & read message
2026-04-20 22:15:54 +02:00
defnax
fefc65b03e Fix for RsServiceType::WIRE 2026-04-19 21:00:07 +02:00
defnax
919343d232 Fixed channels comments navigation
*Fixed layout margins
2026-04-19 19:30:17 +02:00
defnax
9c8563aef1 Added navigation for boards picture viewer 2026-04-19 17:15:11 +02:00
defnax
87d0925a92 removed bool function 2026-04-18 17:18:20 +02:00
defnax
f8eac31a0c Added new method to retrieve groupname or title 2026-04-18 16:14:56 +02:00
defnax
3faa35cfb0 Fixed message read status to use new method
*Fixed default Avatars
2026-04-12 18:10:25 +02:00
defnax
e6e7340da6 Added "Mark all as read" feature 2026-04-12 15:35:24 +02:00
defnax
629f5922dd Fix margins & spacing 2026-04-09 19:52:55 +02:00
defnax
ad7dd0a41a Added Scrollbar 2026-04-09 18:42:01 +02:00
defnax
b814f841e4 Fixed compile 2026-04-08 22:09:10 +02:00
defnax
3eb4e07e4f Fixed to get work basic keyboard navigation 2026-04-07 20:28:35 +02:00
defnax
c797a72b89 remember last used tab 2026-04-07 18:12:41 +02:00
defnax
206e6c1fea Added collect recent smileys
* Added search for smileys
2026-04-06 21:26:00 +02:00
defnax
6e4f9b0322 Improve Usage stats
*Added for circles retroshare links feature
2026-04-06 16:38:47 +02:00
csoler
94225f8cb9
Merge pull request #3184 from defnax/circles-makecoloredgroupicons
Changed circles group tree icons
2026-04-06 16:33:12 +02:00
defnax
d63cdcd797 removed unused define 2026-04-06 11:43:39 +02:00
defnax
6810da41f9 Added to count Wire group box 2026-04-03 16:00:10 +02:00
David Bears
8e557b8a41
Enable RNP lib option in CMakeLists.txt 2026-04-01 12:03:02 -04:00
defnax
2d60ff30c1 Removed the menu function 2026-03-29 12:28:54 +02:00
defnax
cab6efd83e enabled the default icons for circles & added optional change via context menu 2026-03-28 14:45:19 +01:00
csoler
5d2024c2a1
Merge pull request #3182 from jolavillette/FixForumFilterBehaviour
gui: Fix GXS forum selection and display logic when filtering posts
2026-03-22 17:01:27 +01:00
jolavillette
35b6cc3260 gui: Fix GXS forum selection and display logic when filtering posts 2026-03-18 02:13:15 +01:00
csoler
7f225ac15e
Merge pull request #3185 from jolavillette/ImplementIdleTimeNever
Settings: allow disabling idle timeout by setting Idle Time to 0 (Never)
2026-03-17 22:54:14 +01:00
csoler
8dff752eb1
Merge pull request #3187 from jolavillette/FixCountOccurrenceOfTextInChatPreferences
gui: Fixed "count occurrence of the following text" not being saved in Chat Preferences
2026-03-17 22:50:47 +01:00
csoler
7d868dac5c
Merge pull request #3186 from jolavillette/FixChannelAppearingUnsubscribedAfterPosting
GUI/Channels: Fix channel appearing unsubscribed after posting by reloading metadata instead of toggling flag
2026-03-17 22:48:51 +01:00
jolavillette
6d1d0c83ec gui: Fixed "count occurrence of the following text" not being saved in Chat Preferences 2026-03-17 12:31:23 +01:00
jolavillette
6eaad9ae21 GUI/Forums: Restore GxsForumThreadWidget.cpp from master following accidental modifications 2026-03-17 10:07:43 +01:00
jolavillette
470b2df20e GUI/Channels: Fix channel appearing unsubscribed after posting by reloading metadata instead of toggling flag 2026-03-17 06:03:49 +01:00
jolavillette
fecce7999e Settings: allow disabling idle timeout by setting Idle Time to 0 (Never) 2026-03-14 10:06:55 +01:00
defnax
c772917516
Merge pull request #240 from jolavillette/Fix_PR3184_1
GUI: Fix PR3184 bugs (icon distortion, memory leak, nickname refresh) and optimize cache
2026-03-12 16:11:33 +01:00
jolavillette
3481b262e9 GUI: Fix PR3184 bugs (icon distortion, memory leak, nickname refresh) and optimize cache 2026-03-12 07:08:51 +01:00
defnax
4bbdedb7c5 Fixed to show for empty nicks, default string 2026-03-11 20:21:09 +01:00
defnax
6cd25e3277 Fixed Avatar dimensions 2026-03-11 20:07:11 +01:00
defnax
1039a1a8a9 Added group icon generation for the circles group tree 2026-03-11 19:06:37 +01:00
csoler
5ea309d032
Merge pull request #3183 from jolavillette/FixForumDisplaysDetailsInsteadOfPostConten
fix: forum details is displayed instead of post content
2026-03-11 12:17:26 +01:00
csoler
47398f7d03
Merge pull request #3177 from jolavillette/FixI2PProxyUneditable
fix: initialize mSamSettings to prevent i2p proxy fields being uneditable without SAM3
2026-03-11 12:10:48 +01:00
jolavillette
553cb42759 fix: forum details is displayed instead of post content 2026-03-10 09:51:10 +01:00
jolavillette
6392d08347 fix: initialize mSamSettings to prevent i2p proxy fields being uneditable without SAM3 2026-03-09 05:16:06 +01:00
csoler
5b7d50f364
Merge pull request #3171 from samuel-asleep/implement-3107
Modernize Wiki GUI with libretroshare integration and features
2026-03-08 15:15:52 +01:00
Akinniranye Samuel Tomiwa
50d4e2cdd4
fix(ui): remove redundant guards and prevent partial group updates
- Remove meaningless null-check on `ui` value member.
- Remove redundant `!mModeratorsWidget` guard in `initUi()` as it is called once post-initialization.
- Fix `service_updateGroup()` to return early on fetch failure, preventing the submission of default-constructed group data.
- Refactor `addModeratorToList()` to use `findItems().empty()` for duplicate detection instead of a manual loop.
2026-03-07 15:50:40 +01:00
Akinniranye Samuel Tomiwa
00c69e135e
Merge branch 'RetroShare:master' into implement-3107 2026-03-07 12:29:23 +01:00
csoler
80e08cc9d9
Merge pull request #3159 from jolavillette/FixChannelsDetailsAndSubscribeButton
fix GXS details not loading at startup, and Subscribe button not updating when subscribing
2026-03-06 18:46:56 +01:00
csoler
479619d05d
Merge pull request #3168 from jolavillette/FixTheWireUIFreeze
TheWire: Fix UI
2026-03-06 18:32:01 +01:00
csoler
5daca8ff7d
Merge pull request #3175 from jolavillette/FixCrashInRTTStatistics
Fix std::list assertion crash in RttStatistics by checking if results are empty
2026-03-06 18:21:48 +01:00
csoler
be145de3dd
Merge pull request #3179 from retrop00h/chatcolors_switche
add option to disable custom font color in chats
2026-03-06 18:15:04 +01:00
Akinniranye Samuel Tomiwa
28b9228ccd
Merge branch 'RetroShare:master' into implement-3107 2026-03-04 18:05:33 +01:00
jolavillette
046914e77f TheWire: Use new token-free subscribe API 2026-03-04 00:40:55 +01:00
jolavillette
f1dfe1d22f comment out GXS_GROUP_FLAGS_PERSONALSIGN 2026-03-04 00:40:55 +01:00
jolavillette
d1d009517e TheWire: implement event throttling and fix navigation history 2026-03-04 00:40:55 +01:00
jolavillette
47a0cbc232 TheWire: Use deleteLater() in WireDialog to prevent crash during background updates 2026-03-04 00:40:55 +01:00
jolavillette
bcc80890f5 TheWire: Refactor blocking service calls to be asynchronous in WireDialog.cpp 2026-03-04 00:40:55 +01:00
jolavillette
b495252b13 Fix std::list assertion crash in RttStatistics by checking if results are empty 2026-03-04 00:39:37 +01:00
jolavillette
1121d36ee2 fix forum post replaced by forum description on GXS event refresh 2026-03-04 00:39:21 +01:00
jolavillette
74056803a8 cleanup GxsForumThreadWidget.cpp trailing lines to fix merge conflicts 2026-03-04 00:39:21 +01:00
jolavillette
09bc572084 clean code 2026-03-04 00:39:21 +01:00
jolavillette
1658f9bdce remove QTimer from SUBSCRIBE_STATUS_CHANGED handler, use local flag toggle instead 2026-03-04 00:39:21 +01:00
jolavillette
b3e4861b5f enable Posts/Files tabs and update full UI after subscription 2026-03-04 00:39:21 +01:00
jolavillette
e07e6362c3 fix GXS details not loading at startup, and Subscribe button not updating when subscribing 2026-03-04 00:39:21 +01:00
csoler
b020001906
Merge pull request #3170 from jolavillette/FixProfileAvatarSelection
fix profile avatar selection to prioritize connected nodes
2026-03-03 23:08:06 +01:00
retrop00h
ecf413d618 add option to disable custom font color in chats 2026-03-04 00:25:23 +03:00
csoler
61150080d0
Merge pull request #3176 from jolavillette/FixTheWireForcedCompilation
Fix the wire forced compilation
2026-03-03 20:30:09 +01:00
csoler
a554aa4fc3 desactivated thewire from default compilation 2026-03-03 17:41:13 +01:00
csoler
be244c15e3 desactivated thewire from default compilation 2026-03-03 17:22:51 +01:00
csoler
51c643e237 desactivated thewire from default compilation 2026-03-03 17:14:47 +01:00
jolavillette
e331f19c54 build: disable TheWire compilation by default 2026-03-03 07:15:26 +01:00
jolavillette
19619ecb37 guard TheWire code in RetroShareLink.cpp so that RS can be compiled without TheWire 2026-03-03 06:53:05 +01:00
jolavillette
ebaf1a0ed7 fix profile avatar selection to prioritize connected nodes 2026-03-03 06:52:35 +01:00
thunder2
fcc5ba410c Windows build: Updated 7-Zip 26.00 x64 2026-03-02 19:49:24 +01:00
csoler
a0808a839b
Merge pull request #3173 from dbear496/fix-cmake-with-rnp
fix CMake build with RNP
2026-03-01 14:33:36 +01:00
David Bears
8edec60290
fix CMake build with RNP 2026-02-28 18:05:46 -05:00
Akinniranye Samuel Tomiwa
9c01d35d06
Fix stale identity data, HTML injection, and double insertion in WikiGroupDialog 2026-02-28 23:49:15 +01:00
Akinniranye Samuel Tomiwa
c69b7cef0c gui: remove unused WikiTokenWaiter helper 2026-02-28 23:27:18 +01:00
csoler
38dc687e66
Merge pull request #3169 from defnax/fix-wirepostnotifyui
Fix wire post notify & default icon fix
2026-02-28 20:06:04 +01:00
defnax
770ee67e94 Added to use makeDefaultGroupIcon for wire 2026-02-28 14:31:18 +01:00
Akinniranye Samuel Tomiwa
fa28bf6f9c
Modernize Wiki GUI with libretroshare integration and features 2026-02-27 09:53:12 +01:00
defnax
ae098607dc Fix wire post notify 2026-02-24 20:51:37 +01:00
csoler
c686375050
Merge pull request #3141 from SaurabhCodesAI/wire-notifyv2
Wire Complete implementation of Issue #2923 todos
2026-02-23 22:03:25 +01:00
csoler
92fbd85e6a
Merge pull request #3157 from defnax/avatar-fix
Fixed to show the status frame
2026-02-21 21:10:44 +01:00
csoler
16d1744b6a
Merge pull request #3160 from jolavillette/fix-macos-id-edit-password
retroshare-gui: fix identity edit password prompt issues on macOS
2026-02-21 21:00:18 +01:00
jolavillette
aa0e9f9337 retroshare-gui: fix identity edit password prompt issues on macOS
- Fix dangling pointer in RsGUIEventManager when capturing password
- Improve parent selection for input dialog to work correctly with macOS sheets
- Optimize GUI_askForPassword for direct calls when on GUI thread
- Ensure execReturn is initialized to avoid garbage values
- Clear password cache before asking to ensure prompt appears if needed
2026-02-21 12:09:23 +01:00
saurabh
67849d619b Wire: Fix republish/like popup, correct profile counts, show followers, adopt defnax UI cleanup, fix GxsStatisticsProvider migration 2026-02-21 16:07:59 +05:30
csoler
6aef07d2ea
Merge pull request #3167 from csoler/v0.6-BugFixing_42
removed isVisible() from IdDialog update so that it does update when …
2026-02-20 21:33:09 +01:00
csoler
e1afeee37d removed isVisible() from IdDialog update so that it does update when an identity is created from another tab 2026-02-20 21:32:13 +01:00
csoler
9d043c78eb
Merge pull request #3166 from jolavillette/FixDistantChatGreyLight
fix distant chat dialog showing grey status when tunnel is already established
2026-02-20 19:49:43 +01:00
jolavillette
406e538ff3 fix distant chat dialog showing grey status when tunnel is already established 2026-02-20 12:32:29 +01:00
thunder2
8e5629df9c Enabled compile of plugin VOIP for Qt 5 only 2026-02-17 18:56:41 +01:00
thunder2
c83b4f3950 Fixed compile of VOIP for older compilers 2026-02-17 18:56:41 +01:00
thunder2
f26845ad2b Fixed MSYS2 compile. Renamed qmake to qmake-qt5. 2026-02-17 18:56:40 +01:00
csoler
4545141dda updated libretroshare to latest master 2026-02-16 17:26:27 +01:00
csoler
b5f3603eb2
Merge pull request #3093 from jolavillette/ImproveUploadStatistics
[WIP] Improve upload statistics
2026-02-14 20:50:22 +01:00
jolavillette
6405061076 move UI signal blocker to utils and improve cache safety/consistency 2026-02-14 19:50:55 +01:00
jolavillette
801924cbb2 Shared Files refactor: consolidate stats maps, optimize FlatView caching, and fix search responsiveness 2026-02-14 16:02:48 +01:00
jolavillette
030f37f613 add UI for upload stats retention and move clear button to new Upload Statistics group 2026-02-13 21:42:49 +01:00
jolavillette
939f283a92 Optimize RemoteDirModel stats calculation to fix lag in SharedFilesDialog 2026-02-13 21:42:49 +01:00
jolavillette
37f4ddc3d0 Optimized Shared Files view performance by caching file details to eliminate UI freezes and increasing the update frequency for faster list population 2026-02-13 21:42:49 +01:00
jolavillette
ba1d213d5c GUI: Fix "Popular Files" filter persistence and tree expansion when switching views 2026-02-13 21:42:49 +01:00
jolavillette
df44f8b626 GUI: Ensure search filter persists and applies correctly when switching between Tree and Flat views 2026-02-13 21:42:49 +01:00
jolavillette
4103783114 Fix SIGSEGV in SharedFilesDialog by adding defensive null checks and forcing safe model resets 2026-02-13 21:42:49 +01:00
jolavillette
af87346763 fix SIGSEGV in SharedFilesDialog by adding defensive null checks and forcing model reset 2026-02-13 21:42:49 +01:00
jolavillette
352c743be6 display per directory the total number of files and the cumulated size 2026-02-13 21:42:48 +01:00
jolavillette
18afe3a182 fix searche among shared files randomly not working 2026-02-13 21:42:48 +01:00
jolavillette
23a1d0dd75 new attempt at fixing search in My files 2026-02-13 21:42:48 +01:00
jolavillette
abe98b4ec1 fix search not working in My files 2026-02-13 21:42:48 +01:00
jolavillette
4a8e164c7e more fix to correctly display relevant dirs and files when the box is checked 2026-02-13 21:42:48 +01:00
jolavillette
560184337f fix temporary shared files not being displayed in tree view when popular files box is checked 2026-02-13 21:42:48 +01:00
jolavillette
b5d113d7c3 Fix weird behaviour when unchecking "Popular file" box 2026-02-13 21:42:48 +01:00
jolavillette
a7e648851c Fix autocollapse in tree view 2026-02-13 21:42:48 +01:00
jolavillette
1ba88f0293 Fix crash in QItemSelectionRange destructor 2026-02-13 21:42:48 +01:00
jolavillette
9f519b337c Various UI improvements 2026-02-13 21:42:48 +01:00
jolavillette
27b71097d3 Fix SIGSEV in QSortFilterProxyModel::parent 2026-02-13 21:42:47 +01:00
jolavillette
2d13a729ec Improve upload statistics 2026-02-13 21:42:47 +01:00
csoler
da0a9eab8d
Merge pull request #3142 from jolavillette/GxsIdDisplayAndPropagation
Fix Identity/Chat refresh logic to handle instant avatar updates
2026-02-13 18:05:10 +01:00
jolavillette
385ee5ad14 remove dead fallthrough, increase event throttle to 1s, add refreshIdentityDetails() 2026-02-13 11:40:12 +01:00
jolavillette
461d21d6c4 extended event throttling to Channels, Forums, Boards, and Circles to prevent UI freezes 2026-02-12 08:23:27 +01:00
jolavillette
216d25086b fixed UI freeze in People view by throttling IdentityListModel updates 2026-02-12 08:23:27 +01:00
jolavillette
d49a1fbc33 Fix IdentityListModel: Restore original setIdentities implementation to preserve view hierarchy and signals 2026-02-12 08:23:27 +01:00
jolavillette
a7c6c5cb11 Fix IdentityListModel refresh logic to handle avatar updates 2026-02-12 08:23:27 +01:00
csoler
369840993f
Merge pull request #3158 from csoler/v0.6-BugFixing_41
added missing initialization to rsevent handler
2026-02-11 23:33:06 +01:00
csoler
27fc56b8b7 added missing initialization to rsevent handler 2026-02-11 23:30:26 +01:00
defnax
816f377833 Fixed to show the status frame 2026-02-11 21:36:21 +01:00
csoler
b67b040122
Merge pull request #3150 from defnax/avatar-fix
Added square avatar for the own frame
2026-02-08 20:37:27 +01:00
saurabh
6cbc156c13 Merge upstream master
# Conflicts:
#	retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp
2026-02-09 00:03:55 +05:30
saurabh
167bcfefa7 Wire: Add account filter menu and update filter UI 2026-02-08 23:51:32 +05:30
csoler
e04d2c2fc3
Merge pull request #3151 from jolavillette/FixCrashInTurtleRouterDialog
fix dangling pointer crash in TurtleRouterDialog by nullifying top_level pointers in hideEvent
2026-02-07 17:41:52 +01:00
jolavillette
a49175996a fix dangling pointer crash in TurtleRouterDialog by nullifying top_level pointers in hideEvent 2026-02-06 22:00:59 +01:00
csoler
6212dae5a3
Merge pull request #3143 from jolavillette/FixZeroPostCountAtStartup
fix zero post counts in Channels/Forums/Boards on Startup
2026-02-06 21:26:44 +01:00
jolavillette
2c02a46d4a fix zero post counts in Channels/Forums/Boards on Startup 2026-02-06 07:25:52 +01:00
csoler
97e840e38c
Merge pull request #3149 from jolavillette/FixTurtleRouterDialog
Turtle Router Statistics: improve sorting, data formatting, and memory usage
2026-02-05 23:01:26 +01:00
jolavillette
1a6cc7204b simplify hideEvent by using clear() instead of manual child deletion 2026-02-05 22:55:08 +01:00
csoler
737b5a2626
Merge pull request #3140 from jolavillette/ImproveChannelsGUILoading
Optimize GxsChannelPosts rendering to eliminate UI freeze on large lists
2026-02-05 22:31:35 +01:00
jolavillette
86f807303b restore Channels UI aesthetics 2026-02-05 16:40:08 +01:00
jolavillette
e09423bf10 Turtle Router Dialog: fix UI performance bottlenecks in item sorting and hash management 2026-02-05 11:43:41 +01:00
saurabh
7acaccb581 Wire: Remove commented hide line for groupSet comboBox 2026-02-04 15:17:58 +05:30
defnax
0877e542a2 Added square avatar for the own frame 2026-02-03 21:34:11 +01:00
saurabh
e65ae170f5 Wire: Add filter menu, event labels, and UI improvements
- Add filter menu button with Sort by Ascending toggle and time filters
- Show COPY LINK button for own profile (ADMIN) and reposition to header
- Add event-based labels: "Now Following", "Wire Updated", "New Wire"
- Add pulse type labels: "New Like", "New Republish", "New Reply"
2026-02-04 00:15:46 +05:30
jolavillette
de1bb49f9b cosmetic change in Tunnel Requests display 2026-02-03 17:29:45 +01:00
saurabh
76845e50a7 Fix Wire notification tray click not opening Wire page
- Remove shadowed local variable in MainWindow.cpp that prevented wireDialog member from being set

- Add pending navigation pattern in WireDialog for deferred navigation

- Restore openWireGroup() in WireNotifyGroupItem
2026-02-03 14:03:32 +05:30
jolavillette
04e3fce37f Turtle Router Statistics: improve sorting, data formatting, and memory usage 2026-02-02 23:50:35 +01:00
jolavillette
ff01cbc0dc Fix: Adjust scaling and margins in GxsChannelPosts delegate to match original widget appearance 2026-02-02 22:31:29 +01:00
jolavillette
303729f962 Perf: Optimize GxsChannelPosts rendering by replacing QWidget instantiation with direct QPainter drawing 2026-02-02 22:31:29 +01:00
csoler
16a4063a5c
Merge pull request #3117 from dbear496/fix-mod-select-circle
fix moderator list dropdown when editing post in circle-restricted forum
2026-02-02 21:47:33 +01:00
csoler
356e1bab69
Merge pull request #3148 from defnax/update-no-avatar
update no avatar to match with the new avatar system
2026-02-02 21:43:24 +01:00
csoler
1a93047c8f
Merge pull request #3097 from defnax/improve-filetransfertunnels
Improved File transfer Tunnels display
2026-02-02 21:42:48 +01:00
defnax
11f3e466eb added hidevents 2026-02-02 20:57:46 +01:00
defnax
3a81cdf411 moved the defines to cpp file 2026-02-01 22:34:43 +01:00
defnax
bd283e53e8 reorder columns 2026-02-01 21:32:57 +01:00
defnax
1bb55f4144 Fix alignment & calculate the size with friendlyUnit 2026-02-01 18:49:41 +01:00
defnax
7934e8bb71 Improve display 2026-02-01 18:49:41 +01:00
defnax
b2f5153d22 Added separate class for TunnelStatisticsDialog 2026-02-01 18:49:41 +01:00
defnax
2fae419c18 Added own class for GxsNetTunnelsDialog
* Improved GXS Sync Tunnels display
* cleanup code
2026-02-01 18:49:40 +01:00
defnax
3834d495be Improved File transfer Tunnels display 2026-02-01 18:49:39 +01:00
csoler
f6181a0ff6
Merge pull request #3145 from defnax/restorechanges
fix boards gif/webp for #3104
2026-02-01 17:56:23 +01:00
defnax
82b62742ae restore PostedItem class 2026-02-01 17:41:21 +01:00
natinew77-creator
2a4ac83406 Fix missing include for BoardPostImageHelper.h
PostedCreatePostDialog.cpp uses BoardPostImageHelper::MAX_ANIMATED_SIZE
but was missing the include - would cause compilation error
2026-02-01 17:41:21 +01:00
natinew77-creator
99756456b6 Add animation support to BoardsPostItem::viewPicture()
defnax noted that BoardsPostItem is the primary feed view used (not PostedItem).
Added QMovie animation support to viewPicture() popup for animated GIF/WEBP.

- Added QMovie and BoardPostImageHelper includes
- Animation detection and QMovie playback in photo popup
- Static image fallback for non-animated images
- Proper parent-child cleanup (movie->setParent(PView))
2026-02-01 17:41:20 +01:00
natinew77-creator
1de556a35e CRITICAL FIX: Double-delete crash in PhotoView
- Removed manual delete from PhotoView destructor and setMovie()
- Qt parent-child mechanism handles QMovie cleanup automatically
  (caller sets movie->setParent(PView) before calling setMovie)
- Added null check for thumbnail pixmap in PostedItem

This prevents crash when closing PhotoView with animated image
2026-02-01 17:41:20 +01:00
natinew77-creator
60ed88691d Fix code review issues: duplicate include and thumbnail loading
- Removed duplicate #include BoardPostImageHelper.h
- Added movie->jumpToFrame(0) before currentPixmap() to ensure first frame is loaded
2026-02-01 17:41:20 +01:00
natinew77-creator
09ba942d96 CRITICAL FIXES: Memory leaks and code review issues
Fixed all critical issues from code review:
1. Memory leak in createMovieFromData() - QByteArray now properly deleted via lambda
2. Added setParent() to ALL QMovie instances for proper cleanup
3. Fixed double pixmap load in PostedItem - use movie->currentPixmap()
4. Used MAX_ANIMATED_SIZE constant instead of magic number
5. Added validation for corrupted animated images
6. Clarified compact view comment (design choice, not limitation)

Addresses all MUST-FIX items from review
2026-02-01 17:41:19 +01:00
natinew77-creator
5b0053850b Add animation support to PostedItem (feeds/activity view)
- PostedItem now displays animated GIFs/WEBPs in feed
- Completes animation coverage across all Board post views

All views now support animation:
- Card view ✓
- Photo popup ✓
- Compact view (static) ✓
- Feed/Activity view ✓
2026-02-01 17:41:19 +01:00
natinew77-creator
18ac758824 Fix compact view and improve WEBP support
- Compact view now shows static first frame for animated images
  (setPicture() doesn't support QMovie animations)
- Improved WEBP detection with better frameCount handling
- Animation works in: Card view, Photo popup, and static preview in Compact

Addresses defnax feedback about missing compact view images and WEBP support
2026-02-01 17:41:18 +01:00
natinew77-creator
1657971444 Fix maintainer feedback: includes, header optimization, preserve animation
- Added missing QMovie include in PhotoView.cpp
- Optimized BoardPostImageHelper.h with forward declarations
- Added QMovie includes to .cpp files (thunder2's suggestion)
- CRITICAL FIX: Animated GIFs now bypass JPG optimization
  - Load raw GIF/WEBP data to preserve animation
  - Preview first frame in dialog
  - Static images still use optimization

Fixes: Animation now works when posting GIFs
2026-02-01 17:41:18 +01:00
natinew77-creator
b4f56cf4d8 Implement animated GIF/WEBP support for Board posts (#3095)
Features:
- Detect and animate GIF/WEBP images with multiple frames using QMovie
- Automatic looping for smooth playback
- 194KB size limit enforced at upload time
- User-friendly error message for oversized animated images
- Preserve static image display for non-animated content

Implementation:
- Created BoardPostImageHelper utility class for format detection
- Updated BoardPostDisplayWidget (compact and card variants)
- Updated PostedCardView for feed display
- Updated PhotoView for popup animation
- Added upload validation in PostedCreatePostDialog
- Proper memory management to prevent leaks

Technical details:
- Uses QImageReader for frame counting and format detection
- QMovie with QBuffer for animation playback
- Parent-child cleanup for automatic memory management
- Tested on macOS with successful build

Files modified:
- gui/Posted/BoardPostImageHelper.{h,cpp} (NEW)
- gui/Posted/BoardPostDisplayWidget.cpp
- gui/Posted/PostedCardView.cpp
- gui/Posted/PhotoView.{h,cpp}
- gui/Posted/PostedCreatePostDialog.cpp
- retroshare-gui.pro
2026-02-01 17:41:17 +01:00
defnax
35a1e53dd4 update no avatar to match with the new avatar system 2026-01-31 16:45:55 +01:00
saurabh
e5e35da0bb Wire: Enable link clicks in notification items 2026-01-27 17:35:21 +05:30
saurabh
7f19f201c6 Wire: Fix reply/like/republish bugs, read/unread marking, navigate links 2026-01-27 04:08:09 +05:30
saurabh
29d5ce631b Wire notify improvements and bug fixes
- Enable wire events for replies, republishes and likes
- Fix pulse notifications to load data correctly
- Add home button and search filter
- Add copy link for pulses and profiles
- Fix identity selector in account creation
2026-01-26 12:45:21 +05:30
defnax
384e00868e Added missed wire flag 2026-01-24 12:38:46 +01:00
defnax
bcaca4ca2d Fixed Wire counts to use own Wire Page
* Disabled unfinished feeds
2026-01-24 12:38:46 +01:00
defnax
4d1de11905 Disabled hide function 2026-01-24 12:38:46 +01:00
defnax
b4fbdca4e8 update project file 2026-01-24 12:38:46 +01:00
defnax
e129a2504b Rework on wire notify and clean up code 2026-01-24 12:38:46 +01:00
csoler
a26b5a4be5
Merge pull request #3129 from jolavillette/ImproveBWStatistics
BW statistics: remove useless values, display outqueue size in bytes, drain, total in, total out, save config
2026-01-23 23:02:07 +01:00
jolavillette
227f0039f2 add tooltips 2026-01-23 07:34:45 +01:00
jolavillette
9f6d9ffe40 remove InAllowed column as our peers dont provide this information 2026-01-23 06:58:30 +01:00
jolavillette
cac8af8b36 Fix fugitive peer selection and add units to Drain column in Bandwidth Stats 2026-01-20 06:54:41 +01:00
jolavillette
2c54d47ba4 add total in and total since peer connected 2026-01-20 06:54:41 +01:00
jolavillette
492cac2ee2 BW statistics: polish, remove useless values, display outqueue size in bytes, display drain = outqueue / outspeed 2026-01-20 06:54:41 +01:00
csoler
4e6b941ac5
Merge pull request #2969 from defnax/login-dialog
Added for login dialog switch background image
2026-01-19 20:35:13 +01:00
csoler
efd927dc8b
Merge pull request #3134 from dbear496/plugins-rapidjson-include
fix rapidjson include directory for plugins
2026-01-19 20:00:28 +01:00
csoler
478cdc4390
Merge pull request #3135 from defnax/fix-tree-icon
Fixed to show the avatar with right dimensions
2026-01-19 19:58:48 +01:00
defnax
42e062db96 Fixed the default width 2026-01-19 18:08:48 +01:00
defnax
e43295c784 added separate fontmetrics for each tree 2026-01-19 17:43:20 +01:00
defnax
dea890b2f1 Fixed to show the avatar with right dimensions 2026-01-18 22:26:38 +01:00
David Bears
5997bf100c
fix rapidjson include directory 2026-01-18 14:21:54 -05:00
csoler
5ac0a4ac7e
Merge pull request #3127 from dbear496/submodules
update submodules
2026-01-18 18:27:13 +01:00
csoler
7e4da6b178
Merge pull request #3132 from samuel-asleep/master
Fix and Correct compliation error introduced in pr #3122
2026-01-18 18:24:58 +01:00
csoler
8da240d839
Merge pull request #3125 from dbear496/fix-voip
update VOIP for current libavcodec
2026-01-18 17:46:27 +01:00
David Bears
685b63cc27
fix libretroshare submodule commit 2026-01-18 10:09:17 -05:00
David Bears
baf6c9b553
update openpgpsdk 2026-01-18 10:05:40 -05:00
David Bears
f6429e60d4
use absolute URLs for submodules 2026-01-18 10:05:39 -05:00
David Bears
7e25bf6649
checkout fix for Tencent/rapidjson#718 2026-01-18 10:05:36 -05:00
Akinniranye Samuel Tomiwa
42230a4b36
Fix Qt6 QDateTime usage and clarify/refactor group icon cache keys (#2)
* Fix QDateTime epoch conversion for Qt 6/Qt 5

* Update retroshare-gui/src/gui/common/FriendListModel.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-18 03:09:03 +01:00
Akinniranye Samuel Tomiwa
11cc61c6c4
Fix default group icon overloads and string handling
* Fix default group icon string handling

* Add cache key prefixes for group icons
2026-01-18 02:10:57 +01:00
csoler
b681603cb0
Merge pull request #3122 from samuel-asleep/master-clean
Implement deterministic colored default logos for Friend Nodes, Chann…
2026-01-17 22:13:27 +01:00
Akinniranye Samuel Tomiwa
d8fb54b60c
Delete _codeql_detected_source_root 2026-01-17 21:32:10 +01:00
Akinniranye Samuel Tomiwa
e2633dd7de
Fix icon cache macro order, use NUM_AVATAR_SIZES and add string-based group icon generator
* Fix NUM_AVATAR_SIZES define order

* Update retroshare-gui/src/gui/gxs/GxsIdDetails.h

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update retroshare-gui/src/gui/gxs/GxsIdDetails.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update retroshare-gui/src/gui/gxs/GxsIdDetails.h

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-17 21:09:06 +01:00
Akinniranye Samuel Tomiwa
722f2e5420
Add new board icon 2026-01-17 07:39:38 +01:00
Copilot
a55fe09455
Fix type correctness and add safety checks for group icon generation
* Initial plan

* Fix type correctness and add safety checks for avatar icon generation

- Change parameter type from RsGxsId to RsGxsGroupId in makeDefaultGroupIcon methods
- Add NUM_AVATAR_SIZES constant to clarify array size meaning
- Add bounds checking for array access to prevent crashes
- Remove unnecessary RsGxsId casts in dialog classes

Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: samuel-asleep <210051637+samuel-asleep@users.noreply.github.com>
2026-01-17 07:35:05 +01:00
Akinniranye Samuel Tomiwa
a259b1c110
Fix group icon cache keys and add separate cache for generated group avatars
* Fix group icon cache keys

* Update retroshare-gui/src/gui/gxs/GxsIdDetails.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-16 18:07:50 +01:00
David Bears
fabd25be22
remove size from NetQueue template arguments 2026-01-16 12:05:35 -05:00
David Bears
7542ee4f8c
some minor touchup 2026-01-16 11:10:18 -05:00
David Bears
921f8eb690
implement proper avcodec encode/decode loops 2026-01-16 02:30:14 -05:00
Akinniranye Samuel Tomiwa
32cad564fe
Improve friend avatar fallbacks 2026-01-16 00:46:54 +01:00
csoler
cef76825ee
Merge pull request #3123 from defnax/fixiconsize
fixed ID Dialog & Circles icon size issues
2026-01-15 19:43:03 +01:00
csoler
49a4af55fe
Merge pull request #3111 from jolavillette/ImproveDateFormat
add date format selection (System, ISO 8601, Text) in user settings, and standardize date and time formatting across the UI
2026-01-15 19:40:53 +01:00
csoler
830c0c3a76
Merge pull request #3124 from dbear496/open-rscollection-links
internally handle rscollection links
2026-01-15 19:26:54 +01:00
David Bears
e01e1a490d
update VOIP for current libavcodec 2026-01-15 08:58:25 -05:00
jolavillette
a6e2a122ce use raw time_t in FriendListModel to ensure proper Model-UI separation 2026-01-15 09:05:56 +01:00
David Bears
edff72fabc
internally handle rscollection links 2026-01-14 14:01:04 -05:00
defnax
aa4463d27e fixed ID Dialog & Circles icon size issues 2026-01-14 18:27:21 +01:00
Copilot
24911bf6ba
Fix icon paths for new colored default avatars 2026-01-14 18:11:40 +01:00
Akinniranye Samuel Tomiwa
477a699dc9
Update retroshare-gui/src/gui/gxs/GxsIdDetails.cpp
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-14 15:59:54 +01:00
David Bears
47b4c091d0
fix asynchronous fetching of circle details 2026-01-14 08:39:23 -05:00
Copilot
db47c62c2b
Implement deterministic colored default logos for Friend Nodes, Channels, Boards, and Wikis 2026-01-14 13:47:53 +01:00
jolavillette
622a0063ca add onfigurable date formats with live previews, fix sorting via delegates, and implement instant refresh cache 2026-01-14 10:47:25 +01:00
csoler
52c1350dbd
Merge pull request #3106 from defnax/wiki-icons
[RsWIKI] update wiki icons
2026-01-13 23:20:01 +01:00
David Bears
7aca9fa527
removes non-members from ID dropdown in forum message creator 2026-01-13 15:11:49 -05:00
jolavillette
9730b2df56 Standardize date and time formatting across the UI 2026-01-13 18:41:38 +01:00
David Bears
bbca5af542
fix "no identities are allowed to post" 2026-01-12 17:31:54 -05:00
David Bears
d3dd908916
fix moderator list dropdown when editing post in circle-restricted forum 2026-01-12 12:08:13 -05:00
csoler
40036d7b52
Merge pull request #3116 from defnax/wiki-fix-v2
[RsWiki] Removed forgetten buttons
2026-01-12 13:20:15 +01:00
csoler
3248176dfa
Merge pull request #2961 from defnax/w10darkmode
Added system dark mode for Windows 10
2026-01-11 16:40:22 +01:00
csoler
77c3ece753
Merge pull request #2922 from dbear496/moderator-select
Make forum moderator selectable by the user
2026-01-11 16:38:58 +01:00
csoler
7beaa8bb6f
Merge pull request #3108 from jolavillette/DisplayEngineVersion
display libretroshare version in About dialogs and enable dirty flag support
2026-01-11 16:29:32 +01:00
defnax
b9a9ed94bc Removed forgetten buttons 2026-01-10 23:26:15 +01:00
jolavillette
28c28afdca Merge branch 'master' into DisplayEngineVersion 2026-01-09 17:30:07 +01:00
csoler
b5bb1c4a24
Merge pull request #3110 from JohannesKleine/github-workflow-qt5
github workflow rename qmake to qmake-qt5.exe
2026-01-09 08:59:35 +01:00
csoler
8272f36449
Merge pull request #3090 from csoler/v0.6-MailChat
Splitting rsMsgs into rsMail and rsChats
2026-01-08 22:29:48 +01:00
csoler
c49eb9c2a4
Merge pull request #3102 from alvaro-salort/fix/wiki-plugin-modernization
Wiki Plugin: Re-enable and modernize with rsEvents
2026-01-08 22:18:22 +01:00
csoler
11f18f9b18
Merge pull request #3109 from JohannesKleine/aboutWidget
remove downcast error
2026-01-08 22:15:14 +01:00
jolavillette
35f7aff599 more cosmetics 2026-01-08 13:13:40 +01:00
jolavillette
bf9da4f980 consistency and cosmetic changes 2026-01-08 00:05:43 +01:00
jolavillette
c631972ee5 Merge branch 'master' into DisplayEngineVersion 2026-01-07 23:37:21 +01:00
csoler
95df7f0c25
Merge pull request #3105 from jolavillette/FixUnstableFriendsList
Fix unstable friends list
2026-01-07 23:27:52 +01:00
csoler
b65b45aa9d
Merge pull request #3100 from jolavillette/CloseStatisticsWithEscape
Close statistics window with Escape key
2026-01-07 23:17:45 +01:00
csoler
cd6820b753
Merge pull request #3098 from jolavillette/FixWindowsCollectionFreeze
Fix Windows freeze in RsCollectionDialog Download mode
2026-01-07 23:16:34 +01:00
Christoph Johannes Kleine
8ef3f2bb54
github workflow rename qmake to qmake-qt5.exe 2026-01-07 20:07:57 +01:00
jolavillette
e3c7f0e11b use libretroshare not engine as per cjk request 2026-01-06 23:05:08 +01:00
Christoph Johannes Kleine
3ab4c2a76a
remove downcast error
../../../retroshare-gui/src/gui/AboutWidget.cpp:74:22: runtime error: downcast of address 0x503001940ad0 which does not point to an object of type 'QVBoxLayout'
0x503001940ad0: note: object is of type 'QHBoxLayout'
 00 00 00 00 38 52 09 41 94 7f 00 00 00 59 40 01 10 51 00 00 38 53 09 41 94 7f 00 00 00 00 00 00
              ^~~~~~~~~~~~~~~~~~~~~~~
              vptr for 'QHBoxLayout'
2026-01-06 22:45:43 +01:00
jolavillette
df8d7b0f9b display libretroshare version in About dialogs and enable dirty flag support 2026-01-06 19:41:49 +01:00
defnax
192c74f73b update wiki icons 2026-01-06 14:29:28 +01:00
jolavillette
00f5f60e45 Merge branch 'master' into FixWindowsCollectionFreeze 2026-01-06 08:12:29 +01:00
jolavillette
b184e7b4ca Merge branch 'master' into CloseStatisticsWithEscape 2026-01-06 08:11:55 +01:00
jolavillette
303ac670a4 fix avatar randomly disappearing when filtering the friends list 2026-01-06 08:07:52 +01:00
jolavillette
8e3f8f1bb0 Attenpt to fix dangling friends list in network view 2026-01-06 08:07:52 +01:00
Salort Alvaro
bedfc39d61 Wiki: Core event logic and cleanup 2026-01-05 23:16:00 +00:00
jolavillette
3f107957d4 simplify GXS transport statistics async logic by removing redundant QPointer checks 2026-01-05 22:13:50 +01:00
jolavillette
c435d2295f Fix StatisticsWindow crash by preserving static instance per Cyril s feedback 2026-01-04 18:27:42 +01:00
jolavillette
4ba66b8f33 various fixes according to cyril s comments 2026-01-04 18:07:08 +01:00
jolavillette
13afc743c0 use QPointer to fix crash when closing StatisticsWindow during async loading 2026-01-03 19:17:29 +01:00
csoler
32a3c860ae updated retroshare-gui to lbretrohare last commit 2026-01-03 15:39:10 +01:00
jolavillette
70bf22d6ca possibly fix window reopening issues 2026-01-02 23:39:12 +01:00
jolavillette
0bca0d3b27 override the keyPressEvent function, enabling the statistics window to close when the Escape key is pressed 2025-12-31 07:23:22 +01:00
jolavillette
c3a3a25fb9 Fix Windows freeze in Download mode by making the local file system model initialization conditional 2025-12-30 20:01:18 +01:00
csoler
a17699e166
Merge pull request #3096 from defnax/clearupload-stats
Added clear upload stats Button
2025-12-29 16:37:44 +01:00
csoler
8cf9610a21 removed calls to rsmsgs.h 2025-12-28 18:59:09 +01:00
defnax
4c11ae2967 Added clear upload stats Button 2025-12-27 23:44:02 +01:00
csoler
92ae196d73
Merge pull request #3092 from jolavillette/CollapseUnsubcribedChatroomsAtStartup
Collapse all unsubscribed lobbies when RS starts
2025-12-26 11:09:01 +01:00
csoler
460bed388e fixed compilation 2025-12-24 15:48:58 +01:00
csoler
9f99430254 renamed Msgs into Mail 2025-12-24 14:09:13 +01:00
csoler
f0c844d8ea finished splitting 2025-12-23 15:52:41 +01:00
jolavillette
7c68b2bcc2 Collapse all unsubscribed lobbies when RS starts 2025-12-23 15:03:54 +01:00
thunder2
3e057bf5b5 FeedReader: Fixed using first image for posted without need to embed images 2025-12-23 12:19:12 +01:00
csoler
0ba2c046a8 continue Mail/Chat splitting 2025-12-23 11:13:53 +01:00
csoler
def7f5f611
Merge pull request #3089 from defnax/filestatsguiv3
File Upload Stats GUI
2025-12-22 22:01:52 +01:00
csoler
f21d1121ce started separating rsMsgs into rsMail and rsChats 2025-12-22 21:58:38 +01:00
csoler
aa99fa9441
Merge pull request #3072 from jolavillette/RemoveRecursiveSingleShotCalls
Remove recursive singleShot calls on feed items
2025-12-22 13:12:18 +01:00
jolavillette
6d3f44dfb2 Fix wrong filtering condition 2025-12-22 11:32:31 +01:00
csoler
73db13b488
Merge pull request #3083 from defnax/feeds-layout-fix
Fix new feed icons
2025-12-22 11:24:13 +01:00
csoler
8530bd486a
Merge pull request #3085 from csoler/v0.6-Notify3
V0.6 notify3
2025-12-21 22:15:15 +01:00
defnax
51f84df470 Added file upload stats (gui) 2025-12-21 16:21:31 +01:00
csoler
8d10d45199 added missing initialization of event handler id in NetworkView.cpp 2025-12-20 22:47:16 +01:00
csoler
f9d71e9792 commented out beginInsertRows()/endInsertRows() which may use the wrong number of rows and is not needed because of the beginResetModel()/endResetModel() around 2025-12-20 22:44:56 +01:00
defnax
aa6ea508c9 Fix new feed icons 2025-12-20 17:01:53 +01:00
jolavillette
ed64bfe974 only update relevant items in SecurityIpItem + cosmetic fixes 2025-12-19 12:56:52 +01:00
jolavillette
692ee3face remove singleShot calls and use events handlers instead 2025-12-19 12:56:52 +01:00
jolavillette
dfa9e39612 Remove recursive singleShot calls on feed items, that were creating thousands of timers and causing massive cpu overhead 2025-12-19 12:56:52 +01:00
csoler
ed449abb5e
Merge pull request #3074 from Passw/patch-2
fix comments retroshare-gui/src/
2025-12-19 09:26:04 +01:00
csoler
d3b7ab1907
Merge pull request #3073 from Passw/patch-1
remove useless close_button
2025-12-19 09:23:11 +01:00
csoler
82f6eafa1d
Merge pull request #3071 from defnax/feeds-layout-fix
Fixed Layout issue
2025-12-19 09:13:54 +01:00
csoler
fb56978989
Merge pull request #3077 from jolavillette/FixForumsListAndCounters
Fix forums list and counters not displayed when the forum tab is selected for the first time
2025-12-18 23:15:39 +01:00
jolavillette
c8fa6c1908 Fix forums list and counter not displayed when the forum tab is selected for the first time 2025-12-18 20:02:36 +01:00
defnax
d78476ae73 Added 16:9 default icons when there is no pixmap data 2025-12-17 20:01:18 +01:00
Passw
f44f72e3a5 fix comments retroshare-gui/src/
retroshare-gui/src/control/
retroshare-gui/src/gui/Circles/
retroshare-gui/src/gui/advsearch/
retroshare-gui/src/gui/chat/
retroshare-gui/src/gui/common/
2025-12-16 19:32:17 +08:00
Passw
c716f0d79a remove useless close_button 2025-12-16 13:08:05 +08:00
defnax
b7d9d40743 Fixed Layout issue
* Fixed to have same Thumbnail dimensions
2025-12-14 21:39:47 +01:00
csoler
e85e0ad782
Merge pull request #3070 from csoler/v0.6-Notify3
Removed problematic (and irrelevant) timer in PeerItem
2025-12-14 17:17:08 +01:00
csoler
2487d79920 removed instance in FriendsDialog since it is not used 2025-12-13 22:19:20 +01:00
csoler
d6860b2313 moved initialization of event handler id before calling registerEventHandler 2025-12-13 21:57:58 +01:00
csoler
4c5db53fe6 moved unregister friends dialog event handlers before setting instance to null 2025-12-13 21:55:21 +01:00
csoler
befa1e1f7e removed problematic (and irrelevant) timer in PeerItem 2025-12-13 21:01:40 +01:00
csoler
f9cda759ec
Merge pull request #3069 from jolavillette/FixUnregisterEventHandlerInChatUserNotifyDestructor
Fix unregister event handler in ChatUserNotify destructor
2025-12-11 15:27:55 +01:00
jolavillette
ee50e0951b Fix unregister event handler in ChatUserNotify destructor 2025-12-11 15:16:21 +01:00
csoler
6a5e116725
Merge pull request #3066 from csoler/v0.6-Notify3
V0.6 notify3
2025-12-07 20:34:38 +01:00
csoler
7fff0c1894
Merge pull request #41 from defnax/chatstatus
Added to show refused in distant chat
2025-12-07 18:38:17 +01:00
defnax
5c3efdc866 Added to show refused in distant chat 2025-12-07 11:57:05 +01:00
csoler
a6faeb4ec7
Merge pull request #40 from defnax/chatstatus
Fixed Avatar update
2025-12-07 10:40:32 +01:00
defnax
ea1d13c1d9 Fixed Avatar update 2025-12-07 10:02:17 +01:00
csoler
a6ac1ded7a
Merge pull request #39 from defnax/chatstatus
Added Chatstatus
2025-12-06 23:19:04 +01:00
defnax
1ab5ad0a8e Added chat status display 2025-12-06 22:13:09 +01:00
csoler
7873082d28 switched PopupDistantChatDialog to rsEvents 2025-12-06 17:48:41 +01:00
defnax
453173294b
Merge branch 'RetroShare:master' into login-dialog 2025-12-06 13:42:51 +01:00
csoler
6f33dcc8e7
Merge pull request #3055 from thunder2/fix-notify
Fixed crash (NULL pointer access) in RsGUIEventManager::async_handleI…
2025-12-06 10:09:28 +01:00
csoler
e80ad9577d
Merge pull request #3056 from thunder2/fix-status
Added changes of RsChatFlags and RsStatusValue to VOIP plugin
2025-12-06 10:08:46 +01:00
csoler
9eb3d1b442
Merge pull request #3060 from Passw/patch-3
Fix comments GxsChannelPostsWidgetWithModel.cpp
2025-12-06 10:07:56 +01:00
csoler
a0934e2990
Merge pull request #3061 from Passw/patch-4
Fix comments and header guard macro  GxsChannelPostsWidgetWithModel.h
2025-12-06 10:00:09 +01:00
csoler
d92f5408a7
Merge pull request #3062 from Passw/patch-5
Fix comments and header guard macro PostedListWidgetWithModel.h
2025-12-06 09:59:36 +01:00
csoler
a4d14005aa
Merge pull request #3063 from Passw/patch-6
Fix comments PostedListWidgetWithModel.cpp
2025-12-06 09:58:54 +01:00
thunder2
573b46b19d Fixed crash (NULL pointer access) in RsGUIEventManager::async_handleIncomingEvent with activated plugins 2025-12-06 00:50:25 +01:00
thunder2
721cfb9e18 Added changes of RsChatFlags and RsStatusValue to VOIP plugin 2025-12-06 00:48:26 +01:00
csoler
296b612965 fixed merge 2025-12-05 17:09:39 +01:00
csoler
01cdbe68d9
Merge pull request #3065 from JohannesKleine/fix-merge-error
remove duplicate code introduced by merging
2025-12-05 17:08:27 +01:00
csoler
1e3be2b159 fixed duplicate code (posibly due to problem while merging) 2025-12-05 17:03:29 +01:00
Christoph Johannes Kleine
499860ee09
remove duplicate code introduced by merging 2025-12-05 15:43:41 +01:00
csoler
e029ff89f9
Merge pull request #3064 from defnax/fix-board-noty
Fix Boards update notify
2025-12-04 19:01:07 +01:00
defnax
64efeae56a Fix Boards update notify 2025-12-04 18:39:59 +01:00
Passw
13c4699236
Fix comments PostedListWidgetWithModel.cpp 2025-12-04 11:22:36 +08:00
Passw
85527be02e
Fix comment and macro PostedListWidgetWithModel.h
_GXS_CHANNELPOSTSWIDGET_H

https://github.com/RetroShare/RetroShare/blob/master/retroshare-gui/src/gui/gxschannels/GxsChannelPostsWidgetWithModel.h

_POSTED_LISTWIDGETWITHMODEL_H
2025-12-04 11:17:16 +08:00
Passw
ac79ede45b
Fix comments and header macro GxsChannelPostsWidgetWithModel.h 2025-12-04 11:09:49 +08:00
Passw
dc0b0cd4af
Fix comments GxsChannelPostsWidgetWithModel.cpp 2025-12-04 10:59:20 +08:00
csoler
735a1b50c9
Merge pull request #3059 from Passw/patch-2
Fix missing space in SecurityIpItem.cpp
2025-12-03 17:14:24 +01:00
Passw
4cddaf78cb
Fix missing space in SecurityIpItem.cpp 2025-12-03 17:44:08 +08:00
csoler
786b90de5e
Merge pull request #3058 from csoler/v0.6-Notify3
fixed plugin loading
2025-12-02 18:18:38 +01:00
csoler
350a3da359 added comment about plugin confirmation GUI code 2025-12-01 22:33:19 +01:00
csoler
943e597291 fixed plugin loading 2025-12-01 22:24:06 +01:00
csoler
3baf444452
Merge pull request #3054 from csoler/v0.6-Feeds
fixed compilation bug
2025-11-30 19:07:45 +01:00
csoler
3842427fb6 fixed compilation bug 2025-11-30 19:04:33 +01:00
csoler
943c22412f
Merge pull request #3047 from csoler/v0.6-Feeds
Bug fixing in feeds new system.
2025-11-30 18:13:49 +01:00
csoler
553d2e8f50
Merge pull request #2951 from csoler/v0.6-Notify2
Getting rid of old notify system
2025-11-30 18:13:32 +01:00
csoler
e3d05d5474 moved GxsFeedItem and GxsGroupFeedItem to feeds/ as a more appropriate place 2025-11-30 17:07:04 +01:00
csoler
96c150caf2 fixd drand48() call 2025-11-25 21:38:50 +01:00
csoler
28a5db7204 fixed compilation for feed reader plugin 2025-11-24 21:09:45 +01:00
csoler
2eb48e0305 added deferred update to feed items 2025-11-22 17:51:42 +01:00
defnax
7c9684e331
Merge branch 'RetroShare:master' into w10darkmode 2025-11-19 19:35:20 +01:00
csoler
d86c5dabd3 added picture size variables in feed items 2025-11-19 18:22:45 +01:00
csoler
a94c85751e improved layout of board post item 2025-11-18 22:01:12 +01:00
csoler
68ee14e8c0 added expand button for board post items 2025-11-18 21:52:20 +01:00
csoler
c9c4b4c9d8 added PhotoView to BoardsPostItem 2025-11-17 22:51:46 +01:00
csoler
67e07b14fd merged with upstream/master 2025-11-17 21:52:47 +01:00
csoler
784933dbd4 added new boards post item in feeds 2025-11-17 21:23:42 +01:00
csoler
07f415b4c4 fixed calling virtual functions in constructor 2025-11-15 22:33:22 +01:00
csoler
fa91380765
Merge pull request #3044 from defnax/feeds-test
added more feed tests
2025-11-15 21:02:22 +01:00
csoler
567d350e76
Merge pull request #3049 from defnax/fix-people
Fix wording
2025-11-15 21:01:20 +01:00
defnax
0629113d16 Fix wording 2025-11-15 16:58:34 +01:00
defnax
3385abfdc6 Added comment for test feeds 2025-11-15 15:21:04 +01:00
csoler
05fe8adbd1 fixed bug in setting msg as read in forum msg item 2025-11-12 21:17:31 +01:00
csoler
ba4b8e7ff5
Merge pull request #3046 from Passw/patch-1
fix typo WindowsMSys2_InstallGuide.md
2025-11-12 09:37:06 +01:00
Passw
24540db6aa
fix typo WindowsMSys2_InstallGuide.md
complet
complete
2025-11-12 09:12:05 +08:00
csoler
d3069e9b44 fixed compilation 2025-11-11 20:12:53 +01:00
csoler
b8bb797171 fixed compilation 2025-11-11 19:01:04 +01:00
csoler
a91a0893cf renamed NotifyQt into RsGUIEventManager 2025-11-11 18:56:24 +01:00
defnax
72ae5b74ac added more feed tests 2025-11-10 18:43:22 +01:00
csoler
390084971a merged with upstream 2025-11-10 14:14:21 +01:00
csoler
383b1e7d2b
Merge pull request #3042 from csoler/v0.6-Feeds
improved code consistency in feed item loading/killing
2025-11-10 14:12:21 +01:00
csoler
20ff1380ae
Merge pull request #3040 from dbear496/fix-permmatrix-global
fix the permission matrix global switch
2025-11-09 19:16:23 +01:00
csoler
ae5f91700e updated libretroshare submodule to latest commit 2025-11-07 23:39:04 +01:00
csoler
7babc118ff
Merge pull request #3043 from csoler/v0.-ImprovedGUI3
fixed arrow problem in sync time menu
2025-11-07 15:16:32 +01:00
csoler
0502dba2e6 fixed missing link in ChannelsCommentsItem 2025-11-07 14:26:19 +01:00
csoler
82215711c2 fixed arrow problem in sync time menu 2025-11-07 10:15:10 +01:00
csoler
89cb02528c changed enum for data loading in feed items to some more specific name 2025-11-05 20:30:26 +01:00
csoler
c0c9684adf fixed forum msg item loading 2025-11-04 21:27:21 +01:00
csoler
6a0dda8cf7 left test code template in place 2025-11-03 16:38:57 +01:00
csoler
8a23d37870 removed some dead code 2025-11-03 16:32:49 +01:00
csoler
6b88c9a49e fixed PostedGroupItem 2025-11-02 18:36:23 +01:00
csoler
5e4249663e fixed GxsForumMsgItem 2025-11-02 18:25:01 +01:00
csoler
f8061d452c fixed GxsForumGroupItem 2025-11-01 18:05:26 +01:00
csoler
785a83f625 fixed GxsChannelGroupItem 2025-11-01 17:24:58 +01:00
csoler
c8dbf34a14 fixed ChannelsCommentsItem 2025-10-31 19:49:39 +01:00
csoler
c8a93d75f2 fixed deferred loading of GxsChannelPostItem 2025-10-30 19:55:44 +01:00
csoler
b9cd766707 removed unused code 2025-10-30 19:53:55 +01:00
csoler
c3fb087f92 improved code consistency in feed item loading/killing 2025-10-27 14:48:30 +01:00
csoler
ff04cd326a removed warning 2025-10-27 13:48:18 +01:00
csoler
a08d0a62df fixed missing initialization of Event handler ID in ChatLobbyDialog 2025-10-26 20:53:36 +01:00
csoler
516ccdf4bd
Merge pull request #3028 from JohannesKleine/fix-storage-sync-period-ui
[WIP] go back to old function setSyncPostsDelay
2025-10-23 15:50:27 +02:00
David Bears
f73b25c81a
fix the permission matrix global switch 2025-10-22 15:45:04 -04:00
csoler
59df95f162
Merge pull request #3038 from dbear496/fix-i2p-local-port
revert addition of `saveAddresses()` call from #841
2025-10-21 11:31:57 +02:00
csoler
6097ca8b9b
Merge pull request #3039 from dbear496/fix-permmatrix-freeze
fix permissions matrix GUI freeze
2025-10-21 11:30:26 +02:00
csoler
d14f2c9bbe
Merge pull request #3026 from defnax/macos-14-workflow-v2
Added macos workflow
2025-10-21 10:55:49 +02:00
csoler
03dc606ca3
Merge pull request #3037 from dbear496/fix-custom-font-size-button
fix "enable custom font size" checkbox
2025-10-21 10:54:45 +02:00
David Bears
e1906a9819
fix permissions matrix GUI freeze 2025-10-18 15:03:52 -04:00
David Bears
2eed660327
revert addition of saveAddresses() call from #841
fixes a bug where the i2p local port is occasionally reset to 10
2025-10-17 15:50:26 -04:00
David Bears
0103acb807
fix "enable custom font size" checkbox 2025-10-17 10:38:46 -04:00
csoler
0dd1d1562a
Merge pull request #3036 from dbear496/fix-forum-highlighting
fix regular expression syntax for forum quote highlighting
2025-10-17 09:28:57 +02:00
David Bears
9dd24a6bb1
fix regular expression syntax for forum quote highlighting
fixes #3033
2025-10-16 14:48:52 -04:00
csoler
d7ff04c552 removed old calls to NotifyQt, and fixed missing initialization causing crash 2025-10-15 18:49:50 +02:00
csoler
daaa7985a3 fixed problematic re-numbering of status flags (non-backward compatible) 2025-10-13 22:49:15 +02:00
csoler
ed08009414 Merge remote-tracking branch 'upstream/master' into v0.6-Notify2 2025-10-10 16:57:40 +02:00
csoler
7621142c34 cleaned up dead code in notifyQt 2025-10-10 16:45:17 +02:00
csoler
17cbf5da30 removed rsnotify 2025-10-10 16:39:11 +02:00
csoler
2e49aa9183
Merge pull request #3030 from defnax/guide-update-v4
Fix & improve guide
2025-10-08 20:00:50 +02:00
csoler
ff68c770d8 removed all left rsnotify elements and moved uint32 flags to proper enum classes 2025-10-07 21:13:24 +02:00
csoler
116c7f1aec fixed passwd handling in retroshare-service 2025-09-30 21:03:02 +02:00
David Bears
dae321ef8e
fix indentation 2025-09-28 12:25:03 -04:00
David Bears
677b40ddbf
Make forum moderator selectable by the user 2025-09-28 12:24:56 -04:00
csoler
3f21b4bf65 fixed bug causing passwd request to fail 2025-09-28 13:10:09 +02:00
csoler
86b9d6da08 fixed bug using the wrong handler ID 2025-09-27 19:04:15 +02:00
csoler
670475b67d moved pgp passphrase handling to RsLoginHandler and removed irrelevant notify handles 2025-09-27 18:59:28 +02:00
csoler
5592c667ae fixed bug causing crash when rsPlugins is not initialized yet 2025-09-25 18:05:35 +02:00
defnax
ad481bbbc0 Fix & improve guide 2025-09-17 21:43:51 +02:00
csoler
e2b2c1ae44 fixed toasters in notifyQt to use rsEvents 2025-09-16 16:29:47 +02:00
csoler
8ebd9ba21f
Merge pull request #2999 from defnax/cmake-fix-qt
cmake fix qt6
2025-09-14 20:51:37 +02:00
csoler
43e0289604 moved log notify to a rsEvent 2025-09-13 11:20:00 +02:00
Christoph Johannes Kleine
228483de52
go back to old function 2025-09-11 21:53:48 +02:00
csoler
ee3afd9f40 fixed ifdef problem 2025-09-11 21:23:12 +02:00
csoler
d64e4b6e78 fixed bug causing crash in chat history browser 2025-09-11 20:49:35 +02:00
defnax
138b40a375 fix 2025-09-09 21:03:23 +02:00
csoler
e5dc58cfd0
Merge pull request #3027 from defnax/rnp-fix
Added rnp define
2025-09-09 20:01:23 +02:00
csoler
bb97e48db2 fixed bug causing crashes after closing a chat window 2025-09-09 19:49:24 +02:00
defnax
82931d3ce2 fix mac configs 2025-09-07 12:26:59 +02:00
defnax
772069a4a6 Added rnp define 2025-09-06 22:17:03 +02:00
defnax
bc34ef1ac8 Added macos workflow 2025-09-06 21:47:15 +02:00
csoler
483a68000a fixed compilation with rs_efs 2025-09-02 22:16:42 +02:00
csoler
95ae8f9454
Merge pull request #3014 from JohannesKleine/macos-compatibility
Macos compatibility
2025-08-31 09:17:23 +02:00
csoler
97e28d76b3
Merge pull request #3009 from JohannesKleine/ui-storage-period-v2
UI storage period v2
2025-08-30 22:57:45 +02:00
csoler
a991521cd0 updated libretroshare submodule 2025-08-27 17:53:58 +02:00
csoler
96fddc9066 fixed typing message missing 2025-08-27 17:37:45 +02:00
csoler
42f0bd41ae fixed missing update of own status 2025-08-26 20:28:59 +02:00
csoler
af36a0b6d9 fixed hashing status 2025-08-23 19:08:26 +02:00
csoler
bfcfa2293b fixed compilation 2025-08-17 18:06:08 +02:00
csoler
798775e12b moved notifyChatStatus to rsEvents 2025-08-17 17:34:46 +02:00
csoler
e6bd8335dc fixed faulty merge 2025-08-13 19:32:24 +02:00
csoler
d2193812a9 merged with upstream/master 2025-08-13 16:17:07 +02:00
csoler
c41fa0c667
Merge pull request #2949 from JohannesKleine/desktop-file2
.desktop file remove absolute path; fixes #2925
2025-08-12 22:46:50 +02:00
Christoph Johannes Kleine
dc84b7c1d6 .desktop file remove absolute path for icons; fixes #2925 2025-08-12 22:39:27 +02:00
csoler
2506bc5672 using rsEvents for Chat rooms 2025-08-12 21:00:11 +02:00
Christoph Johannes Kleine
1cb21fd2ae ADD: new values to checkDeleay() 2025-08-12 18:15:05 +02:00
Christoph Johannes Kleine
9f34b871af CHANGE: remove spaces in tr string; use correct function 2025-08-12 18:15:05 +02:00
Christoph Johannes Kleine
361fc39f7c ADD: storage and sync time 3 and 5 years 2025-08-12 18:15:05 +02:00
Christoph Johannes Kleine
71a61666b7 remove unsupported macos < 10.13 2025-08-12 18:12:16 +02:00
Christoph Johannes Kleine
14b758cb02 botan-2 instead of botan-3 2025-08-12 18:12:16 +02:00
Christoph Johannes Kleine
7d0aa67b97 fix QMAKE_MAC_SDK 2025-08-12 18:12:16 +02:00
Christoph Johannes Kleine
be39fd075c set QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 2025-08-12 18:12:16 +02:00
Christoph Johannes Kleine
4fd67b276d retroshare.pri add macos targets 2025-08-12 18:12:16 +02:00
redDwarf03
28653ad92c Updates for macos sequoia to run retroshare-service
origin redDwarf03 <sylvain@archethic.net>
2025-08-12 18:12:16 +02:00
csoler
2c1a26ea3e
Merge pull request #3021 from JohannesKleine/github-ubuntu-workflow
ADD: ubuntu workflow files
2025-08-12 16:58:50 +02:00
defnax
b489f7cbb3
Merge branch 'RetroShare:master' into cmake-fix-qt 2025-08-10 22:19:17 +02:00
thunder2
dae748ca2e FIX MSYS2: Disabled VOIP for msys2 and Qt 6 2025-08-10 19:58:56 +02:00
Christoph Johannes Kleine
e0087ea8ee
ADD: apt update 2025-08-10 17:22:17 +02:00
Christoph Johannes Kleine
fd48b6b1ba
ADD: ubuntu workflow files 2025-08-10 17:08:49 +02:00
thunder2
5f5639391a Windows native build: Added architecture in console title during build and pack 2025-08-10 13:21:09 +02:00
csoler
f806cb2c91
Merge pull request #3018 from defnax/qt6-workflow-readme
Added qt6 badge to readme
2025-08-10 11:20:43 +02:00
defnax
aca1c31490 Added qt6 badge to readme 2025-08-10 10:35:39 +02:00
csoler
4e2e806b03
Merge pull request #2965 from defnax/fix-combobox
Fixed the QComboBox issues for light and dark style
2025-08-10 09:47:25 +02:00
csoler
4617015412
Merge pull request #3003 from defnax/qt6-workflow-mingw64
Added Qt6 workflow
2025-08-10 09:46:04 +02:00
csoler
632ba09896
Merge pull request #3017 from defnax/master
Added Linux Install Guide to Readme
2025-08-10 09:45:24 +02:00
defnax
b3999837ed
Merge branch 'RetroShare:master' into master 2025-08-10 02:01:09 +02:00
defnax
e7ece32ab0 Fixed link 2025-08-10 01:44:40 +02:00
csoler
dd7de312a1
Merge pull request #3002 from thunder2/qt6
Qt6
2025-08-09 23:27:39 +02:00
defnax
fcefd49725 Added Linux Install Guide to Readme 2025-08-09 18:47:48 +02:00
csoler
d455b3404e
Merge pull request #3016 from defnax/fedora-guide-v2
Added Fedora Install guide
2025-08-09 18:34:53 +02:00
csoler
28b60406e5
Merge pull request #3012 from defnax/linux-guide-v3
Added Linux Guide
2025-08-09 18:34:22 +02:00
defnax
f6f0f243ad Added fedora guide 2025-08-09 13:21:37 +02:00
defnax
1dc1f4fd56 fixed requested changes 2025-08-09 12:06:14 +02:00
csoler
f5eb458ed3
Merge pull request #3013 from defnax/staus-badge
Added status badge from workflow
2025-08-09 11:35:21 +02:00
csoler
69401188ea
Merge pull request #2979 from defnax/fix-servicepermissionsmatrix-2
Fixed hardcoded background color
2025-08-09 11:34:11 +02:00
defnax
7e8abe1aca corrected sqlcipher repo 2025-08-05 21:40:42 +02:00
defnax
2369f5a916 Update Linux_InstallGuide.md 2025-08-05 20:34:23 +02:00
defnax
e29b907761 update instructions 2025-08-04 18:18:21 +02:00
defnax
47c49ca534
Disable webui &jsonapi 2025-08-04 10:38:29 +02:00
defnax
b75a14fac5 uodate opensuse packages 2025-08-03 19:33:35 +02:00
defnax
1b239c2f2a update instructions 2025-08-03 16:08:34 +02:00
defnax
dc1901b236 fix to use em 2025-08-03 15:53:47 +02:00
defnax
8c6d49158e Added status badge from workflow 2025-08-03 14:29:34 +02:00
defnax
a2cd31443c Added Linux Guide 2025-08-03 14:23:13 +02:00
Thunder
383fd86e68
Merge pull request #3010 from defnax/workflow-fix
Removed jsonapi & webui config from workflow
2025-08-03 14:04:02 +02:00
thunder2
5554e35e21 Updated msys2 installation for Windows build 2025-08-03 13:46:39 +02:00
thunder2
a5076d34d8 Removed appveyor configuration 2025-08-03 13:45:45 +02:00
defnax
e26ed4c3c3 Removed jsonapi & webui config from workflow 2025-08-03 00:29:06 +02:00
csoler
14fab2f6c5 updated submodule libretroshare 2025-08-02 22:46:42 +02:00
csoler
d07e61d1ad
Merge pull request #3005 from defnax/workflow-qt5-v3
Added Qt5 workflow
2025-08-02 22:01:17 +02:00
csoler
ee89b41183
Merge pull request #2997 from defnax/new-readme
Created new readme
2025-08-02 19:10:05 +02:00
csoler
6266627141
Merge pull request #2988 from defnax/Windows-compile-qt
Added Install Guide for qtcreator native build
2025-08-02 19:08:27 +02:00
csoler
27243704c1
Merge pull request #2978 from defnax/fix-filetransferinfowidget
Fixed hardcoded pen color
2025-08-02 18:58:24 +02:00
csoler
584df9010d
Merge pull request #2968 from defnax/networkgrapgh-darkmode
Fix for Standard Dark
2025-08-02 18:54:02 +02:00
defnax
6899b1548c update changes 2025-07-30 22:07:26 +02:00
defnax
9ec24f826f Added Qt5 workflow 2025-07-30 21:55:38 +02:00
thunder2
a6cf325db5 Fixed converting char* to QString for Qt 6.4 2025-07-29 18:32:53 +02:00
thunder2
52fdbd531b Added build with Qt 6 for Windows msys2 2025-07-29 18:32:53 +02:00
thunder2
9a84fef2dd Added pack and installer with Qt 6 Windows native build 2025-07-29 18:32:52 +02:00
Christoph Johannes Kleine
26088a7cbb Replaced depracted QX11Info by QGuiApplication 2025-07-29 18:32:51 +02:00
thunder2
95127592d7 Replaced deprecated QSound and QAudioDeviceInfo by QAudioDevice and QMediaDevices for Qt 6 2025-07-29 18:32:51 +02:00
thunder2
15684bf8d3 Added Qt 5 Core Compat module for QRegExp for Qt 6 2025-07-29 18:32:50 +02:00
thunder2
96c02d94c3 Removed deprecated QCoreApplication::flush for Qt 6 2025-07-29 18:32:50 +02:00
thunder2
c8c833b3d6 Removed deprecated QAbstractEventDispatcher::hasPendingEvents for Q 6 2025-07-29 18:32:49 +02:00
thunder2
1b1cb6e176 Replaced deprecated QSysInfo::MacintoshVersion and QSysInfo::windowsVersion by QSysInfo::prettyProductName 2025-07-29 18:32:49 +02:00
thunder2
c64cca9954 Removed usage of deprecated QSysInfo::WindowsVersion 2025-07-29 18:32:48 +02:00
thunder2
efe9ac773d Replaced deprecated QObject::trUtf8 by QObject::tr 2025-07-29 18:32:48 +02:00
thunder2
21174aa5d7 Replaced depecated QPainter::initFrom by QPainter::begin 2025-07-29 18:32:47 +02:00
thunder2
9ebc4b00ed Replaced deprecated QStyleOption::init by QStyleOption::initFrom 2025-07-29 18:32:47 +02:00
thunder2
3874390de7 Replaced deprecated QStyleOptionProgressBarV2 by QStyleOptionProgressBar and QStyleOptionViewItemV4 by QStyleOptionViewItem 2025-07-29 18:32:47 +02:00
thunder2
15437c0d2d Replaced deprecated QMatrix by QTransform 2025-07-29 18:32:46 +02:00
thunder2
71aaa25e69 Replaced deprecated QGraphicsView::matrix by matrix::transform 2025-07-29 18:32:46 +02:00
thunder2
8d497dce0a Replaced deprecated QVariant::operator< by QVariant::compare for Qt 6 2025-07-29 18:32:45 +02:00
thunder2
79a8b3143f Replaced deprecated QPalette::Background by QPalette::Window 2025-07-29 18:32:45 +02:00
thunder2
ec497f0015 Replaced deprecated QModelIndex::child by QAbstractItemModel::index 2025-07-29 18:32:44 +02:00
thunder2
c00a4dccb5 Replaced deprecated QSortFilterProxyModel::filterChanged by QSortFilterProxyModel::invalidateFilter 2025-07-29 18:32:44 +02:00
thunder2
d4dcaaa41a Changed QDomDocument::setContent for Qt 6.5 2025-07-29 18:32:43 +02:00
thunder2
c4c2c5a0d1 Replaced deprecated Qt::BackgroundColorRole by Qt::BackgroundRole and Qt::TextColorRole by Qt::ForegroundRole 2025-07-29 18:32:43 +02:00
thunder2
ff822498a6 Replaced deprecated QAbstractPrintDialog::addEnabledOption by QPrintDialog::setOption 2025-07-29 18:32:42 +02:00
thunder2
07e7cd023c Replaced deprecated QPrinter::pageRect by QPrinter::pageLayout().paintRectPixels(resolution()) and QPrinter::paperRect by QPrinter::pageLayout().fullRectPixels(resolution()) 2025-07-29 18:32:42 +02:00
thunder2
f4960a8903 Replaced deprecated qVariantFromValue by QVariant::fromValue 2025-07-29 18:32:42 +02:00
thunder2
395a0b05d0 Replaced deprecated QTableWidgetItem::setBackgroundColor by QTableWidgetItem::setBackground 2025-07-29 18:32:41 +02:00
thunder2
1735797d82 Replaced deprecated QTreeWidget::isItemExpanded by QTreeWidgetItem::isExpanded and QTreeWidget::setItemExpanded by QTreeWidgetItem::setExpanded 2025-07-29 18:32:40 +02:00
thunder2
f97b0e9a64 Replaced deprecated qSort by std::sort 2025-07-29 18:32:40 +02:00
thunder2
a530bd9adb Replaced deprecated QList::toList by range constructors 2025-07-29 18:32:39 +02:00
thunder2
bdae3b35b4 Replaced deprecated QColorDialog::getRgba by QColorDialog::getColor 2025-07-29 18:32:39 +02:00
thunder2
990f4dbf09 Replaced deprecated QLayout::margin by QLayout::contentsMargins 2025-07-29 18:32:38 +02:00
thunder2
5efed259e7 Replaced depracated QWheelEvent::delta by QWheelEvent::angleDelta for Qt 6 2025-07-29 18:32:38 +02:00
thunder2
9052b813b9 Replaced deprecated qrand by QRandomGenerator for Qt 6 2025-07-29 18:32:37 +02:00
thunder2
88230fd9bd Replaced deprecated QPalette::foreground by QPalette::windowText and QPalette::background by QPalette::window 2025-07-29 18:32:36 +02:00
thunder2
484d220b04 Replace depracated QTextEdit::setTabStopWidth by QTextEdit::setTabStopDistance 2025-07-29 18:32:36 +02:00
thunder2
6652d7f4f8 Replaced deprecated QTextStream::setCodec by QTextStream::setEncoding 2025-07-29 18:32:36 +02:00
thunder2
47916ee8c0 Removed check for QSysInfo::WindowsVersion in misc::getOpenFileName/getOpenFileNames 2025-07-29 18:32:35 +02:00
thunder2
9816be4b53 Replaced QColor::light by QColor::lighter and QColor::dark by QColor::darker 2025-07-29 18:32:35 +02:00
thunder2
c9e8ac4c3c Added Qt dependent macro for Q_FALLTHROUGH 2025-07-29 18:32:34 +02:00
thunder2
32350dfe83 Added Qt dependent macro for QLabel::pixmap 2025-07-29 18:32:34 +02:00
thunder2
fce618f2aa Added Qt dependent macro for QFontMetrics::horizontalAdvance/width 2025-07-29 18:32:33 +02:00
thunder2
fad7774767 Added Qt dependent macro for QSortFilterProxyModel::setFilterRegularExpression/setFilterRegExp 2025-07-29 18:32:33 +02:00
thunder2
13b294838b Replaced deprecated QRegExp by QRegularExpression 2025-07-29 18:32:32 +02:00
thunder2
f0286740f4 Replaced deprecated QDateTime::toString by QLocale::toString 2025-07-29 18:32:32 +02:00
thunder2
291b2f7cad Fixed usage of QLayout::addWidget 2025-07-29 18:32:31 +02:00
thunder2
6251f36e3e Replaced deprecated QDateTime::toTime_t by QDateTime::toSecsSinceEpoch 2025-07-29 18:32:31 +02:00
thunder2
0d37db307c Replaced some more QDateTime::setTime_t by DateTime::DateTimeFromTime_t 2025-07-29 18:32:30 +02:00
thunder2
a6cf10fd1a Replaced deprecated endl by Qt::endl 2025-07-29 18:32:30 +02:00
thunder2
07ee6581e1 MSYS2: Use date of last git commit instead of current date for packed filename 2025-07-29 18:31:22 +02:00
thunder2
e4672d9a57 Windows native build: Enabled parallel build of external libraries 2025-07-28 18:32:13 +02:00
thunder2
93b232d7ae Windows native build: Removed external library libmicrohttpd 2025-07-28 18:31:49 +02:00
defnax
9e121480c0 Added Qt6 workflow 2025-07-25 20:23:15 +02:00
defnax
37527ed89a
Merge branch 'RetroShare:master' into cmake-fix-qt 2025-07-24 19:42:44 +02:00
Thunder
dd8845f77e
Merge pull request #2989 from JohannesKleine/retroshare-gui.pro
Remove qt4, make x11extras for qt5 only in retroshare-gui.pro
2025-07-23 16:43:37 +02:00
defnax
5868198181 Update CMakeLists.txt 2025-07-22 21:29:32 +02:00
defnax
a9109060d6 Fix qt6 with cmake 2025-07-22 20:55:58 +02:00
Thunder
16a30dcbe3
Merge pull request #2995 from thunder2/fix-language
Fixed set of default language in LanguageSupport::localize. Use value…
2025-07-22 20:27:10 +02:00
Thunder
cbc1a89505
Merge pull request #2991 from thunder2/qt6-sprintf
Replaced deprecated QString::sprintf by QString::asprintf
2025-07-22 20:26:48 +02:00
Thunder
256b188861
Merge pull request #2990 from thunder2/qt6-setMargins
Replaced deprecated QLayout::setMargins by QLayout::setContentsMargins
2025-07-22 20:26:16 +02:00
defnax
48ffc59522 Created new readme 2025-07-21 21:50:48 +02:00
thunder2
eb4f482a4e Fixed set of default language in LanguageSupport::localize. Use value of language map instead of key. 2025-07-21 18:20:12 +02:00
Christoph Johannes Kleine
e3202de4ef CHANGE: remove qt4, make x11extras for qt5 only 2025-07-21 11:24:53 +02:00
thunder2
5bdcf59b5c Replaced deprecated QString::sprintf by QString::asprintf 2025-07-20 18:28:04 +02:00
thunder2
90041fc627 Replaced deprecated QLayout::setMargins by QLayout::setContentsMargins 2025-07-20 14:19:47 +02:00
thunder2
33fc4308c4 Use Qt::MouseButton::NoButton instead of 0 in edge.cpp 2025-07-20 14:19:46 +02:00
thunder2
04b741e70d Fixed linking on Windows with enabled wikipoos 2025-07-20 14:19:45 +02:00
thunder2
42b3b95fd8 Use QDateTime::fromSecsSinceEpoch in Qt 6 instead of QDateTime::fromTime_t 2025-07-20 14:15:27 +02:00
thunder2
a00c1375e5 Renamed QtVersion.h to RsQtVersion.h because of the same filename in Qt 6 2025-07-20 14:14:57 +02:00
thunder2
b93a31a33b Removed deprecated QDesktopWidget for Qt 6 2025-07-20 14:14:38 +02:00
thunder2
3a8f7d5a2d Use "Qt::WindowFlags flags = Qt::WindowFlags()" instead of "Qt::WindowFlags flags = 0" 2025-07-20 14:14:13 +02:00
defnax
a2eb40740f Added Install Guide for qtcreator native build 2025-07-20 13:11:23 +02:00
thunder2
e2e1a431ff Added Qt dependent macro for QString::SkipEmptyParts/Qt::SkipEmptyParts 2025-07-19 23:28:30 +02:00
thunder2
f38b72e7a3 Changed parameter of method enterEvent on ClickableLabel and ZoomableLabel for Qt 6 to QEnterEvent 2025-07-19 21:11:28 +02:00
thunder2
b2bec12a43 Fixed usage of deprecated method "const QPixmap *QLabel::pixmap() const;" 2025-07-19 18:57:29 +02:00
thunder2
fcd7a213e6 Use UIStates() instead of 0 in GxsMessageFrameWidget.cpp 2025-07-19 16:26:07 +02:00
thunder2
29443c4b78 Use QTextDocument::FindFlags() to initialize flags instead of 0 in helpbrowser.cpp 2025-07-19 16:03:02 +02:00
thunder2
8265c5ebec Use Qt::KeyboardModifier::NoModifier instead of 0 in RsButtonOnText.cpp 2025-07-19 14:56:55 +02:00
thunder2
9f607765bc Fixed crash in VOIP by initializing member _image_capture in constructor of QVideoInputDevice 2025-07-19 14:54:51 +02:00
thunder2
eaf2861cd0 Fixed usage of QFileInfo in RsCollectionDialog.cpp 2025-07-19 14:24:52 +02:00
thunder2
23289c4991 Use Qt::MouseButton::NoButton instead of 0 in arrow.cpp 2025-07-19 14:20:31 +02:00
thunder2
23f925f81e Fixed constructor of RsAction 2025-07-19 13:44:54 +02:00
thunder2
c4d1de06d0 Fixed converting number to QString 2025-07-19 13:42:50 +02:00
thunder2
e5c42e63b7 Added missing includes 2025-07-19 13:36:49 +02:00
thunder2
f53a30a0e4 Updated external libraries for Windows native build
- curl-8.9.1
- ffmpeg-4.4.6
- libxml2-2.14.5
- libxslt-1.1.43
- speex-1.2.1
- speexdsp-1.2.1
- xapian-core-1.4.29
2025-07-18 14:25:17 +02:00
Christoph Johannes Kleine
f3150e9d42 HomePage.cpp enable saveCert 2025-07-16 17:59:09 +02:00
thunder2
c850a30c1a Build libretroshare on Windows as shared library 2025-07-16 17:25:57 +02:00
thunder2
6c1eb35a47 MSYS2: Added toolchain to filename of packed files and installer 2025-07-16 17:23:01 +02:00
thunder2
1aec263bb9 MSYS2: Removed parameter "clang" from build. Use "clang32" or "clang64" instead. 2025-07-16 17:23:01 +02:00
defnax
995e3fee85 Fixed hardcoded background color 2025-07-14 21:29:53 +02:00
defnax
e78367f12f Fixed hardcoded pen color 2025-07-14 19:39:24 +02:00
thunder2
ddb4300a60 FeedReader: Updated translation 2025-07-14 00:04:31 +02:00
thunder2
c8cea52b39 FeedReader: Reworked proxy setting 2025-07-14 00:04:31 +02:00
thunder2
1094e3e651 FeedReader: Moved proxy setting to own widget 2025-07-14 00:04:31 +02:00
defnax
8c26fa879d Added asio depency 2025-07-12 23:44:00 +02:00
defnax
42bd651fb3 Update MSYS2 packages 2025-07-12 23:44:00 +02:00
defnax
d7e58a3ac0
Merge branch 'RetroShare:master' into w10darkmode 2025-07-12 14:40:38 +02:00
thunder2
500ab2098b Added asio as external library for Windows native compile 2025-07-11 23:17:12 +02:00
Thunder
5bf59b4376
Merge pull request #2973 from JohannesKleine/Windows-msys2
Windows-msys2 build.bat add asio
2025-07-11 22:10:00 +02:00
Christoph Johannes Kleine
d165a84b67
Windows-msys2 build.bat add asio 2025-07-11 16:35:19 +02:00
csoler
9b881a6214 moved ownAvatarChanged() and ownStatusChanged() to rsEvents 2025-07-10 15:39:10 +02:00
defnax
31756be1be
Merge branch 'RetroShare:master' into login-dialog 2025-07-09 11:13:32 -07:00
defnax
8ab30b639f
Update 2025-07-09 14:48:05 +02:00
csoler
ef25a9079d fixed using the right version of cmake > 3.5 2025-07-08 22:06:28 +02:00
defnax
526507e44f Added for login dialog switch background image 2025-07-08 19:05:06 +02:00
defnax
e418cb27ce
Merge branch 'RetroShare:master' into w10darkmode 2025-07-08 15:20:43 +02:00
csoler
c3640306bd fixed restbed to stick to commit 6001a322809b5005b8bcccdf593fdda6f0173691 2025-07-07 23:37:29 +02:00
csoler
bfa3e557a4
Merge pull request #2963 from defnax/update-homelogo
Fix to load the right logo without restart too
2025-07-07 22:00:19 +02:00
csoler
06c2fd3947
Merge pull request #2955 from defnax/stylefix2
Fixed frame to get styled on system theme (Win/MacOS)
2025-07-07 21:56:56 +02:00
defnax
557e24a5dc Fix for Standard Dark 2025-07-07 21:45:00 +02:00
defnax
315838d772
Merge branch 'RetroShare:master' into w10darkmode 2025-07-06 15:17:16 +02:00
defnax
63d3dd1c08
Added override 2025-07-05 13:24:25 +02:00
defnax
e88c45561a Fixed the QComboBox issues for light and dark style 2025-07-05 00:37:45 +02:00
csoler
b556ff8fc7
Merge pull request #2959 from defnax/move-backgroundimage
Moved background image to light skin
2025-07-04 23:21:49 +02:00
defnax
ad82a94cc7 Fix to load the right logo without restart too 2025-07-03 18:46:24 +02:00
defnax
24a7c2ae39
Merge branch 'RetroShare:master' into stylefix2 2025-07-01 19:23:43 +02:00
defnax
829a1db710 Fix system dark style issues 2025-07-01 18:10:00 +02:00
csoler
432e6970c4
Merge pull request #2953 from defnax/HomeLogo
Added for Dark Style new home logo
2025-07-01 11:16:26 +02:00
csoler
dc6440a72e
Merge pull request #2954 from defnax/patch-4
Update MacOS_X_InstallGuide
2025-07-01 11:13:45 +02:00
defnax
39c5f0763c Added system dark mode for Windows 10 2025-06-30 21:17:00 +02:00
defnax
adc4bf90b5 Fix light skin issues 2025-06-25 20:02:19 +02:00
csoler
4b9d060c81 swiched some of the chat room notify to RsEvent and added new event code for SYSTEM errors 2025-06-25 16:49:26 +02:00
defnax
c05f6f5e52 Moved background image to light skin
*Moved backgrund image from login & profile creation page to light skin
2025-06-22 22:41:35 +02:00
defnax
915bf59d2e Fixed frames to get styles on system style 2025-06-19 18:33:51 +02:00
defnax
1190e45e6b Fixed green color get more contrast on dark style 2025-06-17 21:45:14 +02:00
csoler
41d972b359 removed unused stuff 2025-06-17 21:22:39 +02:00
csoler
c70b84497a moved pre/post-ModDirectories to rsEvents 2025-06-17 20:40:56 +02:00
csoler
e6cacc4d34 moved peerStatusChanged() from notify to rsEvents 2025-06-14 21:56:09 +02:00
defnax
1d4e997df2 Fixed frame to get styled on system theme 2025-06-14 17:20:19 +02:00
defnax
e146706a97
Update macports 2025-06-14 16:21:32 +02:00
defnax
751cc660a6
Update MacOS_X_InstallGuide.md 2025-06-14 14:39:12 +02:00
csoler
0ce2dd8486 removed groupsChanged and used rsEvents::FRIEND_LIST instead 2025-06-12 21:12:47 +02:00
csoler
df02d745d8 removed friendsChanged() and NOTIFY_LIST_FRIENDS 2025-06-11 20:50:38 +02:00
defnax
97304269a2 Added for Dark Style new home logo 2025-06-08 17:32:30 +02:00
csoler
2edb3afc81 moved hashing status info from notify to rsEvents 2025-06-07 15:50:24 +02:00
csoler
5361bed037 updated submodules to latest 2025-06-05 23:22:57 +02:00
csoler
553761fb7c updated submodules to latest 2025-06-05 23:15:24 +02:00
csoler
f5183bc4eb
Merge pull request #2950 from defnax/patch-2
Added deepwiki badge
2025-06-05 22:55:17 +02:00
csoler
b66061d15b
Merge pull request #2948 from JohannesKleine/desktop-file
Desktop file remove 'Application'
2025-06-05 22:48:33 +02:00
csoler
74c9b9493d
Merge pull request #2942 from JohannesKleine/issue_2895
fix typo Stared -> Starred
2025-06-05 22:46:46 +02:00
defnax
12959c60cb
Added deepwiki badge 2025-06-04 21:13:22 +02:00
Christoph Johannes Kleine
d0c4827335
change .desktop file in build_scripts 2025-05-31 18:32:58 +02:00
Christoph Johannes Kleine
a0646c1b66
Desktop file remove 'Application' 2025-05-31 18:28:47 +02:00
csoler
d6228f381d updated submodules to latest commit 2025-05-30 20:54:40 +02:00
Christoph Johannes Kleine
6fe7f7842b
fix typo Stared -> Starred 2025-05-28 12:48:09 +02:00
csoler
1654ed0bc6
Merge pull request #2938 from csoler/v0.6-FriendList
fixed wrong implementation of parentRow() causing loss of selected elem…
2025-05-12 21:46:09 +02:00
csoler
e5273fb887 fixed wrong implementation of parentRow causing loss of selected elements 2025-04-29 21:10:27 +02:00
csoler
da0732b5ad
Merge pull request #2919 from csoler/v0.6-IdentityDialog
Identity list model for IdDialog
2025-04-27 21:31:01 +02:00
csoler
3ec931716a
Merge pull request #2934 from defnax/revert-2910-moved-backgroundimage
Revert "Moved background image to standard light"
2025-04-20 10:57:18 +02:00
csoler
1720a94a80 added fontSizeHandler for Identity list 2025-04-17 20:49:30 +02:00
csoler
39b062fecf fixed compilation 2025-04-17 20:31:18 +02:00
csoler
0b79668f73 fixed merging with master 2025-04-16 22:12:44 +02:00
csoler
2f02f6cd2d fixed coloring for insecure identities 2025-04-16 22:10:58 +02:00
defnax
9810008fc1
Revert "Moved background image to standard light" 2025-04-16 20:29:39 +02:00
csoler
71eba47fe7 fixed voting not working on right panel of People 2025-04-16 13:36:01 +02:00
Thunder
1d1138d0cb
Merge pull request #2932 from defnax/Fix-searches
Fix size & age column
2025-04-13 13:50:38 +02:00
Thunder
015b33b33f
Merge pull request #2931 from thunder2/fontsizehandler
FeedReader: Added FontSizeHandler
2025-04-12 22:20:10 +02:00
defnax
0b3f4a69b9 Fix size & age column 2025-04-12 18:01:38 +02:00
thunder2
bd7dfe957f FeedReader: Added FontSizeHandler 2025-04-12 15:50:43 +02:00
csoler
2b13abe2a9 fixed sizes in idTreeWidget 2025-04-10 21:11:28 +02:00
thunder2
f2bf2f04cc Added missing include for std::function in FontSizeHandler.h 2025-04-10 10:24:35 +02:00
csoler
42bbf785ea
Merge pull request #2918 from defnax/fontssettings
Fonts settings for Tree & list Views & Composer Fonts
2025-04-09 21:19:44 +02:00
csoler
f26fc5ab14
Merge pull request #2910 from defnax/moved-backgroundimage
Moved background image to standard light
2025-04-09 21:01:18 +02:00
csoler
06c0be19e9
Merge pull request #2913 from defnax/fonts-fix-v3
Fixed fonts for macos
2025-04-09 20:59:49 +02:00
csoler
a596acbcec removed uninitialized memory read causing random crashes 2025-04-09 16:54:35 +02:00
csoler
f4364bcaa6 fixed missing clear button in IDDialog search 2025-04-03 20:48:01 +02:00
csoler
aa268c8745 made identity list searchable by whatever is displayed 2025-04-01 22:34:13 +02:00
defnax
e87566ef92 set default font size to 11 2025-04-01 21:26:54 +02:00
csoler
85f411463b fixed display of total number of identities 2025-04-01 20:39:44 +02:00
csoler
c9d5a9ba30 fixed preserving of selection and expanded items 2025-03-31 22:09:55 +02:00
csoler
59d6592855 fixed show in people tab 2025-03-31 21:29:43 +02:00
csoler
c8f71072b0 removed test line 2025-03-29 15:37:18 +01:00
defnax
18b14a033a
Merge pull request #223 from thunder2/pr/2918
Pr/2918
2025-03-29 09:34:41 +01:00
thunder2
973246624f Replaced font handling by FontSizeHandler and reenabled deactivated item delegates 2025-03-28 23:52:54 +01:00
thunder2
93154fddc4 Added new class FontSizeHandler to set font size from settings 2025-03-28 22:14:46 +01:00
thunder2
cab91819d6 Added set and get of font size on RshareSettings 2025-03-28 22:14:45 +01:00
csoler
417f80d752 added some debug info 2025-03-23 17:17:08 +01:00
csoler
8c2c3188ef fixed sizeHint role 2025-03-15 16:07:48 +01:00
csoler
92290015eb added [Loading...] string when loading info in the item model 2025-03-15 15:01:00 +01:00
csoler
e77b4271fc limiting calls to getIdDetails to the bare minimum 2025-03-09 15:34:19 +01:00
csoler
60750812d9 fixed a few bugs 2025-03-06 20:39:29 +01:00
csoler
6fde55217c added async update of ID list 2025-03-04 16:52:29 +01:00
csoler
7c5a45335a fixed load/save of visible columns 2025-03-01 21:26:29 +01:00
csoler
06d9ea2398 enabled processSettings 2025-03-01 20:57:32 +01:00
csoler
e369ba3504 added new column for owner name/ID 2025-03-01 20:38:05 +01:00
defnax
95ea588c9f Fixed Subject column fonts 2025-02-28 17:38:14 +01:00
defnax
2644a0ccb7 Added for search list update fontsize 2025-02-26 17:56:38 +01:00
csoler
756ded0b5d fixed sorting 2025-02-24 20:39:13 +01:00
csoler
0bda8eeb8d fixed save/restore of expanded items 2025-02-23 18:43:48 +01:00
csoler
ee27c52825 improved save/restore of selection/expanded items 2025-02-23 16:33:47 +01:00
csoler
a826a8651c added filtering 2025-02-23 14:50:48 +01:00
csoler
37c0f16a27 fixed update of visible items 2025-02-19 12:05:21 +01:00
defnax
c61c939b2a Fixed to get fonts work in forums tree 2025-02-18 19:56:11 +01:00
csoler
ed6debb3c6 added save/load selection (not working yet) 2025-02-17 23:15:53 +01:00
csoler
80b9006620 fixed drop menus for header and data 2025-02-16 17:58:08 +01:00
csoler
3153df1123 fixed display of icons 2025-02-15 19:55:30 +01:00
csoler
ac620d9077 fixed display of reputation 2025-02-14 22:01:11 +01:00
csoler
40d6c3c973 first working version of IdentityModel 2025-02-14 16:54:02 +01:00
defnax
cd338613c1 Attempt for forums tree fonts settings 2025-02-12 19:26:16 +01:00
defnax
49242e185b Fixed fonts update 2025-02-12 18:36:13 +01:00
defnax
5005c0303d Fixed to update the fonts for MainWindow ListWidget 2025-02-11 18:51:20 +01:00
csoler
435e8ce50c continued implementation of IdentityListModel 2025-02-10 21:18:31 +01:00
defnax
a5752ec4d3 Fixed alignment for the attachment counter 2025-02-10 20:03:43 +01:00
defnax
6d394c9f55 Added for channel composer default size settings 2025-02-10 19:41:19 +01:00
csoler
43d64bf0c5 added abstract item model for identity 2025-02-09 21:05:11 +01:00
defnax
3ffa362079 Added for Composer fonts settings 2025-02-09 18:05:36 +01:00
defnax
b168110a58 Added for settings list fonts settings 2025-02-08 15:44:39 +01:00
defnax
7399c42dfb Fix settings 2025-02-08 15:13:43 +01:00
defnax
533caea81e Added Fonts settings 2025-02-06 20:20:28 +01:00
defnax
18f4ef5574 Fix fonts 2025-02-06 19:02:40 +01:00
defnax
e14fc66ca3 Settings for default tree & listwidget fonts 2025-02-05 20:55:03 +01:00
defnax
b99988385f Added brew packages for RNP 2025-01-30 19:53:59 +01:00
defnax
85b6d18094 Fixed fonts to use default system 2025-01-23 22:22:26 +01:00
defnax
86d96fe60c Fixed fonts for macos
Fixed Toolbar fonts
Fixed forum composer fonts
2025-01-22 23:21:32 +01:00
csoler
8fcc52b304
Merge pull request #2904 from defnax/fix-macos-v2
Fixed some frames to use StyledPanel to get styles on system theme
2025-01-19 17:41:39 +01:00
csoler
5f3f1c9c43
Merge pull request #2905 from defnax/fonts-fix-v2
remove font sizes from the ui files
2025-01-19 17:40:20 +01:00
defnax
e835385000 restore back changes 2025-01-18 16:06:03 +01:00
csoler
e44a216873
Merge pull request #2903 from csoler/v0.6-FT-001
removed unencrypted FT
2025-01-12 14:14:21 +01:00
csoler
4b5dd51681
Merge pull request #2911 from csoler/v0.6-RNP-submodule
added non-backward compatible flag change for v0.7 about sha1 certs
2025-01-12 14:12:36 +01:00
csoler
e18bb74a5e added non-backward compatible flag change for v0.7 about sha1 certs 2025-01-10 22:47:46 +01:00
defnax
c9599ea817 Moved background image to standard light 2025-01-09 19:43:35 +01:00
csoler
b2d05d7d8e
Merge pull request #2907 from dbear496/a-few-fixes
a few small fixes
2025-01-06 20:32:20 +01:00
David Bears
2c53c02319
omit newline after single link 2025-01-04 13:48:00 -05:00
David Bears
99053597a9
allow voting on own identities 2025-01-03 15:03:31 -05:00
defnax
e5f2ef2335 remove font sizes from the ui files 2025-01-03 19:10:45 +01:00
David Bears
0759359e06
Fix JSON API token removal 2025-01-02 22:38:46 -05:00
David Bears
2ca36f5957
Fix port settings for manual I2P 2025-01-02 22:27:43 -05:00
defnax
89ceba2f92 Fixed some frames to use StyledPanel to get styles on system theme
* update mac os section
2025-01-02 23:36:43 +01:00
csoler
41bb83054c removed unencrypted FT 2025-01-01 20:17:49 +01:00
csoler
f9ca8934db
Merge pull request #2902 from defnax/ui-fix-v16
Fixed some frames to get compatible for system style
2024-12-30 22:19:38 +01:00
defnax
01617da863 Fixed some frames to get compatible for system style
* Fixed some frames to get compatible for system style
* update macos package script
2024-12-30 21:36:04 +01:00
csoler
8d96bb920d
Merge pull request #2900 from csoler/v0.6-BugFixing_40
fixed bug causing own identity to not disappear when deleted
2024-12-30 14:15:57 +01:00
thunder2
b502dd71e2 Windows build: Fixed makefile for external libraries 2024-12-28 14:01:45 +01:00
csoler
359305c24f
Merge pull request #2888 from defnax/People-improve
Improve People View
2024-12-27 20:11:51 +01:00
csoler
ca2f8c5bed
Merge pull request #2901 from thunder2/fix_missing_premods
Added missing calls to preMods in RsFriendListModel::setDisplayStatus…
2024-12-27 19:59:09 +01:00
thunder2
ccd1cfbde6 Added missing calls to preMods in RsFriendListModel::setDisplayStatusString and RsFriendListModel::setDisplayStatusIcon 2024-12-27 15:03:36 +01:00
thunder2
32a43b1892 Windows build: Updated cmake to 3.31.3 2024-12-27 14:43:26 +01:00
thunder2
6cde715e66 Windows build: Updated MSYS2 installer to 20241208 2024-12-27 14:35:23 +01:00
thunder2
6825c7e925 Updated librnp submodule 2024-12-27 14:35:10 +01:00
csoler
433ab6514d fixed bug causing own identity to not disappear when deleted 2024-12-26 21:14:49 +01:00
csoler
142049a61e updated master branch to latest commit in libretroshare submodule 2024-12-26 18:42:18 +01:00
csoler
8cc2cf8cd2
Merge pull request #2894 from csoler/v0.6-RNP-submodule
V0.6 rnp submodule
2024-12-26 16:15:56 +01:00
csoler
cbd9dfc86a
Merge pull request #35 from thunder2/rnp
Fixed Windows build with librnp
2024-12-25 16:17:55 +01:00
csoler
675b430833
Merge pull request #2887 from thunder2/fix_msgs
Use all mails for the calculation of counts in MessagesDialog::update…
2024-12-25 14:56:53 +01:00
csoler
b17cb811d6
Merge pull request #2891 from fkobi/patch-1
Improve desktop icon
2024-12-25 14:44:27 +01:00
csoler
d6d2f09673 updated submodule url to comply with RS standard 2024-12-19 22:25:27 +01:00
thunder2
d79ce90c68 Fixed Windows build with librnp 2024-12-19 00:32:26 +01:00
csoler
38e82adaea
Merge pull request #2893 from fkobi/patch-2
Mention "desktop" instead of "GNOME"
2024-12-08 17:24:05 +01:00
csoler
5d7b235941 added back key certification with RNP 2024-12-07 16:37:37 +01:00
fkobi
8e94a99a53
Mention "desktop" instead of "GNOME" 2024-11-30 15:14:41 +00:00
csoler
6a77d6b7bc fixed retroshare.pri 2024-11-26 22:19:02 +01:00
csoler
e6f1878f1f Merge remote-tracking branch 'upstream/master' into v0.6-RNP-submodule 2024-11-26 20:46:19 +01:00
fkobi
9a7c94314c
Improve desktop icon
- add missing categories
- sort according to 
  https://specifications.freedesktop.org/menu-spec/latest/additional-category-registry.html
2024-11-25 19:58:52 +00:00
csoler
5c9bf3bf7c added commands to make rnp a submodule 2024-11-20 22:20:28 +01:00
defnax
d8d2243b9e Improve People View 2024-11-16 16:48:30 +01:00
thunder2
00241d6252 Use all mails for the calculation of counts in MessagesDialog::updateMessageSummaryList, not just the current selected box 2024-11-16 15:48:32 +01:00
csoler
3248a06134 updated master branch to latest version of submodules 2024-11-16 15:02:48 +01:00
csoler
ae1bd27ad1
Merge pull request #2885 from defnax/People-improve
Improved People view
2024-11-02 14:40:30 +01:00
defnax
9fefbb3b13 Improved People view
* Improved People View
* Update translations
2024-11-01 16:00:28 +01:00
csoler
ed0105f44c switched rs_usernp into rs_useopenpgpsdk 2024-10-22 19:25:11 +02:00
csoler
126ce6607e changed flag name to remove it from v07 changes list 2024-10-09 21:31:42 +02:00
csoler
e20a4c4e60 changed retroshare.pri to add V07_NON_BACKWARD_COMPATIBLE_CHANGE_005 by default 2024-09-18 21:15:44 +02:00
csoler
e888e89437
Merge pull request #2879 from zapek/fix-image-jpeg-uri-mimetype
Fix image data URI
2024-09-02 09:41:52 +02:00
David Gerber
bb4b8f0bc5
Fix image data URI
Make JPEG images use the image/jpeg mimetype instead of the wrong image/png one.
2024-09-01 22:51:22 +02:00
csoler
a9c87225e2 disabled certificate signature when using librnp 2024-08-19 18:53:25 +02:00
csoler
37261761dd fixed compilation 2024-08-11 23:32:11 +02:00
csoler
3361727a37 added switch to compile with rnp or openpgp-sdk 2024-08-11 16:43:20 +02:00
csoler
d222cfe8e0 added compilation flag for RNP 2024-07-26 11:10:52 +02:00
csoler
64f4d84e74
Merge pull request #2862 from defnax/statusicons-settings
Added optional display status icon from friendslist context menu
2024-07-07 20:10:52 +02:00
defnax
b90e75e912
Merge pull request #215 from thunder2/pr/2862
Pr/2862
2024-07-03 15:38:35 +02:00
thunder2
d72e46cfda Update NewFriendList on avatar and status change 2024-07-03 14:58:03 +02:00
thunder2
874748e7da Use avatar for profile in RsFriendListModel of best node 2024-07-03 14:58:03 +02:00
defnax
b5b2e77a7e set default idle color which has better contrast 2024-07-02 23:52:31 +02:00
defnax
afc4096740
Merge pull request #214 from thunder2/pr/2862
Pr/2862
2024-07-02 08:29:37 +02:00
thunder2
2c3b0a1c44 Fixed show best status icon for profile 2024-07-01 23:26:43 +02:00
thunder2
c8975bb2e9 Optimized avatar loading in RsFriendListModel 2024-07-01 16:48:52 +02:00
defnax
19d613edcc fix naming 2024-06-25 19:09:03 +02:00
defnax
56b6b0cb5a Added optional display status icon from friendslist context menu 2024-06-24 23:36:45 +02:00
csoler
3461da7c3a
Merge pull request #2860 from defnax/fixstatuscolors
Fixed status colors
2024-06-19 21:02:40 +02:00
defnax
332939c3f5 Fixed status colors 2024-06-17 22:07:18 +02:00
csoler
2fb9b3eb46
Merge pull request #2858 from csoler/v0.6-Collection
fixed bug showing peers offline when status service is remotely disabled
2024-06-13 21:38:01 +02:00
csoler
794ec3576c using statusRole instead of onlineRole to decide on node string 2024-06-13 11:08:28 +02:00
csoler
1b4886715d fixed usage of statusRole in FriendListModel 2024-06-09 21:25:43 +02:00
csoler
7dfd6de15f fixed bug showing peers offline when status service is remotely disabled 2024-06-07 11:26:35 +02:00
thunder2
a60f3f44f7 FeedReader: Don't add items as new item when pubDate less than storage time 2024-04-16 19:25:26 +02:00
thunder2
83b433a2e2 Revert changes in libbitdht of "Merge pull request #2852 from thunder2/fix_rscollection" 2024-04-04 00:58:34 +02:00
csoler
55c414b400
Merge pull request #2852 from thunder2/fix_rscollection
Renamed RsCollectionErrorCode::NO_ERROR to COLLECTION_NO_ERROR b…
2024-04-04 00:48:28 +02:00
thunder2
5a24fad354 Renamed RsCollectionErrorCode::NO_ERROR to COLLECTION_NO_ERROR because of double define of NO_ERROR in winerror.h 2024-04-03 22:20:33 +02:00
csoler
16d6d4d597 updated master to all submodules 2024-04-02 17:55:11 +02:00
csoler
d92404d047
Merge pull request #2846 from csoler/v0.6-Collection
Attempt at making RsCollection faster to use (Needs #144)
2024-04-01 18:32:39 +02:00
csoler
0b75abaa04 minor fixes to rscollection PR 2024-04-01 18:25:49 +02:00
csoler
3f9d49921d fixed bug asking for overwriting a non existant file 2024-03-30 18:37:20 +01:00
csoler
0551f4f819 fixed compilation after removal of RsCollection::downloadFiles 2024-03-28 22:14:46 +01:00
csoler
8366cbca59 removed dead code, and added check for incorrect file names when saving 2024-03-28 21:26:09 +01:00
csoler
20f4b51bb7 fixed conflicts with upstream/master 2024-03-26 21:07:57 +01:00
csoler
a02d2e63e2 fixed updating save filename, removal of files/dirs, and cleaning before save 2024-03-20 21:00:42 +01:00
csoler
2ebd7617fc added proper remove for files/dirs 2024-03-19 23:22:46 +01:00
csoler
5aa80f2f68 updated master of Retroshare/ to master of libretroshare 2024-03-18 22:52:46 +01:00
csoler
c7fe3059a5
Merge pull request #2849 from defnax/exportfriendslistv2
Added export Friendslist to Profile Page
2024-03-16 20:37:46 +01:00
defnax
5f748b3131 renaming button text 2024-03-16 20:23:28 +01:00
defnax
21c2312952 Added export Friendslist to Profile Page 2024-03-15 20:10:20 +01:00
csoler
a36f7221e7 added new folder capability in collection 2024-03-14 22:44:49 +01:00
csoler
27f0962654 fixed download from RsCollection dialog 2024-03-14 22:12:57 +01:00
csoler
094c80e046 disable save button when files are being hashed 2024-03-13 22:28:39 +01:00
csoler
0697116289 added green color for files being hashed 2024-03-13 22:20:21 +01:00
csoler
7ef81a37ff added auto-update of files being hashed 2024-03-12 21:39:05 +01:00
csoler
5e3434396c fixed a few bugs in counting and model parenting 2024-03-11 13:37:09 +01:00
csoler
c1a6b8fe12 added some debug info in RsCollectionModel 2024-03-10 23:41:10 +01:00
csoler
9ba4ac6362 fixed a few bugs in file counting 2024-03-09 18:31:01 +01:00
csoler
67ff37a0d4 using vectors instead of maps for mCollectionModel data. 2024-03-09 00:03:16 +01:00
csoler
f375912bc5 added checkable items in RsCollectionModel 2024-03-07 22:15:12 +01:00
csoler
80a5705aea
Merge pull request #2844 from csoler/v0.6-Params2
Cleaned up command line parameter handling (to be used with #143)
2024-03-04 23:33:50 +01:00
csoler
c0d222dedf more cleaning in PR 2844 2024-03-04 23:32:50 +01:00
csoler
2a5698c9d3 removed dead code 2024-03-04 23:22:03 +01:00
csoler
be96f417b3 fixed update of tree when changed 2024-03-04 23:00:25 +01:00
csoler
398db7dfe8
Merge pull request #34 from defnax/fixmacos
Fix for macos
2024-03-04 09:34:27 +01:00
csoler
e106959fbd fixed creating new collection 2024-03-01 23:00:17 +01:00
csoler
31c390aa27 simplified usage of RsCollectionDialog in shared files (removed duplicate functionality) 2024-02-29 22:07:52 +01:00
csoler
2ed72a146b fixed basic functionality of RsCollectionModel 2024-02-28 21:56:38 +01:00
defnax
790c169c02 Fix for macos 2024-02-28 19:47:01 +01:00
csoler
885eb640dc starting fixing RsCollection with the new model 2024-02-27 22:10:49 +01:00
csoler
eae4fe86aa added RsCollectionModel to RsCollectionDialog (unfiished) 2024-02-26 22:10:32 +01:00
csoler
a163f716b0
Merge pull request #2841 from defnax/update-trans
update translation
2024-02-25 21:34:23 +01:00
csoler
f425f2fa23
Merge pull request #2842 from defnax/macos_linedit
(macOS)Fixed iconsize issue with fontmetrics on macos
2024-02-25 21:33:29 +01:00
csoler
b0b3d51571
Merge pull request #2845 from defnax/update-invite-icon
update invite icon
2024-02-25 21:32:49 +01:00
csoler
eb0ef1e39b implemented RsCollectionModel 2024-02-25 17:58:51 +01:00
csoler
97309f2f9f started implementing RsCollectionModel 2024-02-24 21:49:50 +01:00
csoler
5bc071b03c fixed compilation 2024-02-24 20:27:18 +01:00
csoler
5071656209 started adapting RsCollectionDialog to the new API of RsCollection 2024-02-24 17:44:13 +01:00
csoler
206da93d99 fixed a few compilation errors in RsCollection handling 2024-02-24 15:55:21 +01:00
csoler
258fe58547 switch RsCollection to using RsfileTree as a base structure instead of a QDomDocument (not compiling yet) 2024-02-23 21:10:13 +01:00
csoler
eccfc7ba71 fixed handling of incoming rscollection files 2024-02-16 13:28:55 +01:00
csoler
142a8e2503 fixed proper handling of language parameter at startup 2024-02-16 10:33:41 +01:00
defnax
91ed9ed894 update readme 2024-02-13 19:04:38 +01:00
defnax
f4f51e53eb update invite icon 2024-02-13 18:46:30 +01:00
csoler
9210e52aae fixed compilation in parameter handling 2024-02-13 16:24:32 +01:00
csoler
c5aface2cb additional step in rewriting commandline parameter handling 2024-02-11 22:16:50 +01:00
csoler
4f56c7dd2f use argstream::usage() in the help message box 2024-02-04 18:26:47 +01:00
defnax
8db6076ce1 update translation 2024-02-04 16:10:35 +01:00
defnax
ae24db1da0 Fixed iconsize issue with fontmetrics on macos 2024-02-03 23:26:25 +01:00
defnax
b7414c078a update translation 2024-02-03 22:37:04 +01:00
csoler
8564a22bef
Merge pull request #2831 from defnax/downloadupload-treefixes
Improved Sharedfiles treesize and font fix for macos
2024-02-02 13:04:22 +01:00
csoler
9437bce60a
Merge pull request #2836 from defnax/chatlobby.fix
Removed "chat rooms" string from tree item
2024-02-01 21:17:46 +01:00
csoler
ed13a2f47f
Merge pull request #2838 from defnax/update-trans
update translations
2024-02-01 20:32:57 +01:00
defnax
388120956d update translations 2024-01-30 23:15:23 +01:00
defnax
e4da288b25
removed "chat rooms" string from tree item 2024-01-29 21:53:09 +01:00
defnax
a523d654ef Improved Sharedfiles treesize and font fix for macos 2024-01-16 14:54:04 +01:00
csoler
dc5131567f
Merge pull request #2830 from defnax/downloadupload-treefixes
Improved downloads and uploads tree display
2024-01-15 21:56:24 +01:00
defnax
3063e74e59 Improved downloads and uploads tree display 2024-01-15 21:43:09 +01:00
csoler
d9f7e96c68 updated master branch to sync with submodules 2024-01-14 16:26:07 +01:00
csoler
0c03e93a47
Merge pull request #2810 from defnax/macos-guide
[macOS] Fixes and Guide updates
2024-01-03 18:02:50 +01:00
defnax
020e9e5927
Enabled delete CFBundleGetInfoString, to update Version string 2024-01-02 15:30:32 +01:00
defnax
d3513ffed0
Merge branch 'RetroShare:master' into macos-guide 2024-01-02 14:58:07 +01:00
defnax
15f2ea4e29 Added to fix from Dock Icon to Show/Hide for macOS platform 2024-01-02 12:58:11 +01:00
csoler
91dd22d8d3
Merge pull request #2819 from thunder2/fix-chatlobby-traymenu
Fixed memory leak when using tray menu of chat lobby and removed doub…
2024-01-01 18:54:22 +01:00
thunder2
f00e8ba18e Fixed memory leak when using tray menu of chat lobby and removed double connect of signals 2024-01-01 15:58:44 +01:00
csoler
73f1da20f0
Merge pull request #2812 from defnax/fix-cmake-macos
[macOS] fix cmake compile on macos to find include and libs path
2024-01-01 15:41:21 +01:00
csoler
24f13a4b88
Merge pull request #2814 from defnax/comments-tree
Added show author for comments tree
2024-01-01 15:40:22 +01:00
csoler
249ff6e8c5
Merge pull request #2816 from defnax/changed-tray-notifyicon-broadcastchat
changed broadcast chat notify icon
2024-01-01 15:38:42 +01:00
csoler
aac9425626
Merge pull request #2820 from defnax/macos-fix
{macOS} Fix for macos alternative chat room notify
2024-01-01 15:36:40 +01:00
defnax
4982e4b664
Fix for macos alternative chat room notify 2023-12-30 16:01:43 +01:00
csoler
267ffc99af
Merge pull request #2765 from PYRET1C/new_token_service
[WIP] Added the new token service in this file
2023-12-30 15:23:25 +01:00
defnax
75ef4dceb5 Added close window shortcut 2023-12-30 00:15:28 +01:00
defnax
79977a0c37 Fixed minimize on macOS with CTRL + M shortcut 2023-12-29 21:34:54 +01:00
defnax
3615ebf05e
Added retroshare-service compile with cmake to guide 2023-12-27 22:50:22 +01:00
csoler
0caf8e79db
Merge pull request #2817 from vladpirlog/fix/friendlistmodel-index-bug
Add row count check in the RsFriendListModel::index method
2023-12-27 20:01:48 +01:00
Vlad Pirlog
b5d40f7964
Add row count check in the RsFriendListModel::index method
Fix bug occurring after login where the app would crash unexpectedly.
Turns out there was an index out of bounds exception occurring in
the RsFriendListModel::index method.
2023-12-27 12:41:25 +02:00
defnax
17407f7ea3
removed not needed dependency libmicrohttp 2023-12-26 17:53:53 +01:00
defnax
5c9c7e8cf6
changed broadcast chat notify icon 2023-12-26 15:54:40 +01:00
defnax
d1393acfa6
Added show author for comments tree 2023-12-26 12:35:29 +01:00
defnax
c0f9f14455
Update GxsCommentTreeWidget.h 2023-12-26 12:30:56 +01:00
defnax
4af12b14e1
Set fusion style for macos 2023-12-24 22:01:03 +01:00
defnax
d395be256b
fix cmake compile on macos to find include and libs path 2023-12-24 18:56:43 +01:00
defnax
eb4a5a4e4d
Fix show messages on macos 2023-12-24 14:54:05 +01:00
defnax
1374d4520f
Merge branch 'RetroShare:master' into macos-guide 2023-12-24 14:51:58 +01:00
csoler
081782c97c
Merge pull request #2806 from defnax/macos-fixes
Added logo for retroshare-service on macOS
2023-12-23 18:02:43 +01:00
defnax
0ec569216b
Added cmake install to the guide 2023-12-23 09:23:53 +01:00
defnax
48510e3818
Added Feedreader include path for libxml2 2023-12-20 12:30:42 -08:00
defnax
50c6b4a8aa
Added needed feedreader depencies 2023-12-20 21:12:18 +01:00
defnax
419d3895be Added a dock menu for macOS 2023-12-19 18:58:16 +01:00
csoler
883d9f9b52
Merge pull request #2801 from csoler/v0.6-BugFixing_30
removed some debug output
2023-12-18 20:48:07 +01:00
defnax
6f982a20ba
Added logo for retroshare-service on macOS 2023-12-18 13:09:11 +01:00
defnax
6fb53d823e
Added icon for retroshare-service for the macOS platform #2802 2023-12-18 13:07:36 +01:00
PYRET1C
351855a5bd Merge branch 'new_token_service' of https://github.com/PYRET1C/RetroShare into new_token_service 2023-12-15 00:05:48 +05:30
PYRET1C
b9e7bb5457 added the new token service in more funcitons and resolved the crash on posting a pulse 2023-12-15 00:05:41 +05:30
Tushar Garg
74e0692f69
Merge branch 'RetroShare:master' into new_token_service 2023-12-15 00:03:01 +05:30
csoler
852ddb96d8
Merge pull request #2763 from defnax/wirecroppicture
[Wire] Fix to hide picture browse button on republish & like view
2023-12-11 22:05:12 +01:00
csoler
7decd2b7b0 removed some debug output 2023-12-11 21:51:17 +01:00
csoler
d27616f28b
Merge pull request #2797 from defnax/improve-macosdoc
Improved macos guide
2023-12-08 21:33:08 +01:00
defnax
e00e94e87f
fix for line 2023-12-05 12:46:06 +01:00
defnax
493f89643c
Update MacOS_X_InstallGuide.md 2023-12-05 11:49:19 +01:00
defnax
ec35e74400
fix last commit 2023-12-01 22:31:01 +01:00
defnax
6fffb322ae
Improved makeOSXPackage.sh file
* Added to ship sounds dir
* Added CFBundleVersion & CFBundleShortVersionString string
* Added to get Git head string for package naming
2023-12-01 22:26:44 +01:00
defnax
31552b1119
Update MacOS_X_InstallGuide.md 2023-11-29 15:32:16 +01:00
defnax
5ee6f6a2e8
Update XCode part 2023-11-29 12:36:23 +01:00
Gioacchino Mazzurco
463a25a048
Update OBS submodule 2023-11-28 22:47:59 +01:00
Gioacchino Mazzurco
67762c1eb0
More attempts at fixing GitlabCI
See https://forum.gitlab.com/t/docker-dind-stops-working-after-12-1-0-update/28664/11
2023-11-27 02:08:21 +01:00
Gioacchino Mazzurco
3f40837b1c
Fix GitlabCI and improve CMake support
Do not use mirrors which may be out of sync
2023-11-27 00:06:12 +01:00
Gioacchino Mazzurco
678357ab2a
Update libretroshare submodule 2023-11-26 22:53:35 +01:00
Gioacchino Mazzurco
ea943369a0
Update libretroshare submodule 2023-11-26 21:56:37 +01:00
csoler
a1fdce2e58
Merge pull request #2795 from thunder2/fix-git-describe
Changed automatic version numbering with "git describe" to split the …
2023-11-26 18:21:38 +01:00
defnax
331cc2e374
added new improved macos package file 2023-11-26 18:09:56 +01:00
defnax
9ae8c7a196
Improved masos compile guide 2023-11-26 18:07:06 +01:00
Gioacchino Mazzurco
c0e564517e
Add script to ease tag cleanup for every developers 2023-11-26 09:52:25 +01:00
Gioacchino Mazzurco
e0873687a2
Update submodules and gitignore 2023-11-26 09:30:52 +01:00
thunder2
441ba17b53 Changed automatic version numbering with "git describe" to split the third part into mini version (leading numbers) and extra version (string after the numbers) 2023-11-26 00:19:59 +01:00
csoler
951be8f9a1 updated to latest commits in submodules 2023-11-25 17:25:16 +01:00
Gioacchino Mazzurco
737eecad9e
retroshare-service CMake fix icons install path 2023-11-20 11:29:13 +01:00
csoler
95ad01c4db
Merge pull request #2790 from defnax/Ui-fixes
UI fixes
2023-11-19 17:25:25 +01:00
csoler
8d243b964f
Merge pull request #2787 from defnax/master-2
Fixed led labels
2023-11-19 17:21:44 +01:00
csoler
6c22125980
Merge pull request #2788 from csoler/v0.6-BugFixing_30
attempt to fix bug in closing GxsChannelComment feed item
2023-11-19 17:21:14 +01:00
csoler
45c701c8e8 removed debug output 2023-11-19 17:16:48 +01:00
csoler
929c04edd5 fixing channel comment feed item crash 2023-11-18 23:46:32 +01:00
defnax
69a84c94a2
Cosmetic layout fixes 2023-11-17 17:10:18 +01:00
csoler
6555cc5792 attempt to fix bug in closing GxsChannelComment feed item 2023-11-17 14:10:14 +01:00
defnax
902f278a19
Fixed led labels 2023-11-15 20:42:56 +01:00
Gioacchino Mazzurco
533e711d47
Merge branch 'master' of github.com:RetroShare/RetroShare 2023-11-15 09:37:47 +01:00
csoler
0e48422d1f updated retroshare to latest libretroshare 2023-11-12 12:07:56 +01:00
csoler
470a104418 updated Retroshare to the latest submodule commits 2023-11-12 11:23:54 +01:00
csoler
746bac8325
Merge pull request #2786 from csoler/v0.6-BugFixing_30
cleaning up debug info
2023-11-12 11:20:28 +01:00
csoler
9db3208f72 improved colored output on login 2023-11-11 23:51:14 +01:00
csoler
48da2d195a removed some debug output 2023-11-11 23:51:13 +01:00
thunder2
2c8e7d2a51 Updated OpenSSL to 1.1.1w in Windows native build 2023-11-10 22:36:24 +01:00
thunder2
bc125a75bf Fixed download of msys2 during Windows build 2023-11-10 22:36:23 +01:00
csoler
b30b575955
Merge pull request #2783 from csoler/v0.6-BugFixing_30
cleaning up webui/jsonapi interaction code
2023-11-07 22:10:39 +01:00
csoler
97fe92d1e7 updated master branch of Retroshare/ to latest commits in master branches of OBS and libretroshare 2023-11-07 14:05:39 +01:00
thunder2
eb7e2ec8e6 Enabled ANSI color support in Windows console for retroshare-service 2023-11-06 23:04:48 +01:00
thunder2
cd81d69357 Removed not needed files of tor from Windows installer 2023-11-06 23:04:33 +01:00
thunder2
befc473624 Fixed download of tor in Windows native build 2023-11-06 23:04:09 +01:00
csoler
a64fda1fb8 improved user commandline webui startup user experience 2023-11-05 16:10:42 +01:00
csoler
53313670f5 cleaning up webui/jsonapi interaction code 2023-11-04 23:41:49 +01:00
csoler
adf5a41a77
Merge pull request #2782 from csoler/v0.6-BugFixing_30
fixed colored output
2023-11-03 17:54:02 +01:00
csoler
62513a0d23 made initialization of webui as early as possible to avoir the need to restart jsonapi 2023-11-01 22:08:51 +01:00
csoler
fb78591baf fixed colored output 2023-11-01 15:52:02 +01:00
csoler
999fc143bf
Merge pull request #2780 from defnax/service-text-coloring
update output colors
2023-11-01 14:04:22 +01:00
csoler
9f0134f32d
Merge pull request #2781 from csoler/v0.6-BugFixing_30
GUI fixes
2023-11-01 13:56:02 +01:00
defnax
c502b0df06 coloring hidden outputs 2023-10-30 22:43:17 +01:00
csoler
b02acfae4b fixed missing event handler registration 2023-10-29 21:06:09 +01:00
csoler
ab61149cb1 fixed missing event handler registration 2023-10-29 21:05:02 +01:00
csoler
55651e73d9 made ConnectFriendWizard to accept retroshare links 2023-10-29 20:47:00 +01:00
defnax
ab7deede57 clean the color code from the text 2023-10-29 18:24:25 +01:00
csoler
315fb77d63 fixed forum and chnanel group feed items reacting to changes to the channel/forum group 2023-10-28 21:03:21 +02:00
defnax
36282e750d update output colors 2023-10-26 18:31:37 +02:00
csoler
c52e84d709
Merge pull request #2778 from defnax/service-text-coloring
Added colors for the service output
2023-10-25 23:09:45 +02:00
defnax
9f89ac42e7 Fix spacing 2023-10-25 12:13:15 +02:00
defnax
8814cbd9f2 color improvements for accounts display 2023-10-25 11:54:51 +02:00
defnax
168f36bc21 Added colors for the output 2023-10-24 22:44:40 +02:00
csoler
71a096f817
Merge pull request #2777 from csoler/v0.6-BugFixing_30
fixed non working expand button in forum feed
2023-10-21 14:48:31 +02:00
csoler
d26f7db319 fixed non working expand button in forum feed 2023-10-21 14:35:47 +02:00
Gioacchino Mazzurco
98c27fcf6d
Update libretroshare submodule 2023-10-18 18:57:11 +02:00
Gioacchino Mazzurco
d84b981e9a
Update libsam3 submodule 2023-10-18 18:56:04 +02:00
Gioacchino Mazzurco
e67abc36af
Update OBS submodule 2023-10-18 12:23:32 +02:00
Gioacchino Mazzurco
9b7149f16e
Update OBS submodule 2023-10-18 11:44:58 +02:00
Gioacchino Mazzurco
eab5c4bf4c
Updated gui build script according to new friendserver naming 2023-10-18 10:36:19 +02:00
Gioacchino Mazzurco
9d406ba26f
Fix inconsistence in friendserver QMake build option naming 2023-10-18 10:34:17 +02:00
Gioacchino Mazzurco
ededce7bd6
Merge branch 'master' of github.com:RetroShare/RetroShare 2023-10-13 18:56:00 +02:00
Gioacchino Mazzurco
e9d4cacac5
Attempt to fix udp-discovery-cpp submodule ref 2023-10-13 18:55:01 +02:00
csoler
5db6eb0359 updated retroshare base dir to latest version of libretroshare 2023-10-12 21:03:00 +02:00
csoler
7eb08c8706
Merge pull request #2776 from csoler/v0.6-BugFixing_30
Small Bug Fixing
2023-10-12 20:21:36 +02:00
csoler
d8bca5c56d removed some debug output 2023-10-12 20:18:53 +02:00
csoler
d83709d519 fixed implicit type warning 2023-10-12 20:18:36 +02:00
csoler
7a873c3b53 fixed compilation on ubuntu 18.04 2023-10-12 20:18:21 +02:00
csoler
606baf6f3e updated webui, libbitdht and libretroshare to latest submodule commit 2023-10-08 23:49:16 +02:00
csoler
6d105680d6
Merge pull request #2775 from csoler/v0.6-BugFixing_30
Bug fixing
2023-09-27 19:33:59 +02:00
csoler
96ae492bad
Merge pull request #2774 from csoler/v0.6-BugFixing_31
Quick bug fix in friend list.
2023-09-27 19:33:23 +02:00
csoler
712c7e5fb1 Merge remote-tracking branch 'upstream/master' into v0.6-BugFixing_30 2023-09-24 19:50:41 +02:00
csoler
a99f686fd1 restricted SPAM/STAR/TAGS to inbox, and made msg summary list refer to current box only 2023-09-23 17:53:12 +02:00
csoler
41069a0fa5 added missing removal of event handler in jsonapi and webui settings 2023-09-23 17:31:24 +02:00
csoler
7c90a2365c
Merge pull request #2772 from csoler/v0.6-BugFixing_30
Improved JsonApi / WebUI interaction
2023-09-22 22:55:41 +02:00
csoler
034bddf1ef made registered services list non editable 2023-09-22 22:50:45 +02:00
csoler
4cb36a5b69
Merge pull request #2769 from defnax/thumbnailfixchannelpost
Fix transparency for channel post thumbnails
2023-09-19 15:19:21 +02:00
csoler
11c07cd7c3 moved endResetModel() call to the endof internal data update in RsFriendListModel 2023-09-19 15:10:29 +02:00
csoler
0e0430a222 added more debug info to comment tree widget 2023-09-19 15:08:52 +02:00
csoler
b606b26dd3 fixed double allocation of webui page 2023-09-15 20:15:29 +02:00
csoler
5251427cbf improved webui and jsonapi config pages 2023-09-12 22:28:54 +02:00
csoler
5e62af44e5 fixed compilation 2023-09-12 13:50:43 +02:00
csoler
7e9a5a4244
Merge pull request #2352 from RetroPooh/keyring1
keyring - fix removing accepted keys; allow multi-select
2023-09-12 09:44:16 +02:00
csoler
c1bf4fb27f
Merge branch 'master' into keyring1 2023-09-12 09:43:13 +02:00
csoler
c877a6e5c8 improved login of on/off and parameter display in webui/jsonapi config pages 2023-09-11 22:55:42 +02:00
defnax
d5088caac6 fix second part for transparency check 2023-09-11 21:54:54 +02:00
csoler
d83f0125f3 improved UI of webUI and JsonAPI and interaction between these two (unfinished) 2023-09-10 17:49:51 +02:00
thunder2
d0b4bfdaa1 Fixed Linux compile of FeedReader plugin 2023-09-10 15:25:13 +02:00
csoler
c90fab0136 added help for JSON API page 2023-09-08 20:48:54 +02:00
defnax
43afcf3f98 Fix to use RGBA32 2023-09-05 21:10:38 +02:00
csoler
313bbaaae2
Merge pull request #2771 from csoler/v0.6-BugFixing_30
fixed bug in ModelIndex creation in channel post view, and implemented arrow key navigation
2023-09-05 16:51:14 +02:00
csoler
8a20ab33b4 fixed bug in ModelIndex creation in channel post view, and implemented arrow key navigation 2023-09-04 21:58:45 +02:00
csoler
f8a38aa821
Merge pull request #2770 from csoler/v0.6-BugFixing_30
V0.6 bug fixing 30
2023-09-01 09:08:36 +02:00
csoler
0ed32eb597 removed export menu entry (duplicates functionality, and wasnt connected anyway) 2023-08-31 23:27:18 +02:00
csoler
013786a7b7 disabled external port+address on auto-tor mode 2023-08-31 23:18:24 +02:00
csoler
d80951cd53 added missing comment 2023-08-31 23:18:06 +02:00
defnax
1efed9d436 Fix transparency for channel post thumbnails 2023-08-29 14:28:18 +02:00
csoler
17562e727e
Merge pull request #2764 from csoler/v0.6-BugFixing_30
Bug fixing
2023-08-27 16:28:22 +02:00
PYRET1C
5433e85323 added the new token service in this file 2023-08-20 18:19:05 +05:30
csoler
811b3b3658 fixed bug not showing icons/text button on loading 2023-08-18 13:21:28 +02:00
defnax
1b8bee4262 Removed hardcorded stylesheet from PulseReplySeperator
* Fixed some dark style issues
2023-08-15 23:12:54 +02:00
defnax
3a07a268ca Added to store last used group filter 2023-08-15 21:57:42 +02:00
csoler
fd9f31987d attempt at fixing crash with gtk2 style when the proper environment variable is not set 2023-08-15 21:14:32 +02:00
csoler
eeacb4500d removed some debug output 2023-08-15 21:13:53 +02:00
csoler
e8872c6780
Merge pull request #2761 from csoler/v0.6-BugFixing_30
bug fixing
2023-08-15 19:42:46 +02:00
defnax
4a20e1b4d2 Fix to hide picture browse button on republish & like view
* Fix to hide picture browse button on republish & like view
2023-08-14 21:27:46 +02:00
csoler
685cc29415
Merge pull request #2758 from defnax/wirecroppicture
[Wire] Added crop picture feature for wire background picture
2023-08-11 09:52:18 +02:00
csoler
f6bcfb549a made delete button and delete menu item call the same functions, so as to make the actions identical 2023-08-10 23:41:51 +02:00
csoler
234a510d6f fixed possible crash in channel feed item being deleted during async loading 2023-08-10 23:28:03 +02:00
csoler
e5b111c8bb
Merge pull request #2760 from csoler/v0.6-BugFixing_30
added "copy http link" action to board posts when applicable
2023-08-07 14:48:34 +02:00
csoler
a81caa3ac1 added comment about latest changes 2023-08-06 23:18:12 +02:00
csoler
a382d58b68 fixed icon in To column of Sent box 2023-08-06 23:12:06 +02:00
csoler
3fa0b8f6d4 fixed tooltip for popularity and items in boards 2023-08-04 13:57:34 +02:00
csoler
e54322521e fixed popularity and items at friends in Board details dialog 2023-08-04 13:52:27 +02:00
csoler
46e8db7d6d fixing crash when deleting forum feed items while loading 2023-08-03 20:22:30 +02:00
csoler
5ca3b15188 added "copy http link" action to board posts when possible 2023-08-03 18:41:31 +02:00
csoler
39ae560885
Merge pull request #2759 from csoler/v0.6-BugFixing_30
GUI bug fixing
2023-07-31 20:03:40 +02:00
csoler
24dd71d15f fixed open file / preview file in TransfersDialog 2023-07-30 20:51:51 +02:00
csoler
583431852c fixed copy comment in channels/post/comment (and GXS comments in general) 2023-07-30 18:47:56 +02:00
csoler
4867d396fe
Merge pull request #2757 from csoler/v0.6-BugFixing_30
bug fixing in UI
2023-07-25 23:21:16 +02:00
defnax
311ac03790 Update wire-notify.svg 2023-07-25 20:33:09 +02:00
csoler
ade297f257 attempt at fixing unread msg count to display before GXS service tab is displayed 2023-07-24 23:45:12 +02:00
defnax
74049d1b22 Added crop picture feature for wire background picture
* Added crop picture feature for wire background picture
* Fix smooth transformation for pixmaps
* Added stylesheet for label_masthead
* Edit profile on profile page feature
* New svg icons for wire
2023-07-24 23:19:17 +02:00
csoler
1512819200 fixed compilation on arch 2023-07-24 18:35:21 +02:00
csoler
7a4558a3da added missing change in previous commit 2023-07-24 18:35:05 +02:00
csoler
5c52509e27
Merge pull request #2754 from csoler/v0.6-BugFixing_30
Various bug fixes
2023-07-19 20:35:11 +02:00
csoler
10feb45bce fixed Board posts links copy on right-click 2023-07-18 20:03:46 +02:00
csoler
030bc46d26 fixed sorting of TO column in Sent mails 2023-07-18 15:15:21 +02:00
thunder2
13ff7f4e65 Fixed Linux compile of TheWire 2023-07-18 14:34:08 +02:00
csoler
7a3c9f7efe
Merge pull request #2746 from PYRET1C/edit_account
This commit gives the edit account feature in the wire.
2023-07-17 09:40:30 +02:00
PYRET1C
cbe4fca9ae just making the actual path to relative path. 2023-07-15 19:36:48 +05:30
csoler
584dd64308
Merge pull request #2749 from csoler/v0.6-BugFixing_30
Bug fixing in channels post files
2023-07-04 22:16:00 +02:00
PYRET1C
59c6eabad9 Revert "Changes to the .pro file for the newly made files."
This reverts commit 3cc077ff38.

This commit adds the new files to the .pro file.
2023-07-02 12:48:38 +05:30
PYRET1C
680c1942df Revert "Changes to the .pro file for the newly made files."
This reverts commit 3cc077ff38.

bad commit
2023-07-02 11:29:02 +05:30
PYRET1C
3cc077ff38 Changes to the .pro file for the newly made files. 2023-07-02 10:42:40 +05:30
csoler
b4d6a7b4e4 fixed sorting of files in channels/post/files 2023-07-01 23:18:51 +02:00
csoler
d95518d17e fixed DL output path in DL list 2023-07-01 18:06:12 +02:00
csoler
fe8c81e84a fixed open file / open dir in channel/post/files 2023-07-01 00:00:46 +02:00
csoler
df68d03953 fixed item not switching to "Open/Play" when DL is finished in channel/post/files 2023-06-30 17:24:55 +02:00
csoler
bb533eefc8
Merge pull request #2747 from csoler/v0.6-BugFixing_30
2 important fixes
2023-06-29 14:23:36 +02:00
csoler
a782122742 fixed copy file link in channel post files 2023-06-28 21:48:07 +02:00
PYRET1C
ae855098cf This commit gives the edit account feature in the wire. 2023-06-27 22:16:37 +05:30
csoler
afba23882e stop GxsGroupFrameDialog from stealing the focus on summary update 2023-06-27 14:00:04 +02:00
csoler
463383e25c auto-switch to progressive instead of random when the user doesnt want random FT strategy. Added more info about this. 2023-06-26 21:07:48 +02:00
csoler
a75133d554
Merge pull request #2745 from csoler/v0.6-BugFixing_30
removed question before sending invite, since the request is not in auto mode
2023-06-24 20:49:22 +02:00
csoler
c278239f97 added warning about random FT strategy on windows 2023-06-20 21:57:51 +02:00
csoler
438489fb01 removed question before sending invite, since the request is not in auto mode 2023-06-20 21:27:41 +02:00
csoler
7fb0fb49f1
Merge pull request #2743 from csoler/v0.6-BugFixing_30
fixed uninitialized memory read in FileDetail struct causing weird dates in search dialog
2023-06-13 11:12:39 +02:00
csoler
9bbc832906 added missing initialization of "trust friends with banned files" checkbox 2023-06-04 21:30:26 +02:00
csoler
e8187dbeab moved FileDetail structure in SearchDialog where it belongs 2023-06-04 17:59:17 +02:00
csoler
2a1991fe85 Merge remote-tracking branch 'upstream/master' into v0.6-BugFixing_30 2023-06-04 16:48:42 +02:00
csoler
0c9b086bd1 added missing handle to modify mTrustFriendNodesWithBannedFiles 2023-06-04 15:12:23 +02:00
csoler
3185829219
Merge pull request #2742 from csoler/v0.6-ChannelsGUI_03
fixed sorting of files->status in channels all files list
2023-06-03 23:52:56 +02:00
csoler
3f8e8805a2 fixed uninitialized memory read in FileDetail struct causing weird dates in search dialog 2023-06-03 23:51:31 +02:00
csoler
0f41d8bf46 fixed sorting of files->status in channels all files list 2023-06-01 20:30:19 +02:00
RetroPooh
47d89a6959 keyring - make accepted keys removing correct; allow multi-select 2021-02-22 21:43:42 +03:00
752 changed files with 84633 additions and 80175 deletions

83
.github/workflows/ci-macOS.yml vendored Normal file
View File

@ -0,0 +1,83 @@
name: macOS Build
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
concurrency:
group: ${{ github.workflow}}-${{ github.head_ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
build:
runs-on: macos-14
permissions:
actions: write
defaults:
run:
shell: bash
steps:
- name: Setup XCode
uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: 15.0.1
- name: Show current version of Xcode
run: xcodebuild -version
- name: Checkout repository
uses: actions/checkout@v4
with:
persist-credentials: false
- name: Setup Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@main
- name: Show OpenSSL version
run: pkg-config --cflags libcrypto
- name: Install Packages
run: brew install openssl
miniupnpc
rapidjson
sqlcipher
bzip2
zlib
botan@2
libxslt
libxml2
qt
- name: Checkout submodules
run: |
env
git submodule update --init --remote libbitdht/ libretroshare/ retroshare-webui/
git submodule update --init supportlibs/librnp supportlibs/rapidjson supportlibs/restbed openpgpsdk/
- name: CI-Build
run: |
qmake6 . -r "CONFIG+=rs_macos14.0" "CONFIG+=release" "CONFIG+=rs_autologin" "CONFIG+=no_rs_sam3" "CONFIG+=no_rs_sam3_libsam3" "CONFIG+=rs_no_rnplib" \
INCLUDEPATH+="/opt/homebrew/opt/openssl@3/include" \
INCLUDEPATH+="/opt/homebrew/opt/rapidjson/include" \
INCLUDEPATH+="/opt/homebrew/opt/sqlcipher/include" \
INCLUDEPATH+="/opt/homebrew/opt/miniupnpc/include" \
INCLUDEPATH+="/opt/homebrew/opt/libxslt/include" \
INCLUDEPATH+="/opt/homebrew/opt/libxml2/include" \
QMAKE_LIBDIR+="/opt/homebrew/opt/openssl@3/lib" \
QMAKE_LIBDIR+="/opt/homebrew/opt/rapidjson/lib" \
QMAKE_LIBDIR+="/opt/homebrew/opt/sqlcipher/lib" \
QMAKE_LIBDIR+="/opt/homebrew/opt/miniupnpc/lib" \
QMAKE_LIBDIR+="/opt/homebrew/opt/libxslt/lib" \
QMAKE_LIBDIR+="/opt/homebrew/opt/libxml2/lib" \
CONFIG+=no_retroshare_service \
CONFIG+=no_retroshare_friendserver
make

76
.github/workflows/ci-mingw64-Qt6.yml vendored Normal file
View File

@ -0,0 +1,76 @@
name: MINGW64 Qt6 Build
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
concurrency:
group: ${{ github.workflow}}-${{ github.head_ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
build:
runs-on: windows-latest
permissions:
actions: write
defaults:
run:
shell: msys2 {0}
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
persist-credentials: false
- name: Setup MSYS2
uses: msys2/setup-msys2@40677d36a502eb2cf0fb808cc9dec31bf6152638 # v2.28.0
with:
msystem: MINGW64
update: true
install: >-
base-devel
git
wget
p7zip
gcc
perl
ruby
doxygen
cmake
mingw-w64-x86_64-toolchain
mingw-w64-x86_64-miniupnpc
mingw-w64-x86_64-libxslt
mingw-w64-x86_64-xapian-core
mingw-w64-x86_64-sqlcipher
mingw-w64-x86_64-qt6-base
mingw-w64-x86_64-qt6-multimedia
mingw-w64-x86_64-qt6
mingw-w64-x86_64-ccmake
mingw-w64-x86_64-rapidjson
mingw-w64-x86_64-json-c
mingw-w64-x86_64-libbotan
mingw-w64-x86_64-asio
- name: Checkout submodules
run: |
env
git submodule update --init --remote libbitdht/ libretroshare/ retroshare-webui/
git submodule update --init supportlibs/librnp supportlibs/rapidjson supportlibs/restbed
- name: Workaround librnp strlen build regression
run: |
FILE="supportlibs/librnp/src/lib/crypto/mem.cpp"
grep -q '#include <cstring>' "$FILE" || sed -i '/#include <cstdio>/a #include <cstring>' "$FILE"
- name: Build
run: |
qmake6 . -r -spec win32-g++ "CONFIG+=release" "CONFIG+=rs_autologin" "CONFIG+=no_rs_sam3" "CONFIG+=no_rs_sam3_libsam3"
mingw32-make -j3

75
.github/workflows/ci-mingw64.yml vendored Normal file
View File

@ -0,0 +1,75 @@
name: MINGW64 Qt5 Build
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
concurrency:
group: ${{ github.workflow}}-${{ github.head_ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
build:
runs-on: windows-latest
permissions:
actions: write
defaults:
run:
shell: msys2 {0}
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
persist-credentials: false
- name: Setup MSYS2
uses: msys2/setup-msys2@40677d36a502eb2cf0fb808cc9dec31bf6152638 # v2.28.0
with:
msystem: MINGW64
update: true
install: >-
base-devel
git
wget
p7zip
gcc
perl
ruby
doxygen
cmake
mingw-w64-x86_64-toolchain
mingw-w64-x86_64-miniupnpc
mingw-w64-x86_64-libxslt
mingw-w64-x86_64-xapian-core
mingw-w64-x86_64-sqlcipher
mingw-w64-x86_64-qt5-base
mingw-w64-x86_64-qt5-multimedia
mingw-w64-x86_64-ccmake
mingw-w64-x86_64-rapidjson
mingw-w64-x86_64-json-c
mingw-w64-x86_64-libbotan
mingw-w64-x86_64-asio
- name: Checkout submodules
run: |
env
git submodule update --init --remote libbitdht/ libretroshare/ retroshare-webui/
git submodule update --init supportlibs/librnp supportlibs/rapidjson supportlibs/restbed
- name: Workaround librnp strlen build regression
run: |
FILE="supportlibs/librnp/src/lib/crypto/mem.cpp"
grep -q '#include <cstring>' "$FILE" || sed -i '/#include <cstdio>/a #include <cstring>' "$FILE"
- name: CI-Build
run: |
qmake-qt5.exe . -r -spec win32-g++ "CONFIG+=release" "CONFIG+=rs_autologin" "CONFIG+=no_rs_sam3" "CONFIG+=no_rs_sam3_libsam3"
mingw32-make -j3

89
.github/workflows/macos-cmake-qt6.yml vendored Normal file
View File

@ -0,0 +1,89 @@
# macOS CMake CI for the RetroShare super-project built against Qt6.
#
# Qt6 counterpart of macos-cmake.yml. Same whole-tree build and Homebrew flag
# harvesting, but installs the `qt` formula (Qt6, which bundles qt5compat, svg,
# multimedia and tools) instead of qt@5, and builds with plugins OFF (VOIP still
# uses the Qt5-era QtMultimedia API; out of scope for this migration).
#
# Submodules are initialised WITHOUT --remote so libretroshare stays on its
# pinned, CMake-enabled commit.
#
# SPDX-License-Identifier: AGPL-3.0-or-later
name: macOS CMake C/C++ CI (Qt6)
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
build:
name: macOS 14 / Qt6 / CMake
runs-on: macos-14
defaults:
run:
shell: bash
steps:
- uses: actions/checkout@v5
with:
persist-credentials: false
# Same pinned-commit init as the Ubuntu CMake CI (no --remote); librnp needs
# --recursive for its nested src/libsexpp.
- name: Init submodules (pinned commits)
run: |
git submodule update --init \
libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/
git submodule update --init --recursive \
supportlibs/librnp
git submodule update --init \
supportlibs/restbed supportlibs/libsam3 \
supportlibs/udp-discovery-cpp supportlibs/rapidjson
git --no-pager -C libretroshare log --max-count 1 --oneline
- name: Install Homebrew dependencies
run: >
brew install
ninja qt openssl@3 botan@2 sqlcipher miniupnpc
json-c asio speex speexdsp ffmpeg
libxml2 libxslt bzip2 zlib rapidjson doxygen
# Mirrors the validated local macOS command: harvest every Homebrew opt/*
# include/lib dir into the compiler/linker flags, and additionally expose them
# to find_package() via CMAKE_PREFIX_PATH (needed for keg-only botan@2…).
- name: CMake configure
run: |
HB="$(brew --prefix)"
QT6="$(brew --prefix qt)"
IFLAGS="-I$HB/include"; for d in "$HB"/opt/*/include; do IFLAGS="$IFLAGS -I$d"; done
LFLAGS="-L$HB/lib"; for d in "$HB"/opt/*/lib; do LFLAGS="$LFLAGS -L$d"; done
# qt (Qt6) first so find_package(QT NAMES Qt6 Qt5) resolves to this config.
PREFIX="$QT6;$HB"; for d in "$HB"/opt/*; do PREFIX="$PREFIX;$d"; done
cmake -G Ninja -B Build-cmake -S . \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_PREFIX_PATH="$PREFIX" \
-DQt6_DIR="$QT6/lib/cmake/Qt6" \
-DOPENSSL_ROOT_DIR="$(brew --prefix openssl@3)" \
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON \
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON -DRS_PLUGINS=OFF -DRS_FORUM_DEEP_INDEX=OFF \
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON \
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON \
-DCMAKE_C_FLAGS="$IFLAGS" -DCMAKE_CXX_FLAGS="$IFLAGS" \
-DCMAKE_EXE_LINKER_FLAGS="$LFLAGS" \
-DCMAKE_SHARED_LINKER_FLAGS="$LFLAGS" \
-DCMAKE_MODULE_LINKER_FLAGS="$LFLAGS"
- name: CMake build
run: cmake --build Build-cmake -j$(sysctl -n hw.ncpu)

90
.github/workflows/macos-cmake.yml vendored Normal file
View File

@ -0,0 +1,90 @@
# macOS CMake CI for the RetroShare super-project (root aggregate build).
#
# CMake counterpart of the legacy qmake ci-macOS.yml. Unlike that one (which
# disables service/friendserver/sam3/rnp), this builds the WHOLE tree with the
# same feature set as the Linux CMake CI, using the user's validated local macOS
# command (Homebrew -I/-L flag harvesting).
#
# Submodules are initialised WITHOUT --remote (identical to ubuntu-cmake.yml) so
# libretroshare stays on its pinned, CMake-enabled commit.
#
# SPDX-License-Identifier: AGPL-3.0-or-later
name: macOS CMake C/C++ CI
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
build:
name: macOS 14 / Qt5 / CMake
runs-on: macos-14
defaults:
run:
shell: bash
steps:
- uses: actions/checkout@v5
with:
persist-credentials: false
# Same pinned-commit init as the Ubuntu CMake CI (no --remote); librnp needs
# --recursive for its nested src/libsexpp.
- name: Init submodules (pinned commits)
run: |
git submodule update --init \
libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/
git submodule update --init --recursive \
supportlibs/librnp
git submodule update --init \
supportlibs/restbed supportlibs/libsam3 \
supportlibs/udp-discovery-cpp supportlibs/rapidjson
git --no-pager -C libretroshare log --max-count 1 --oneline
- name: Install Homebrew dependencies
run: >
brew install
ninja qt@5 openssl@3 botan@2 sqlcipher miniupnpc
json-c asio speex speexdsp ffmpeg
libxml2 libxslt bzip2 zlib rapidjson doxygen
# Mirrors the validated local macOS command: harvest every Homebrew opt/*
# include/lib dir into the compiler/linker flags, and additionally expose them
# to find_package() via CMAKE_PREFIX_PATH (needed for keg-only qt@5, botan@2…).
- name: CMake configure
run: |
HB="$(brew --prefix)"
QT5="$(brew --prefix qt@5)"
IFLAGS="-I$HB/include"; for d in "$HB"/opt/*/include; do IFLAGS="$IFLAGS -I$d"; done
LFLAGS="-L$HB/lib"; for d in "$HB"/opt/*/lib; do LFLAGS="$LFLAGS -L$d"; done
# qt@5 first so find_package(Qt5) picks the keg-only (correct) config, not a
# broken Qt5 config that may sit directly under the Homebrew prefix.
PREFIX="$QT5;$HB"; for d in "$HB"/opt/*; do PREFIX="$PREFIX;$d"; done
cmake -G Ninja -B Build-cmake -S . \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_PREFIX_PATH="$PREFIX" \
-DQt5_DIR="$QT5/lib/cmake/Qt5" \
-DOPENSSL_ROOT_DIR="$(brew --prefix openssl@3)" \
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON \
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON -DRS_PLUGINS=ON -DRS_FORUM_DEEP_INDEX=OFF \
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON \
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON \
-DCMAKE_C_FLAGS="$IFLAGS" -DCMAKE_CXX_FLAGS="$IFLAGS" \
-DCMAKE_EXE_LINKER_FLAGS="$LFLAGS" \
-DCMAKE_SHARED_LINKER_FLAGS="$LFLAGS" \
-DCMAKE_MODULE_LINKER_FLAGS="$LFLAGS"
- name: CMake build
run: cmake --build Build-cmake -j$(sysctl -n hw.ncpu)

30
.github/workflows/mirror-to-gitlab.yml vendored Normal file
View File

@ -0,0 +1,30 @@
name: Mirror to GitLab
on:
push:
branches:
- '**'
tags:
- '**'
workflow_dispatch:
jobs:
mirror:
runs-on: ubuntu-latest
steps:
- name: Install GitLab deploy key
uses: webfactory/ssh-agent@v0.9.0
with:
ssh-private-key: ${{ secrets.RETROSHARE_GITLAB_MIRROR_SSH_KEY }}
- name: Trust GitLab host key
run: |
ssh-keyscan gitlab.com >> ~/.ssh/known_hosts
- name: Mirror repository to GitLab
run: |
git clone --bare "https://github.com/${GITHUB_REPOSITORY}.git" repo.git
cd repo.git
git remote set-url --push origin git@gitlab.com:RetroShare/RetroShare.git
git push --prune origin 'refs/heads/*:refs/heads/*' 'refs/tags/*:refs/tags/*'

86
.github/workflows/ubuntu-cmake-qt6.yml vendored Normal file
View File

@ -0,0 +1,86 @@
# Ubuntu CMake CI for the RetroShare super-project built against Qt6.
#
# This is the Qt6 counterpart of ubuntu-cmake.yml (which builds against Qt5).
# It exercises the version-agnostic Qt detection added to
# retroshare-gui/CMakeLists.txt (find_package(QT NAMES Qt6 Qt5 ...)).
#
# Scope note: plugins are built OFF here. The VOIP plugin still uses the Qt5-era
# QtMultimedia API (QAudioInput/QAudioOutput/QCameraInfo, removed/redesigned in
# Qt6) and FeedReader's CMake still hardcodes Qt5; both are out of scope for the
# Qt6 GUI migration and are intentionally excluded until ported.
#
# As in ubuntu-cmake.yml, submodules are initialised WITHOUT --remote so the
# pinned, CMake-enabled commits are used.
#
# SPDX-License-Identifier: AGPL-3.0-or-later
name: Ubuntu CMake C/C++ CI (Qt6)
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true
jobs:
build:
name: Ubuntu 24.04 / Qt6 / CMake
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v5
# NOTE: no --remote here (on purpose) so the pinned, CMake-enabled commits
# are checked out. librnp needs --recursive for its nested src/libsexpp.
- name: Init submodules (pinned commits)
run: |
git submodule update --init \
libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/
git submodule update --init --recursive \
supportlibs/librnp
git submodule update --init \
supportlibs/restbed supportlibs/libsam3 \
supportlibs/udp-discovery-cpp supportlibs/rapidjson
git --no-pager -C libretroshare log --max-count 1 --oneline
- name: apt update
run: sudo apt-get update
- name: apt install build dependencies
run: >
sudo apt-get install -y
build-essential g++ cmake ninja-build pkg-config git
qt6-base-dev qt6-base-dev-tools qt6-multimedia-dev libqt6svg6-dev
qt6-5compat-dev libqt6core5compat6-dev qt6-tools-dev qt6-tools-dev-tools
libssl-dev zlib1g-dev libbz2-dev libbotan-2-dev libjson-c-dev
libasio-dev libsqlcipher-dev
libspeex-dev libspeexdsp-dev libminiupnpc-dev
libavcodec-dev libavutil-dev
libx11-dev libxss-dev
libxml2-dev libxslt1-dev libcurl4-openssl-dev
doxygen python3
- name: print working directory
run: pwd && ls -la
# Mirrors ubuntu-cmake.yml but selects Qt6 (qmake6 / Qt6 cmake config are the
# only Qt available on the runner) and keeps plugins OFF (see scope note).
- name: CMake configure
run: >
cmake -G Ninja -B Build-cmake -S .
-DCMAKE_POLICY_VERSION_MINIMUM=3.5
-DCMAKE_BUILD_TYPE=Release
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON
-DRS_PLUGINS=OFF -DRS_FORUM_DEEP_INDEX=OFF
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON
- name: CMake build
run: cmake --build Build-cmake -j$(nproc)

83
.github/workflows/ubuntu-cmake.yml vendored Normal file
View File

@ -0,0 +1,83 @@
# Ubuntu CMake CI for the RetroShare super-project (root aggregate build).
#
# This is the CMake counterpart of the legacy qmake workflows
# (ubuntu-qt5_c-cpp.yml / ubuntu-qt6_c-cpp.yml). It builds the WHOLE tree from
# the top-level CMakeLists.txt: libretroshare + retroshare-gui + service +
# friendserver + plugins, with the JSON API / WebUI enabled.
#
# Key difference vs the qmake CI: submodules are initialised WITHOUT --remote, so
# libretroshare stays on the commit pinned by this super-project (a CMake-enabled
# commit that lives on master). Using --remote would move it to the latest upstream
# tip and could pull a non-CMake state, breaking the build.
#
# SPDX-License-Identifier: AGPL-3.0-or-later
name: Ubuntu CMake C/C++ CI
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true
jobs:
build:
name: Ubuntu 22.04 / Qt5 / CMake
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v5
# NOTE: no --remote here (on purpose) so the pinned, CMake-enabled commits
# are checked out. librnp needs --recursive for its nested src/libsexpp.
- name: Init submodules (pinned commits)
run: |
git submodule update --init \
libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/
git submodule update --init --recursive \
supportlibs/librnp
git submodule update --init \
supportlibs/restbed supportlibs/libsam3 \
supportlibs/udp-discovery-cpp supportlibs/rapidjson
git --no-pager -C libretroshare log --max-count 1 --oneline
- name: apt update
run: sudo apt-get update
- name: apt install build dependencies
run: >
sudo apt-get install -y
build-essential g++ cmake ninja-build pkg-config git
qtbase5-dev qtbase5-dev-tools qtmultimedia5-dev libqt5svg5-dev
libqt5x11extras5-dev qttools5-dev qttools5-dev-tools
libssl-dev zlib1g-dev libbz2-dev libbotan-2-dev libjson-c-dev
libasio-dev libsqlcipher-dev
libspeex-dev libspeexdsp-dev libminiupnpc-dev
libavcodec-dev libavutil-dev
libx11-dev libxss-dev
libxml2-dev libxslt1-dev libcurl4-openssl-dev
doxygen python3
- name: print working directory
run: pwd && ls -la
# Mirrors the validated local Linux build command.
- name: CMake configure
run: >
cmake -G Ninja -B Build-cmake -S .
-DCMAKE_POLICY_VERSION_MINIMUM=3.5
-DCMAKE_BUILD_TYPE=Release
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON
-DRS_PLUGINS=ON -DRS_FORUM_DEEP_INDEX=OFF
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON
- name: CMake build
run: cmake --build Build-cmake -j$(nproc)

40
.github/workflows/ubuntu-qt5_c-cpp.yml vendored Normal file
View File

@ -0,0 +1,40 @@
name: Ubuntu Qt 5 C/C++ CI
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
jobs:
build:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: git init
run: git submodule update --init --remote libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/ && git --no-pager log --max-count 1
- name: git submodule supportlibs
run: git submodule update --init supportlibs/librnp supportlibs/restbed #supportlibs/rapidjson
- name: run apt update
run: sudo apt-get update
- name: apt install
run: sudo apt-get install g++ cmake qt5-qmake qtmultimedia5-dev libqt5x11extras5-dev libasio-dev libbz2-dev libjson-c-dev libssl-dev libsqlcipher-dev libupnp-dev libxss-dev rapidjson-dev libbotan-2-dev doxygen libsecret-1-dev libxml2-dev libxslt1-dev libcurl4-openssl-dev libavcodec-dev libavutil-dev libspeex-dev libspeexdsp-dev
- name: print working directory
run: pwd && ls -la
- name: qmake
run: |
qmake CONFIG+=debug \
CONFIG+=rs_autologin \
CONFIG+=rs_webui \
CONFIG+=rs_jsonapi \
CONFIG+=wikipoos \
CONFIG+=gxsthewire \
CONFIG+=retroshare_plugins
- name: make
run: make
- name: make check
run: make check

40
.github/workflows/ubuntu-qt6_c-cpp.yml vendored Normal file
View File

@ -0,0 +1,40 @@
name: Ubuntu Qt 6 C/C++ CI
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
jobs:
build:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- name: git init
run: git submodule update --init --remote libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/ && git --no-pager log --max-count 1
- name: git submodule supportlibs
run: git submodule update --init supportlibs/librnp supportlibs/restbed #supportlibs/rapidjson
- name: run apt update
run: sudo apt-get update
- name: apt install
run: sudo apt-get install g++ cmake qt6-base-dev qt6-multimedia-dev libasio-dev libbz2-dev libjson-c-dev libssl-dev libsqlcipher-dev libupnp-dev libxss-dev rapidjson-dev libbotan-2-dev doxygen qt6-5compat-dev libqt6core5compat6-dev libsecret-1-dev libxml2-dev libxslt1-dev libcurl4-openssl-dev
- name: print working directory
run: pwd && ls -la
- name: qmake
run: |
qmake6 CONFIG+=debug \
CONFIG+=rs_autologin \
CONFIG+=rs_webui \
CONFIG+=rs_jsonapi \
CONFIG+=wikipoos \
CONFIG+=gxsthewire \
CONFIG+=retroshare_plugins
- name: make
run: make
- name: make check
run: make check

109
.github/workflows/windows-cmake-qt6.yml vendored Normal file
View File

@ -0,0 +1,109 @@
# Windows (MSYS2 / UCRT64) CMake CI for the RetroShare super-project built against Qt6.
#
# Qt6 counterpart of windows-cmake.yml. Same whole-tree build and flags, but the
# UCRT64 toolchain installs the qt6-* packages (incl. qt6-5compat for the
# Core5Compat module my version-agnostic CMake requires) and plugins are OFF
# (VOIP still uses the Qt5-era QtMultimedia API; out of scope for this migration).
#
# Submodules are initialised WITHOUT --remote so libretroshare stays on its
# pinned, CMake-enabled commit.
#
# SPDX-License-Identifier: AGPL-3.0-or-later
name: Windows UCRT64 CMake C/C++ CI (Qt6)
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
build:
name: Windows UCRT64 / Qt6 / CMake
runs-on: windows-latest
defaults:
run:
shell: msys2 {0}
steps:
- name: Checkout repository
uses: actions/checkout@v5
with:
persist-credentials: false
- name: Setup MSYS2 (UCRT64)
uses: msys2/setup-msys2@40677d36a502eb2cf0fb808cc9dec31bf6152638 # v2.28.0
with:
msystem: UCRT64
update: true
install: >-
base-devel
git
perl
ruby
mingw-w64-ucrt-x86_64-toolchain
mingw-w64-ucrt-x86_64-doxygen
mingw-w64-ucrt-x86_64-cmake
mingw-w64-ucrt-x86_64-ninja
mingw-w64-ucrt-x86_64-python
mingw-w64-ucrt-x86_64-qt6-base
mingw-w64-ucrt-x86_64-qt6-multimedia
mingw-w64-ucrt-x86_64-qt6-svg
mingw-w64-ucrt-x86_64-qt6-5compat
mingw-w64-ucrt-x86_64-qt6-tools
mingw-w64-ucrt-x86_64-openssl
mingw-w64-ucrt-x86_64-libbotan
mingw-w64-ucrt-x86_64-sqlcipher
mingw-w64-ucrt-x86_64-miniupnpc
mingw-w64-ucrt-x86_64-json-c
mingw-w64-ucrt-x86_64-rapidjson
mingw-w64-ucrt-x86_64-asio
mingw-w64-ucrt-x86_64-libxml2
mingw-w64-ucrt-x86_64-libxslt
mingw-w64-ucrt-x86_64-speex
mingw-w64-ucrt-x86_64-speexdsp
mingw-w64-ucrt-x86_64-ffmpeg
mingw-w64-ucrt-x86_64-bzip2
mingw-w64-ucrt-x86_64-zlib
# Same pinned-commit init as the Ubuntu/macOS CMake CI (no --remote); librnp
# needs --recursive for its nested src/libsexpp.
- name: Init submodules (pinned commits)
run: |
git submodule update --init \
libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/
git submodule update --init --recursive \
supportlibs/librnp
git submodule update --init \
supportlibs/restbed supportlibs/libsam3 \
supportlibs/udp-discovery-cpp supportlibs/rapidjson
git --no-pager -C libretroshare log --max-count 1 --oneline
# Mirrors windows-cmake.yml (Ninja, shared libretroshare) but with Qt6 and
# plugins OFF.
- name: CMake configure
run: >
cmake -G Ninja -B Build-cmake -S .
-DCMAKE_POLICY_VERSION_MINIMUM=3.5
-DCMAKE_BUILD_TYPE=Release
-DRS_LIBRETROSHARE_STATIC=OFF -DRS_LIBRETROSHARE_SHARED=ON
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON
-DRS_PLUGINS=OFF -DRS_FORUM_DEEP_INDEX=OFF
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON
-DCMAKE_C_FLAGS="-include string.h -include stdint.h"
-DCMAKE_CXX_FLAGS="-include cstring -include cstdint -Wno-template-body"
- name: CMake build
run: cmake --build Build-cmake -j3

108
.github/workflows/windows-cmake.yml vendored Normal file
View File

@ -0,0 +1,108 @@
# Windows (MSYS2 / UCRT64) CMake CI for the RetroShare super-project.
#
# CMake counterpart of the legacy qmake ci-ucrt64.yml. Unlike that one (GUI-only,
# sam3 disabled, mingw32-make), this builds the WHOLE tree with the same feature
# set as the Linux/macOS CMake CIs, using Ninja and the user's validated local
# Windows command (shared libretroshare).
#
# Submodules are initialised WITHOUT --remote (identical to ubuntu-cmake.yml) so
# libretroshare stays on its pinned, CMake-enabled commit. On WIN32 libretroshare
# pulls restbed via FetchContent, so the restbed submodule is unused there.
#
# SPDX-License-Identifier: AGPL-3.0-or-later
name: Windows UCRT64 CMake C/C++ CI
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
build:
name: Windows UCRT64 / Qt5 / CMake
runs-on: windows-latest
defaults:
run:
shell: msys2 {0}
steps:
- name: Checkout repository
uses: actions/checkout@v5
with:
persist-credentials: false
- name: Setup MSYS2 (UCRT64)
uses: msys2/setup-msys2@40677d36a502eb2cf0fb808cc9dec31bf6152638 # v2.28.0
with:
msystem: UCRT64
update: true
install: >-
base-devel
git
perl
ruby
mingw-w64-ucrt-x86_64-toolchain
mingw-w64-ucrt-x86_64-doxygen
mingw-w64-ucrt-x86_64-cmake
mingw-w64-ucrt-x86_64-ninja
mingw-w64-ucrt-x86_64-python
mingw-w64-ucrt-x86_64-qt5-base
mingw-w64-ucrt-x86_64-qt5-multimedia
mingw-w64-ucrt-x86_64-qt5-svg
mingw-w64-ucrt-x86_64-qt5-tools
mingw-w64-ucrt-x86_64-openssl
mingw-w64-ucrt-x86_64-libbotan
mingw-w64-ucrt-x86_64-sqlcipher
mingw-w64-ucrt-x86_64-miniupnpc
mingw-w64-ucrt-x86_64-json-c
mingw-w64-ucrt-x86_64-rapidjson
mingw-w64-ucrt-x86_64-asio
mingw-w64-ucrt-x86_64-libxml2
mingw-w64-ucrt-x86_64-libxslt
mingw-w64-ucrt-x86_64-speex
mingw-w64-ucrt-x86_64-speexdsp
mingw-w64-ucrt-x86_64-ffmpeg
mingw-w64-ucrt-x86_64-bzip2
mingw-w64-ucrt-x86_64-zlib
# Same pinned-commit init as the Ubuntu/macOS CMake CI (no --remote); librnp
# needs --recursive for its nested src/libsexpp.
- name: Init submodules (pinned commits)
run: |
git submodule update --init \
libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/
git submodule update --init --recursive \
supportlibs/librnp
git submodule update --init \
supportlibs/restbed supportlibs/libsam3 \
supportlibs/udp-discovery-cpp supportlibs/rapidjson
git --no-pager -C libretroshare log --max-count 1 --oneline
# Mirrors the validated local Windows command (Ninja, shared libretroshare).
- name: CMake configure
run: >
cmake -G Ninja -B Build-cmake -S .
-DCMAKE_POLICY_VERSION_MINIMUM=3.5
-DCMAKE_BUILD_TYPE=Release
-DRS_LIBRETROSHARE_STATIC=OFF -DRS_LIBRETROSHARE_SHARED=ON
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON
-DRS_PLUGINS=ON -DRS_FORUM_DEEP_INDEX=OFF
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON
-DCMAKE_C_FLAGS="-include string.h -include stdint.h"
-DCMAKE_CXX_FLAGS="-include cstring -include cstdint -Wno-template-body"
- name: CMake build
run: cmake --build Build-cmake -j3

6
.gitignore vendored
View File

@ -21,7 +21,7 @@ Thumbs.db
!supportlibs/libsam3/Makefile
# QtCreator cruft
*CMakeLists.txt.user
*CMakeLists.txt.user*
# Build artifacts
/jsonapi-generator/src/jsonapi-generator
@ -35,3 +35,7 @@ Thumbs.db
/retroshare-gui/src/temp/
/retroshare-service/src/retroshare-service
/*.tar.?z
# Build artifacts
build/
.vscode/

View File

@ -1,7 +1,7 @@
image: docker:stable
image: docker:latest
services:
- docker:stable-dind
- docker:dind
stages:
- build
@ -18,6 +18,7 @@ variables:
build-ubuntu-test-image:
stage: build
script:
- docker --version
- >
docker login "$CI_REGISTRY"
--username "$CI_REGISTRY_USER"
@ -35,6 +36,7 @@ build-ubuntu-test-image:
test-ubuntu:
stage: test
script:
- docker --version
- >
docker login "$CI_REGISTRY"
--username "$CI_REGISTRY_USER"

16
.gitmodules vendored
View File

@ -10,7 +10,8 @@
[submodule "supportlibs/udp-discovery-cpp"]
path = supportlibs/udp-discovery-cpp
url = https://github.com/truvorskameikin/udp-discovery-cpp.git
branch = develop
branch = master
# develop branch was removed we were using it at commit f3a3103a6c52e5707629e8d0a7e279a7758fe845
[submodule "supportlibs/rapidjson"]
path = supportlibs/rapidjson
url = https://github.com/Tencent/rapidjson.git
@ -22,16 +23,21 @@
url = https://github.com/RetroShare/jni.hpp.git
[submodule "openpgpsdk"]
path = openpgpsdk
url = ../OpenPGP-SDK
url = https://github.com/RetroShare/OpenPGP-SDK.git
branch = master
[submodule "libbitdht"]
path = libbitdht
url = ../BitDHT
url = https://github.com/RetroShare/BitDHT.git
branch = master
[submodule "libretroshare"]
path = libretroshare
url = ../libretroshare
url = https://github.com/RetroShare/libretroshare.git
branch = master
[submodule "retroshare-webui"]
path = retroshare-webui
url = ../RSNewWebUI
url = https://github.com/RetroShare/RSNewWebUI.git
branch = master
[submodule "supportlibs/librnp"]
path = supportlibs/librnp
url = https://github.com/rnpgp/rnp.git
branch = main

469
BUILD-cmake.md Normal file
View File

@ -0,0 +1,469 @@
# RetroShare — CMake build (Linux / macOS / Windows)
Build commands for the whole tree from the root of the super-project. The
top-level `CMakeLists.txt` only *aggregates* the independent component projects
(libretroshare + GUI + service + friendserver + plugins) — each is a standalone
CMake project, buildable on its own. JSON API / WebUI enabled.
## Qt5 or Qt6
The build is **version-agnostic**: `retroshare-gui/CMakeLists.txt` probes Qt6
first (`find_package(Qt6 QUIET COMPONENTS Core)`) and falls back to Qt5, so the
same tree builds against **either** Qt5 or Qt6. When both are installed **Qt6 is
preferred**; force Qt5 with `-DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON`.
> Why an explicit probe and not `find_package(QT NAMES Qt6 Qt5 …)`: on
> Debian/Ubuntu multiarch (Qt5 and Qt6 both under `/usr/lib/<arch>/cmake`) the
> `NAMES` order is **not** honoured — CMake globs the sibling `Qt5*`/`Qt6*`
> config dirs and stops at whichever `…Config.cmake` it reaches first, which is
> filesystem-order dependent and routinely lands on Qt5 even with Qt6 listed
> first. The explicit Qt6 probe makes the preference deterministic, and is also
> what makes `-DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON` actually force a Qt5 build
> (with the versionless `QT` package name that switch had no effect).
Two deltas for a Qt6 build (everything else is identical):
- different Qt `-dev` packages (see each platform below);
- **`-DRS_PLUGINS=OFF`** — the VOIP plugin still uses the Qt5-era QtMultimedia API
(`QAudioInput`/`QAudioOutput`/`QCameraInfo`) and isn't ported to Qt6 yet;
FeedReader's CMake is also still Qt5-only.
Each configure below is prefixed with `rm -rf Build-cmake`, so the build dir is
recreated from scratch every time. This keeps switching between Qt5 and Qt6 in the
same `Build-cmake` clean (no stale `CMakeCache.txt` pinning the previous Qt
version). Drop the `rm -rf` if you want an incremental rebuild instead.
Validated by the CMake CI:
`.github/workflows/{ubuntu,macos,windows}-cmake.yml` (Qt5) and the matching
`…-cmake-qt6.yml` (Qt6).
Other notes:
- `RS_FORUM_DEEP_INDEX=OFF` on purpose (Xapian unused; re-enabled later via the
ForumContentSearchFTS5 branch).
- Ninja is used on all three platforms for consistency.
- `RS_SERVICE_TERMINAL_WEBUI_PASSWORD=ON` is **required** for `retroshare-service`
to expose the `-W`/`-B` flags that enable and serve the WebUI. `RS_WEBUI=ON`
alone builds the WebUI machinery, but the service then has **no way to turn it
on** — `enableWebUI` defaults to false and only `-W` ever sets it, so the WebUI
never serves. It is a `cmake_dependent_option` requiring `RS_WEBUI=ON`.
## Submodules (init WITHOUT --remote)
`--remote` would move libretroshare off its pinned CMake commit and break the
build. librnp needs `--recursive` for its nested `src/libsexpp`.
```bash
git submodule update --init libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/
git submodule update --init --recursive supportlibs/librnp
git submodule update --init supportlibs/restbed supportlibs/libsam3 \
supportlibs/udp-discovery-cpp supportlibs/rapidjson
```
**rapidjson / GCC >= 13:** the commit pinned by the super-project (`f54b0e47`)
has a broken `GenericStringRef::operator=` that assigns to the `const` member
`length`, so it fails to compile on modern toolchains (e.g. Debian 13 / GCC 14)
with *"assignment of read-only member 'length'"*. Check out the upstream fix
commit (#719, on Tencent/rapidjson master):
```bash
git -C supportlibs/rapidjson fetch origin
git -C supportlibs/rapidjson checkout 9bd618f5
```
## Version numbering
Versions are **not** hard-coded — CMake derives them at configure time from
`git describe` run in each component's working tree, so what a build reports is
exactly what your local checkout resolves to. Three independent strings are
stamped in:
| String | Source command | CMake file |
|---|---|---|
| `RS_GUI_VERSION` — the GUI's own version (shown in *Help ▸ About*) | `git describe --tags --always --dirty` in the super-project, leading `v` stripped | `retroshare-gui/CMakeLists.txt` |
| libRetroShare version (`RS_MAJOR`/`RS_MINOR`/`RS_MINI` + `RS_EXTRA_VERSION`) | `git describe --tags --long --match 'v*.*.*'` in `libretroshare/`, parsed into `major.minor.mini` + trailing extra | `libretroshare/CMakeLists.txt` |
| `RS_LIB_VERSION_HASH` — engine build hash | `git describe --tags --always --dirty` in `libretroshare/`, leading `v` stripped | `libretroshare/CMakeLists.txt` |
The super-project's `describe` resolves to a `v0.6.7.x` tag; libretroshare's own
tags are `v0.6.7`. So a GUI version reads like `0.6.7.3-1112-gd6047eb5a` and the
engine like `0.6.7-548-g25845f94`, i.e. `<tag>-<commits since tag>-g<short hash>`.
To read the exact values a build **would** stamp, without building, run from the
super-project root:
```bash
git describe --tags --always --dirty
git -C libretroshare describe --tags --long --match 'v*.*.*'
```
The first line is `RS_GUI_VERSION` (drop the leading `v`); the second is the
libRetroShare version.
Notes:
- **`-dirty`** is appended whenever the working tree has *tracked* modifications
at configure time. Modified **submodule pointers count as tracked changes**, so
a tree that is otherwise clean apart from submodule drift still stamps `-dirty`
on the GUI/engine version. Untracked files never trigger it.
- libretroshare uses `--long`, which **always** prints the `-<N>-g<hash>` suffix —
even on a tagged commit you get `v0.6.7-0-g…`, never a bare `0.6.7`.
- Merging feature branches into an integration branch (e.g. `combo`) only grows
the `-<N>-` commit count and changes the `-g<hash>`; the `v0.6.7.x` / `v0.6.7`
tag prefix stays put. An octopus merge (one merge commit) yields a slightly
lower `<N>` than the same branches merged one by one (one merge commit each).
- If git metadata is unavailable (tarball / distro build, or the git call fails),
the GUI falls back to the default in `retroshare-gui/src/rsguiversion.h`
(`"version not available"`), and libretroshare must be given the version on the
CMake command line: `-DRS_MAJOR_VERSION=… -DRS_MINOR_VERSION=… -DRS_MINI_VERSION=…`.
---
## Linux (Ubuntu/Debian)
Dependencies — **Qt5**:
```bash
sudo apt-get update
sudo apt-get install -y \
build-essential g++ cmake ninja-build pkg-config git \
qtbase5-dev qtbase5-dev-tools qtmultimedia5-dev libqt5svg5-dev \
libqt5x11extras5-dev qttools5-dev qttools5-dev-tools \
libssl-dev zlib1g-dev libbz2-dev libbotan-2-dev libjson-c-dev \
libasio-dev libsqlcipher-dev \
libspeex-dev libspeexdsp-dev libminiupnpc-dev \
libavcodec-dev libavutil-dev \
libxml2-dev libxslt1-dev libcurl4-openssl-dev \
doxygen python3
```
Dependencies — **Qt6** (self-contained; only the `qt*` packages differ from the
Qt5 list above):
```bash
sudo apt-get update
sudo apt-get install -y \
build-essential g++ cmake ninja-build pkg-config git \
qt6-base-dev qt6-base-dev-tools qt6-multimedia-dev \
qt6-5compat-dev qt6-tools-dev qt6-tools-dev-tools \
libssl-dev zlib1g-dev libbz2-dev libbotan-2-dev libjson-c-dev \
libasio-dev libsqlcipher-dev \
libspeex-dev libspeexdsp-dev libminiupnpc-dev \
libavcodec-dev libavutil-dev \
libxml2-dev libxslt1-dev libcurl4-openssl-dev \
doxygen python3
```
> On Ubuntu 24.04 the Core5Compat dev headers come from `qt6-5compat-dev` (there
> is no `libqt6core5compat6-dev`). Svg/X11Extras dev packages aren't needed on
> Linux for Qt6.
Build — **Qt5**:
```bash
rm -rf Build-cmake
cmake -G Ninja -B Build-cmake -S . \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON \
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON -DRS_SERVICE_TERMINAL_WEBUI_PASSWORD=ON \
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON -DRS_PLUGINS=ON -DRS_FORUM_DEEP_INDEX=OFF \
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON \
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON
cmake --build Build-cmake -j$(nproc)
```
Build — **Qt6** (auto-selected once the qt6 `-dev` packages are installed):
```bash
rm -rf Build-cmake
cmake -G Ninja -B Build-cmake -S . \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Release \
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON -DRS_SERVICE_TERMINAL_WEBUI_PASSWORD=ON \
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON -DRS_PLUGINS=OFF -DRS_FORUM_DEEP_INDEX=OFF \
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON \
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON
cmake --build Build-cmake -j$(nproc)
```
### Debug build (Linux)
The commands above build `Release` (`-O3 -DNDEBUG`): aggressive inlining, assertions
stripped. Fine for daily use, wrong under a debugger — backtraces land on
misattributed lines and locals read `<optimized out>`. To step through code or
investigate a crash with `gdb`, build `Debug` instead.
Two changes to the Qt5 configure above:
- swap `-DCMAKE_BUILD_TYPE=Release` for `-DCMAKE_BUILD_TYPE=Debug` (gives `-g -O0`);
- pin explicit debug flags so every symbol is emitted and nothing is inlined:
`-DCMAKE_CXX_FLAGS_DEBUG` / `-DCMAKE_C_FLAGS_DEBUG` = `-g3 -O0 -fno-omit-frame-pointer`.
`-g3` emits full debug info **including macro definitions**; `-O0` disables inlining so
backtrace line numbers are exact; `-fno-omit-frame-pointer` keeps stack unwinding
reliable.
```bash
rm -rf Build-cmake
cmake -G Ninja -B Build-cmake -S . \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Debug \
-DCMAKE_CXX_FLAGS_DEBUG="-g3 -O0 -fno-omit-frame-pointer" \
-DCMAKE_C_FLAGS_DEBUG="-g3 -O0 -fno-omit-frame-pointer" \
-DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON \
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON -DRS_SERVICE_TERMINAL_WEBUI_PASSWORD=ON \
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON -DRS_PLUGINS=ON -DRS_FORUM_DEEP_INDEX=OFF \
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON \
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON
cmake --build Build-cmake -j$(nproc)
```
> For a **Qt6** debug build, drop `-DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON` and set
> `-DRS_PLUGINS=OFF` (as in the Release Qt6 command); the debug flags are identical.
> A Debug build compiles slower and produces a much larger binary — expected.
> `RelWithDebInfo` (`-O2 -g`) is a middle ground with usable symbols, but because it
> still optimizes it gives approximate backtraces; prefer `Debug` when chasing a crash.
Run the GUI under gdb (the binary lands at `Build-cmake/retroshare-gui/retroshare`):
```bash
gdb ./Build-cmake/retroshare-gui/retroshare
```
then `run`, reproduce the issue, and `bt` at the crash for a full symbolized stack.
#### AddressSanitizer (use-after-free / heap bugs)
For memory-corruption bugs (use-after-free, heap overflow, double free), an ASan build
reports the fault **at the moment of the bad access**, with three stacks — allocation,
free, and the offending access — instead of a bare `SIGSEGV` after the fact. Add
`-fsanitize=address` to both the compile and the link flags:
```bash
rm -rf Build-cmake
cmake -G Ninja -B Build-cmake -S . \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Debug \
-DCMAKE_CXX_FLAGS_DEBUG="-g3 -O1 -fno-omit-frame-pointer -fsanitize=address" \
-DCMAKE_C_FLAGS_DEBUG="-g3 -O1 -fno-omit-frame-pointer -fsanitize=address" \
-DCMAKE_EXE_LINKER_FLAGS="-fsanitize=address" \
-DCMAKE_SHARED_LINKER_FLAGS="-fsanitize=address" \
-DCMAKE_MODULE_LINKER_FLAGS="-fsanitize=address" \
-DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON \
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON -DRS_SERVICE_TERMINAL_WEBUI_PASSWORD=ON \
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON -DRS_PLUGINS=ON -DRS_FORUM_DEEP_INDEX=OFF \
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON \
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON
cmake --build Build-cmake -j$(nproc)
```
> Needs the ASan runtime: `sudo apt-get install -y libasan8`. Run with leak detection
> **off** — RetroShare allocates plenty at startup that would otherwise bury the report:
> ```bash
> ASAN_OPTIONS=abort_on_error=1:detect_leaks=0 ./Build-cmake/retroshare-gui/retroshare
> ```
> `-O1` (not `-O0`) is deliberate: ASan needs light optimization for acceptable runtime
> and cleaner reports, and the sanitizer preserves accurate line numbers regardless.
---
## macOS (Homebrew, Apple Silicon)
Dependencies — **Qt5**:
```bash
brew install ninja qt@5 openssl@3 botan@2 sqlcipher miniupnpc \
json-c asio speex speexdsp ffmpeg libxml2 libxslt bzip2 zlib rapidjson doxygen
```
Dependencies — **Qt6** (self-contained; only the Qt package differs from the Qt5
list above). Unlike Linux's split `qt6-*` packages, Homebrew ships Qt6 as a
**single monolithic `qt` formula** that already bundles qt5compat / svg /
multimedia / tools — so installing `qt` is all you need:
```bash
brew install ninja qt openssl@3 botan@2 sqlcipher miniupnpc \
json-c asio speex speexdsp ffmpeg libxml2 libxslt bzip2 zlib rapidjson doxygen
```
> `qt5compat` (bundled in `qt`) provides `Qt6::Core5Compat`, required by the GUI
> (QRegExp / QTextCodec).
>
> **If `brew install qt` fails with** `Cannot install qtbase because conflicting
> formulae are installed … qt@5: because both link conflicting binaries`, your
> qt@5 is (force-)linked. Run `brew unlink qt@5` first, then re-run
> `brew install qt`:
> ```bash
> brew unlink qt@5
> brew install qt
> ```
> Both Qt versions then coexist: the Qt6 build finds Qt6 via `Qt6_DIR`, and the
> Qt5 build still finds qt@5 via `-DQt5_DIR="$(brew --prefix qt@5)/lib/cmake/Qt5"`
> (the keg path works whether or not qt@5 is linked).
> **Botan:** with several Botan versions installed (`botan`=v3, `botan@2`,
> `botan@3`), a fresh configure can mismatch — Botan 3 headers + Botan 2 lib →
> `Undefined symbols … Botan::…` linker errors in librnp. Both macOS commands
> below pin it with `-DBOTAN_ROOT_DIR="$(brew --prefix botan@2)"` so headers and
> lib come from the **same** keg ([FindBotan.cmake] searches `BOTAN_ROOT_DIR`
> only, via `NO_DEFAULT_PATH`). To build against Botan 3 instead, point it at
> `$(brew --prefix botan)` — RNP then detects v3 and links `libbotan-3`.
> The harvest loop in both macOS commands skips every `qt*` keg on purpose: Qt is
> provided via `Qt6_DIR` / `Qt5_DIR`, and pulling a second Qt's headers off
> `/opt/homebrew/opt/qt*` would mix Qt5/Qt6 and break the build.
Build — **Qt5** (harvest Homebrew include/lib dirs; point find_package(Qt5) at keg-only qt@5):
```bash
HB="$(brew --prefix)"; QT5="$(brew --prefix qt@5)"
IFLAGS="-I$HB/include"; LFLAGS="-L$HB/lib"; PREFIX="$QT5;$HB"
for d in "$HB"/opt/*; do
case "${d##*/}" in qt*) continue;; esac
[ -d "$d/include" ] && IFLAGS="$IFLAGS -I$d/include"
[ -d "$d/lib" ] && LFLAGS="$LFLAGS -L$d/lib"
PREFIX="$PREFIX;$d"
done
rm -rf Build-cmake
cmake -G Ninja -B Build-cmake -S . \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_PREFIX_PATH="$PREFIX" -DQt5_DIR="$QT5/lib/cmake/Qt5" \
-DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON \
-DOPENSSL_ROOT_DIR="$(brew --prefix openssl@3)" \
-DBOTAN_ROOT_DIR="$(brew --prefix botan@2)" \
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON -DRS_SERVICE_TERMINAL_WEBUI_PASSWORD=ON \
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON -DRS_PLUGINS=ON -DRS_FORUM_DEEP_INDEX=OFF \
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON \
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON \
-DCMAKE_C_FLAGS="$IFLAGS" -DCMAKE_CXX_FLAGS="$IFLAGS" \
-DCMAKE_EXE_LINKER_FLAGS="$LFLAGS" \
-DCMAKE_SHARED_LINKER_FLAGS="$LFLAGS" \
-DCMAKE_MODULE_LINKER_FLAGS="$LFLAGS"
cmake --build Build-cmake -j$(sysctl -n hw.ncpu)
```
Build — **Qt6** (use the `qt` prefix + `Qt6_DIR`; plugins OFF):
```bash
HB="$(brew --prefix)"; QT6="$(brew --prefix qt)"
IFLAGS="-I$HB/include"; LFLAGS="-L$HB/lib"; PREFIX="$QT6;$HB"
for d in "$HB"/opt/*; do
case "${d##*/}" in qt*) continue;; esac
[ -d "$d/include" ] && IFLAGS="$IFLAGS -I$d/include"
[ -d "$d/lib" ] && LFLAGS="$LFLAGS -L$d/lib"
PREFIX="$PREFIX;$d"
done
rm -rf Build-cmake
cmake -G Ninja -B Build-cmake -S . \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_PREFIX_PATH="$PREFIX" -DQt6_DIR="$QT6/lib/cmake/Qt6" \
-DOPENSSL_ROOT_DIR="$(brew --prefix openssl@3)" \
-DBOTAN_ROOT_DIR="$(brew --prefix botan@2)" \
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON -DRS_SERVICE_TERMINAL_WEBUI_PASSWORD=ON \
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON -DRS_PLUGINS=OFF -DRS_FORUM_DEEP_INDEX=OFF \
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON \
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON \
-DCMAKE_C_FLAGS="$IFLAGS" -DCMAKE_CXX_FLAGS="$IFLAGS" \
-DCMAKE_EXE_LINKER_FLAGS="$LFLAGS" \
-DCMAKE_SHARED_LINKER_FLAGS="$LFLAGS" \
-DCMAKE_MODULE_LINKER_FLAGS="$LFLAGS"
cmake --build Build-cmake -j$(sysctl -n hw.ncpu)
```
---
## Windows (MSYS2 — UCRT64 shell)
> The build commands use `-j$(nproc)` (all cores; `nproc` is available in MSYS2).
> MinGW C++ compilation is RAM-hungry (RNP/rapidjson can use ~1.5 GB per job), so
> on a low-memory machine lower it manually, e.g. `-j4` — that's why it used to be
> hard-capped at `-j3`.
> **`RS_USE_NATIVE_DIALOGS=ON`** — Qt's own (non-native) file/directory dialogs
> hang on Windows. Using the OS native dialogs (`RS_USE_NATIVE_DIALOGS=ON`)
> avoids the problem. On Linux/macOS the default `OFF` works fine.
Dependencies — common + **Qt5** (use the UCRT64 doxygen, not the base MSYS one —
it mishandles `D:/` paths):
```bash
pacman -S --needed base-devel git perl ruby \
mingw-w64-ucrt-x86_64-toolchain mingw-w64-ucrt-x86_64-cmake mingw-w64-ucrt-x86_64-ninja \
mingw-w64-ucrt-x86_64-doxygen mingw-w64-ucrt-x86_64-python \
mingw-w64-ucrt-x86_64-qt5-base mingw-w64-ucrt-x86_64-qt5-multimedia \
mingw-w64-ucrt-x86_64-qt5-svg mingw-w64-ucrt-x86_64-qt5-tools \
mingw-w64-ucrt-x86_64-openssl mingw-w64-ucrt-x86_64-libbotan mingw-w64-ucrt-x86_64-sqlcipher \
mingw-w64-ucrt-x86_64-miniupnpc mingw-w64-ucrt-x86_64-json-c mingw-w64-ucrt-x86_64-rapidjson \
mingw-w64-ucrt-x86_64-asio mingw-w64-ucrt-x86_64-libxml2 mingw-w64-ucrt-x86_64-libxslt \
mingw-w64-ucrt-x86_64-speex mingw-w64-ucrt-x86_64-speexdsp mingw-w64-ucrt-x86_64-ffmpeg \
mingw-w64-ucrt-x86_64-bzip2 mingw-w64-ucrt-x86_64-zlib
```
Dependencies — **Qt6** (self-contained; only the `qt*` packages differ from the
Qt5 list above):
```bash
pacman -S --needed base-devel git perl ruby \
mingw-w64-ucrt-x86_64-toolchain mingw-w64-ucrt-x86_64-cmake mingw-w64-ucrt-x86_64-ninja \
mingw-w64-ucrt-x86_64-doxygen mingw-w64-ucrt-x86_64-python \
mingw-w64-ucrt-x86_64-qt6-base mingw-w64-ucrt-x86_64-qt6-multimedia \
mingw-w64-ucrt-x86_64-qt6-svg mingw-w64-ucrt-x86_64-qt6-5compat mingw-w64-ucrt-x86_64-qt6-tools \
mingw-w64-ucrt-x86_64-openssl mingw-w64-ucrt-x86_64-libbotan mingw-w64-ucrt-x86_64-sqlcipher \
mingw-w64-ucrt-x86_64-miniupnpc mingw-w64-ucrt-x86_64-json-c mingw-w64-ucrt-x86_64-rapidjson \
mingw-w64-ucrt-x86_64-asio mingw-w64-ucrt-x86_64-libxml2 mingw-w64-ucrt-x86_64-libxslt \
mingw-w64-ucrt-x86_64-speex mingw-w64-ucrt-x86_64-speexdsp mingw-w64-ucrt-x86_64-ffmpeg \
mingw-w64-ucrt-x86_64-bzip2 mingw-w64-ucrt-x86_64-zlib
```
Build — **Qt5** (the `-include` / `-Wno-template-body` flags are only needed for
GCC >= 16 — RNP/rapidjson; harmless on older GCC):
```bash
rm -rf Build-cmake
cmake -G Ninja -B Build-cmake -S . \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Release \
-DRS_LIBRETROSHARE_STATIC=OFF -DRS_LIBRETROSHARE_SHARED=ON \
-DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON \
-DRS_USE_NATIVE_DIALOGS=ON \
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON -DRS_SERVICE_TERMINAL_WEBUI_PASSWORD=ON \
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON -DRS_PLUGINS=ON -DRS_FORUM_DEEP_INDEX=OFF \
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON \
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON \
-DCMAKE_C_FLAGS="-include string.h -include stdint.h" \
-DCMAKE_CXX_FLAGS="-include cstring -include cstdint -Wno-template-body"
cmake --build Build-cmake -j$(nproc)
```
Build — **Qt6** (auto-selected once the qt6 packages are installed; plugins OFF):
```bash
rm -rf Build-cmake
cmake -G Ninja -B Build-cmake -S . \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Release \
-DRS_LIBRETROSHARE_STATIC=OFF -DRS_LIBRETROSHARE_SHARED=ON \
-DRS_USE_NATIVE_DIALOGS=ON \
-DRS_RNPLIB=ON -DRS_JSON_API=ON -DRS_WEBUI=ON -DRS_SERVICE_TERMINAL_WEBUI_PASSWORD=ON \
-DRS_GUI=ON -DRS_SERVICE=ON -DRS_FRIENDSERVER=ON -DRS_PLUGINS=OFF -DRS_FORUM_DEEP_INDEX=OFF \
-DRS_USE_I2P_SAM3=ON -DRS_BITDHT=ON -DRS_MINIUPNPC=ON \
-DRS_BRODCAST_DISCOVERY=ON -DRS_SQLCIPHER=ON \
-DCMAKE_C_FLAGS="-include string.h -include stdint.h" \
-DCMAKE_CXX_FLAGS="-include cstring -include cstdint -Wno-template-body"
cmake --build Build-cmake -j$(nproc)
```
### Packaging & Deployment (Portable & Setup Installer)
Once the CMake build finishes successfully, you can bundle RetroShare and all its DLL dependencies into a standalone portable folder, a compressed archive, and a Windows Setup Installer.
To do this, run the deployment script from the project root:
```bash
./build_scripts/Windows-msys2/deploy-windows.sh
```
By default, the script looks for your build files in `Build-cmake/`. You can override this by setting the `BUILD_DIR` environment variable:
```bash
BUILD_DIR=MyCustomBuildDir ./build_scripts/Windows-msys2/deploy-windows.sh
```
#### Portable Archives (7z / ZIP)
- The script automatically gathers all DLLs (Qt libraries, compiler runtime, and third-party dependencies) and places them alongside the executables.
- It then compresses the folder into a portable package.
- If `p7zip` is installed, it will compress using **7-Zip** for high compression ratios. Otherwise, it falls back to standard **ZIP**.
- To install 7-Zip in MSYS2:
```bash
pacman -S --needed p7zip
```
#### Setup Installer (NSIS)
- If `makensis` is found, the script will automatically compile a self-extracting Windows installer (`-setup.exe`) using Nullsoft Scriptable Install System (NSIS).
- To enable this, you must install the NSIS package for your active shell environment:
- **UCRT64 shell**:
```bash
pacman -S --needed mingw-w64-ucrt-x86_64-nsis
```
- **MinGW64 shell**:
```bash
pacman -S --needed mingw-w64-x86_64-nsis
```

109
CMakeLists.txt Normal file
View File

@ -0,0 +1,109 @@
# CMakeLists.txt for the RetroShare super-project (root aggregate build)
#
# SPDX-License-Identifier: AGPL-3.0-or-later
cmake_minimum_required(VERSION 3.5.0)
set(CMAKE_POLICY_VERSION_MINIMUM 3.5)
project(retroshare-superproject)
# Default to Release build type if not specified
if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Choose the type of build (Debug or Release)" FORCE)
endif()
# Force C++17 globally for all targets (including plugins)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
if(APPLE)
# On macOS, allow undefined symbols in shared modules/libraries at link time
# because they will be resolved at runtime by the host executable (retroshare-gui)
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -undefined dynamic_lookup")
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -undefined dynamic_lookup")
endif()
# Global setting to allow executables to export symbols for plugin/module linking
set(CMAKE_ENABLE_EXPORTS ON)
# Configuration Options
option(RS_GUI "Build RetroShare GUI" ON)
option(RS_SERVICE "Build RetroShare Service" ON)
option(RS_FRIENDSERVER "Build RetroShare Friendserver" ON)
option(RS_PLUGINS "Build RetroShare Plugins" OFF)
option(RS_USE_I2P_SAM3 "Enable I2P SAMv3 support" ON)
# The "sam3" target is defined once here, at the top level, because it is linked
# by more than one subproject: libretroshare AND retroshare-gui (which uses libsam3
# directly in gui/settings/ServerPage.cpp). Defining it once avoids a duplicate
# target definition when the whole tree is configured together. If libretroshare is
# reworked to export sam3 as a target, this top-level definition could be dropped.
if(RS_USE_I2P_SAM3)
add_definitions(-DRS_USE_I2P_SAM3 -DRS_USE_I2P_SAM3_LIBSAM3)
set(SAM3_DEVEL_DIR "${CMAKE_SOURCE_DIR}/supportlibs/libsam3")
if(EXISTS "${SAM3_DEVEL_DIR}")
message(STATUS "libsam3 found at ${SAM3_DEVEL_DIR}, defining target sam3 globally")
add_library(sam3 STATIC
"${SAM3_DEVEL_DIR}/src/libsam3/libsam3.c"
"${SAM3_DEVEL_DIR}/src/libsam3a/libsam3a.c"
)
target_include_directories(sam3 PUBLIC
"${SAM3_DEVEL_DIR}/src/libsam3"
"${SAM3_DEVEL_DIR}/src/libsam3a"
)
if(WIN32)
target_link_libraries(sam3 PUBLIC ws2_32)
endif()
endif()
endif()
# NOTE: Windows-specific workarounds that used to live here as global
# add_definitions()/add_compile_options() have been moved to the specific targets
# that need them (see the per-target block after the add_subdirectory() calls
# below), so they no longer leak into every target in the tree.
# 1. First add the core library (libretroshare)
add_subdirectory(libretroshare)
# 2. Then add the dependent executables
if(RS_GUI)
add_subdirectory(retroshare-gui)
if(RS_PLUGINS)
add_subdirectory(plugins)
endif()
endif()
if(RS_SERVICE)
add_subdirectory(retroshare-service)
endif()
if(RS_FRIENDSERVER)
add_subdirectory(retroshare-friendserver)
endif()
# ---------------------------------------------------------------------------
# Per-target Windows fixups (applied to the specific targets that need them,
# rather than globally, per review feedback). These run after the subdirectories
# so the targets already exist.
# ---------------------------------------------------------------------------
if(WIN32)
# libbitdht needs the wide-char Windows API (e.g. MoveFileExW). libretroshare
# already sets UNICODE/_UNICODE PUBLIC for itself and its consumers, but
# libbitdht is a dependency (not a consumer) so it needs its own definition.
if(TARGET bitdht)
target_compile_definitions(bitdht PRIVATE UNICODE _UNICODE)
endif()
# Legacy C submodules trip strict GCC >= 15 diagnostics that are now errors by
# default; downgrade them to warnings only for those targets. Add other legacy
# targets here if a future toolchain flags them.
if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
foreach(legacy_target sam3 bitdht miniupnpc udp-discovery)
if(TARGET ${legacy_target})
target_compile_options(${legacy_target} PRIVATE
-Wno-error=incompatible-pointer-types
-Wno-error=int-conversion
-Wno-error=implicit-function-declaration )
endif()
endforeach()
endif()
endif()

View File

@ -1,67 +0,0 @@
// SPDX-FileCopyrightText: Retroshare Team <contact@retroshare.cc>
// SPDX-License-Identifier: CC-BY-SA-4.0
= RetroShare
RetroShare is a decentralized, private, secure, cross-platform, communication
toolkit.
RetroShare provides file sharing, chat, messages, forums, channels and more.
.Build Status
|===============================================================================
|GNU/Linux (via Gitlab CI) | image:https://gitlab.com/RetroShare/RetroShare/badges/master/pipeline.svg[link="https://gitlab.com/RetroShare/RetroShare/-/commits/master",title="pipeline status"]
|Windows (via AppVeyor) | image:https://ci.appveyor.com/api/projects/status/github/RetroShare/RetroShare?svg=true[link="https://ci.appveyor.com/project/RetroShare58622/retroshare"]
|macOS, (via Travis CI) | image:https://app.travis-ci.com/RetroShare/RetroShare.svg?branch=master[link="https://app.travis-ci.com/github/RetroShare/RetroShare"]
|libretroshare GNU/Linux, Android (via Gitlab CI) | image:https://gitlab.com/RetroShare/libretroshare/badges/master/pipeline.svg[link="https://gitlab.com/RetroShare/libretroshare/-/commits/master",title="pipeline status"]
|===============================================================================
== Get the source
Clone this repository, enter the directory and then get the submodules with the
following command
[source,bash]
--------
git submodule update --init --remote --force libbitdht/ libretroshare/ openpgpsdk/
--------
== Compilation
Short of comprehensive and updated documentation on how to build RetroShare
(for the many supported platforms it runs on), scripts and recipes are provided
in the aim of creating packages for the supported platforms (and more)
in the `build_scripts` directory of this repository.
Those packaging receipts together with the continuous integration files
`.travis.yml` and `appveyor.yml` are a good source of knowledge on how to
compile RetroShare on different platforms.
== Using RetroShare on a headless computer with web UI
WARNING: This section is outdated need to be adapted to the new web UI
The web UI needs to be enabled as a parameter option to the retroshare-service:
[source,bash]
--------
./retroshare-nogui --webinterface 9090 --docroot /usr/share/retroshare/webui/
--------
The web UI is only accessible on localhost:9090. It is advised to keep it that way so that your RS
cannot be controlled using an untrusted connection.
To access your web UI from a distance, just open a SSH tunnel to it:
[source,bash]
--------
distant_machine:~/ > ssh rs_host -L 9090:localhost:9090 -N
--------
"rs_host" is the machine running `retroshare-nogui`. Then on the distant machine, access your web UI on
http://localhost:9090
(This can also be done from the RetroShare GUI.)

55
README.md Normal file
View File

@ -0,0 +1,55 @@
## RetroShare
RetroShare is a decentralized, private, secure, cross-platform, communication
toolkit.
RetroShare provides file sharing, chat, messages, forums, channels, boards and more.
[![GitHub release](https://img.shields.io/github/release/retroshare/retroshare.svg?label=latest%20release)](https://github.com/retroshare/retroshare/releases/latest)
[![Downloads](https://img.shields.io/github/downloads/retroshare/retroshare/total)](https://github.com/retroshare/retroshare/releases/latest)
[![MINGW64 Qt5 Build](https://github.com/RetroShare/RetroShare/actions/workflows/ci-mingw64.yml/badge.svg)](https://github.com/RetroShare/RetroShare/actions/workflows/ci-mingw64.yml)
[![UCRT64 Qt5 Build](https://github.com/RetroShare/RetroShare/actions/workflows/ci-ucrt64.yml/badge.svg)](https://github.com/RetroShare/RetroShare/actions/workflows/ci-ucrt64.yml)
[![MINGW64 Qt6 Build](https://github.com/RetroShare/RetroShare/actions/workflows/ci-mingw64-Qt6.yml/badge.svg)](https://github.com/RetroShare/RetroShare/actions/workflows/ci-mingw64-Qt6.yml)
[![GNU/Linux (via Gitlab CI)](https://gitlab.com/RetroShare/RetroShare/badges/master/pipeline.svg)](https://gitlab.com/RetroShare/RetroShare/-/commits/master)
[![libretroshare GNU/Linux, Android (via Gitlab CI)](https://gitlab.com/RetroShare/libretroshare/badges/master/pipeline.svg)](https://gitlab.com/RetroShare/libretroshare/-/commits/master)
[![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/RetroShare/RetroShare)
## Get the source
Clone this repository, enter the directory and then get the submodules with the
following command
git submodule update --init --remote --force libbitdht/ libretroshare/ openpgpsdk/
## Compilation
Short of comprehensive and updated documentation on how to build RetroShare
(for the many supported platforms it runs on), scripts and recipes are provided
in the aim of creating packages for the supported platforms (and more)
in the [build_scripts](https://github.com/RetroShare/RetroShare/tree/master/build_scripts) directory of this repository.
## Compilation on Windows
Follow this file : [WindowsMSys2_InstallGuide](https://github.com/RetroShare/RetroShare/blob/master/build_scripts/Windows-msys2/WindowsMSys2_InstallGuide.md)
With QtCreator : [Windows-QtCreator-InstallGuide](https://github.com/RetroShare/RetroShare/blob/master/build_scripts/Windows/Windows-QtCreator-InstallGuide.md)
## Compilation on MacOSX
Follow this file : [MacOS_X_InstallGuide](https://github.com/RetroShare/RetroShare/blob/master/build_scripts/OSX/MacOS_X_InstallGuide.md)
## Compilation on Linux
Follow this file : [Linux_InstallGuide](https://github.com/RetroShare/RetroShare/blob/master/build_scripts/Debian+Ubuntu/Linux_InstallGuide.md)
## Releases
Latest release [here](https://github.com/RetroShare/RetroShare/releases)
Other Builds [RetroShare Downloads](https://retroshare.cc/downloads.html)
## Documentation
- [RetroShare Docs](https://retrosharedocs.readthedocs.io/en/latest/)

View File

@ -25,9 +25,6 @@ CONFIG += c++14
TEMPLATE = subdirs
SUBDIRS += openpgpsdk
openpgpsdk.file = openpgpsdk/src/openpgpsdk.pro
rs_jsonapi:isEmpty(JSONAPI_GENERATOR_EXE) {
SUBDIRS += jsonapi-generator
jsonapi-generator.file = jsonapi-generator/src/jsonapi-generator.pro
@ -36,7 +33,7 @@ rs_jsonapi:isEmpty(JSONAPI_GENERATOR_EXE) {
SUBDIRS += libbitdht
libbitdht.file = libbitdht/src/libbitdht.pro
libretroshare.depends += openpgpsdk libbitdht
libretroshare.depends += libbitdht
SUBDIRS += libretroshare
libretroshare.file = libretroshare/src/libretroshare.pro

View File

@ -1,312 +0,0 @@
# SPDX-FileCopyrightText: (C) 2004-2019 Retroshare Team <contact@retroshare.cc>
# SPDX-License-Identifier: CC0-1.0
# Notes:
# - Minimal appveyor.yml file is an empty file. All sections are optional.
# - Indent each level of configuration with 2 spaces. Do not use tabs!
# - All section names are case-sensitive.
# - Section names should be unique on each level.
# from example:
# https://github.com/Phonations/Joker/blob/master/appveyor.yml
# https://github.com/unicorn-engine/autobuild/blob/master/.appveyor.yml
#---------------------------------#
# general configuration #
#---------------------------------#
# version format
version: RetroShare-git-{branch}-{build}
image: Visual Studio 2019
# you can use {branch} name in version format too
# version: 1.0.{build}-{branch}
# branches to build
branches:
# whitelist
#only:
# - master
# blacklist
except:
- /^skipthisbranch$/
# Do not build on tags (GitHub only)
skip_tags: true
# Skipping commits with particular message or from user
skip_commits:
message: /Created.*\.(png|jpg|jpeg|bmp|gif)/ # Regex for matching commit message
#author: Anonymous # Commit author's username, name, email or regexp maching one of these.
#---------------------------------#
# environment configuration #
#---------------------------------#
# Operating system (build VM template)
#os: Windows Server 2012
# scripts that are called at very beginning, before repo cloning
init:
- git config --global core.autocrlf input
#To get RDP while compiling
- ps: iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
on_finish:
#To get RDP running after compiling
#- ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
# clone directory
clone_folder: C:\projects\RetroShare
# fetch repository as zip archive
#shallow_clone: true # default is "false"
# set clone depth
clone_depth: 2000 # clone entire repository history if not defined
environment:
global:
## Qt: https://www.appveyor.com/docs/installed-software#qt
# QTDIR: C:\Qt\5.10.1\mingw53_32
MSYS2_ARCH: i686
TARGET: i686_32-pc-msys
MINGW_PREFIX: C:\msys64\mingw32
RS_DEPLOY: RetroShare_deploy
# build cache to preserve files/folders between builds
#cache:
# Disabled because it's bigger then supported by appveyor free plan
# - C:\msys64\var\cache\pacman\pkg
# scripts that run after cloning repository
#install:
# # by default, all script lines are interpreted as batch
# - echo This is batch
# # to run script as a PowerShell command prepend it with ps:
# - ps: Write-Host 'This is PowerShell'
# # batch commands start from cmd:
# - cmd: echo This is batch again
# - cmd: set MY_VAR=12345
install:
# We cannot get OBS submodule as it use illegal folder name for windows.
#- git submodule update --init
# Configuring MSys2
- set PATH=C:\msys64\usr\bin;%PATH%
- set PATH=C:\msys64\mingw32\bin;%PATH%
- >
pacman --noconfirm -Sy
mingw-w64-i686-qt5 mingw-w64-i686-miniupnpc mingw-w64-i686-rapidjson
mingw-w64-i686-sqlcipher mingw-w64-i686-xapian-core mingw-w64-i686-cmark
#- set PATH=C:\msys64\mingw32\qt5-static\bin\;%PATH%
# Configuring Qt
# - set PATH=%QTDIR%\bin;C:\Qt\Tools\mingw491_32\bin;%PATH%
# Hack for new MSys2
- copy C:\msys64\mingw32\i686-w64-mingw32\bin\ar.exe C:\msys64\mingw32\bin\i686-w64-mingw32-ar.exe
- copy C:\msys64\mingw32\i686-w64-mingw32\bin\ranlib.exe C:\msys64\mingw32\bin\i686-w64-mingw32-ranlib.exe
- copy C:\msys64\mingw32\bin\windres.exe C:\msys64\mingw32\bin\i686-w64-mingw32-windres.exe
- copy C:\msys64\mingw64\x86_64-w64-mingw32\bin\ar.exe C:\msys64\mingw64\bin\x86_64-w64-mingw32-ar.exe
- copy C:\msys64\mingw64\x86_64-w64-mingw32\bin\ranlib.exe C:\msys64\mingw64\bin\x86_64-w64-mingw32-ranlib.exe
- copy C:\msys64\mingw64\bin\windres.exe C:\msys64\mingw64\bin\x86_64-w64-mingw32-windres.exe
# Work-around linker looking for Qt dll in wrong place
- copy C:\msys64\mingw32\bin\Qt5PrintSupport.dll C:\msys64\mingw32\lib\Qt5PrintSupport.dll
- copy C:\msys64\mingw32\bin\Qt5Widgets.dll C:\msys64\mingw32\lib\Qt5Widgets.dll
- copy C:\msys64\mingw32\bin\Qt5Multimedia.dll C:\msys64\mingw32\lib\Qt5Multimedia.dll
- copy C:\msys64\mingw32\bin\Qt5Gui.dll C:\msys64\mingw32\lib\Qt5Gui.dll
- copy C:\msys64\mingw32\bin\Qt5Network.dll C:\msys64\mingw32\lib\Qt5Network.dll
- copy C:\msys64\mingw32\bin\Qt5Xml.dll C:\msys64\mingw32\lib\Qt5Xml.dll
- copy C:\msys64\mingw32\bin\Qt5Core.dll C:\msys64\mingw32\lib\Qt5Core.dll
#---------------------------------#
# build configuration #
#---------------------------------#
# build platform, i.e. x86, x64, Any CPU. This setting is optional.
platform: x86
# to add several platforms to build matrix:
#platform:
# - x86
# - Any CPU
# build Configuration, i.e. Debug, Release, etc.
configuration: Release
# to add several configurations to build matrix:
#configuration:
# - Debug
# - Release
# scripts to run before build
before_build:
- cd C:\projects\RetroShare
- git submodule update --init
- cd C:\projects\
- mkdir RetroShare-build
- cd RetroShare-build
# - find C:\ > filelist.txt
# scripts to run *after* solution is built and *before* automatic packaging occurs (web apps, NuGet packages, Azure Cloud Services)
before_package:
# to run your custom scripts instead of automatic MSBuild
build_script:
- env
- qmake ../RetroShare -spec win32-g++ "CONFIG+=debug"
- mingw32-make -j3
# scripts to run after build
after_build:
- find .
- mkdir %RS_DEPLOY%
- copy retroshare-gui\src\debug\retroshare.exe %RS_DEPLOY%\
- copy retroshare-service\src\debug\retroshare-service.exe %RS_DEPLOY%\
# - copy retroshare-service\src\retroshare-service.exe %RS_DEPLOY%\
# - copy retroshare-gui\src\retroshare.exe %RS_DEPLOY%\
## In Debug build winedeplyqt forget the non debug Qt libs
- copy C:\msys64\mingw32\bin\Qt5Svg.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\Qt5Core.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\Qt5Multimedia.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\Qt5Widgets.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\Qt5Xml.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\Qt5PrintSupport.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\Qt5Gui.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\Qt5Network.dll %RS_DEPLOY%\
- mkdir %RS_DEPLOY%\playlistformats\
- copy C:\msys64\mingw32\share\qt5\plugins\playlistformats\qtmultimedia_m3u.dll %RS_DEPLOY%\playlistformats
- mkdir %RS_DEPLOY%\printsupport\
- copy C:\msys64\mingw32\share\qt5\plugins\printsupport\windowsprintersupport.dll %RS_DEPLOY%\printsupport\
- mkdir %RS_DEPLOY%\iconengines\
- copy C:\msys64\mingw32\share\qt5\plugins\iconengines\qsvgicon.dll %RS_DEPLOY%\iconengines\
- mkdir %RS_DEPLOY%\bearer\
- copy C:\msys64\mingw32\share\qt5\plugins\bearer\qgenericbearer.dll %RS_DEPLOY%\bearer\
- mkdir %RS_DEPLOY%\mediaservice\
- copy C:\msys64\mingw32\share\qt5\plugins\mediaservice\qtmedia_audioengine.dll %RS_DEPLOY%\mediaservice\
- copy C:\msys64\mingw32\share\qt5\plugins\mediaservice\dsengine.dll %RS_DEPLOY%\mediaservice\
- mkdir %RS_DEPLOY%\styles\
- copy C:\msys64\mingw32\share\qt5\plugins\styles\qwindowsvistastyle.dll %RS_DEPLOY%\styles\
- mkdir %RS_DEPLOY%\imageformats\
- copy C:\msys64\mingw32\share\qt5\plugins\imageformats\qwebp.dll %RS_DEPLOY%\imageformats\
- copy C:\msys64\mingw32\share\qt5\plugins\imageformats\qicns.dll %RS_DEPLOY%\imageformats\
- copy C:\msys64\mingw32\share\qt5\plugins\imageformats\qjpeg.dll %RS_DEPLOY%\imageformats\
- copy C:\msys64\mingw32\share\qt5\plugins\imageformats\qtiff.dll %RS_DEPLOY%\imageformats\
- copy C:\msys64\mingw32\share\qt5\plugins\imageformats\qtga.dll %RS_DEPLOY%\imageformats\
- copy C:\msys64\mingw32\share\qt5\plugins\imageformats\qjp2.dll %RS_DEPLOY%\imageformats\
- copy C:\msys64\mingw32\share\qt5\plugins\imageformats\qico.dll %RS_DEPLOY%\imageformats\
- copy C:\msys64\mingw32\share\qt5\plugins\imageformats\qwbmp.dll %RS_DEPLOY%\imageformats\
- copy C:\msys64\mingw32\share\qt5\plugins\imageformats\qicns.dll %RS_DEPLOY%\imageformats\
- copy C:\msys64\mingw32\share\qt5\plugins\imageformats\qgif.dll %RS_DEPLOY%\imageformats\
- copy C:\msys64\mingw32\share\qt5\plugins\imageformats\qsvg.dll %RS_DEPLOY%\imageformats\
- mkdir %RS_DEPLOY%\platforms\
- copy C:\msys64\mingw32\share\qt5\plugins\platforms\qwindows.dll %RS_DEPLOY%\platforms\
- mkdir %RS_DEPLOY%\audio\
- copy C:\msys64\mingw32\share\qt5\plugins\audio\qtaudio_windows.dll %RS_DEPLOY%\audio\
- windeployqt %RS_DEPLOY%\retroshare.exe
- copy C:\msys64\mingw32\bin\libbz2*.dll %RS_DEPLOY%\
#- copy C:\msys64\mingw32\bin\libeay32.dll %RS_DEPLOY%\
- copy C:\OpenSSL-Win32\libeay32.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libminiupnpc.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libsqlcipher*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libsqlite3*.dll %RS_DEPLOY%\
#- copy C:\msys64\mingw32\bin\ssleay32.dll %RS_DEPLOY%\
- copy C:\OpenSSL-Win32\ssleay32.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\zlib*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libgcc_s_dw2*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libstdc*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libwinpthread*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libicu*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libpcre*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libharfbuzz*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libpng*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libfreetype*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libglib*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libgraphite2.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libintl*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libiconv*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libjasper*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libjpeg*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libtiff*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libwebp*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libwebpdemux*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\liblzma*.dll %RS_DEPLOY%\
## Needed for cmark
- copy C:\msys64\mingw32\bin\libcmark*.dll %RS_DEPLOY%\
- copy C:\msys64\mingw32\bin\libdouble-conversion*.dll %RS_DEPLOY%\
# to disable automatic builds
#build: off
#---------------------------------#
# artifacts configuration #
#---------------------------------#
artifacts:
- path: '**\*.exe'
- path: filelist.txt
- path: $(RS_DEPLOY)
#
# # pushing a single file
# - path: test.zip
#
# # pushing a single file with environment variable in path and "Deployment name" specified
# - path: MyProject\bin\$(configuration)
# name: myapp
#
# # pushing entire folder as a zip archive
# - path: logs
#---------------------------------#
# deployment configuration #
#---------------------------------#
#No deployment under unknown computer!!!
#---------------------------------#
# global handlers #
#---------------------------------#
# on successful build
#on_success:
# - do something
# on build failure
#on_failure:
# - do something
# after build failure or success
#on_finish:
# - do something
#---------------------------------#
# notifications #
#---------------------------------#
notifications:
# Email
- provider: Email
to:
- retrosharephenom@gmail.com
subject: 'Build {{status}}' # optional
message: "{{message}}, {{commitId}}, ..." # optional
on_build_status_changed: true

View File

@ -0,0 +1,170 @@
## Compilation on Linux
### Install package dependencies:
#### Debian / Ubuntu / Linux Mint
```bash
sudo apt-get install git g++ cmake libbz2-dev libjson-c-dev libssl-dev libsqlcipher-dev \
libupnp-dev doxygen libxss-dev rapidjson-dev libbotan-2-dev libasio-dev
```
To compile with Qt5:
```bash
sudo apt-get install qt5-qmake qtmultimedia5-dev libqt5x11extras5-dev
```
To compile with Qt6:
```bash
sudo apt-get install qt6-base-dev qt6-multimedia-dev qt6-5compat-dev
```
Additional dependencies for Feedreader plugin:
```bash
sudo apt-get install libxml2-dev libxslt1-dev libcurl4-openssl-dev
```
Additional dependencies for Voip plugin:
```bash
sudo apt-get install libavcodec-dev libcurl4-openssl-dev \
libqt5multimedia5-plugins libspeexdsp-dev
```
Autologin:
```bash
sudo apt install libsecret-1-dev
```
#### openSUSE
```bash
sudo zypper install git gcc-c++ cmake libqt5-qtbase-devel \
libqt5-qtmultimedia-devel libqt5-qtx11extras-devel libbz2-devel \
libopenssl-devel libupnp-devel libXss-devel sqlcipher-devel rapidjson-devel \
json-c botan bzip2
```
Additional packages to compile with Qt6:
```bash
sudo zypper install qt6-base-devel qt6-multimedia-devel qt6-qt5compat-devel
```
Additional dependencies for plugins:
```bash
sudo zypper install ffmpeg-4-libavcodec-devel libcurl-devel libxml2-devel \
libxslt-devel speex-devel speexdsp-devel
```
#### Arch Linux / Manjaro / EndeavourOS
```bash
sudo pacman -S base-devel libgnome-keyring cmake qt5-tools qt5-multimedia qt5-x11extras \
rapidjson doxygen libupnp libxslt libxss sqlcipher botan2 bzip2 json-c
```
To compile with Qt6:
```bash
sudo pacman -S qt6-base qt6-multimedia qt6-5compat
```
### Checkout the source code
```bash
cd ~
git clone https://github.com/RetroShare/RetroShare.git retroshare
```
### Checkout the submodules
```bash
cd retroshare
git submodule update --init --remote libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/
git submodule update --init --remote supportlibs/librnp supportlibs/restbed supportlibs/rapidjson
```
### Compile
```bash
qmake CONFIG+=release CONFIG+=rs_jsonapi CONFIG+=rs_webui
make
```
The executable produced will be:
```bash
./retroshare-gui/src/retroshare
```
### Install
```bash
sudo make install
```
The executable produced will be:
```bash
~/usr/bin/RetroShare
```
### For packagers
Packagers can use PREFIX and LIB\_DIR to customize the installation paths:
```bash
qmake PREFIX=/usr LIB_DIR=/usr/lib64 "CONFIG-=debug" "CONFIG+=release"
make
make INSTALL_ROOT=${PKGDIR} install
```
### libsqlcipher
If libsqlcipher is not available as a package
You need to place sqlcipher so that the hierarchy is:
~Home
|
+--- retroshare
|
+--- lib
|
+---- sqlcipher
```bash
mkdir lib
cd lib
git clone https://github.com/sqlcipher/sqlcipher.git --depth=1 --branch v3.4.1
cd sqlcipher
./configure --enable-tempstore=yes CFLAGS="-DSQLITE_HAS_CODEC" LDFLAGS="-lcrypto"
make
cd ..
```
### Build infos
Note: If you installed Qt6 you need to use `qmake6` on the command line.
For the `FeedReader` it is required to append the config option `CONFIG+=retroshare_plugins`.
Make sure `plugins/plugins.pro` contains `FeedReader` in the list of plugins to compile.
Do not mix plugins compiled with Qt5 with those compiled with Qt6. They work only if they are compiled
with the same Qt version as RetroShare.
Voip is outdated and is not compileable on the latest Debian.
For `Autologin` it is required to append the config option `CONFIG+=rs_autologin`.
### Build options
* Mandatory
* release or debug: normally you would like to use the release option
* Extra features (optional)
* rs_autologin: enable autologin
* retroshare_plugins: build plugins
* rs_webui: enable Web interface
* rs_jsonapi: enable json api interface, required by rs_webui
* gxsthewire: enable Wire service (experimental)
* wikipoos: enable Wiki service
* rs_use_native_dialogs: enable native dialogs (may cause crashes with some versions of Gtk)
* rs_deep_channels_index: build with deep channel indexing support
* rs_deep_files_index: build with deep file indexing support
* "CONFIG+=..." enable other extra compile time features, you can find the almost complete list in file *&lt;sourcefolder&gt;\retroshare.pri*
### Examples:
```batch
qmake CONFIG+=debug CONFIG+=release CONFIG+=rs_use_native_dialog CONFIG+=rs_gui_cmark
qmake CONFIG+=rs_jsonapi CONFIG+=rs_webui CONFIG+=rs_autologin
```

View File

@ -1,48 +0,0 @@
ARG ANDROID_NDK_ARCH=arm
FROM registry.gitlab.com/retroshare/retroshare:android_${ANDROID_NDK_ARCH}_base
ENV APT_UNAT="--assume-yes --quiet"
RUN apt-get update $APT_UNAT && apt-get upgrade $APT_UNAT --show-upgraded
ARG REPO_URL=https://gitlab.com/RetroShare/RetroShare.git
ARG REPO_BRANCH=master
WORKDIR /RetroShare
RUN git remote add testing $REPO_URL && \
git fetch --tags testing $REPO_BRANCH && \
git reset --hard testing/$REPO_BRANCH && \
git --no-pager log --max-count 1
RUN rm -rf /jsonapi-generator-build ; mkdir /jsonapi-generator-build
WORKDIR /jsonapi-generator-build/
RUN qmake ../RetroShare/jsonapi-generator/src/ \
CONFIG+=no_retroshare_plugins \
CONFIG+=no_retroshare_service CONFIG+=no_retroshare_gui \
CONFIG+=rs_jsonapi CONFIG+=no_rs_sam3_libsam3 && \
make -j$(nproc)
RUN rm -rf /retroshare-service-android-build ; mkdir /retroshare-service-android-build
WORKDIR /retroshare-service-android-build
# ARG declared before FROM get wiped after it, so we need declaring it again
ARG ANDROID_NDK_ARCH=arm
ARG RS_SERVICE_QMAKE_EXTRA_OPTS
RUN $($PREPARE_TOOLCHAIN get_qt_dir | head -n 1)/bin/qmake ../RetroShare \
-spec android-clang \
CONFIG+=retroshare_service CONFIG+=rs_jsonapi \
RS_UPNP_LIB=miniupnpc \
JSONAPI_GENERATOR_EXE=/jsonapi-generator-build/jsonapi-generator \
NATIVE_LIBS_TOOLCHAIN_PATH=$NATIVE_LIBS_TOOLCHAIN_PATH \
CONFIG+=no_retroshare_gui CONFIG+=no_rs_service_webui_terminal_password \
CONFIG+=no_rs_service_terminal_login \
CONFIG+=no_rs_sam3 CONFIG+=no_rs_sam3_libsam3 \
$RS_SERVICE_QMAKE_EXTRA_OPTS
RUN make -j$(nproc)
RUN make install INSTALL_ROOT=/retroshare-service-android-build/android-build/
ARG ANDROID_PLATFORM_VER=16
RUN $($PREPARE_TOOLCHAIN get_qt_dir | head -n 1)/bin/androiddeployqt \
--input retroshare-service/src/android-libretroshare-service.so-deployment-settings.json \
--output android-build --android-platform android-$ANDROID_PLATFORM_VER \
--jdk $JAVA_HOME --gradle

View File

@ -12,7 +12,7 @@
## To run the container
# docker run -it -p 127.0.0.1:9092:9092 "${CI_REGISTRY_IMAGE}" retroshare-service --jsonApiPort 9092 --jsonApiBindAddress 0.0.0.0
FROM ubuntu:22.04
FROM ubuntu:26.04
ENV DEBIAN_FRONTEND=noninteractive
ENV APT_UNAT="--assume-yes --quiet"
@ -26,7 +26,7 @@ RUN apt-get update $APT_UNAT && \
libsqlite3-dev libsqlcipher-dev \
pkg-config libz-dev \
libxapian-dev doxygen rapidjson-dev \
git cmake curl python3
git cmake curl python3 libasio-dev libjson-c-dev libbotan-3-dev
## Avoid git cloning spuriously failing with
# server certificate verification failed. CAfile: none CRLfile: none
@ -40,18 +40,19 @@ RUN git clone --depth 1 https://github.com/aetilius/pHash.git && \
rm -rf pHash-build pHash
ARG FRESHCLONE=0
ARG REPO_URL=https://gitlab.com/RetroShare/RetroShare.git
ARG REPO_URL=https://github.com/RetroShare/RetroShare.git
ARG REPO_BRANCH=master
ARG REPO_DEPTH="--depth 2000"
RUN git clone $REPO_DEPTH $REPO_URL -b $REPO_BRANCH && cd RetroShare && \
RUN git clone $REPO_DEPTH $REPO_URL -b $REPO_BRANCH && \
cd RetroShare && \
git fetch --tags && \
git submodule update --init --remote --force \
libbitdht/ libretroshare/ openpgpsdk/ && \
cd ..
git submodule update --init \
libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/ \
supportlibs/restbed/
RUN \
mkdir RetroShare-build && cd RetroShare-build && \
cmake -B. -S../RetroShare/retroshare-service \
-DRS_FORUM_DEEP_INDEX=ON -DRS_JSON_API=ON && \
-DRS_FORUM_DEEP_INDEX=ON -DRS_JSON_API=ON -DRS_WEBUI=ON && \
make -j$(nproc) && make install && \
cd .. && rm -rf RetroShare-build

View File

@ -1,9 +1,16 @@
#!/bin/sh
[ -n "$CI_MERGE_REQUEST_ID" ] &&
echo \
--build-arg REPO_URL="$CI_MERGE_REQUEST_SOURCE_PROJECT_URL" \
--build-arg REPO_BRANCH="$CI_MERGE_REQUEST_SOURCE_BRANCH_NAME" ||
echo \
--build-arg REPO_URL="$CI_REPOSITORY_URL" \
--build-arg REPO_BRANCH="$CI_COMMIT_BRANCH"
# Emit --build-arg flags so gitlabCI.Dockerfile fetches the EXACT ref that
# triggered the pipeline. REPO_REF can be a commit SHA (the CI default), a
# branch name, or a tag. The remote URL is still chosen per-case so
# MR-from-fork fetches from the fork.
if [ -n "$CI_MERGE_REQUEST_ID" ]; then
REPO_URL="$CI_MERGE_REQUEST_SOURCE_PROJECT_URL"
else
REPO_URL="$CI_REPOSITORY_URL"
fi
echo \
--build-arg REPO_URL="$REPO_URL" \
--build-arg REPO_REF="$CI_COMMIT_SHA"

View File

@ -2,19 +2,21 @@ FROM registry.gitlab.com/retroshare/retroshare:base
RUN apt-get update -y && apt-get upgrade -y
ARG REPO_URL=https://gitlab.com/RetroShare/RetroShare.git
ARG REPO_BRANCH=master
ARG REPO_URL=https://github.com/RetroShare/RetroShare.git
ARG REPO_REF=master
RUN \
cd RetroShare && git remote add testing $REPO_URL && \
git fetch --tags testing $REPO_BRANCH && \
git reset --hard testing/$REPO_BRANCH && \
git submodule update --init --remote --force \
libbitdht/ libretroshare/ openpgpsdk/ && \
git fetch --tags testing $REPO_REF && \
git checkout --force FETCH_HEAD && \
git submodule deinit -f --all && \
git submodule update --init \
libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/ \
supportlibs/restbed/ && \
git --no-pager log --max-count 1
RUN \
mkdir RetroShare-build && cd RetroShare-build && \
cmake -B. -S../RetroShare/retroshare-service \
-DRS_FORUM_DEEP_INDEX=ON -DRS_JSON_API=ON \
-DRS_FORUM_DEEP_INDEX=ON -DRS_JSON_API=ON -DRS_WEBUI=ON \
-DRS_WARN_DEPRECATED=OFF -DRS_WARN_LESS=ON && \
make -j$(nproc) && make install && \
cd .. && rm -rf RetroShare-build

@ -1 +1 @@
Subproject commit df16cb915465d058c75277678799ce4dadeae287
Subproject commit 042d1d5a9f65e51e1abafe527cab2f04d6fab29b

View File

@ -2,13 +2,15 @@
## Qt Installation
Install Qt via: [Qt Download](http://www.qt.io/download/)
Qt 5.15 is not available as install package.
Use default options. And add Qt Script support.
Download Qt 5.15.x from here: [Qt 5.15.17](https://download.qt.io/archive/qt/5.15/5.15.17/single/qt-everywhere-opensource-src-5.15.17.tar.xz)
Instruction howto Build Qt 5.15.x on macOS: [macOS Building](https://doc.qt.io/archives/qt-5.15/macos-building.html)
## Set the Environment Variables
Add to the PATH environment variable by editing your *~/.profile* file.
export PATH="/users/$USER/Qt/5.14.1/clang_64/bin:$PATH"
export PATH="/users/$USER/Qt/5.15.17/clang_64/bin:$PATH"
Depends on which version of Qt you use.
@ -30,32 +32,20 @@ In GitHub Desktop -> Clone Repository -> URL
Add Repository URL: https://github.com/RetroShare/RetroShare.git and Clone
## ***Choose if you use MacPort or HomeBrew***
## ***Get XCode & MacOSX SDK***
### MacPort Installation
To identify the correct version of Xcode to install, you need to know which OS you are running. Go to the [x] menu -> "About This Mac" and read the macOS version number.
Install MacPort and XCode following this guide: [MacPort and XCode](http://guide.macports.org/#installing.xcode)
If you are running macOS Ventura 13.5 or later, you can install Xcode directly from App Store using the instructions below.
Start XCode to get it updated and to able C compiler to create executables.
You can find older versions of Xcode at [Apple Developer Downloads](https://developer.apple.com/downloads/). Find the appropriate .xip file for your macOS version
#### Install libraries
To install from App Store:
$ sudo port -v selfupdate
$ sudo port install openssl
$ sudo port install miniupnpc
$ sudo port install libmicrohttpd
For VOIP Plugin:
Select [x] menu - > "App Store…".
Search for Xcode. Download and install.
$ sudo port install speex-devel
$ sudo port install opencv
$ sudo port install ffmpeg
Get Your OSX SDK if missing: [MacOSX-SDKs](https://github.com/phracker/MacOSX-SDKs)
### HOMEBREW Installation
Install HomeBrew following this guide: [HomeBrew](http://brew.sh/)
Once Xcode has installed, you must drag the XCode icon into your Applications folder. After you have done this, open Xcode from the Applications folder by double-clicking on the icon and then follow the remaining instructions below.
Install XCode command line developer tools:
@ -63,13 +53,33 @@ Install XCode command line developer tools:
Start XCode to get it updated and to able C compiler to create executables.
Older MacOSX SDK is available from here: [MacOSX-SDKs](https://github.com/phracker/MacOSX-SDKs)
### MacPort Installation
Install MacPort following this guide: [MacPort](http://guide.macports.org/#installing.xcode)
### HOMEBREW Installation
Install HomeBrew following this guide: [HomeBrew](http://brew.sh/)
#### Install libraries
$ brew install openssl
$ brew install miniupnpc
$ brew install libmicrohttpd
$ brew install rapidjson
$ brew install sqlcipher
For RNP lib:
$ brew install bzip2
$ brew install zlib
$ brew install json-c
$ brew install botan@2
#### Install CMake
$ brew install cmake
If you have error in linking, run this:
@ -85,8 +95,7 @@ For VOIP Plugin:
For FeedReader Plugin:
$ brew install libxslt
Get Your OSX SDK if missing: [MacOSX-SDKs](https://github.com/phracker/MacOSX-SDKs)
$ brew install libxml2
## Last Settings
@ -104,11 +113,8 @@ In QtCreator Projects -> Build -> Build Settings -> Build Steps -> Add Additiona
## Set your Mac OS SDK version
Edit RetroShare.pro
CONFIG += c++14 rs_macos11.1
and then retroshare.pri
Edit retroshare.pri and set your installed sdk version example for 11.1 -> rs_macos11.1 (line 135:)
macx:CONFIG *= rs_macos11.1
rs_macos10.8:CONFIG -= rs_macos11.1
@ -122,7 +128,7 @@ and then retroshare.pri
## Link Include & Libraries
Edit your retroshare.pri and add to macx-* section
When required edit your retroshare.pri macx-* section, check if the Include and Lib path are correct (macx-* section)
INCLUDEPATH += "/usr/local/opt/openssl/include"
QMAKE_LIBDIR += "/usr/local/opt/openssl/lib"
@ -131,13 +137,21 @@ Edit your retroshare.pri and add to macx-* section
alternative via Terminal
$ qmake INCLUDEPATH+="/usr/local/opt/openssl/include" QMAKE_LIBDIR+="/usr/local/opt/openssl/lib" QMAKE_LIBDIR+="/usr/local/opt/sqlcipher/lib" QMAKE_LIBDIR+="/usr/local/opt/miniupnpc/lib"
$ qmake
INCLUDEPATH+="/usr/local/opt/openssl/include" \
QMAKE_LIBDIR+="/usr/local/opt/openssl/lib" \
QMAKE_LIBDIR+="/usr/local/opt/sqlcipher/lib" \
QMAKE_LIBDIR+="/usr/local/opt/miniupnpc/lib" \
CONFIG+=rs_autologin \
CONFIG+=rs_use_native_dialogs \
CONFIG+=release \
..
For FeedReader Plugin:
INCLUDEPATH += "/usr/local/opt/libxml2/include/libxml2"
For building RetroShare with plugins:
With plugins:
$ qmake \
INCLUDEPATH+="/usr/local/opt/openssl/include" QMAKE_LIBDIR+="/usr/local/opt/openssl/lib" \
@ -159,13 +173,30 @@ For building RetroShare with plugins:
You can now compile RetroShare into Qt Creator or with Terminal
cd retroshare
qmake; make
$ cd /path/to/retroshare
$ qmake ..
$ make
You can change Target and SDK in *./retroshare.pri:82* changing value of QMAKE_MACOSX_DEPLOYMENT_TARGET and QMAKE_MAC_SDK
You can find the compiled application at *./retroshare/retroshare-gui/src/retroshare.app*
## Issues
If you have issues with openssl (Undefined symbols for architecture x86_64) try to add to *~/.profile* file this or via Terminal
export PATH="/usr/local/opt/openssl/bin:$PATH"
export LDFLAGS="-L/usr/local/opt/openssl/lib"
export CPPFLAGS="-I/usr/local/opt/openssl/include"
export PKG_CONFIG_PATH="/usr/local/opt/openssl/lib/pkgconfig"
For Qt Creator -> QtCreator Projects -> Build -> Build Settings -> Build Steps -> Add Additional arguments:
LDFLAGS="-L/usr/local/opt/openssl/lib"
CPPFLAGS="-I/usr/local/opt/openssl/include"
## Copy Plugins
$ cp \
@ -173,3 +204,13 @@ You can find the compiled application at *./retroshare/retroshare-gui/src/retros
./plugins/VOIP/lib/libVOIP.dylib \
./plugins/RetroChess/lib/libRetroChess.dylib \
./retroshare-gui/src/RetroShare.app/Contents/Resources/
### Compile Retroshare-Service & Webui with CMake
before you can compile overwrite the file "asio/include/asio/detail/config.hpp" here is a fix for macos [
asio fix](https://github.com/chriskohlhoff/asio/commit/68df16d560c68944809bb2947360fe8035e9ae0a)
$ cd retroshare-service
$ mkdir build-dir
$ cd build-dir
$ cmake -DRS_WEBUI=ON -DCMAKE_BUILD_TYPE=Release ..
$ make

224
build_scripts/OSX/deploy-macos.sh Executable file
View File

@ -0,0 +1,224 @@
#!/bin/bash
# ==============================================================================
# RetroShare macOS Portability & Deployment Packaging Script
# Designed for macOS environment with CMake
# ------------------------------------------------------------------------------
# Why this is more than a one-liner: macdeployqt IS the standard tool and does the
# heavy lifting (bundling Qt frameworks, fixing rpaths). The extra steps around it
# handle RetroShare specifics that macdeployqt does not cover:
# - RetroShare refuses to load plugins on macOS unless they end in ".dylib",
# so built plugins are copied/renamed accordingly.
# - macdeployqt skips .so plugins, so each plugin is passed via -executable=.
# - Qt imageformats (SVG) are force-copied (macdeployqt sometimes misses them).
# - Ad-hoc codesign is mandatory on Apple Silicon, otherwise the app won't run.
# ==============================================================================
set -e
# Always operate from the repository root, regardless of where this script lives
# (it resides under build_scripts/OSX/). All paths below are relative to the root.
cd "$(dirname "$0")/../.." || exit 1
# Build directory (override with: BUILD_DIR=mydir ./build_scripts/OSX/deploy-macos.sh)
BUILD_DIR="${BUILD_DIR:-Build-cmake}"
APP_NAME="RetroShare"
# 1. Vérifications initiales du dossier de build
if [ ! -d "$BUILD_DIR" ]; then
echo "ERROR: Build directory '$BUILD_DIR' not found. Please compile the project first!"
exit 1
fi
# On cherche l'application compilée, mais on exclut les dossiers de déploiement précédents
APP_BUNDLE=$(find "$BUILD_DIR" -maxdepth 3 -type d -name "retroshare-gui.app" ! -path "*/RetroShare-*" | head -n 1)
if [ -z "$APP_BUNDLE" ]; then
echo "ERROR: retroshare-gui.app not found in $BUILD_DIR. Please compile the GUI first."
exit 1
fi
echo "================================================================================"
echo " RETROSHARE MACOS DEPLOYMENT GENERATOR"
echo "================================================================================"
# 2. Détermination dynamique des variables de version
echo ">>> Extracting versioning info from Git and environment..."
DATE_STR=$(date +%Y%m%d)
GIT_DESC=$(git describe --tags --always --dirty 2>/dev/null || echo "0.6.7-unknown")
CLEAN_DESC=${GIT_DESC#v}
VERSION="$CLEAN_DESC"
GIT_SUFFIX=""
if [[ "$CLEAN_DESC" == *-* ]]; then
VERSION=$(echo "$CLEAN_DESC" | cut -d'-' -f1)
COMMIT_INFO=$(echo "$CLEAN_DESC" | cut -d'-' -f2-)
GIT_SUFFIX="-${DATE_STR}-${COMMIT_INFO}"
else
GIT_SUFFIX="-${DATE_STR}"
fi
# Detect the Qt version for the archive name (qmake reports it). Homebrew's qt@5
# is keg-only so its qmake is usually not in PATH; fall back to it, then to a
# generic label if nothing is found.
QT_VERSION=""
if command -v qmake &> /dev/null; then
QT_VERSION=$(qmake -query QT_VERSION 2>/dev/null)
fi
if [[ ! "$QT_VERSION" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
QT5_QMAKE="$(brew --prefix qt@5 2>/dev/null)/bin/qmake"
[ -x "$QT5_QMAKE" ] && QT_VERSION=$("$QT5_QMAKE" -query QT_VERSION 2>/dev/null)
fi
if [[ ! "$QT_VERSION" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
QT_VERSION="UnknownQt"
fi
MACVERSION=$(sw_vers -productVersion 2>/dev/null || echo "UnknownOS")
ARCH=$(uname -m)
ARCHIVE_BASE="RetroShare-${VERSION}-macOS-${ARCH}${GIT_SUFFIX}-Qt-${QT_VERSION}"
DEPLOY_DIR="${BUILD_DIR}/${ARCHIVE_BASE}"
echo " Target Package Name: ${ARCHIVE_BASE}"
echo " Deploy Directory: ${DEPLOY_DIR}"
echo ">>> Cleaning up previous deployment directories..."
rm -rf "${BUILD_DIR}/RetroShare-"*"-macOS-"*
mkdir -p "$DEPLOY_DIR"
# 3. Copie de l'application dans notre dossier de déploiement
echo ">>> Copying retroshare-gui.app..."
cp -R "$APP_BUNDLE" "$DEPLOY_DIR/"
TARGET_APP="$DEPLOY_DIR/$(basename "$APP_BUNDLE")"
echo ">>> Creating target directory layout..."
APP_RESOURCES="$TARGET_APP/Contents/Resources"
APP_MACOS="$TARGET_APP/Contents/MacOS"
mkdir -p "$APP_MACOS/extensions6"
mkdir -p "$APP_RESOURCES/sounds"
mkdir -p "$APP_RESOURCES/translations"
mkdir -p "$APP_RESOURCES/webui"
# 4. Copie des exécutables annexes (service, friendserver) s'ils existent (non-bloquant)
echo ">>> Copying additional executables if they exist..."
for exe in retroshare-service retroshare-friendserver; do
found_exe=$(find "$BUILD_DIR" -type f -name "$exe" -perm -0111 | grep -v "CMakeFiles" | head -n 1)
if [ -n "$found_exe" ]; then
echo " Found and copying: $found_exe"
cp "$found_exe" "$APP_MACOS/"
else
echo " INFO: Executable '$exe' not found. Skipping."
fi
done
# Copie des plugins
echo ">>> Copying RetroShare plugins..."
if [ -d "$BUILD_DIR/plugins" ]; then
mkdir -p "$APP_RESOURCES/extensions6"
for plugin in $(find "$BUILD_DIR/plugins" -type f \( -name "*.dylib" -o -name "*.so" \)); do
filename=$(basename "$plugin")
# RetroShare sur macOS refuse de charger les plugins s'ils ne finissent pas par .dylib !
newname="${filename%.*}.dylib"
cp "$plugin" "$APP_RESOURCES/$newname"
cp "$plugin" "$APP_RESOURCES/extensions6/$newname"
done
echo " Plugins copied and renamed to .dylib in $APP_RESOURCES/ and $APP_RESOURCES/extensions6/."
else
echo " INFO: Plugins directory not found. Skipping plugins."
fi
# 5. Copie des ressources statiques
echo ">>> Copying RetroShare static assets..."
if [ -d "retroshare-gui/src/sounds" ]; then
cp -r retroshare-gui/src/sounds/* "$APP_RESOURCES/sounds/" 2>/dev/null || true
fi
if [ -f "libbitdht/src/bitdht/bdboot.txt" ]; then
cp "libbitdht/src/bitdht/bdboot.txt" "$APP_RESOURCES/"
echo " Copied bdboot.txt"
fi
if [ -d "retroshare-gui/src/translations" ]; then
find "retroshare-gui/src/translations" -name "*.qm" -exec cp {} "$APP_RESOURCES/translations/" \; 2>/dev/null || true
fi
if [ -d "retroshare-webui/src" ]; then
cp -r retroshare-webui/src/* "$APP_RESOURCES/webui/" 2>/dev/null || true
echo " WebUI copied to app resources."
fi
# 6. Mise à jour du Info.plist
echo ">>> Updating Info.plist..."
PLIST_PATH="$TARGET_APP/Contents/Info.plist"
if command -v /usr/libexec/PlistBuddy &> /dev/null; then
/usr/libexec/PlistBuddy -c "Delete :CFBundleGetInfoString" "$PLIST_PATH" 2>/dev/null || true
/usr/libexec/PlistBuddy -c "Delete :CFBundleVersion" "$PLIST_PATH" 2>/dev/null || true
/usr/libexec/PlistBuddy -c "Add :CFBundleVersion string $VERSION" "$PLIST_PATH" 2>/dev/null || true
/usr/libexec/PlistBuddy -c "Delete :CFBundleShortVersionString" "$PLIST_PATH" 2>/dev/null || true
/usr/libexec/PlistBuddy -c "Add :CFBundleShortVersionString string $VERSION" "$PLIST_PATH" 2>/dev/null || true
/usr/libexec/PlistBuddy -c "Delete :NSRequiresAquaSystemAppearance" "$PLIST_PATH" 2>/dev/null || true
else
echo " WARNING: PlistBuddy not found, skipping Info.plist update."
fi
# 7. Déploiement Qt via macdeployqt
echo ">>> Running macdeployqt..."
if command -v macdeployqt &> /dev/null; then
# Forcer la copie des plugins d'images (SVG, etc.) au cas où macdeployqt les oublie
MACDEPLOY_BIN=$(command -v macdeployqt)
QT_BASE=$(dirname "$(dirname "$MACDEPLOY_BIN")")
QT_PLUGINS_DIR="$QT_BASE/share/qt/plugins"
if [ ! -d "$QT_PLUGINS_DIR" ]; then
QT_PLUGINS_DIR="$QT_BASE/plugins"
fi
if [ -d "$QT_PLUGINS_DIR/imageformats" ]; then
echo ">>> Forcing copy of Qt imageformats plugins (SVG support) from $QT_PLUGINS_DIR..."
mkdir -p "$TARGET_APP/Contents/PlugIns/imageformats"
cp "$QT_PLUGINS_DIR/imageformats/"*.dylib "$TARGET_APP/Contents/PlugIns/imageformats/" 2>/dev/null || true
fi
# Par défaut macdeployqt ignore les fichiers .so, il faut le forcer avec -executable
EXTRA_EXECS=""
for plugin in "$TARGET_APP"/Contents/Resources/*.so "$TARGET_APP"/Contents/Resources/*.dylib "$TARGET_APP"/Contents/Resources/extensions6/*.so "$TARGET_APP"/Contents/Resources/extensions6/*.dylib "$TARGET_APP"/Contents/PlugIns/imageformats/*.dylib; do
if [ -f "$plugin" ]; then
EXTRA_EXECS="$EXTRA_EXECS -executable=$plugin"
fi
done
# macdeployqt copie les frameworks et ajuste les rpaths
macdeployqt "$TARGET_APP" -always-overwrite $EXTRA_EXECS
echo ">>> Ad-hoc code signing (required for Apple Silicon)..."
if command -v codesign &> /dev/null; then
# On signe d'abord toutes les bibliothèques, plugins (.so/.dylib) et frameworks individuellement
find "$TARGET_APP" -type f \( -name "*.dylib" -o -name "*.so" \) -exec codesign --force --sign - {} \; 2>/dev/null || true
find "$TARGET_APP" -type d -name "*.framework" -exec codesign --force --sign - {} \; 2>/dev/null || true
# Puis on signe l'application entière
codesign --force --deep --sign - "$TARGET_APP"
fi
echo ">>> Creating dmg archive using hdiutil..."
DMG_FILE="${BUILD_DIR}/${ARCHIVE_BASE}.dmg"
rm -f "$DMG_FILE"
if command -v hdiutil &> /dev/null; then
hdiutil create -volname "${APP_NAME}" -srcfolder "$TARGET_APP" -ov -format UDZO "$DMG_FILE"
if [ -f "$DMG_FILE" ]; then
echo "================================================================================"
echo "SUCCESS: Standalone package created at: $DMG_FILE"
echo "================================================================================"
else
echo "WARNING: .dmg not generated."
fi
else
echo "WARNING: hdiutil not found, cannot create .dmg."
fi
else
echo " WARNING: macdeployqt tool not found in PATH! Make sure Qt is installed and its bin folder is in PATH."
echo " Cannot bundle Qt dependencies or create DMG automatically."
echo "================================================================================"
echo "SUCCESS: App bundle generated at: ${TARGET_APP}"
echo "================================================================================"
fi

View File

@ -0,0 +1,51 @@
#!/bin/sh
APP="RetroShare"
RSVERSION="0.6.7a"
QTVERSION="Qt-5.15.11"
# Install the 7z to create dmg archives.
#brew list p7zip || brew install p7zip
# Package your app
echo "Packaging retroshare..."
#cd ${project_dir}/build/macOS/clang/x86_64/release/
cd retroshare-gui/src/
# Remove build directories that you don't want to deploy
rm -rf moc
rm -rf obj
rm -rf qrc
# This sets the CFBundleVersion & CFBundleShortVersionString string
/usr/libexec/PlistBuddy -c "Delete :CFBundleGetInfoString" retroshare.app/Contents/Info.plist
/usr/libexec/PlistBuddy -c "Add :CFBundleVersion string $RSVERSION" retroshare.app/Contents/Info.plist
/usr/libexec/PlistBuddy -c "Add :CFBundleShortVersionString string $RSVERSION" retroshare.app/Contents/Info.plist
/usr/libexec/PlistBuddy -c "Delete :NSRequiresAquaSystemAppearance" retroshare.app/Contents/Info.plist
# This automatically creates retroshare.dmg
echo "Creating dmg archive..."
macdeployqt retroshare.app -dmg
DATE=`date +"%m-%d-%Y"`
MACVERSION=`sw_vers -productVersion`
#RSVERSION=`git describe --abbrev=0 --tags`
GITHEAD=`git rev-parse --short HEAD`
mv $APP.dmg "$APP-$RSVERSION-$GITHEAD-$DATE-MacOS-$MACVERSION-$QTVERSION.dmg"
# You can use the appdmg command line app to create your dmg file if
# you want to use a custom background and icon arrangement. I'm still
# working on this for my apps, myself. If you want to do this, you'll
# remove the -dmg option above.
# appdmg json-path YourApp_${TRAVIS_TAG}.dmg
# Copy other project files
cp "../../libbitdht/src/bitdht/bdboot.txt" "retroshare.app/Contents/Resources/"
cp "../../plugins/FeedReader/lib/libFeedReader.dylib" "retroshare.app/Contents/Resources/"
cp -R "sounds" "retroshare.app/Contents/Resources/sounds"
# cp "${project_dir}/README.md" "README.md"
# cp "${project_dir}/LICENSE" "LICENSE"
# cp "${project_dir}/Qt License" "Qt License"

View File

@ -0,0 +1,129 @@
## Compilation on Red Hat-based Linux
### Install package dependencies:
#### RedHat/Fedora
```bash
sudo dnf install mesa-libGL-devel gcc cmake rapidjson-devel \
libupnp openssl sqlcipher sqlcipher-devel \
botan2 botan2-devel json-c-devel bzip2-devel asio-devel libsecret libXScrnSaver-devel
```
To compile with Qt5:
```bash
sudo dnf install qt5-qtbase-devel qt5-qtmultimedia qt5-qtx11extras
```
To compile with Qt6:
```bash
sudo dnf install qt6-qtbase-devel qt6-qtmultimedia-devel qt6-qt5compat-devel
```
Additional dependencies for Feedreader plugin:
```bash
sudo dnf install libxml2-devel libxslt-devel libcurl-devel
```
### Checkout the source code
```bash
cd ~
git clone https://github.com/RetroShare/RetroShare.git retroshare
```
### Checkout the submodules
```bash
cd retroshare
git submodule update --init --remote libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/
git submodule update --init --remote supportlibs/librnp supportlibs/restbed supportlibs/rapidjson
```
### Compile
```bash
qmake CONFIG+=release CONFIG+=rs_jsonapi CONFIG+=rs_webui
make
```
The executable produced will be:
```bash
./retroshare-gui/src/retroshare
```
### Install
```bash
sudo make install
```
The executable produced will be:
```bash
~/usr/bin/RetroShare
```
### For packagers
Packagers can use PREFIX and LIB\_DIR to customize the installation paths:
```bash
qmake PREFIX=/usr LIB_DIR=/usr/lib64 "CONFIG-=debug" "CONFIG+=release"
make
make INSTALL_ROOT=${PKGDIR} install
```
### SQLCipher
If libsqlcipher is not available as a package
You need to place sqlcipher so that the hierarchy is:
~Home
|
+--- retroshare
|
+--- lib
|
+---- sqlcipher
```bash
mkdir lib
cd lib
git clone https://github.com/sqlcipher/sqlcipher.git --depth=1 --branch v3.4.1
cd sqlcipher
./configure --enable-tempstore=yes CFLAGS="-DSQLITE_HAS_CODEC" LDFLAGS="-lcrypto"
make
cd ..
```
### Build infos
Note: If you installed Qt6 you need to use `qmake6` on the command line.
For the `FeedReader` it is required to append the config option `CONFIG+=retroshare_plugins`.
Make sure `plugins/plugins.pro` contains `FeedReader` in the list of plugins to compile.
Do not mix plugins compiled with Qt5 with those compiled with Qt6. They work only if they are compiled
with the same Qt version as RetroShare.
Voip is outdated and is not compileable on the latest Debian.
For `Autologin` it is required to append the config option `CONFIG+=rs_autologin`.
### Build options
* Mandatory
* release or debug: normally you would like to use the release option
* Extra features (optional)
* rs_autologin: enable autologin
* retroshare_plugins: build plugins
* rs_webui: enable Web interface
* rs_jsonapi: enable json api interface, required by rs_webui
* gxsthewire: enable Wire service (experimental)
* wikipoos: enable Wiki service
* rs_use_native_dialogs: enable native dialogs (may cause crashes with some versions of Gtk)
* rs_deep_channels_index: build with deep channel indexing support
* rs_deep_files_index: build with deep file indexing support
* "CONFIG+=..." enable other extra compile time features, you can find the almost complete list in file *&lt;sourcefolder&gt;\retroshare.pri*
Example:
```batch
qmake CONFIG+=debug CONFIG+=release CONFIG+=rs_use_native_dialog CONFIG+=rs_gui_cmark
qmake CONFIG+=rs_jsonapi CONFIG+=rs_webui CONFIG+=rs_autologin
```

View File

@ -1,10 +1,11 @@
[Desktop Entry]
Encoding=UTF-8
Version=1.0
Name=RetroShare
Comment=Securely share files with your friends
Comment=Securely communicate with your friends
Exec=/usr/bin/retroshare %U
Icon=/usr/share/pixmaps/retroshare.xpm
Icon=retroshare.xpm
Terminal=false
Type=Application
Categories=Network;P2P;
Categories=Network;Email;InstantMessaging;Chat;Feed;FileTransfer;P2P
MimeType=x-scheme-handler/retroshare;

View File

@ -8,7 +8,7 @@ Requirements: about 12 GB of free space
The resulting binary is a 32-bit build of Retroshare which will also work
fine on a 64-bit system.
**If you want to make complet solution without debugging it, prefer to use \build_scripts\Windows-msys2\build.bat**
**If you want to make complete solution without debugging it, prefer to use \build_scripts\Windows-msys2\build.bat**
This batch will install and build all for you.
@ -18,8 +18,8 @@ At the end, you'll get at ..\\*-msys2\deploy\ the Portable 7zip file.
### MSYS2 INSTALLATION (for editing or debugging)
Download MSYS2 from [MSYS2](http://www.msys2.org/). Get the i686 version
if you run a 32-bit Windows or the x86_64 if you run a 64-bit Windows.
Download MSYS2 from [MSYS2](http://www.msys2.org/). Installing
MSYS2 requires 64 bit Windows 10 or newer.
Run the installer and install MSYS2.
@ -40,26 +40,29 @@ Run MSYS2 MSYS again and finish updating with:
Install the default programs needed to build:
pacman -S base-devel git wget p7zip gcc perl ruby python2 doxygen cmake
pacman -S base-devel git wget p7zip gcc perl ruby doxygen cmake
Install the 32-bit toolchain:
Install the 64-bit toolchain:
pacman -S mingw-w64-i686-toolchain
pacman -S mingw-w64-x86_64-toolchain
Install all needed dependencies:
pacman -S mingw-w64-i686-miniupnpc
pacman -S mingw-w64-i686-libmicrohttpd
pacman -S mingw-w64-i686-libxslt
pacman -S mingw-w64-i686-xapian-core
pacman -S mingw-w64-i686-sqlcipher
pacman -S mingw-w64-i686-qt5
pacman -S mingw32/mingw-w64-i686-cmake
pacman -S mingw-w64-i686-rapidjson
pacman -S mingw-w64-x86_64-miniupnpc
pacman -S mingw-w64-x86_64-libxslt
pacman -S mingw-w64-x86_64-xapian-core
pacman -S mingw-w64-x86_64-sqlcipher
pacman -S mingw-w64-x86_64-qt5-base
pacman -S mingw-w64-x86_64-qt5-multimedia
pacman -S mingw-w64-x86_64-ccmake
pacman -S mingw-w64-x86_64-rapidjson
pacman -S mingw-w64-x86_64-json-c
pacman -S mingw-w64-x86_64-libbotan
pacman -S mingw-w64-x86_64-asio
If you want to use QtCreator as IDE, prefer using this one publish by MSYS2 as all build Kit are already setted.
pacman -S mingw-w64-i686-qt-creator
pacman -S mingw-w64-x86_64-qt-creator
*You can start it from MSYS2 terminal.*
@ -67,7 +70,7 @@ We're done installing MSYS2, close the shell terminal.
### BUILDING RETROSHARE
Now run the MSYS2 MinGW 32-bit shell terminal (it's in the start menu).
Now run the MSYS2 MinGW 64-bit shell terminal (it's in the start menu).
We will use it to checkout Retroshare and build it:
git clone https://github.com/RetroShare/RetroShare.git

View File

@ -43,7 +43,9 @@ set NSIS_PARAM=%NSIS_PARAM% /DDEPLOYDIR="%RsDeployPath%"
set NSIS_PARAM=%NSIS_PARAM% /DOUTDIR="%RsPackPath%"
set NSIS_PARAM=%NSIS_PARAM% /DINSTALLERADD="%RsArchiveAdd%"
set NSIS_PARAM=%NSIS_PARAM% /DARCHITECTURE="%RsArchitecture%"
set NSIS_PARAM=%NSIS_PARAM% /DTOOLCHAIN="%RsToolchain%"
set NSIS_PARAM=%NSIS_PARAM% /DREVISION=%RsVersion.Extra%
set NSIS_PARAM=%NSIS_PARAM% /DQTVERSION=%QtVersion%
set QtMainVersion=%QtVersion:~0,1%
@ -53,7 +55,10 @@ rem makensis %NSIS_PARAM% "%SourcePath%\build_scripts\Windows-msys2\installer\re
rem pushd "%SourcePath%\build_scripts\Windows-msys2\installer"
rem %EnvMSYS2Cmd% "makensis $0 retroshare-Qt%QtMainVersion%.nsi" "%NSIS_PARAM%"
rem popd
"%RsMinGWPath%\bin\makensis" %NSIS_PARAM% "%SourcePath%\build_scripts\Windows-msys2\installer\retroshare-Qt%QtMainVersion%.nsi"
rem Currently no need for separate nsi files
rem "%RsMinGWPath%\bin\makensis" %NSIS_PARAM% "%SourcePath%\build_scripts\Windows-msys2\installer\retroshare-Qt%QtMainVersion%.nsi"
"%RsMinGWPath%\bin\makensis" %NSIS_PARAM% "%SourcePath%\build_scripts\Windows-msys2\installer\retroshare.nsi"
exit /B %ERRORLEVEL%

View File

@ -15,18 +15,22 @@ call "%~dp0env-base.bat" %*
if errorlevel 2 exit /B 2
if errorlevel 1 goto error_env
title Build - %SourceName%-%RsBuildConfig% Qt-%QtVersion% %RsToolchain% [Prerequisites]
if not "%ParamNoupdate%"=="1" (
:: Install needed things
%EnvMSYS2Cmd% "pacman --noconfirm --needed -S make git mingw-w64-%RsMSYS2Architecture%-toolchain mingw-w64-%RsMSYS2Architecture%-qt5 mingw-w64-%RsMSYS2Architecture%-miniupnpc mingw-w64-%RsMSYS2Architecture%-sqlcipher mingw-w64-%RsMSYS2Architecture%-cmake mingw-w64-%RsMSYS2Architecture%-rapidjson"
%EnvMSYS2Cmd% "pacman --noconfirm --needed -S make git mingw-w64-%RsMSYS2Architecture%-toolchain mingw-w64-%RsMSYS2Architecture%-qt%ParamQtVersion% mingw-w64-%RsMSYS2Architecture%-miniupnpc mingw-w64-%RsMSYS2Architecture%-sqlcipher mingw-w64-%RsMSYS2Architecture%-cmake mingw-w64-%RsMSYS2Architecture%-rapidjson"
:: rnp
%EnvMSYS2Cmd% "pacman --noconfirm --needed -S mingw-w64-%RsMSYS2Architecture%-json-c mingw-w64-%RsMSYS2Architecture%-libbotan"
:: Webui
if "%ParamWebui%"=="1" %EnvMSYS2Cmd% "pacman --noconfirm --needed -S mingw-w64-%RsMSYS2Architecture%-doxygen"
if "%ParamWebui%"=="1" %EnvMSYS2Cmd% "pacman --noconfirm --needed -S mingw-w64-%RsMSYS2Architecture%-doxygen mingw-w64-%RsMSYS2Architecture%-asio"
:: Plugins
if "%ParamPlugins%"=="1" %EnvMSYS2Cmd% "pacman --noconfirm --needed -S mingw-w64-%RsMSYS2Architecture%-speex mingw-w64-%RsMSYS2Architecture%-speexdsp mingw-w64-%RsMSYS2Architecture%-curl mingw-w64-%RsMSYS2Architecture%-libxslt mingw-w64-%RsMSYS2Architecture%-opencv mingw-w64-%RsMSYS2Architecture%-ffmpeg"
:: Clang
if "%ParamClang%"=="1" %EnvMSYS2Cmd% "pacman --noconfirm --needed -S mingw-w64-%RsMSYS2Architecture%-clang"
if "%ClangCompiler%"=="1" %EnvMSYS2Cmd% "pacman --noconfirm --needed -S mingw-w64-%RsMSYS2Architecture%-clang"
:: Indexing
if "%ParamIndexing%"=="1" %EnvMSYS2Cmd% "pacman --noconfirm --needed -S mingw-w64-%RsMSYS2Architecture%-xapian-core mingw-w64-%RsMSYS2Architecture%-libvorbis mingw-w64-%RsMSYS2Architecture%-flac mingw-w64-%RsMSYS2Architecture%-taglib"
@ -51,7 +55,7 @@ echo.
echo === Version
echo.
title Build - %SourceName%-%RsBuildConfig% [Version]
title Build - %SourceName%-%RsBuildConfig% Qt-%QtVersion% %RsToolchain% [Version]
pushd "%SourcePath%\retroshare-gui\src\gui\images"
:: Touch resource file
@ -65,7 +69,7 @@ echo.
echo === qmake
echo.
title Build - %SourceName%-%RsBuildConfig% [qmake]
title Build - %SourceName%-%RsBuildConfig% Qt-%QtVersion% %RsToolchain% [qmake]
set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% "CONFIG+=%RsBuildConfig%"
if "%ParamAutologin%"=="1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% "CONFIG+=rs_autologin"
@ -77,14 +81,13 @@ echo %RsBuildConfig% >> buildinfo.txt
echo %RsArchitecture% >> buildinfo.txt
echo Qt %QtVersion% >> buildinfo.txt
echo %RsToolchain% >> buildinfo.txt
echo %RsCompiler% >> buildinfo.txt
call "%ToolsPath%\msys2-path.bat" "%SourcePath%" MSYS2SourcePath
call "%ToolsPath%\msys2-path.bat" "%EnvMSYS2Path%" MSYS2EnvMSYS2Path
if "%ParamClang%"=="1" (
%EnvMSYS2Cmd% "qmake "%MSYS2SourcePath%/RetroShare.pro" -r -spec win32-clang-g++ %RS_QMAKE_CONFIG%"
if "%ClangCompiler%"=="1" (
%EnvMSYS2Cmd% "%QMakeCmd% "%MSYS2SourcePath%/RetroShare.pro" -r -spec win32-clang-g++ %RS_QMAKE_CONFIG%"
) else (
%EnvMSYS2Cmd% "qmake "%MSYS2SourcePath%/RetroShare.pro" -r -spec win32-g++ %RS_QMAKE_CONFIG%"
%EnvMSYS2Cmd% "%QMakeCmd% "%MSYS2SourcePath%/RetroShare.pro" -r -spec win32-g++ %RS_QMAKE_CONFIG%"
)
if errorlevel 1 goto error
@ -92,7 +95,7 @@ echo.
echo === make
echo.
title Build - %SourceName%-%RsBuildConfig% [make]
title Build - %SourceName%-%RsBuildConfig% Qt-%QtVersion% %RsToolchain% [make]
%EnvMSYS2Cmd% "make -j %CoreCount%"
if errorlevel 1 goto error

View File

@ -5,14 +5,16 @@ set ParamAutologin=0
set ParamPlugins=0
set ParamTor=0
set ParamWebui=0
set ParamClang=0
set ClangCompiler=0
set ParamIndexing=0
set ParamFriendserver=0
set ParamNoupdate=0
set CoreCount=%NUMBER_OF_PROCESSORS%
set RS_QMAKE_CONFIG=
set RsToolchain=
set ParamQtVersion=5
set tcc=0
set QtVersionCount=0
:parameter_loop
if "%~1" NEQ "" (
@ -43,6 +45,12 @@ if "%~1" NEQ "" (
set /A tcc=tcc+1
) else if "%%~a"=="release" (
set ParamRelease=1
) else if "%%~a"=="qt5" (
set ParamQtVersion=5
set /A QtVersionCount+=1
) else if "%%~a"=="qt6" (
set ParamQtVersion=6
set /A QtVersionCount+=1
) else if "%%~a"=="debug" (
set ParamDebug=1
) else if "%%~a"=="autologin" (
@ -55,8 +63,6 @@ if "%~1" NEQ "" (
set ParamWebui=1
) else if "%%~a"=="singlethread" (
set CoreCount=1
) else if "%%~a"=="clang" (
set ParamClang=1
) else if "%%~a"=="indexing" (
set ParamIndexing=1
) else if "%%~a"=="friendserver" (
@ -80,6 +86,16 @@ if %tcc% NEQ 1 (
goto :usage
)
if %QtVersionCount% GTR 1 (
echo Multiple Qt versions specified
goto :usage
)
if "%ParamQtVersion%" NEQ "5" if "%ParamQtVersion%" NEQ "6" (
echo Wrong Qt version specified
goto :usage
)
if "%RsToolchain%"=="mingw32" (
set RsArchitecture=x86
set RsMSYS2Architecture=i686
@ -96,24 +112,18 @@ if "%RsToolchain%"=="mingw32" (
set RsArchitecture=x64
set RsMSYS2Architecture=clang-x86_64
set MSYSTEM=CLANG64
set ParamClang=1
set ClangCompiler=1
) else if "%RsToolchain%"=="clang32" (
set RsArchitecture=x86
set RsMSYS2Architecture=clang-i686
set MSYSTEM=CLANG32
set ParamClang=1
set ClangCompiler=1
) else if "%RsToolchain%"=="clangarm64" (
set RsArchitecture=arm64
set RsMSYS2Architecture=clang-aarch64
set MSYSTEM=CLANGARM64
)
if "%ParamClang%"=="1" (
set RsCompiler=Clang
) else (
set RsCompiler=GCC
)
if "%ParamRelease%"=="1" (
if "%ParamDebug%"=="1" (
echo.
@ -148,7 +158,7 @@ exit /B 0
:usage
echo.
echo Usage: 32^|64^|other release^|debug [autologin plugins webui singlethread clang indexing friendserver noupdate] ["CONFIG+=..."]
echo Usage: 32^|64^|other release^|debug qt5^|qt6 [autologin plugins webui singlethread clang indexing friendserver noupdate] ["CONFIG+=..."]
echo.
echo Mandatory parameter
echo 32^|64 32-bit or 64-bit version (same as mingw32 or mingw64)
@ -156,13 +166,13 @@ echo Or you can specify any other toolchain supported by msys
echo mingw32^|mingw64^|clang32^|clang64^|ucrt64^|clangarm64
echo More info: https://www.msys2.org/docs/environments
echo release^|debug Build release or debug version
echo qt5^|qt6 Build with Qt 5 (default) or Qt 6
echo.
echo Optional parameter (need clean when changed)
echo autologin Build with autologin
echo plugins Build plugins
echo webui Enable JsonAPI and pack webui files
echo singlethread Use only 1 thread for building
echo clang Use clang compiler instead of GCC
echo indexing Build with deep channel and file indexing support
echo friendserver Enable friendserver support
echo noupdate Skip updating the libraries

View File

@ -1,6 +1,6 @@
call "%~dp0env-base.bat" %*
if errorlevel 2 exit /B 2
if errorlevel 1 goto error_env
if errorlevel 1 exit /B 1
set BuildPath=%EnvRootPath%\builds
set DeployPath=%EnvRootPath%\deploy
@ -8,14 +8,20 @@ set DeployPath=%EnvRootPath%\deploy
if not exist "%BuildPath%" mkdir "%BuildPath%"
if not exist "%DeployPath%" mkdir "%DeployPath%"
set QMakeCmd=
if "%ParamQtVersion%"=="5" set QMakeCmd=qmake-qt5
if "%ParamQtVersion%"=="6" set QMakeCmd=qmake6
if "%QMakeCmd%"=="" %cecho% error "Unknown Qt version %ParamQtVersion%." & exit /B 1
:: Get Qt version
call "%ToolsPath%\get-qt-version.bat" QtVersion
call "%ToolsPath%\get-qt-version.bat" QtVersion %QMakeCmd%
if errorlevel 1 %cecho% error "Cannot get Qt version." & exit /B 1
if "%QtVersion%"=="" %cecho% error "Cannot get Qt version." & exit /B 1
set RsMinGWPath=%EnvMSYS2BasePath%\%RsToolchain%
set RsBuildPath=%BuildPath%\Qt-%QtVersion%-%RsToolchain%-%RsCompiler%-%RsBuildConfig%
set RsDeployPath=%DeployPath%\Qt-%QtVersion%%RsType%-%RsToolchain%-%RsCompiler%-%RsBuildConfig%
set RsBuildPath=%BuildPath%\Qt-%QtVersion%-%RsToolchain%-%RsBuildConfig%
set RsDeployPath=%DeployPath%\Qt-%QtVersion%-%RsToolchain%%RsType%-%RsBuildConfig%
set RsPackPath=%DeployPath%
set RsArchiveAdd=
set RsWebuiBuildPath=%RsBuildPath%\retroshare-webui\webui

View File

@ -55,25 +55,28 @@ set RsVersion=%RsVersion.Major%.%RsVersion.Minor%.%RsVersion.Mini%
:: Check WMIC is available
wmic.exe alias /? >nul 2>&1 || echo WMIC is not available.&& goto error
:: Use WMIC to retrieve date in format YYYYMMDD
set RsDate=
for /f "tokens=2 delims==" %%I in ('wmic os get localdatetime /format:list') do set RsDate=%%I
set RsDate=%RsDate:~0,4%%RsDate:~4,2%%RsDate:~6,2%
:: Get date
call "%ToolsPath%\get-rs-date.bat" "%SourcePath%" RsDate
if errorlevel 1 %cecho% error "Could not get date."& goto error
if "%RsDate%"=="" %cecho% error "Could not get date."& goto error
set QtMainVersion=%QtVersion:~0,1%
set QtSharePath=%RsMinGWPath%\share\qt%QtMainVersion%\
rem Qt 4 = QtSvg4.dll
rem Qt 5 = Qt5Svg.dll
rem Qt 6 = Qt6Svg.dll
set QtMainVersion1=
set QtMainVersion2=
if "%QtMainVersion%"=="4" set QtMainVersion2=4
if "%QtMainVersion%"=="5" set QtMainVersion1=5
if "%QtMainVersion%"=="6" set QtMainVersion1=6
if "%RsBuildConfig%" NEQ "release" (
set Archive=%RsPackPath%\RetroShare-%RsVersion%-Windows-Portable-%RsDate%-%RsVersion.Extra%-%RsArchitecture%-msys2%RsType%%RsArchiveAdd%-%RsBuildConfig%.7z
set Archive=%RsPackPath%\RetroShare-%RsVersion%-Windows-Portable-%RsDate%-%RsVersion.Extra%-Qt-%QtVersion%-%RsToolchain%-msys2%RsType%%RsArchiveAdd%-%RsBuildConfig%.7z
) else (
set Archive=%RsPackPath%\RetroShare-%RsVersion%-Windows-Portable-%RsDate%-%RsVersion.Extra%-%RsArchitecture%-msys2%RsType%%RsArchiveAdd%.7z
set Archive=%RsPackPath%\RetroShare-%RsVersion%-Windows-Portable-%RsDate%-%RsVersion.Extra%-Qt-%QtVersion%-%RsToolchain%-msys2%RsType%%RsArchiveAdd%.7z
)
if exist "%Archive%" del /Q "%Archive%"
@ -81,7 +84,7 @@ if exist "%Archive%" del /Q "%Archive%"
:: Create deploy path
mkdir "%RsDeployPath%"
title Pack - %SourceName%%RsType%-%RsBuildConfig% [copy files]
title Pack - %SourceName%%RsType%-%RsBuildConfig% Qt-%QtVersion% %RsToolchain% [copy files]
set ExtensionsFile=%SourcePath%\libretroshare\src\rsserver\rsinit.cc
set Extensions=
@ -105,6 +108,7 @@ copy "%RsBuildPath%\retroshare-nogui\src\%RsBuildConfig%\retroshare*-nogui.exe"
copy "%RsBuildPath%\retroshare-service\src\%RsBuildConfig%\retroshare*-service.exe" "%RsDeployPath%" %Quite%
copy "%RsBuildPath%\supportlibs\cmark\build\src\libcmark.dll" "%RsDeployPath%" %Quite%
if exist "%RsBuildPath%\libretroshare\src\lib\retroshare.dll" copy "%RsBuildPath%\libretroshare\src\lib\retroshare.dll" "%RsDeployPath%" %Quite%
if exist "%RsBuildPath%\supportlibs\librnp\Build\src\lib\librnp.dll" copy "%RsBuildPath%\supportlibs\librnp\Build\src\lib\librnp.dll" "%RsDeployPath%" %Quite%
if exist "%RsBuildPath%\retroshare-friendserver\src\%RsBuildConfig%\retroshare-friendserver.exe" (
copy "%RsBuildPath%\retroshare-friendserver\src\%RsBuildConfig%\retroshare-friendserver.exe" "%RsDeployPath%" %Quite%
)
@ -117,18 +121,24 @@ for /D %%D in ("%RsBuildPath%\plugins\*") do (
echo copy Qt DLL's
copy "%RsMinGWPath%\bin\Qt%QtMainVersion1%Svg%QtMainVersion2%.dll" "%RsDeployPath%" %Quite%
if "%QtMainVersion%"=="5" (
if %QtMainVersion% GEQ 5 (
mkdir "%RsDeployPath%\platforms"
copy "%QtSharePath%\plugins\platforms\qwindows.dll" "%RsDeployPath%\platforms" %Quite%
)
if "%QtMainVersion%"=="5" (
mkdir "%RsDeployPath%\audio"
copy "%QtSharePath%\plugins\audio\qtaudio_windows.dll" "%RsDeployPath%\audio" %Quite%
)
if exist "%QtSharePath%\plugins\styles\qwindowsvistastyle.dll" (
echo copy styles
mkdir "%RsDeployPath%\styles" %Quite%
echo copy styles
mkdir "%RsDeployPath%\styles" %Quite%
if "%QtMainVersion%"=="5" (
copy "%QtSharePath%\plugins\styles\qwindowsvistastyle.dll" "%RsDeployPath%\styles" %Quite%
)
if "%QtMainVersion%"=="6" (
copy "%QtSharePath%\plugins\styles\qmodernwindowsstyle.dll" "%RsDeployPath%\styles" %Quite%
)
copy "%QtSharePath%\plugins\imageformats\*.dll" "%RsDeployPath%\imageformats" %Quite%
del /Q "%RsDeployPath%\imageformats\*d?.dll" %Quite%
@ -169,11 +179,13 @@ xcopy /S "%SourcePath%\retroshare-gui\src\license" "%RsDeployPath%\license" %Qui
echo copy translation
copy "%SourcePath%\retroshare-gui\src\translations\qt_tr.qm" "%RsDeployPath%\translations" %Quite%
copy "%QtSharePath%\translations\qt_*.qm" "%RsDeployPath%\translations" %Quite%
if "%QtMainVersion%"=="5" (
if "%QtMainVersion%"=="6" (
copy "%QtSharePath%\translations\qtbase_*.qm" "%RsDeployPath%\translations" %Quite%
copy "%QtSharePath%\translations\qtscript_*.qm" "%RsDeployPath%\translations" %Quite%
copy "%QtSharePath%\translations\qtquick1_*.qm" "%RsDeployPath%\translations" %Quite%
copy "%QtSharePath%\translations\qtmultimedia_*.qm" "%RsDeployPath%\translations" %Quite%
)
if "%QtMainVersion%"=="5" (
copy "%QtSharePath%\translations\qtscript_*.qm" "%RsDeployPath%\translations" %Quite%
copy "%QtSharePath%\translations\qtxmlpatterns_*.qm" "%RsDeployPath%\translations" %Quite%
)
@ -198,7 +210,7 @@ if "%ParamWebui%"=="1" (
)
rem pack files
title Pack - %SourceName%%RsType%-%RsBuildConfig% [pack files]
title Pack - %SourceName%%RsType%-%RsBuildConfig% Qt-%QtVersion% %RsToolchain% [pack files]
"%EnvSevenZipExe%" a -mx=9 -t7z "%Archive%" "%RsDeployPath%\*"

View File

@ -0,0 +1,374 @@
#!/bin/bash
# ==============================================================================
# RetroShare Windows Portability & Deployment Packaging Script
# Designed for MSYS2 MinGW64 Shell environment
# ------------------------------------------------------------------------------
# Why this is more than a one-liner: windeployqt IS the standard tool and does the
# heavy lifting (bundling Qt DLLs/plugins). The extra steps around it handle MSYS2
# /MinGW + RetroShare specifics that windeployqt does not reliably cover:
# - Manual fallback copy of the Qt 'platforms'/'styles'/'imageformats' plugins,
# which windeployqt sometimes misses under MSYS2.
# - Recursive ldd-based resolution of MinGW runtime DLLs (compiler runtime,
# 3rd-party libs) into the portable folder.
# - RetroShare's portable layout (Data/extensions6 for plugins, qss/stylesheets/
# sounds/translations) and the 'portable' marker file.
# ==============================================================================
set -e
# Toujours travailler depuis la racine du dépôt (ce script vit sous
# build_scripts/Windows-msys2/), sinon les chemins relatifs (retroshare-gui/src,
# libbitdht, ...) sont muets et produisent un paquet incomplet sans erreur.
cd "$(dirname "$0")/../.." || exit 1
# Build directory (override with: BUILD_DIR=mydir ./build_scripts/Windows-msys2/deploy-windows.sh)
BUILD_DIR="${BUILD_DIR:-Build-cmake}"
# Préfixe de l'environnement MSYS2 utilisé pour la compilation
# (mingw64 / ucrt64 / clang64). Indispensable pour retrouver le runtime
# compilateur et les plugins Qt quel que soit l'environnement employé.
MINGW_PREFIX="${MSYSTEM_PREFIX:-/mingw64}"
# 1. Vérifications initiales du dossier de build
if [ ! -d "$BUILD_DIR" ]; then
echo "ERROR: Build directory '$BUILD_DIR' not found. Please compile the project first!"
exit 1
fi
echo "================================================================================"
echo " RETROSHARE WINDOWS DEPLOYMENT GENERATOR"
echo "================================================================================"
# 2. Détermination dynamique des variables de version (inspiré de qmake)
echo ">>> Extracting versioning info from Git and environment..."
# Date au format YYYYMMDD
DATE_STR=$(date +%Y%m%d)
# Récupération du describe de Git (ex: v0.6.7.2-892-g5341b777d-dirty)
GIT_DESC=$(git describe --tags --always --dirty 2>/dev/null || echo "0.6.7-unknown")
CLEAN_DESC=${GIT_DESC#v} # Enlève le 'v' initial
# Valeurs par défaut
VERSION="$CLEAN_DESC"
GIT_SUFFIX=""
if [[ "$CLEAN_DESC" == *-* ]]; then
# Format: tag-commits-hash[-dirty] (ex: 0.6.7.2-892-g5341b777d-dirty)
VERSION=$(echo "$CLEAN_DESC" | cut -d'-' -f1)
COMMIT_INFO=$(echo "$CLEAN_DESC" | cut -d'-' -f2-)
GIT_SUFFIX="-${DATE_STR}-${COMMIT_INFO}"
else
# Si on est pile sur un tag
GIT_SUFFIX="-${DATE_STR}"
fi
# Recherche de l'exécutable windeployqt adéquat
WINDEPLOYQT_CMD=""
for cmd in windeployqt windeployqt-qt5 windeployqt-qt6; do
if command -v "$cmd" &> /dev/null; then
WINDEPLOYQT_CMD="$cmd"
break
fi
done
# Détection de la version de Qt
QT_VERSION=""
if command -v qmake &> /dev/null; then
QT_VERSION=$(qmake -query QT_VERSION 2>/dev/null)
fi
# Si qmake n'a pas donné de version propre, on cherche avec windeployqt
if [[ ! "$QT_VERSION" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]] && [ -n "$WINDEPLOYQT_CMD" ]; then
QT_VERSION=$("$WINDEPLOYQT_CMD" --version 2>/dev/null | grep -o -E '[0-9]+\.[0-9]+\.[0-9]+' | head -n 1 || echo "")
fi
# Valeur de secours si rien n'a été détecté ou si la version est invalide
if [[ ! "$QT_VERSION" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
QT_VERSION="5.15.18"
fi
# Nom de base de l'archive finale
ARCHIVE_BASE="RetroShare-${VERSION}-Windows-Portable${GIT_SUFFIX}-Qt-${QT_VERSION}-mingw64-msys2"
DEPLOY_DIR="${BUILD_DIR}/${ARCHIVE_BASE}"
echo " Target Package Name: ${ARCHIVE_BASE}"
echo " Deploy Directory: ${DEPLOY_DIR}"
# Nettoyage des anciennes générations de déploiement
echo ">>> Cleaning up previous deployment directories..."
# Ne supprimer que les anciens RÉPERTOIRES de déploiement, pas les archives
# .7z / .zip produites lors des runs précédents (qui matchent le même motif).
find "$BUILD_DIR" -maxdepth 1 -type d -name "RetroShare-*-Windows-Portable*" -exec rm -rf {} + 2>/dev/null || true
mkdir -p "$DEPLOY_DIR"
# 3. Création de l'arborescence complète attendue par RetroShare
echo ">>> Creating target directory layout..."
mkdir -p "$DEPLOY_DIR/Data/extensions6" # Répertoire pour les plugins de RetroShare
mkdir -p "$DEPLOY_DIR/qss" # Feuilles de style de l'interface
mkdir -p "$DEPLOY_DIR/stylesheets" # Feuilles de style de la messagerie
mkdir -p "$DEPLOY_DIR/sounds" # Sons système de l'interface
mkdir -p "$DEPLOY_DIR/translations" # Fichiers de traductions (RetroShare + Qt)
mkdir -p "$DEPLOY_DIR/license" # Fichiers de licences
mkdir -p "$DEPLOY_DIR/log" # Dossier de logs de fonctionnement
# 4. Création du fichier témoin 'portable'
echo ">>> Creating 'portable' mode indicator file..."
touch "$DEPLOY_DIR/portable"
# 5. Copie des exécutables et DLL générées par la compilation
echo ">>> Copying compiled binaries..."
for exe in retroshare-gui.exe retroshare-service.exe retroshare-friendserver.exe; do
found_exe=$(find "$BUILD_DIR" -path "$DEPLOY_DIR" -prune -o -name "$exe" -print | head -n 1)
if [ -n "$found_exe" ]; then
echo " Found and copying: $found_exe"
cp "$found_exe" "$DEPLOY_DIR/"
else
echo " WARNING: Executable '$exe' not found. Skipping."
fi
done
echo ">>> Copying local build libraries (DLLs)..."
# Recherche et copie des DLL compilées en interne dans le projet (RNP, CMark, RetroShare, Restbed)
# NB: on élague "$DEPLOY_DIR" (situé sous "$BUILD_DIR") pour éviter de re-trouver
# les DLL déjà copiées et de déployer par erreur une variante stale.
find "$BUILD_DIR" -path "$DEPLOY_DIR" -prune -o -name "libcmark.dll" -exec cp {} "$DEPLOY_DIR/" \; 2>/dev/null || true
find "$BUILD_DIR" -path "$DEPLOY_DIR" -prune -o -name "*retroshare.dll" -exec cp {} "$DEPLOY_DIR/" \; 2>/dev/null || true
find "$BUILD_DIR" -path "$DEPLOY_DIR" -prune -o -name "*restbed*.dll" -exec cp {} "$DEPLOY_DIR/" \; 2>/dev/null || true
if [ -d "supportlibs/librnp/Build" ]; then
find "supportlibs/librnp/Build" -name "librnp.dll" -exec cp {} "$DEPLOY_DIR/" \; 2>/dev/null || true
fi
find "$BUILD_DIR" -path "$DEPLOY_DIR" -prune -o -name "librnp.dll" -exec cp {} "$DEPLOY_DIR/" \; 2>/dev/null || true
echo ">>> Copying RetroShare plugins..."
if [ -d "$BUILD_DIR/plugins" ]; then
find "$BUILD_DIR/plugins" -name "*.dll" -exec cp {} "$DEPLOY_DIR/Data/extensions6/" \; 2>/dev/null || true
echo " Plugins copied to Data/extensions6."
else
echo " WARNING: Plugins directory not found. Skipping plugins."
fi
# 6. Copie des ressources statiques de RetroShare (QSS, sons, etc.)
echo ">>> Copying RetroShare static assets..."
if [ -d "retroshare-gui/src/qss" ]; then
cp -r retroshare-gui/src/qss/* "$DEPLOY_DIR/qss/" 2>/dev/null || true
fi
if [ -d "retroshare-gui/src/gui/qss/chat" ]; then
cp -r retroshare-gui/src/gui/qss/chat/* "$DEPLOY_DIR/stylesheets/" 2>/dev/null || true
# Supprime les répertoires inutiles d'après le pack.bat historique
rm -rf "$DEPLOY_DIR/stylesheets/compact" "$DEPLOY_DIR/stylesheets/standard"
fi
if [ -d "retroshare-gui/src/sounds" ]; then
cp -r retroshare-gui/src/sounds/* "$DEPLOY_DIR/sounds/" 2>/dev/null || true
fi
if [ -d "retroshare-gui/src/license" ]; then
cp -r retroshare-gui/src/license/* "$DEPLOY_DIR/license/" 2>/dev/null || true
fi
if [ -f "libbitdht/src/bitdht/bdboot.txt" ]; then
cp "libbitdht/src/bitdht/bdboot.txt" "$DEPLOY_DIR/"
echo " Copied bdboot.txt"
fi
# 7. Copie des fichiers de traduction
echo ">>> Copying translations (RetroShare + Qt system)..."
if [ -d "retroshare-gui/src/translations" ]; then
find "retroshare-gui/src/translations" -name "*.qm" -exec cp {} "$DEPLOY_DIR/translations/" \; 2>/dev/null || true
fi
# Copie des traductions Qt de l'environnement MSYS2 MinGW64
QT_TRANS_DIR="$MINGW_PREFIX/share/qt5/translations"
if [ -d "$QT_TRANS_DIR" ]; then
cp "$QT_TRANS_DIR"/qt_*.qm "$DEPLOY_DIR/translations/" 2>/dev/null || true
fi
QT6_TRANS_DIR="$MINGW_PREFIX/share/qt6/translations"
if [ -d "$QT6_TRANS_DIR" ]; then
cp "$QT6_TRANS_DIR"/qt_*.qm "$DEPLOY_DIR/translations/" 2>/dev/null || true
cp "$QT6_TRANS_DIR"/qtbase_*.qm "$DEPLOY_DIR/translations/" 2>/dev/null || true
fi
# 8. Déploiement des dépendances Qt via windeployqt
if [ -f "$DEPLOY_DIR/retroshare-gui.exe" ]; then
if [ -n "$WINDEPLOYQT_CMD" ]; then
echo ">>> Running $WINDEPLOYQT_CMD on retroshare-gui.exe..."
# Convert path to Windows-style for the native windeployqt tool if cygpath is available
if command -v cygpath &> /dev/null; then
WIN_EXE_PATH=$(cygpath -w "$DEPLOY_DIR/retroshare-gui.exe")
echo " Using Windows path: $WIN_EXE_PATH"
"$WINDEPLOYQT_CMD" --no-compiler-runtime "$WIN_EXE_PATH" || true
else
"$WINDEPLOYQT_CMD" --no-compiler-runtime "$DEPLOY_DIR/retroshare-gui.exe" || true
fi
else
echo " WARNING: windeployqt tool not found in PATH! Make sure Qt package is installed."
fi
fi
# Fallback manuel pour les plugins Qt essentiels (comme 'platforms' et 'styles')
# Indispensable si windeployqt a échoué ou n'était pas présent.
if [ ! -d "$DEPLOY_DIR/platforms" ] || [ ! -f "$DEPLOY_DIR/platforms/qwindows.dll" ]; then
echo ">>> Manual fallback: Copying Qt 'platforms' directory (qwindows.dll)..."
mkdir -p "$DEPLOY_DIR/platforms"
COPIED_PLATFORMS=false
for path in \
"$MINGW_PREFIX/share/qt6/plugins/platforms/qwindows.dll" \
"$MINGW_PREFIX/share/qt5/plugins/platforms/qwindows.dll" \
"$MINGW_PREFIX/lib/qt6/plugins/platforms/qwindows.dll" \
"$MINGW_PREFIX/lib/qt5/plugins/platforms/qwindows.dll"; do
if [ -f "$path" ]; then
echo " Found platforms plugin at: $path"
cp "$path" "$DEPLOY_DIR/platforms/"
COPIED_PLATFORMS=true
break
fi
done
if [ "$COPIED_PLATFORMS" = false ]; then
echo " WARNING: Could not find qwindows.dll in standard MSYS2 paths!"
fi
fi
if [ ! -d "$DEPLOY_DIR/styles" ] || [ ! -f "$DEPLOY_DIR/styles/qwindowsvistastyle.dll" ]; then
echo ">>> Manual fallback: Copying Qt 'styles' directory (qwindowsvistastyle.dll)..."
mkdir -p "$DEPLOY_DIR/styles"
for path in \
"$MINGW_PREFIX/share/qt6/plugins/styles/qwindowsvistastyle.dll" \
"$MINGW_PREFIX/share/qt5/plugins/styles/qwindowsvistastyle.dll" \
"$MINGW_PREFIX/lib/qt6/plugins/styles/qwindowsvistastyle.dll" \
"$MINGW_PREFIX/lib/qt5/plugins/styles/qwindowsvistastyle.dll"; do
if [ -f "$path" ]; then
echo " Found styles plugin at: $path"
cp "$path" "$DEPLOY_DIR/styles/"
break
fi
done
fi
echo ">>> Deploying Qt 'imageformats' directory (essential for SVG/ICO icons)..."
mkdir -p "$DEPLOY_DIR/imageformats"
COPIED_IMAGEFORMATS=false
for path in \
"$MINGW_PREFIX/share/qt6/plugins/imageformats" \
"$MINGW_PREFIX/share/qt5/plugins/imageformats" \
"$MINGW_PREFIX/lib/qt6/plugins/imageformats" \
"$MINGW_PREFIX/lib/qt5/plugins/imageformats"; do
if [ -d "$path" ]; then
echo " Found imageformats plugin directory at: $path"
cp -r "$path"/* "$DEPLOY_DIR/imageformats/" 2>/dev/null || true
COPIED_IMAGEFORMATS=true
break
fi
done
if [ "$COPIED_IMAGEFORMATS" = false ]; then
echo " WARNING: Could not find imageformats directory in standard MSYS2 paths!"
fi
# 9. Résolution dynamique des dépendances MinGW (ldd)
echo ">>> Resolving system and 3rd party DLL dependencies using ldd..."
TEMP_DEPENDENCY_LIST=$(mktemp)
trap 'rm -f "$TEMP_DEPENDENCY_LIST"' EXIT
PREV_COUNT=0
while true; do
# Scanner tous les exe et dll présents dans le dossier de déploiement
find "$DEPLOY_DIR" \( -name "*.exe" -o -name "*.dll" \) -exec ldd {} \; 2>/dev/null \
| grep -i "$MINGW_PREFIX/bin" | awk '{print $3}' | sort -u > "$TEMP_DEPENDENCY_LIST"
CURR_COUNT=$(wc -l < "$TEMP_DEPENDENCY_LIST")
if [ "$CURR_COUNT" -eq "$PREV_COUNT" ]; then
break
fi
PREV_COUNT=$CURR_COUNT
while read -r dll_path; do
if [ -f "$dll_path" ]; then
dll_name=$(basename "$dll_path")
# Ne pas écraser les DLL déjà présentes (Qt ou compilées localement)
if [ ! -f "$DEPLOY_DIR/$dll_name" ]; then
echo " Deploying dependency: $dll_name"
cp "$dll_path" "$DEPLOY_DIR/"
fi
fi
done < "$TEMP_DEPENDENCY_LIST"
done
rm -f "$TEMP_DEPENDENCY_LIST"
# Detect if we should strip debug symbols (only in explicit Release or MinSizeRel builds)
IS_RELEASE_BUILD=false
if [ -f "$BUILD_DIR/CMakeCache.txt" ]; then
if grep -q "CMAKE_BUILD_TYPE:STRING=Release" "$BUILD_DIR/CMakeCache.txt" || grep -q "CMAKE_BUILD_TYPE:STRING=MinSizeRel" "$BUILD_DIR/CMakeCache.txt"; then
IS_RELEASE_BUILD=true
fi
fi
# 9.5 Stripping debug symbols to reduce file sizes (shrinks exe from 91MB down to ~22MB)
if [ "$IS_RELEASE_BUILD" = false ]; then
echo ">>> Non-Release build detected (CMakeCache.txt). Skipping stripping of debug symbols to preserve GDB compatibility!"
else
echo ">>> Stripping debug symbols from our compiled binaries..."
if command -v strip &> /dev/null; then
# Strip main executables and core DLLs
for binary in \
"$DEPLOY_DIR"/retroshare-gui.exe \
"$DEPLOY_DIR"/retroshare-service.exe \
"$DEPLOY_DIR"/retroshare-friendserver.exe \
"$DEPLOY_DIR"/retroshare.dll \
"$DEPLOY_DIR"/libretroshare.dll \
"$DEPLOY_DIR"/libcmark.dll \
"$DEPLOY_DIR"/librestbed-shared.dll \
"$DEPLOY_DIR"/librestbed.dll \
"$DEPLOY_DIR"/librnp.dll; do
if [ -f "$binary" ]; then
echo " Stripping: $(basename "$binary")"
strip "$binary" || true
fi
done
# Strip plugins
if [ -d "$DEPLOY_DIR/Data/extensions6" ]; then
find "$DEPLOY_DIR/Data/extensions6" -name "*.dll" | while read -r plugin; do
echo " Stripping plugin: $(basename "$plugin")"
strip "$plugin" || true
done
fi
else
echo " WARNING: 'strip' tool not found. Skipping stripping of debug symbols."
fi
fi
# 10. Déploiement de la WebUI (si présente)
echo ">>> Deploying WebUI static assets..."
if [ -d "retroshare-webui/src" ]; then
mkdir -p "$DEPLOY_DIR/webui"
cp -r retroshare-webui/src/* "$DEPLOY_DIR/webui/" 2>/dev/null || true
echo " WebUI copied to deployment folder."
else
echo " WebUI source folder not found. Skipping WebUI packaging."
fi
# 11. Création de l'archive finale (7z en priorité, zip en fallback)
echo ">>> Packaging final compressed archive..."
(
cd "$BUILD_DIR" || exit 1
if command -v 7z &> /dev/null; then
echo " Using 7z for ultra high compression..."
7z a -t7z -mx=9 "${ARCHIVE_BASE}.7z" "${ARCHIVE_BASE}"
echo "================================================================================"
echo "SUCCESS: Standalone package created at: ${BUILD_DIR}/${ARCHIVE_BASE}.7z"
echo "================================================================================"
elif command -v zip &> /dev/null; then
echo " 7z not found. Falling back to standard zip..."
zip -r "${ARCHIVE_BASE}.zip" "${ARCHIVE_BASE}"
echo "================================================================================"
echo "SUCCESS: Standalone package created at: ${BUILD_DIR}/${ARCHIVE_BASE}.zip"
echo "================================================================================"
else
echo "================================================================================"
echo "SUCCESS: Folder generated at: ${DEPLOY_DIR}"
echo "NOTE: Neither '7z' nor 'zip' commands were found. Archive creation skipped."
echo "================================================================================"
fi
)

View File

@ -16,7 +16,13 @@ if "%~1"=="clean" (
goto exit
)
if exist "%EnvMSYS2Path%\msys%MSYS2Base%\usr\bin\pacman.exe" (
set MSYS2Version=20250622
set MSYS2Install=msys2-base-x86_64-%MSYS2Version%.sfx.exe
set MSYS2Url=https://github.com/msys2/msys2-installer/releases/download/%MSYS2Version:~0,4%-%MSYS2Version:~4,2%-%MSYS2Version:~6,2%/%MSYS2Install%
set MSYS2UnpackPath=%EnvMSYS2Path%\msys64
if exist "%MSYS2UnpackPath%\usr\bin\pacman.exe" (
if "%~1"=="reinstall" (
choice /M "Found existing MSYS2 version. Do you want to proceed?"
if !ERRORLEVEL!==2 goto exit
@ -25,30 +31,26 @@ if exist "%EnvMSYS2Path%\msys%MSYS2Base%\usr\bin\pacman.exe" (
)
)
if "%MSYS2Architecture%"=="i686" set MSYS2Version=20210705
if "%MSYS2Architecture%"=="x86_64" set MSYS2Version=20210725
if exist "%MSYS2UnpackPath%" (
%cecho% info "Remove previous MSYS2 version"
call "%ToolsPath%\remove-dir.bat" "%MSYS2UnpackPath%"
)
set MSYS2Install=msys2-base-%MSYS2Architecture%-%MSYS2Version%.tar.xz
set MSYS2Url=https://repo.msys2.org/distrib/%MSYS2Architecture%/%MSYS2Install%
%cecho% info "Remove previous MSYS2 version"
call "%ToolsPath%\remove-dir.bat" "%EnvMSYS2Path%"
%cecho% info "Download installation files"
%cecho% info "Download MSYS2 installation files"
if not exist "%EnvDownloadPath%\%MSYS2Install%" call "%ToolsPath%\download-file.bat" "%MSYS2Url%" "%EnvDownloadPath%\%MSYS2Install%"
if not exist "%EnvDownloadPath%\%MSYS2Install%" %cecho% error "Cannot download MSYS" & goto error
%cecho% info "Unpack MSYS2"
"%EnvSevenZipExe%" x -so "%EnvDownloadPath%\%MSYS2Install%" | "%EnvSevenZipExe%" x -y -si -ttar -o"%EnvMSYS2Path%"
"%EnvDownloadPath%\%MSYS2Install%" -y -o"%EnvMSYS2Path%"
set MSYS2SH=%EnvMSYS2Path%\msys%MSYS2Base%\usr\bin\sh
set MSYS2SH=%MSYS2UnpackPath%\usr\bin\sh
%cecho% info "Initialize MSYS2"
"%MSYS2SH%" -lc "yes | pacman --noconfirm -Syuu msys2-keyring"
"%MSYS2SH%" -lc "pacman --noconfirm -Sy"
"%MSYS2SH%" -lc "pacman --noconfirm -Su"
call "%EnvMSYS2Path%\msys%MSYS2Base%\autorebase.bat"
call "%MSYS2UnpackPath%\autorebase.bat"
:exit
endlocal

View File

@ -4,8 +4,8 @@ if "%EnvRootPath%"=="" exit /B 1
set CEchoUrl=https://github.com/lordmulder/cecho/releases/download/2015-10-10/cecho.2015-10-10.zip
set CEchoInstall=cecho.2015-10-10.zip
set SevenZipUrl=https://sourceforge.net/projects/sevenzip/files/7-Zip/18.05/7z1805.msi/download
set SevenZipInstall=7z1805.msi
set SevenZipUrl=https://www.7-zip.org/a/7z2600-x64.msi
set SevenZipInstall=7z2600-x64.msi
if not exist "%EnvToolsPath%\7z.exe" (
call "%ToolsPath%\remove-dir.bat" "%EnvTempPath%"
@ -34,7 +34,7 @@ if not exist "%EnvToolsPath%\cecho.exe" (
if not exist "%EnvDownloadPath%\%cCEhoInstall%" echo Cannot download cecho installation& goto error
echo Unpack cecho
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%CEchoInstall%"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%CEchoInstall%" -y -bso0
copy "%EnvTempPath%\cecho.exe" "%EnvToolsPath%"
call "%ToolsPath%\remove-dir.bat" "%EnvTempPath%"

View File

@ -2,18 +2,13 @@
setlocal
if exist "%~dp0msys2\msys32" call :update 32
if exist "%~dp0msys2\msys64" call :update 64
if not exist "%~dp0msys2\msys64" goto :EOF
goto :EOF
set MSYS2SH=%~dp0msys2\msys64\usr\bin\sh
:update
set MSYS2SH=%~dp0msys2\msys%~1\usr\bin\sh
echo Update MSYS2 %~1
echo Update MSYS2
"%MSYS2SH%" -lc "yes | pacman --noconfirm -Syuu msys2-keyring"
"%MSYS2SH%" -lc "pacman --noconfirm -Su"
:exit
endlocal
goto :EOF

View File

@ -9,6 +9,7 @@
;!define REVISION ""
;!define DEPLOYDIR ""
;!define ARCHITECTURE ""
;!define TOOLCHAIN ""
# Optional defines
;!define OUTDIR ""
@ -21,6 +22,9 @@
!ifndef ARCHITECTURE
!error "ARCHITECTURE is not defined"
!endif
!ifndef TOOLCHAIN
!error "TOOLCHAIN is not defined"
!endif
# Check optional defines
!ifdef OUTDIR
@ -72,7 +76,7 @@ ${!defineifexist} TOR_EXISTS "${DEPLOYDIR}\tor.exe"
# Main Install settings
Name "${APPNAMEANDVERSION}"
InstallDirRegKey HKLM "Software\${APPNAME}" ""
OutFile "${OUTDIR_}RetroShare-${VERSION}-${Date}-${REVISION}-${ARCHITECTURE}${RSTYPE}${INSTALLERADD}-setup.exe"
OutFile "${OUTDIR_}RetroShare-${VERSION}-${Date}-${REVISION}-Qt-${QTVERSION}-${TOOLCHAIN}-msys2${RSTYPE}${INSTALLERADD}-setup.exe"
BrandingText "${APPNAMEANDVERSION}"
RequestExecutionlevel highest
# Use compression

View File

@ -44,8 +44,9 @@ Run the scripts in this order:
**Always delete the build artifacts folder if you enable or disable extra features after the build command: &lt;sourcefolder&gt;-msys2\deploy\builds**
* Mandatory
* 32 or 64: 32 or 64 bit version
* 32, 64, mingw32, mingw64, ucrt64, clang32, clang64 or clangarm64: It sets the msys2 build environment to the selected value. 32 is a shortcut for mingw32, 64 is a shortcut for mingw64. Default in build.bat and buil-tor.bat is 64.
* release or debug: normally you would like to use the release option
* qt5 or qt6: build with Qt 5 (default) or Qt 6
* Extra features (optional)
* autologin: enable autologin
* plugins: build plugins
@ -55,7 +56,6 @@ Run the scripts in this order:
* "CONFIG+=..." enable other extra compile time features, you can find the almost complete list in file *&lt;sourcefolder&gt;\retroshare.pri*
* For fixing compile problems (optional)
* singlethread: use only 1 thread for building, slow but useful if you don't find the error message in the console
* clang: use clang compiler instead of GCC
* noupdate: skip the msys2 update step, sometimes some msys2 packages are broken, you can manually switch back to the older package, and this option will prevent updating to the broken version again
Example:

View File

@ -1,5 +1,5 @@
:: Usage:
:: call get-qt-version.bat variable
:: call get-qt-version.bat variable qmake
setlocal
@ -10,9 +10,16 @@ if "%Var%"=="" (
exit /B 1
)
set QMakeCmd=%~2
if "%QMakeCmd%"=="" (
echo.
echo Parameter error.
exit /B 1
)
set QtVersion=
%EnvMSYS2Cmd% "qmake -version" >"%~dp0qtversion.tmp"
%EnvMSYS2Cmd% "%QMakeCmd% -version" >"%~dp0qtversion.tmp"
for /F "tokens=1,2,3,4" %%A in (%~sdp0qtversion.tmp) do (
if "%%A"=="Using" (
set QtVersion=%%D

View File

@ -0,0 +1,32 @@
REM Usage:
REM call get-rs-date.bat SourcePath Variable
setlocal
set SourcePath=%~1
set Variable=%~2
if "%Variable%"=="" (
echo.
echo Parameter error
exit /B 1
)
:: Check git executable
set GitPath=
call "%~dp0find-in-path.bat" GitPath git.exe
if "%GitPath%"=="" (
echo.
echo Git executable not found in PATH.
exit /B 1
)
set Date=
pushd "%SourcePath%"
rem This doesn't work: git log -1 --date=format:"%Y%m%d" --format="%ad"
for /F "tokens=1,2,3* delims=-" %%A in ('git log -1 --date^=short --format^="%%ad"') do set Date=%%A%%B%%C
popd
:exit
endlocal & set %Variable%=%Date%
exit /B 0

View File

@ -0,0 +1,35 @@
## Build Retroshare with QtCreator & Qt 6.9 on Windows
### Qt 6.9 Installation
Download Qt 6.9 from: https://www.qt.io/download-dev
Run the installer and install Qt 6.9
Add GCC.exe to Path
C:\Qt\Tools\mingw1310_64\bin
Compile the external libs start build-libs.bat:
Open Qt Command Prompt:
cd C:\Users\User\Documents\GitHub\RetroShare\build_scripts\Windows\build-libs
Type (this will take some time to build all libs):
build-libs.bat
Open Qt Creator
Open project -> RetroShare.pro
After Project loaded, go to:
Projects->Build->Build Steps->Additional arguments:
Add EXTERNAL_LIB_DIR:
"EXTERNAL_LIB_DIR=%{sourceDir}\..\RetroShare-env\build-libs\gcc-13.1.0\x64\libs"
After done, Build Project

View File

@ -1,24 +1,32 @@
ZLIB_VERSION=1.2.11
BZIP2_VERSION=1.0.8
MINIUPNPC_VERSION=2.2.3
OPENSSL_VERSION=1.1.1p
SPEEX_VERSION=1.2.0
SPEEXDSP_VERSION=1.2.0
LIBXML2_VERSION=2.9.12
LIBXSLT_VERSION=1.1.34
CURL_VERSION=7.81.0
OPENSSL_VERSION=1.1.1w
SPEEX_VERSION=1.2.1
SPEEXDSP_VERSION=1.2.1
LIBXML2_MAIN_VERSION=2.14
LIBXML2_VERSION=$(LIBXML2_MAIN_VERSION).5
LIBXSLT_MAIN_VERSION=1.1
LIBXSLT_VERSION=$(LIBXSLT_MAIN_VERSION).43
CURL_VERSION=8.9.1
TCL_VERSION=8.6.10
SQLCIPHER_VERSION=4.5.0
LIBMICROHTTPD_VERSION=0.9.75
FFMPEG_VERSION=4.4
FFMPEG_VERSION=4.4.6
RAPIDJSON_VERSION=1.1.0
XAPIAN_VERSION=1.4.19
XAPIAN_VERSION=1.4.29
ASIO_VERSION=1-34-2
#RNP_VERSION=0.17.1
# libaries for rnp
JSON_C_VERSION=0.18
BOTAN_VERSION=2.19.5
DOWNLOAD_PATH?=download
BUILD_PATH=build
LIBS_PATH?=libs
all: dirs zlib bzip2 miniupnpc openssl speex speexdsp libxml2 libxslt curl sqlcipher libmicrohttpd ffmpeg rapidjson xapian copylibs
all: dirs zlib bzip2 miniupnpc openssl speex speexdsp libxml curl sqlcipher ffmpeg rapidjson xapian jsonc botan asio copylibs
#rnp
download: \
$(DOWNLOAD_PATH)/zlib-$(ZLIB_VERSION).tar.gz \
@ -27,13 +35,12 @@ download: \
$(DOWNLOAD_PATH)/openssl-$(OPENSSL_VERSION).tar.gz \
$(DOWNLOAD_PATH)/speex-$(SPEEX_VERSION).tar.gz \
$(DOWNLOAD_PATH)/speexdsp-$(SPEEXDSP_VERSION).tar.gz \
$(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.gz \
$(DOWNLOAD_PATH)/libxslt-$(LIBXSLT_VERSION).tar.gz \
$(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.xz \
$(DOWNLOAD_PATH)/libxslt-$(LIBXSLT_VERSION).tar.xz \
$(DOWNLOAD_PATH)/curl-$(CURL_VERSION).tar.gz \
$(DOWNLOAD_PATH)/tcl$(TCL_VERSION)-src.tar.gz \
$(DOWNLOAD_PATH)/sqlcipher-$(SQLCIPHER_VERSION).tar.gz \
$(DOWNLOAD_PATH)/libmicrohttpd-$(LIBMICROHTTPD_VERSION).tar.gz \
$(DOWNLOAD_PATH)/ffmpeg-$(FFMPEG_VERSION).tar.gz \
$(DOWNLOAD_PATH)/ffmpeg-$(FFMPEG_VERSION).tar.xz \
$(DOWNLOAD_PATH)/rapidjson-$(RAPIDJSON_VERSION).tar.gz \
$(DOWNLOAD_PATH)/xapian-core-$(XAPIAN_VERSION).tar.xz
@ -56,8 +63,7 @@ $(BUILD_PATH)/zlib-$(ZLIB_VERSION): $(DOWNLOAD_PATH)/zlib-$(ZLIB_VERSION).tar.gz
rm -r -f $(BUILD_PATH)/zlib-*
tar xvf $(DOWNLOAD_PATH)/zlib-$(ZLIB_VERSION).tar.gz
# build
cd zlib-$(ZLIB_VERSION) && make -f win32/Makefile.gcc libz.a
cd zlib-$(ZLIB_VERSION) && make
cd zlib-$(ZLIB_VERSION) && make -j -f win32/Makefile.gcc libz.a
# copy files
mkdir -p $(BUILD_PATH)/zlib-$(ZLIB_VERSION).tmp/include
cp zlib-$(ZLIB_VERSION)/zlib.h $(BUILD_PATH)/zlib-$(ZLIB_VERSION).tmp/include/
@ -79,7 +85,7 @@ $(BUILD_PATH)/bzip2-$(BZIP2_VERSION): $(DOWNLOAD_PATH)/bzip2-$(BZIP2_VERSION).ta
tar xvf $(DOWNLOAD_PATH)/bzip2-$(BZIP2_VERSION).tar.gz
# build
#cd bzip2-$(BZIP2_VERSION) && make install PREFIX="`pwd`/../$(BUILD_PATH)"
cd bzip2-$(BZIP2_VERSION) && make
cd bzip2-$(BZIP2_VERSION) && make -j
# copy files
mkdir -p $(BUILD_PATH)/bzip2-$(BZIP2_VERSION).tmp/include
cp bzip2-$(BZIP2_VERSION)/bzlib.h $(BUILD_PATH)/bzip2-$(BZIP2_VERSION).tmp/include/
@ -99,7 +105,7 @@ $(BUILD_PATH)/miniupnpc-$(MINIUPNPC_VERSION): $(DOWNLOAD_PATH)/miniupnpc-$(MINIU
rm -r -f $(BUILD_PATH)/miniupnpc-*
tar xvf $(DOWNLOAD_PATH)/miniupnpc-$(MINIUPNPC_VERSION).tar.gz
# build
cd miniupnpc-$(MINIUPNPC_VERSION) && export CC=gcc && export PATH=.:$$PATH && make -f Makefile.mingw libminiupnpc.a miniupnpc.dll
cd miniupnpc-$(MINIUPNPC_VERSION) && export CC=gcc && export PATH=.:$$PATH && make -j -f Makefile.mingw libminiupnpc.a miniupnpc.dll
# copy files
mkdir -p $(BUILD_PATH)/miniupnpc-$(MINIUPNPC_VERSION).tmp/include/miniupnpc
cp miniupnpc-$(MINIUPNPC_VERSION)/include/*.h $(BUILD_PATH)/miniupnpc-$(MINIUPNPC_VERSION).tmp/include/miniupnpc/
@ -124,7 +130,7 @@ $(BUILD_PATH)/openssl-$(OPENSSL_VERSION): $(DOWNLOAD_PATH)/openssl-$(OPENSSL_VER
#cd openssl-$(OPENSSL_VERSION) && ./config --prefix="`pwd`/../$(BUILD_PATH)"
#cd openssl-$(OPENSSL_VERSION) && make install
cd openssl-$(OPENSSL_VERSION) && ./config shared
cd openssl-$(OPENSSL_VERSION) && make
cd openssl-$(OPENSSL_VERSION) && make -j
# copy files
mkdir -p $(BUILD_PATH)/openssl-$(OPENSSL_VERSION).tmp/include/openssl
cp openssl-$(OPENSSL_VERSION)/include/openssl/*.h $(BUILD_PATH)/openssl-$(OPENSSL_VERSION).tmp/include/openssl/
@ -153,7 +159,7 @@ $(BUILD_PATH)/speex-$(SPEEX_VERSION): $(DOWNLOAD_PATH)/speex-$(SPEEX_VERSION).ta
# build
cd speex-$(SPEEX_VERSION) && ./configure
#cd speex-$(SPEEX_VERSION) && make install exec_prefix="`pwd`/../$(BUILD_PATH)"
cd speex-$(SPEEX_VERSION) && make
cd speex-$(SPEEX_VERSION) && make -j
# copy files
mkdir -p $(BUILD_PATH)/speex-$(SPEEX_VERSION).tmp/include/speex
cp speex-$(SPEEX_VERSION)/include/speex/*.h $(BUILD_PATH)/speex-$(SPEEX_VERSION).tmp/include/speex/
@ -174,7 +180,7 @@ $(BUILD_PATH)/speexdsp-$(SPEEXDSP_VERSION): $(DOWNLOAD_PATH)/speexdsp-$(SPEEXDSP
tar xvf $(DOWNLOAD_PATH)/speexdsp-$(SPEEXDSP_VERSION).tar.gz
# build
cd speexdsp-$(SPEEXDSP_VERSION) && ./configure
cd speexdsp-$(SPEEXDSP_VERSION) && make
cd speexdsp-$(SPEEXDSP_VERSION) && make -j
# copy files
mkdir -p $(BUILD_PATH)/speexdsp-$(SPEEXDSP_VERSION).tmp/include/speex
cp speexdsp-$(SPEEXDSP_VERSION)/include/speex/*.h $(BUILD_PATH)/speexdsp-$(SPEEXDSP_VERSION).tmp/include/speex/
@ -184,50 +190,52 @@ $(BUILD_PATH)/speexdsp-$(SPEEXDSP_VERSION): $(DOWNLOAD_PATH)/speexdsp-$(SPEEXDSP
rm -r -f speexdsp-$(SPEEXDSP_VERSION)
mv $(BUILD_PATH)/speexdsp-$(SPEEXDSP_VERSION).tmp $(BUILD_PATH)/speexdsp-$(SPEEXDSP_VERSION)
libxml2: $(BUILD_PATH)/libxml2-$(LIBXML2_VERSION)
libxml: \
$(BUILD_PATH)/libxml2-$(LIBXML2_VERSION) \
$(BUILD_PATH)/libxslt-$(LIBXSLT_VERSION)
$(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.gz:
wget ftp://xmlsoft.org/libxml2/libxml2-$(LIBXML2_VERSION).tar.gz -O $(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.gz
$(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.xz:
wget --no-check-certificate https://download.gnome.org/sources/libxml2/$(LIBXML2_MAIN_VERSION)/libxml2-$(LIBXML2_VERSION).tar.xz -O $(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.xz
$(BUILD_PATH)/libxml2-$(LIBXML2_VERSION): $(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.gz
# prepare
$(DOWNLOAD_PATH)/libxslt-$(LIBXSLT_VERSION).tar.xz:
wget --no-check-certificate https://download.gnome.org/sources/libxslt/$(LIBXSLT_MAIN_VERSION)/libxslt-$(LIBXSLT_VERSION).tar.xz -O $(DOWNLOAD_PATH)/libxslt-$(LIBXSLT_VERSION).tar.xz
$(BUILD_PATH)/libxml2-$(LIBXML2_VERSION) $(BUILD_PATH)/libxslt-$(LIBXSLT_VERSION): \
$(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.xz \
$(DOWNLOAD_PATH)/libxslt-$(LIBXSLT_VERSION).tar.xz
# libxml2: prepare
pacman --needed --noconfirm -S python3 pkg-config
rm -r -f $(BUILD_PATH)/libxml2-*
tar xvf $(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.gz
# build
tar xvf $(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.xz
# libxslt: prepare
rm -r -f $(BUILD_PATH)/libxslt-*
tar xvf $(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.xz
tar xvf $(DOWNLOAD_PATH)/libxslt-$(LIBXSLT_VERSION).tar.xz
# libxml2: build
cd libxml2-$(LIBXML2_VERSION) && ./configure --without-iconv -enable-shared=no
#cd libxml2-$(LIBXML2_VERSION) && make install exec_prefix="`pwd`/../$(BUILD_PATH)"
cd libxml2-$(LIBXML2_VERSION) && make
# copy files
cd libxml2-$(LIBXML2_VERSION) && make -j libxml2.la
# libxslt: build
cd libxslt-$(LIBXSLT_VERSION) && ./configure --with-libxml-src=../libxml2-$(LIBXML2_VERSION) -enable-shared=no CFLAGS=-DLIBXML_STATIC
cd libxslt-$(LIBXSLT_VERSION)/libxslt && make -j
cd libxslt-$(LIBXSLT_VERSION)/libexslt && make -j
# libxml2: copy files
mkdir -p $(BUILD_PATH)/libxml2-$(LIBXML2_VERSION).tmp/include/libxml
cp libxml2-$(LIBXML2_VERSION)/include/libxml/*.h $(BUILD_PATH)/libxml2-$(LIBXML2_VERSION).tmp/include/libxml/
mkdir -p $(BUILD_PATH)/libxml2-$(LIBXML2_VERSION).tmp/lib
cp libxml2-$(LIBXML2_VERSION)/.libs/libxml2.a $(BUILD_PATH)/libxml2-$(LIBXML2_VERSION).tmp/lib/
# cleanup
#rm -r -f libxml2-$(LIBXML2_VERSION) # see libxslt
mv $(BUILD_PATH)/libxml2-$(LIBXML2_VERSION).tmp $(BUILD_PATH)/libxml2-$(LIBXML2_VERSION)
libxslt: $(BUILD_PATH)/libxslt-$(LIBXSLT_VERSION)
$(DOWNLOAD_PATH)/libxslt-$(LIBXSLT_VERSION).tar.gz:
wget ftp://xmlsoft.org/libxml2/libxslt-$(LIBXSLT_VERSION).tar.gz -O $(DOWNLOAD_PATH)/libxslt-$(LIBXSLT_VERSION).tar.gz
$(BUILD_PATH)/libxslt-$(LIBXSLT_VERSION): $(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.gz $(DOWNLOAD_PATH)/libxslt-$(LIBXSLT_VERSION).tar.gz
# prepare
rm -r -f $(BUILD_PATH)/libxslt-*
tar xvf $(DOWNLOAD_PATH)/libxml2-$(LIBXML2_VERSION).tar.gz
tar xvf $(DOWNLOAD_PATH)/libxslt-$(LIBXSLT_VERSION).tar.gz
# build
cd libxslt-$(LIBXSLT_VERSION) && ./configure --with-libxml-src=../libxml2-$(LIBXML2_VERSION) -enable-shared=no CFLAGS=-DLIBXML_STATIC
cd libxslt-$(LIBXSLT_VERSION) && make
# copy files
# libxslt: copy files
mkdir -p $(BUILD_PATH)/libxslt-$(LIBXSLT_VERSION).tmp/include/libxslt
cp libxslt-$(LIBXSLT_VERSION)/libxslt/*.h $(BUILD_PATH)/libxslt-$(LIBXSLT_VERSION).tmp/include/libxslt/
mkdir -p $(BUILD_PATH)/libxslt-$(LIBXSLT_VERSION).tmp/lib
cp libxslt-$(LIBXSLT_VERSION)/libxslt/.libs/libxslt.a $(BUILD_PATH)/libxslt-$(LIBXSLT_VERSION).tmp/lib/
cp libxslt-$(LIBXSLT_VERSION)/libexslt/.libs/libexslt.a $(BUILD_PATH)/libxslt-$(LIBXSLT_VERSION).tmp/lib/
# cleanup
# libxml2: cleanup
rm -r -f libxml2-$(LIBXML2_VERSION)
# libxslt: cleanup
rm -r -f libxslt-$(LIBXSLT_VERSION)
# finish
mv $(BUILD_PATH)/libxml2-$(LIBXML2_VERSION).tmp $(BUILD_PATH)/libxml2-$(LIBXML2_VERSION)
mv $(BUILD_PATH)/libxslt-$(LIBXSLT_VERSION).tmp $(BUILD_PATH)/libxslt-$(LIBXSLT_VERSION)
curl: $(BUILD_PATH)/curl-$(CURL_VERSION)
@ -242,7 +250,7 @@ $(BUILD_PATH)/curl-$(CURL_VERSION): $(DOWNLOAD_PATH)/curl-$(CURL_VERSION).tar.gz
# build
cd curl-$(CURL_VERSION) && ./configure --disable-shared --with-ssl="`pwd`/../$(BUILD_PATH)/openssl-$(OPENSSL_VERSION)"
#cd curl-$(CURL_VERSION) && make install exec_prefix="`pwd`/../$(BUILD_PATH)"
cd curl-$(CURL_VERSION) && make
cd curl-$(CURL_VERSION)/lib && make -j
# copy files
mkdir -p $(BUILD_PATH)/curl-$(CURL_VERSION).tmp/include/curl
cp curl-$(CURL_VERSION)/include/curl/*.h $(BUILD_PATH)/curl-$(CURL_VERSION).tmp/include/curl/
@ -267,14 +275,14 @@ $(BUILD_PATH)/sqlcipher-$(SQLCIPHER_VERSION): $(DOWNLOAD_PATH)/tcl$(TCL_VERSION)
tar xvf $(DOWNLOAD_PATH)/tcl$(TCL_VERSION)-src.tar.gz
mkdir -p tcl$(TCL_VERSION)/build
cd tcl$(TCL_VERSION)/build && ../win/configure
cd tcl$(TCL_VERSION)/build && make
cd tcl$(TCL_VERSION)/build && make -j
#sqlcipher
tar xvf $(DOWNLOAD_PATH)/sqlcipher-$(SQLCIPHER_VERSION).tar.gz
cd sqlcipher-$(SQLCIPHER_VERSION) && ln -s ../tcl$(TCL_VERSION)/build/tclsh86.exe tclsh
mkdir -p tcl$(TCL_VERSION)/lib
ln -s `pwd`/tcl$(TCL_VERSION)/library `pwd`/tcl$(TCL_VERSION)/lib/tcl8.6
# build
cd sqlcipher-$(SQLCIPHER_VERSION) && PATH=.:$$PATH:`pwd`/../tcl$(TCL_VERSION)/build && export LIBS="-L`pwd`/../$(BUILD_PATH)/openssl-$(OPENSSL_VERSION)/lib -lgdi32 $$LIBS" && ./configure --disable-shared --enable-static --enable-tempstore=yes CFLAGS="-DSQLITE_HAS_CODEC -I`pwd`/../$(BUILD_PATH)/openssl-$(OPENSSL_VERSION)/include -I`pwd`/../tcl$(TCL_VERSION)/generic" LDFLAGS="-L`pwd`/../$(BUILD_PATH)/openssl-$(OPENSSL_VERSION)/lib -lcrypto -lgdi32" --with-tcl="`pwd`/../tcl$(TCL_VERSION)/build" && make install prefix="`pwd`/install"
cd sqlcipher-$(SQLCIPHER_VERSION) && PATH=.:$$PATH:`pwd`/../tcl$(TCL_VERSION)/build && export LIBS="-L`pwd`/../$(BUILD_PATH)/openssl-$(OPENSSL_VERSION)/lib -lgdi32 $$LIBS" && ./configure --disable-shared --enable-static --enable-tempstore=yes CFLAGS="-DSQLITE_HAS_CODEC -I`pwd`/../$(BUILD_PATH)/openssl-$(OPENSSL_VERSION)/include -I`pwd`/../tcl$(TCL_VERSION)/generic" LDFLAGS="-L`pwd`/../$(BUILD_PATH)/openssl-$(OPENSSL_VERSION)/lib -lcrypto -lgdi32" --with-tcl="`pwd`/../tcl$(TCL_VERSION)/build" && make -j install prefix="`pwd`/install"
# copy files
mkdir -p $(BUILD_PATH)/sqlcipher-$(SQLCIPHER_VERSION).tmp/include
cp -r sqlcipher-$(SQLCIPHER_VERSION)/install/include/* $(BUILD_PATH)/sqlcipher-$(SQLCIPHER_VERSION).tmp/include/
@ -287,34 +295,18 @@ $(BUILD_PATH)/sqlcipher-$(SQLCIPHER_VERSION): $(DOWNLOAD_PATH)/tcl$(TCL_VERSION)
rm -r -f tcl$(TCL_VERSION)
mv $(BUILD_PATH)/sqlcipher-$(SQLCIPHER_VERSION).tmp $(BUILD_PATH)/sqlcipher-$(SQLCIPHER_VERSION)
libmicrohttpd: $(BUILD_PATH)/libmicrohttpd-$(LIBMICROHTTPD_VERSION)
$(DOWNLOAD_PATH)/libmicrohttpd-$(LIBMICROHTTPD_VERSION).tar.gz:
wget --no-check-certificate http://ftp.gnu.org/gnu/libmicrohttpd/libmicrohttpd-$(LIBMICROHTTPD_VERSION).tar.gz -O $(DOWNLOAD_PATH)/libmicrohttpd-$(LIBMICROHTTPD_VERSION).tar.gz
$(BUILD_PATH)/libmicrohttpd-$(LIBMICROHTTPD_VERSION): $(DOWNLOAD_PATH)/libmicrohttpd-$(LIBMICROHTTPD_VERSION).tar.gz
# prepare
rm -r -f $(BUILD_PATH)/libmicrohttpd-*
tar xvf $(DOWNLOAD_PATH)/libmicrohttpd-$(LIBMICROHTTPD_VERSION).tar.gz
# build
cd libmicrohttpd-$(LIBMICROHTTPD_VERSION) && ./configure --disable-shared --enable-static --prefix="`pwd`/../$(BUILD_PATH)/libmicrohttpd-$(LIBMICROHTTPD_VERSION).tmp"
cd libmicrohttpd-$(LIBMICROHTTPD_VERSION) && make install
# cleanup
rm -r -f libmicrohttpd-$(LIBMICROHTTPD_VERSION)
mv $(BUILD_PATH)/libmicrohttpd-$(LIBMICROHTTPD_VERSION).tmp $(BUILD_PATH)/libmicrohttpd-$(LIBMICROHTTPD_VERSION)
ffmpeg: $(BUILD_PATH)/ffmpeg-$(FFMPEG_VERSION)
$(DOWNLOAD_PATH)/ffmpeg-$(FFMPEG_VERSION).tar.gz:
wget --no-check-certificate https://ffmpeg.org/releases/ffmpeg-$(FFMPEG_VERSION).tar.gz -O $(DOWNLOAD_PATH)/ffmpeg-$(FFMPEG_VERSION).tar.gz
$(DOWNLOAD_PATH)/ffmpeg-$(FFMPEG_VERSION).tar.xz:
wget --no-check-certificate https://ffmpeg.org/releases/ffmpeg-$(FFMPEG_VERSION).tar.xz -O $(DOWNLOAD_PATH)/ffmpeg-$(FFMPEG_VERSION).tar.xz
$(BUILD_PATH)/ffmpeg-$(FFMPEG_VERSION): $(DOWNLOAD_PATH)/ffmpeg-$(FFMPEG_VERSION).tar.gz
$(BUILD_PATH)/ffmpeg-$(FFMPEG_VERSION): $(DOWNLOAD_PATH)/ffmpeg-$(FFMPEG_VERSION).tar.xz
# prepare
rm -r -f $(BUILD_PATH)/ffmpeg-*
tar xvf $(DOWNLOAD_PATH)/ffmpeg-$(FFMPEG_VERSION).tar.gz
tar xvf $(DOWNLOAD_PATH)/ffmpeg-$(FFMPEG_VERSION).tar.xz
# build
cd ffmpeg-$(FFMPEG_VERSION) && ./configure --disable-shared --enable-static --disable-programs --disable-ffmpeg --disable-ffplay --disable-ffprobe --disable-doc --disable-htmlpages --disable-manpages --disable-podpages --disable-txtpages --disable-yasm --disable-everything --enable-encoder=mpeg4 --enable-decoder=mpeg4 --prefix="`pwd`/../$(BUILD_PATH)/ffmpeg-$(FFMPEG_VERSION).tmp"
cd ffmpeg-$(FFMPEG_VERSION) && make install
cd ffmpeg-$(FFMPEG_VERSION) && make -j install
# cleanup
rm -r -f ffmpeg-$(FFMPEG_VERSION)
mv $(BUILD_PATH)/ffmpeg-$(FFMPEG_VERSION).tmp $(BUILD_PATH)/ffmpeg-$(FFMPEG_VERSION)
@ -352,7 +344,7 @@ $(BUILD_PATH)/xapian-core-$(XAPIAN_VERSION): $(DOWNLOAD_PATH)/xapian-core-$(XAPI
#cd xapian-core-$(XAPIAN_VERSION) && ./configure --disable-shared --enable-static --prefix="`pwd`/../$(BUILD_PATH)/xapian-core-$(XAPIAN_VERSION).tmp"
#cd xapian-core-$(XAPIAN_VERSION) && make install
cd xapian-core-$(XAPIAN_VERSION) && ./configure --disable-shared --enable-static
cd xapian-core-$(XAPIAN_VERSION) && make
cd xapian-core-$(XAPIAN_VERSION) && make -j
# copy files
mkdir -p $(BUILD_PATH)/xapian-core-$(XAPIAN_VERSION).tmp/include
cp -r xapian-core-$(XAPIAN_VERSION)/include/* $(BUILD_PATH)/xapian-core-$(XAPIAN_VERSION).tmp/include/
@ -363,8 +355,73 @@ $(BUILD_PATH)/xapian-core-$(XAPIAN_VERSION): $(DOWNLOAD_PATH)/xapian-core-$(XAPI
rm -r -f xapian-core-$(XAPIAN_VERSION)
mv $(BUILD_PATH)/xapian-core-$(XAPIAN_VERSION).tmp $(BUILD_PATH)/xapian-core-$(XAPIAN_VERSION)
jsonc: $(BUILD_PATH)/json-c-$(JSON_C_VERSION)
$(BUILD_PATH)/json-c-$(JSON_C_VERSION):
# prepare
rm -r -f $(BUILD_PATH)/json-c-*
[ -d "json-c-$(JSON_C_VERSION)" ] || git clone https://github.com/json-c/json-c.git --depth=1 --branch json-c-$(JSON_C_VERSION) "json-c-$(JSON_C_VERSION)"
# build
mkdir -p json-c-$(JSON_C_VERSION)/build
cd json-c-$(JSON_C_VERSION)/build && cmake .. -G"MSYS Makefiles" -Wno-dev -DCMAKE_BUILD_TYPE="release" -DBUILD_SHARED_LIBS=off -DBUILD_STATIC_LIBS=on -DBUILD_TESTING=off -DCMAKE_CXX_FLAGS="-D__MINGW_USE_VC2005_COMPAT" -DCMAKE_INSTALL_PREFIX="`pwd`/install" -DCMAKE_INSTALL_PREFIX="`pwd`/../../$(BUILD_PATH)/json-c-$(JSON_C_VERSION).tmp"
cd json-c-$(JSON_C_VERSION)/build && make -j install
# cleanup
rm -r -f json-c-$(JSON_C_VERSION)
mv $(BUILD_PATH)/json-c-$(JSON_C_VERSION).tmp $(BUILD_PATH)/json-c-$(JSON_C_VERSION)
botan: $(BUILD_PATH)/botan-$(BOTAN_VERSION)
$(BUILD_PATH)/botan-$(BOTAN_VERSION):
# prepare
pacman --needed --noconfirm -S python3
rm -r -f $(BUILD_PATH)/botan-*
[ -d "botan-$(BOTAN_VERSION)" ] || git clone https://github.com/randombit/botan.git --depth=1 --branch $(BOTAN_VERSION) "botan-$(BOTAN_VERSION)"
# build
if [ $(MSYSTEM) = "MINGW32" ] ; then cd botan-$(BOTAN_VERSION) && ./configure.py --os=mingw --cpu=x86_32 --disable-shared-library --enable-static-library --extra-cxxflags="-D__MINGW_USE_VC2005_COMPAT" --prefix="`pwd`/../$(BUILD_PATH)/botan-$(BOTAN_VERSION).tmp" ; fi
if [ $(MSYSTEM) = "MINGW64" ] ; then cd botan-$(BOTAN_VERSION) && ./configure.py --os=mingw --cpu=x86_64 --disable-shared-library --enable-static-library --prefix="`pwd`/../$(BUILD_PATH)/botan-$(BOTAN_VERSION).tmp" ; fi
cd botan-$(BOTAN_VERSION) && make -j install
# cleanup
rm -r -f botan-$(BOTAN_VERSION)
mv $(BUILD_PATH)/botan-$(BOTAN_VERSION).tmp $(BUILD_PATH)/botan-$(BOTAN_VERSION)
asio: $(BUILD_PATH)/asio-$(ASIO_VERSION)
$(BUILD_PATH)/asio-$(ASIO_VERSION):
# prepare
rm -r -f $(BUILD_PATH)/asio-*
[ -d "asio-$(ASIO_VERSION)" ] || git clone https://github.com/chriskohlhoff/asio.git --depth=1 --branch asio-$(ASIO_VERSION) "asio-$(ASIO_VERSION)"
# copy files
mkdir -p $(BUILD_PATH)/asio-$(ASIO_VERSION).tmp/include/asio
cp asio-$(ASIO_VERSION)/asio/include/*.hpp $(BUILD_PATH)/asio-$(ASIO_VERSION).tmp/include/
cp -r asio-$(ASIO_VERSION)/asio/include/asio/* $(BUILD_PATH)/asio-$(ASIO_VERSION).tmp/include/asio/
# cleanup
rm -r -f asio-$(ASIO_VERSION)
mv $(BUILD_PATH)/asio-$(ASIO_VERSION).tmp $(BUILD_PATH)/asio-$(ASIO_VERSION)
rnp: $(BUILD_PATH)/rnp-$(RNP_VERSION)
$(BUILD_PATH)/rnp-$(RNP_VERSION):
# prepare
rm -r -f $(BUILD_PATH)/rnp-*
[ -d "rnp-$(RNP_VERSION)" ] || git clone https://github.com/rnpgp/rnp.git --depth=1 --branch v$(RNP_VERSION) --recurse-submodules --shallow-submodules "rnp-$(RNP_VERSION)"
# build
mkdir -p rnp-$(RNP_VERSION)/build
cd rnp-$(RNP_VERSION)/build && cmake .. -G"MSYS Makefiles" -Wno-dev -DCMAKE_INSTALL_PREFIX="`pwd`/install" -DBUILD_SHARED_LIBS=yes -DBUILD_TESTING=off -DCMAKE_CXX_FLAGS="-D__MINGW_USE_VC2005_COMPAT -D__STDC_FORMAT_MACROS" -DBZIP2_INCLUDE_DIR="`pwd`/../../$(BUILD_PATH)/bzip2-$(BZIP2_VERSION)/include" -DBZIP2_LIBRARY_RELEASE="`pwd`/../../$(BUILD_PATH)/bzip2-$(BZIP2_VERSION)/lib/libbz2.a" -DBZIP2_LIBRARIES="`pwd`/../../$(BUILD_PATH)/bzip2-$(BZIP2_VERSION)/lib/libbz2.a" -DZLIB_INCLUDE_DIR="`pwd`/../../$(BUILD_PATH)/zlib-$(ZLIB_VERSION)/include" -DZLIB_LIBRARY="`pwd`/../../$(BUILD_PATH)/zlib-$(ZLIB_VERSION)/lib/libz.a" -DJSON-C_INCLUDE_DIR="`pwd`/../../$(BUILD_PATH)/json-c-$(JSON_C_VERSION)/include/json-c" -DJSON-C_LIBRARY="`pwd`/../../$(BUILD_PATH)/json-c-$(JSON_C_VERSION)/lib/libjson-c.a" -DBOTAN_INCLUDE_DIR="`pwd`/../../$(BUILD_PATH)/botan-$(BOTAN_VERSION)/include/botan-`echo $(BOTAN_VERSION) | cut -c1-1`" -DBOTAN_LIBRARY="`pwd`/../../$(BUILD_PATH)/botan-$(BOTAN_VERSION)/lib/libbotan-`echo $(BOTAN_VERSION) | cut -c1-1`.a"
cmake --build rnp-$(RNP_VERSION)/build
# copy files
mkdir -p $(BUILD_PATH)/rnp-$(RNP_VERSION).tmp/include/rnp
cp -r rnp-$(RNP_VERSION)/include/rnp/* $(BUILD_PATH)/rnp-$(RNP_VERSION).tmp/include/rnp/
cp -r rnp-$(RNP_VERSION)/build/src/lib/rnp/* $(BUILD_PATH)/rnp-$(RNP_VERSION).tmp/include/rnp/
mkdir -p $(BUILD_PATH)/rnp-$(RNP_VERSION).tmp/lib
cp -r rnp-$(RNP_VERSION)/build/src/lib/librnp.dll.a $(BUILD_PATH)/rnp-$(RNP_VERSION).tmp/lib/
mkdir -p $(BUILD_PATH)/rnp-$(RNP_VERSION).tmp/bin
cp -r rnp-$(RNP_VERSION)/build/src/lib/librnp.dll $(BUILD_PATH)/rnp-$(RNP_VERSION).tmp/bin/
# cleanup
rm -r -f rnp-$(RNP_VERSION)
mv $(BUILD_PATH)/rnp-$(RNP_VERSION).tmp $(BUILD_PATH)/rnp-$(RNP_VERSION)
copylibs:
rm -r -f $(LIBS_PATH) ; \
mkdir -p $(LIBS_PATH) ; \
cp $(BUILD_PATH)/gcc-version $(LIBS_PATH) ; \
find $(BUILD_PATH) -mindepth 1 -maxdepth 1 -type d -not -name "*.tmp" -print -exec cp -r {}/. $(LIBS_PATH) \; ; \
cp -p $(BUILD_PATH)/gcc-version $(LIBS_PATH) ; \
find $(BUILD_PATH) -mindepth 1 -maxdepth 1 -type d -not -name "*.tmp" -print -exec cp -r -p {}/. $(LIBS_PATH) \; ; \

View File

@ -33,7 +33,7 @@ echo.
echo === Version
echo.
title Build - %SourceName%-%RsBuildConfig% [Version]
title Build - %SourceName%-%RsBuildConfig% Qt-%QtVersion%-%GCCArchitecture% [Version]
pushd "%SourcePath%\retroshare-gui\src\gui\images"
:: Touch resource file
@ -47,7 +47,7 @@ echo.
echo === qmake
echo.
title Build - %SourceName%-%RsBuildConfig% [qmake]
title Build - %SourceName%-%RsBuildConfig% Qt-%QtVersion%-%GCCArchitecture% [qmake]
set RS_QMAKE_CONFIG=%RsBuildConfig%
if "%ParamAutologin%"=="1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% rs_autologin
@ -56,7 +56,7 @@ if "%ParamWebui%"=="1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% rs_webui
if "%ParamPlugins%"=="1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% retroshare_plugins
if "%ParamUseNativeDialogs%"=="1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% rs_use_native_dialogs
if "%ParamService%" NEQ "1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% no_retroshare_service
if "%ParamFriendServer%" NEQ "1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% no_rs_friendserver
if "%ParamFriendServer%" NEQ "1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% no_retroshare_friendserver
if "%ParamEmbeddedFriendServer%"=="1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% rs_efs
qmake "%SourcePath%\RetroShare.pro" -r -spec win32-g++ "CONFIG+=%RS_QMAKE_CONFIG%" "EXTERNAL_LIB_DIR=%BuildLibsPath%\libs"
@ -66,7 +66,7 @@ echo.
echo === make
echo.
title Build - %SourceName%-%RsBuildConfig% [make]
title Build - %SourceName%-%RsBuildConfig% Qt-%QtVersion%-%GCCArchitecture% [make]
mingw32-make -j %CoreCount%
if errorlevel 1 goto error
@ -75,7 +75,7 @@ echo.
echo === Changelog
echo.
title Build - %SourceName%-%RsBuildConfig% [changelog]
title Build - %SourceName%-%RsBuildConfig% Qt-%QtVersion%-%GCCArchitecture% [changelog]
call "%ToolsPath%\generate-changelog.bat" "%SourcePath%" "%RsBuildPath%\changelog.txt"
:error

View File

@ -59,10 +59,12 @@ set QtMainVersion=%QtVersion:~0,1%
rem Qt 4 = QtSvg4.dll
rem Qt 5 = Qt5Svg.dll
rem Qt 6 = Qt6Svg.dll
set QtMainVersion1=
set QtMainVersion2=
if "%QtMainVersion%"=="4" set QtMainVersion2=4
if "%QtMainVersion%"=="5" set QtMainVersion1=5
if "%QtMainVersion%"=="6" set QtMainVersion1=6
if "%RsBuildConfig%" NEQ "release" (
set Archive=%RsPackPath%\RetroShare-%RsVersion%-Windows-Portable-%RsDate%-%RsVersion.Extra%-Qt-%QtVersion%-%GCCArchitecture%%RsType%%RsArchiveAdd%-%RsBuildConfig%.7z
@ -75,7 +77,7 @@ if exist "%Archive%" del /Q "%Archive%"
:: Create deploy path
mkdir "%RsDeployPath%"
title Pack - %SourceName%%RsType%-%RsBuildConfig% [copy files]
title Pack - %SourceName%%RsType%-%RsBuildConfig% Qt-%QtVersion%-%GCCArchitecture% [copy files]
set ExtensionsFile=%SourcePath%\libretroshare\src\rsserver\rsinit.cc
set Extensions=
@ -96,6 +98,7 @@ copy nul "%RsDeployPath%\portable" %Quite%
echo copy binaries
copy "%RsBuildPath%\retroshare-gui\src\%RsBuildConfig%\retroshare*.exe" "%RsDeployPath%" %Quite%
if exist "%RsBuildPath%\libretroshare\src\lib\retroshare.dll" copy "%RsBuildPath%\libretroshare\src\lib\retroshare.dll" "%RsDeployPath%" %Quite%
if exist "%RsBuildPath%\supportlibs\librnp\Build\src\lib\librnp.dll" copy "%RsBuildPath%\supportlibs\librnp\Build\src\lib\librnp.dll" "%RsDeployPath%" %Quite%
if "%ParamService%"=="1" (
copy "%RsBuildPath%\retroshare-service\src\%RsBuildConfig%\retroshare*-service.exe" "%RsDeployPath%" %Quite%
@ -130,18 +133,24 @@ if exist "%RsDeployPath%\retroshare.dll" call :copy_dependencies "%RsDeployPath%
echo copy Qt DLL's
copy "%QtPath%\Qt%QtMainVersion1%Svg%QtMainVersion2%.dll" "%RsDeployPath%" %Quite%
if "%QtMainVersion%"=="5" (
if %QtMainVersion% GEQ 5 (
mkdir "%RsDeployPath%\platforms"
copy "%QtPath%\..\plugins\platforms\qwindows.dll" "%RsDeployPath%\platforms" %Quite%
)
if "%QtMainVersion%"=="5" (
mkdir "%RsDeployPath%\audio"
copy "%QtPath%\..\plugins\audio\qtaudio_windows.dll" "%RsDeployPath%\audio" %Quite%
)
if exist "%QtPath%\..\plugins\styles\qwindowsvistastyle.dll" (
echo Copy styles
mkdir "%RsDeployPath%\styles" %Quite%
echo Copy styles
mkdir "%RsDeployPath%\styles" %Quite%
if "%QtMainVersion%"=="5" (
copy "%QtPath%\..\plugins\styles\qwindowsvistastyle.dll" "%RsDeployPath%\styles" %Quite%
)
if "%QtMainVersion%"=="6" (
copy "%QtPath%\..\plugins\styles\qmodernwindowsstyle.dll" "%RsDeployPath%\styles" %Quite%
)
copy "%QtPath%\..\plugins\imageformats\*.dll" "%RsDeployPath%\imageformats" %Quite%
del /Q "%RsDeployPath%\imageformats\*d?.dll" %Quite%
@ -168,10 +177,12 @@ xcopy /S "%SourcePath%\retroshare-gui\src\license" "%RsDeployPath%\license" %Qui
echo copy translation
copy "%SourcePath%\retroshare-gui\src\translations\qt_tr.qm" "%RsDeployPath%\translations" %Quite%
copy "%QtPath%\..\translations\qt_*.qm" "%RsDeployPath%\translations" %Quite%
if "%QtMainVersion%"=="5" (
if %QtMainVersion% GEQ 5 (
copy "%QtPath%\..\translations\qtbase_*.qm" "%RsDeployPath%\translations" %Quite%
copy "%QtPath%\..\translations\qtscript_*.qm" "%RsDeployPath%\translations" %Quite%
copy "%QtPath%\..\translations\qtmultimedia_*.qm" "%RsDeployPath%\translations" %Quite%
)
if "%QtMainVersion%"=="5" (
copy "%QtPath%\..\translations\qtscript_*.qm" "%RsDeployPath%\translations" %Quite%
copy "%QtPath%\..\translations\qtxmlpatterns_*.qm" "%RsDeployPath%\translations" %Quite%
)
@ -195,7 +206,7 @@ if "%ParamTor%"=="1" (
)
rem pack files
title Pack - %SourceName%%RsType%-%RsBuildConfig% [pack files]
title Pack - %SourceName%%RsType%-%RsBuildConfig% Qt-%QtVersion%-%GCCArchitecture% [pack files]
"%EnvSevenZipExe%" a -mx=9 -t7z "%Archive%" "%RsDeployPath%\*"

View File

@ -22,11 +22,12 @@ if "%GCCArchitecture%"=="x64" (
)
set EnvMSYS2Path=%EnvRootPath%\msys2
set EnvMSYS2BasePath=%EnvMSYS2Path%\msys64
call "%~dp0tools\prepare-msys2.bat" %1
if errorlevel 1 exit /B %ERRORLEVEL%
set EnvMSYS2SH=%EnvMSYS2Path%\msys64\usr\bin\sh.exe
set EnvMSYS2SH=%EnvMSYS2BasePath%\usr\bin\sh.exe
if not exist "%EnvMSYS2SH%" if errorlevel 1 goto error_env
set EnvMSYS2Cmd="%EnvMSYS2SH%" -lc

View File

@ -16,15 +16,15 @@ if "%~1"=="clean" (
goto exit
)
set MSYS2Version=20230318
set MSYS2Version=20250622
set MSYS2Install=msys2-base-x86_64-%MSYS2Version%.sfx.exe
set MSYS2Url=https://github.com/msys2/msys2-installer/releases/download/%MSYS2Version:~0,4%-%MSYS2Version:~4,2%-%MSYS2Version:~6,2%/%MSYS2Install%
set CMakeInstall=cmake-3.19.0-win32-x86.zip
set CMakeUrl=https://github.com/Kitware/CMake/releases/download/v3.19.0/%CMakeInstall%
set CMakeUnpackPath=%EnvMSYS2Path%\msys64
set MSYS2UnpackPath=%EnvMSYS2Path%\msys64
set CMakeInstall=cmake-3.31.3-windows-i386.zip
set CMakeUrl=https://github.com/Kitware/CMake/releases/download/v3.31.3/%CMakeInstall%
if exist "%CMakeUnpackPath%\usr\bin\pacman.exe" (
if exist "%MSYS2UnpackPath%\usr\bin\pacman.exe" (
if "%~1"=="reinstall" (
choice /M "Found existing MSYS2 version. Do you want to proceed?"
if !ERRORLEVEL!==2 goto exit
@ -33,13 +33,12 @@ if exist "%CMakeUnpackPath%\usr\bin\pacman.exe" (
)
)
if exist "%CMakeUnpackPath%" (
if exist "%MSYS2UnpackPath%" (
%cecho% info "Remove previous MSYS2 version"
call "%ToolsPath%\remove-dir.bat" "%CMakeUnpackPath%"
call "%ToolsPath%\remove-dir.bat" "%MSYS2UnpackPath%"
)
%cecho% info "Download installation files"
%cecho% info "Download MSYS2 installation files"
if not exist "%EnvDownloadPath%\%MSYS2Install%" call "%ToolsPath%\download-file.bat" "%MSYS2Url%" "%EnvDownloadPath%\%MSYS2Install%"
if not exist "%EnvDownloadPath%\%MSYS2Install%" %cecho% error "Cannot download MSYS" & goto error
@ -50,29 +49,29 @@ if not exist "%EnvDownloadPath%\%CMakeInstall%" %cecho% error "Cannot download C
"%EnvDownloadPath%\%MSYS2Install%" -y -o"%EnvMSYS2Path%"
%cecho% info "Unpack CMake"
"%EnvSevenZipExe%" x -o"%CMakeUnpackPath%" "%EnvDownloadPath%\%CMakeInstall%"
"%EnvSevenZipExe%" x -o"%MSYS2UnpackPath%" "%EnvDownloadPath%\%CMakeInstall%" -y -bso0
%cecho% info "Install CMake"
set CMakeVersion=
for /D %%F in (%CMakeUnpackPath%\cmake*) do set CMakeVersion=%%~nxF
for /D %%F in (%MSYS2UnpackPath%\cmake*) do set CMakeVersion=%%~nxF
if "%CMakeVersion%"=="" %cecho% error "CMake version not found." & goto :exit
%cecho% info "Found CMake version %CMakeVersion%"
set FoundProfile=
for /f "tokens=3" %%F in ('find /c /i "%CMakeVersion%" "%CMakeUnpackPath%\etc\profile"') do set FoundProfile=%%F
for /f "tokens=3" %%F in ('find /c /i "%CMakeVersion%" "%MSYS2UnpackPath%\etc\profile"') do set FoundProfile=%%F
if "%FoundProfile%"=="0" (
echo export PATH="${PATH}:/%CMakeVersion%/bin">>"%CMakeUnpackPath%\etc\profile"
echo export PATH="${PATH}:/%CMakeVersion%/bin">>"%MSYS2UnpackPath%\etc\profile"
)
set MSYS2SH=%CMakeUnpackPath%\usr\bin\sh
set MSYS2SH=%MSYS2UnpackPath%\usr\bin\sh
%cecho% info "Initialize MSYS2"
"%MSYS2SH%" -lc "yes | pacman --noconfirm -Syuu msys2-keyring"
"%MSYS2SH%" -lc "pacman --noconfirm -Sy"
"%MSYS2SH%" -lc "pacman --noconfirm -Su"
call "%CMakeUnpackPath%\autorebase.bat"
call "%MSYS2UnpackPath%\autorebase.bat"
:exit
endlocal

View File

@ -4,8 +4,8 @@ if "%EnvRootPath%"=="" exit /B 1
set CEchoUrl=https://github.com/lordmulder/cecho/releases/download/2015-10-10/cecho.2015-10-10.zip
set CEchoInstall=cecho.2015-10-10.zip
set SevenZipUrl=https://sourceforge.net/projects/sevenzip/files/7-Zip/19.00/7z1900.msi/download
set SevenZipInstall=7z1900.msi
set SevenZipUrl=https://www.7-zip.org/a/7z2600-x64.msi
set SevenZipInstall=7z2600-x64.msi
set DependsUrl=http://www.dependencywalker.com/depends22_x86.zip
set DependsInstall=depends22_x86.zip
set UnixToolsUrl=http://unxutils.sourceforge.net/UnxUpdates.zip
@ -19,9 +19,9 @@ set MinGitInstallPath=%EnvToolsPath%\MinGit
set DoxygenInstall=doxygen-1.9.6.windows.x64.bin.zip
set DoxygenUrl=https://github.com/doxygen/doxygen/releases/download/Release_1_9_6/%DoxygenInstall%
set DoxygenInstallPath=%EnvToolsPath%\doxygen
set CMakeVersion=cmake-3.19.0-win32-x86
set CMakeVersion=cmake-3.31.3-windows-i386
set CMakeInstall=%CMakeVersion%.zip
set CMakeUrl=https://github.com/Kitware/CMake/releases/download/v3.19.0/%CMakeInstall%
set CMakeUrl=https://github.com/Kitware/CMake/releases/download/v3.31.3/%CMakeInstall%
set CMakeInstallPath=%EnvToolsPath%\cmake
set TorProjectUrl=https://www.torproject.org
set TorDownloadIndexUrl=%TorProjectUrl%/download/tor
@ -53,7 +53,7 @@ if not exist "%EnvToolsPath%\cecho.exe" (
if not exist "%EnvDownloadPath%\%cCEhoInstall%" echo Cannot download cecho installation& goto error
echo Unpack cecho
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%CEchoInstall%"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%CEchoInstall%" -y -bso0
copy "%EnvTempPath%\cecho.exe" "%EnvToolsPath%"
call "%ToolsPath%\remove-dir.bat" "%EnvTempPath%"
@ -69,7 +69,7 @@ if not exist "%EnvToolsPath%\depends.exe" (
if not exist "%EnvDownloadPath%\%DependsInstall%" %cecho% error "Cannot download Dependendy Walker installation" & goto error
%cecho% info "Unpack Dependency Walker"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%DependsInstall%"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%DependsInstall%" -y -bso0
copy "%EnvTempPath%\*" "%EnvToolsPath%"
call "%ToolsPath%\remove-dir.bat" "%EnvTempPath%"
@ -85,7 +85,7 @@ if not exist "%EnvToolsPath%\cut.exe" (
if not exist "%EnvDownloadPath%\%UnixToolsInstall%" %cecho% error "Cannot download Unix Tools installation" & goto error
%cecho% info "Unpack Unix Tools"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%UnixToolsInstall%"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%UnixToolsInstall%" -y -bso0
copy "%EnvTempPath%\cut.exe" "%EnvToolsPath%"
call "%ToolsPath%\remove-dir.bat" "%EnvTempPath%"
@ -101,7 +101,7 @@ if not exist "%EnvToolsPath%\sed.exe" (
if not exist "%EnvDownloadPath%\%UnixToolsInstall%" %cecho% error "Cannot download Unix Tools installation" & goto error
%cecho% info "Unpack Unix Tools"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%UnixToolsInstall%"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%UnixToolsInstall%" -y -bso0
copy "%EnvTempPath%\sed.exe" "%EnvToolsPath%"
call "%ToolsPath%\remove-dir.bat" "%EnvTempPath%"
@ -121,7 +121,7 @@ if not exist "%NSISInstallPath%\nsis.exe" (
if not exist "%EnvDownloadPath%\%NSISInstall%" %cecho% error "Cannot download NSIS installation" & goto error
%cecho% info "Unpack NSIS"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%NSISInstall%"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%NSISInstall%" -y -bso0
if not exist "%NSISInstallPath%" mkdir "%NSISInstallPath%"
xcopy /s "%EnvTempPath%" "%NSISInstallPath%"
@ -135,7 +135,7 @@ if not exist "%MinGitInstallPath%\cmd\git.exe" (
if not exist "%EnvDownloadPath%\%MinGitInstall%" %cecho% error "Cannot download MinGit installation" & goto error
%cecho% info "Unpack MinGit"
"%EnvSevenZipExe%" x -o"%MinGitInstallPath%" "%EnvDownloadPath%\%MinGitInstall%"
"%EnvSevenZipExe%" x -o"%MinGitInstallPath%" "%EnvDownloadPath%\%MinGitInstall%" -y -bso0
)
if not exist "%EnvDownloadPath%\%DoxygenInstall%" call "%ToolsPath%\remove-dir.bat" "%DoxygenInstallPath%"
@ -148,7 +148,7 @@ if not exist "%DoxygenInstallPath%\doxygen.exe" (
if not exist "%EnvDownloadPath%\%DoxygenInstall%" %cecho% error "Cannot download doxygen installation" & goto error
%cecho% info "Unpack Doxygen"
"%EnvSevenZipExe%" x -o"%DoxygenInstallPath%" "%EnvDownloadPath%\%DoxygenInstall%"
"%EnvSevenZipExe%" x -o"%DoxygenInstallPath%" "%EnvDownloadPath%\%DoxygenInstall%" -y -bso0
)
if not exist "%EnvDownloadPath%\%CMakeInstall%" call "%ToolsPath%\remove-dir.bat" "%CMakeInstallPath%"
@ -163,7 +163,7 @@ if not exist "%CMakeInstallPath%\bin\cmake.exe" (
if not exist "%EnvDownloadPath%\%CMakeInstall%" %cecho% error "Cannot download CMake installation" & goto error
%cecho% info "Unpack CMake"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%CMakeInstall%"
"%EnvSevenZipExe%" x -o"%EnvTempPath%" "%EnvDownloadPath%\%CMakeInstall%" -y -bso0
move "%EnvTempPath%\%CMakeVersion%" "%CMakeInstallPath%"
@ -176,7 +176,7 @@ mkdir "%EnvTempPath%"
call "%ToolsPath%\download-file.bat" "%TorDownloadIndexUrl%" "%EnvTempPath%\index.html"
if not exist "%EnvTempPath%\index.html" %cecho% error "Cannot download Tor installation" & goto error
for /F "tokens=1,2 delims= " %%A in ('%EnvSedExe% -r -n -e"s/.*href=\"^(.*^)^(tor-.*windows-i686\.tar\.gz^)\".*/\2 \1\2/p" "%EnvTempPath%\index.html"') do set TorInstall=%%A& set TorDownloadUrl=%%B
for /F "tokens=1,2 delims= " %%A in ('%EnvSedExe% -r -n -e"s/.*href=\"^(.*^)^(tor-.*windows-i686.*\.tar\.gz^)\".*/\2 \1\2/p" "%EnvTempPath%\index.html"') do set TorInstall=%%A& set TorDownloadUrl=%%B
call "%ToolsPath%\remove-dir.bat" "%EnvTempPath%"
if "%TorInstall%"=="" %cecho% error "Cannot download Tor installation" & goto error
if "%TorDownloadUrl%"=="" %cecho% error "Cannot download Tor installation" & goto error
@ -189,7 +189,7 @@ if not exist "%EnvTorPath%\Tor\tor.exe" (
if not exist "%EnvDownloadPath%\%TorInstall%" %cecho% error "Cannot download Tor installation" & goto error
%cecho% info "Unpack Tor"
"%EnvSevenZipExe%" x -so "%EnvDownloadPath%\%TorInstall%" | "%EnvSevenZipExe%" x -si -ttar -o"%EnvTorPath%"
"%EnvSevenZipExe%" x -so "%EnvDownloadPath%\%TorInstall%" | "%EnvSevenZipExe%" x -si -ttar -o"%EnvTorPath%" -y -bso0
)
:exit

View File

@ -232,7 +232,7 @@ Section $(Section_Main) Section_Main
; Qt styles
SetOutPath "$INSTDIR\styles"
File /NONFATAL "${QTDIR}\plugins\styles\qwindowsvistastyle.dll"
File "${QTDIR}\plugins\styles\qwindowsvistastyle.dll"
; MinGW binaries
SetOutPath "$INSTDIR"
@ -247,6 +247,7 @@ Section $(Section_Main) Section_Main
; External binaries
File "${EXTERNAL_LIB_DIR}\bin\miniupnpc.dll"
File "${RELEASEDIR}\supportlibs\librnp\Build\src\lib\librnp.dll"
!if ${ARCHITECTURE} == "x86"
File "${EXTERNAL_LIB_DIR}\bin\libcrypto-1_1.dll"
File "${EXTERNAL_LIB_DIR}\bin\libssl-1_1.dll"
@ -318,7 +319,7 @@ SectionEnd
!ifdef TOR_EXISTS
Section /o $(Section_Tor) Section_Tor
SetOutPath "$INSTDIR\tor"
File /r "${TORDIR}\*"
File "${TORDIR}\*"
SectionEnd
!endif

View File

@ -0,0 +1,622 @@
; Script generated with the Venis Install Wizard & modified by defnax
; Reworked by Thunder
!include ifexist.nsh
# Needed defines
;!define REVISION ""
;!define RELEASEDIR ""
;!define QTDIR ""
;!define MINGWDIR ""
# Optional defines
;!define OUTDIR ""
# Check needed defines
!ifndef RELEASEDIR
!error "RELEASEDIR is not defined"
!endif
!ifndef QTDIR
!error "QTDIR is not defined"
!endif
!ifndef MINGWDIR
!error "MINGWDIR is not defined"
!endif
!ifndef ARCHITECTURE
!error "Architecture is not defined"
!endif
# Check optional defines
!ifdef OUTDIR
!define OUTDIR_ "${OUTDIR}\"
!else
!define OUTDIR ""
!define OUTDIR_ ""
!endif
!ifndef INSTALLERADD
!define INSTALLERADD ""
!endif
# Source directory
!define SOURCEDIR "..\..\.."
# Get version from executable
!GetDllVersion "${RELEASEDIR}\retroshare-gui\src\release\retroshare.exe" VERSION_
!define VERSION ${VERSION_1}.${VERSION_2}.${VERSION_3}
;!define REVISION ${VERSION_4}
# Get version of Qt
!GetDllVersion "${QTDIR}\bin\Qt6Core.dll" QTVERSION_
!define QTVERSION ${QTVERSION_1}.${QTVERSION_2}.${QTVERSION_3}
# Check version
!ifndef REVISION
!error "REVISION is not defined"
!endif
# Date
!ifndef DATE
!define /date DATE "%Y%m%d"
!endif
# Service
${!defineifexist} SERVICE_EXISTS "${RELEASEDIR}\retroshare-service\src\release\retroshare-service.exe"
# Tor
!ifdef TORDIR
${!defineifexist} TOR_EXISTS "${TORDIR}\tor.exe"
!ifndef TOR_EXISTS
!error "tor.exe not found"
!endif
!endif
# WebUI
!ifdef WEBUIDIR
${!defineifexist} WEBUI_EXISTS "${WEBUIDIR}\index.html"
!ifndef WEBUI_EXISTS
!error "WebUI files not found"
!endif
!endif
# Friend Server
!ifdef TOR_EXISTS
# Add Friend Server with Tor only
#${!defineifexist} FRIENDSERVER_EXISTS "${RELEASEDIR}\retroshare-friendserver\src\release\retroshare-friendserver.exe"
!endif
# Application name and version
!define APPNAME "RetroShare"
!define APPNAMEANDVERSION "${APPNAME} ${VERSION}"
!define PUBLISHER "RetroShare Team"
# Install path
!if ${ARCHITECTURE} == "x86"
!define INSTDIR_NORMAL "$ProgramFiles32\${APPNAME}"
!endif
!if ${ARCHITECTURE} == "x64"
!define INSTDIR_NORMAL "$ProgramFiles64\${APPNAME}"
!endif
!define INSTDIR_PORTABLE "$Desktop\${APPNAME}"
!define DATADIR_NORMAL "$APPDATA\${APPNAME}"
!define DATADIR_PORTABLE "$INSTDIR\Data"
# Main Install settings
Name "${APPNAMEANDVERSION}"
InstallDirRegKey HKLM "Software\${APPNAME}" ""
OutFile "${OUTDIR_}RetroShare-${VERSION}-${DATE}-${REVISION}-Qt-${QTVERSION}-${ARCHITECTURE}${INSTALLERADD}-setup.exe"
BrandingText "${APPNAMEANDVERSION}"
RequestExecutionlevel highest
# Use compression
SetCompressor /SOLID LZMA
# Global variables
Var PortableMode
Var InstDirNormal
Var InstDirPortable
Var DataDir
Var StyleSheetDir
# Modern interface settings
!include Sections.nsh
!include nsDialogs.nsh
!include "MUI.nsh"
# Interface Settings
!define MUI_ABORTWARNING
!define MUI_HEADERIMAGE
!define MUI_HEADERIMAGE_BITMAP "${SOURCEDIR}\build_scripts\Windows\installer\HeaderImage.bmp"
;!define MUI_WELCOMEFINISHPAGE_BITMAP "...bmp"
# MUI defines
!define MUI_ICON "${NSISDIR}\Contrib\Graphics\Icons\orange-install.ico"
!define MUI_FINISHPAGE_NOAUTOCLOSE
!define MUI_LICENSEPAGE_RADIOBUTTONS
!define MUI_COMPONENTSPAGE_SMALLDESC
!define MUI_FINISHPAGE_LINK "Visit the RetroShare forum for the latest news and support"
!define MUI_FINISHPAGE_LINK_LOCATION "http://retroshare.sourceforge.net/forum/"
!define MUI_FINISHPAGE_RUN "$INSTDIR\retroshare.exe"
!define MUI_FINISHPAGE_SHOWREADME $INSTDIR\changelog.txt
!define MUI_FINISHPAGE_SHOWREADME_TEXT changelog.txt
;!define MUI_FINISHPAGE_SHOWREADME_NOTCHECKED
!define MUI_UNICON "${NSISDIR}\Contrib\Graphics\Icons\orange-uninstall.ico"
!define MUI_UNFINISHPAGE_NOAUTOCLOSE
;!define MUI_LANGDLL_REGISTRY_ROOT HKLM
;!define MUI_LANGDLL_REGISTRY_KEY ${REGKEY}
;!define MUI_LANGDLL_REGISTRY_VALUENAME InstallerLanguage
# Defines the un-/installer logo of RetroShare
!insertmacro MUI_DEFAULT MUI_WELCOMEFINISHPAGE_BITMAP "${NSISDIR}\Contrib\Graphics\Wizard\orange.bmp"
!insertmacro MUI_DEFAULT MUI_UNWELCOMEFINISHPAGE_BITMAP "${NSISDIR}\Contrib\Graphics\Wizard\orange-uninstall.bmp"
# Installer pages
!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_LICENSE "$(myLicenseData)"
Page Custom PortableModePageCreate PortableModePageLeave
!define MUI_PAGE_CUSTOMFUNCTION_LEAVE dir_leave
!insertmacro MUI_PAGE_DIRECTORY
!insertmacro MUI_PAGE_COMPONENTS
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_PAGE_FINISH
!insertmacro MUI_UNPAGE_CONFIRM
!insertmacro MUI_UNPAGE_INSTFILES
# Set languages (first is default language)
!insertmacro MUI_RESERVEFILE_LANGDLL
# Installer languages
!define MUI_LANGDLL_ALLLANGUAGES
# Translations
!macro LANG_LOAD LANGUAGE LANGCODE LANGID LICENCEFILE
!insertmacro MUI_LANGUAGE "${LANGUAGE}"
; !verbose off
!define LANG "${LANGUAGE}"
!include "lang\${LANGCODE}.nsh"
LangString LANGUAGEID "${LANG_${LANG}}" "1031"
LicenseLangString myLicenseData ${LANGCODE} ${LICENCEFILE}
; !verbose on
!undef LANG
!macroend
!macro LANG_STRING NAME VALUE
LangString "${NAME}" "${LANG_${LANG}}" "${VALUE}"
!macroend
!insertmacro LANG_LOAD "English" "en" "1033" "${SOURCEDIR}\retroshare-gui\src\license\license.txt"
!insertmacro LANG_LOAD "French" "fr" "1036" "${SOURCEDIR}\retroshare-gui\src\license\license-FR.txt"
!insertmacro LANG_LOAD "German" "de" "1031" "${SOURCEDIR}\retroshare-gui\src\license\license-GER.txt"
!insertmacro LANG_LOAD "Turkish" "tr" "1055" "${SOURCEDIR}\retroshare-gui\src\license\license-TR.txt"
!insertmacro LANG_LOAD "SimpChinese" "zh_CN" "2052" "${SOURCEDIR}\retroshare-gui\src\license\license.txt"
!insertmacro LANG_LOAD "Polish" "pl" "1045" "${SOURCEDIR}\retroshare-gui\src\license\license.txt"
!insertmacro LANG_LOAD "Spanish" "es" "1034" "${SOURCEDIR}\retroshare-gui\src\license\license.txt"
!insertmacro LANG_LOAD "Russian" "ru" "1049" "${SOURCEDIR}\retroshare-gui\src\license\license.txt"
!insertmacro LANG_LOAD "Catalan" "ca_ES" "1027" "${SOURCEDIR}\retroshare-gui\src\license\license.txt"
LicenseData $(myLicenseData)
# Main binaries
Section $(Section_Main) Section_Main
;Set Section required
SectionIn RO
; Set Section properties
SetOverwrite on
; Clears previous error logs
; Delete "$INSTDIR\*.log"
; Main binaries
SetOutPath "$INSTDIR"
File "${RELEASEDIR}\retroshare-gui\src\release\retroshare.exe"
File /nonfatal "${RELEASEDIR}\libretroshare\src\lib\retroshare.dll"
; Qt binaries
File "${QTDIR}\bin\Qt6Core.dll"
File "${QTDIR}\bin\Qt6Core5Compat.dll"
File "${QTDIR}\bin\Qt6Gui.dll"
File "${QTDIR}\bin\Qt6Multimedia.dll"
File "${QTDIR}\bin\Qt6Network.dll"
File "${QTDIR}\bin\Qt6PrintSupport.dll"
File "${QTDIR}\bin\Qt6Svg.dll"
File "${QTDIR}\bin\Qt6Widgets.dll"
File "${QTDIR}\bin\Qt6Xml.dll"
; Qt platforms
SetOutPath "$INSTDIR\platforms"
File "${QTDIR}\plugins\platforms\qwindows.dll"
; Qt styles
SetOutPath "$INSTDIR\styles"
File "${QTDIR}\plugins\styles\qmodernwindowsstyle.dll"
; MinGW binaries
SetOutPath "$INSTDIR"
File "${MINGWDIR}\bin\libstdc++-6.dll"
!if ${ARCHITECTURE} == "x86"
File "${MINGWDIR}\bin\libgcc_s_dw2-1.dll"
!endif
!if ${ARCHITECTURE} == "x64"
File "${MINGWDIR}\bin\libgcc_s_seh-1.dll"
!endif
File "${MINGWDIR}\bin\libwinpthread-1.dll"
; External binaries
File "${EXTERNAL_LIB_DIR}\bin\miniupnpc.dll"
File "${RELEASEDIR}\supportlibs\librnp\Build\src\lib\librnp.dll"
!if ${ARCHITECTURE} == "x86"
File "${EXTERNAL_LIB_DIR}\bin\libcrypto-1_1.dll"
File "${EXTERNAL_LIB_DIR}\bin\libssl-1_1.dll"
!endif
!if ${ARCHITECTURE} == "x64"
File "${EXTERNAL_LIB_DIR}\bin\libcrypto-1_1-x64.dll"
File "${EXTERNAL_LIB_DIR}\bin\libssl-1_1-x64.dll"
!endif
; Other files
File "${RELEASEDIR}\changelog.txt"
File "${SOURCEDIR}\libbitdht\src\bitdht\bdboot.txt"
; License
SetOutPath "$INSTDIR\license"
File "${SOURCEDIR}\retroshare-gui\src\license\*.*"
; Image formats
SetOutPath "$INSTDIR\imageformats"
File /r "${QTDIR}\plugins\imageformats\qgif.dll"
File /r "${QTDIR}\plugins\imageformats\qicns.dll"
File /r "${QTDIR}\plugins\imageformats\qico.dll"
File /r "${QTDIR}\plugins\imageformats\qjpeg.dll"
File /r "${QTDIR}\plugins\imageformats\qsvg.dll"
File /r "${QTDIR}\plugins\imageformats\qtga.dll"
File /r "${QTDIR}\plugins\imageformats\qtiff.dll"
File /r "${QTDIR}\plugins\imageformats\qwbmp.dll"
File /r "${QTDIR}\plugins\imageformats\qwebp.dll"
; Sounds
SetOutPath "$INSTDIR\sounds"
File /r "${SOURCEDIR}\retroshare-gui\src\sounds\*.*"
; Translations
SetOutPath "$INSTDIR\translations"
File /r "${SOURCEDIR}\retroshare-gui\src\translations\*.qm"
File /r "${QTDIR}\translations\qt_*.qm"
File /r "${QTDIR}\translations\qtbase_*.qm"
File /r "${QTDIR}\translations\qtmultimedia_*.qm"
; WebUI
; SetOutPath "$INSTDIR\webui"
; File /r "${SOURCEDIR}\libresapi\src\webui\*.*"
; License
SetOutPath "$INSTDIR\license"
File /r "${SOURCEDIR}\retroshare-gui\src\license\*.*"
SectionEnd
# Service
!ifdef SERVICE_EXISTS
Section /o $(Section_Service) Section_Service
SetOutPath "$INSTDIR"
File "${RELEASEDIR}\retroshare-service\src\release\retroshare-service.exe"
SectionEnd
!endif
# Friend Server
!ifdef FRIENDSERVER_EXISTS
Section /o $(Section_FriendServer) Section_FriendServer
SetOutPath "$INSTDIR"
File "${RELEASEDIR}\retroshare-friendserver\src\release\retroshare-friendserver.exe"
SectionEnd
!endif
# Tor
!ifdef TOR_EXISTS
Section /o $(Section_Tor) Section_Tor
SetOutPath "$INSTDIR\tor"
File "${TORDIR}\*"
SectionEnd
!endif
# WebUI
!ifdef WEBUI_EXISTS
Section /o $(Section_WebUI) Section_WebUI
SetOutPath "$INSTDIR\webui"
File /r "${WEBUIDIR}\*"
SectionEnd
!endif
# Plugins
${!defineifexist} PLUGIN_FEEDREADER_EXISTS "${RELEASEDIR}\plugins\FeedReader\lib\FeedReader.dll"
${!defineifexist} PLUGIN_VOIP_EXISTS "${RELEASEDIR}\plugins\VOIP\lib\VOIP.dll"
!ifdef PLUGIN_FEEDREADER_EXISTS
!define /ifndef PLUGIN_EXISTS
!endif
!ifdef PLUGIN_VOIP_EXISTS
!define /ifndef PLUGIN_EXISTS
!endif
!ifdef PLUGIN_EXISTS
SectionGroup $(Section_Plugins) Section_Plugins
!ifdef PLUGIN_FEEDREADER_EXISTS
Section $(Section_Plugin_FeedReader) Section_Plugin_FeedReader
SetOutPath "$DataDir\extensions6"
File "${RELEASEDIR}\plugins\FeedReader\lib\FeedReader.dll"
SectionEnd
!endif
!ifdef PLUGIN_VOIP_EXISTS
Section $(Section_Plugin_VOIP) Section_Plugin_VOIP
SetOutPath "$DataDir\extensions6"
File "${RELEASEDIR}\plugins\VOIP\lib\VOIP.dll"
SetOutPath "$INSTDIR\sounds"
File /r "${SOURCEDIR}\plugins\VOIP\gui\sounds\*.*"
SectionEnd
!endif
SectionGroupEnd
!endif
# Data (Styles)
Section $(Section_Data) Section_Data
; Set Section properties
SetOverwrite on
; Chat style
SetOutPath "$StyleSheetDir\stylesheets\Bubble"
File /r "${SOURCEDIR}\retroshare-gui\src\gui\qss\chat\Bubble\*.*"
SetOutPath "$StyleSheetDir\stylesheets\Bubble_Compact"
File /r "${SOURCEDIR}\retroshare-gui\src\gui\qss\chat\Bubble_Compact\*.*"
; Stylesheets
SetOutPath "$INSTDIR\qss"
File /nonfatal /r "${SOURCEDIR}\retroshare-gui\src\qss\*.*"
SectionEnd
;Section $(Section_Link) Section_Link
; Delete any existing keys
; Write the file association
; WriteRegStr HKCR .pqi "" retroshare
; WriteRegStr HKCR retroshare "" "PQI File"
; WriteRegBin HKCR retroshare EditFlags 00000100
; WriteRegStr HKCR "retroshare\shell" "" open
; WriteRegStr HKCR "retroshare\shell\open\command" "" `"$INSTDIR\retroshare.exe" "%1"`
;SectionEnd
# Shortcuts
SectionGroup $(Section_Shortcuts) Section_Shortcuts
Section $(Section_StartMenu) Section_StartMenu
SetOutPath "$INSTDIR"
CreateDirectory "$SMPROGRAMS\${APPNAME}"
CreateShortCut "$SMPROGRAMS\${APPNAME}\$(Link_Uninstall).lnk" "$INSTDIR\uninstall.exe" "" "$INSTDIR\uninstall.exe" 0
CreateShortCut "$SMPROGRAMS\${APPNAME}\${APPNAME}.lnk" "$INSTDIR\retroshare.exe" "" "$INSTDIR\retroshare.exe" 0
!ifdef SERVICE_EXISTS
SectionGetFlags ${Section_Service} $0
IntOp $0 $0 & ${SF_SELECTED}
${If} $0 == ${SF_SELECTED}
CreateShortCut "$SMPROGRAMS\${APPNAME}\${APPNAME} Service.lnk" "$INSTDIR\retroshare-service.exe" "" "$INSTDIR\retroshare-service.exe" 0
${EndIf}
!endif
!ifdef FRIENDSERVER_EXISTS
SectionGetFlags ${Section_FriendServer} $0
IntOp $0 $0 & ${SF_SELECTED}
${If} $0 == ${SF_SELECTED}
CreateShortCut "$SMPROGRAMS\${APPNAME}\${APPNAME} Friend Server.lnk" "$INSTDIR\retroshare-friendserver.exe" "" "$INSTDIR\retroshare-friendserver.exe" 0
${EndIf}
!endif
SectionEnd
Section $(Section_Desktop) Section_Desktop
CreateShortCut "$DESKTOP\${APPNAME}.lnk" "$INSTDIR\retroshare.exe" "" "$INSTDIR\retroshare.exe" 0
SectionEnd
Section $(Section_QuickLaunch) Section_QuickLaunch
CreateShortCut "$QUICKLAUNCH\${APPNAME}.lnk" "$INSTDIR\retroshare.exe" "" "$INSTDIR\retroshare.exe" 0
SectionEnd
SectionGroupEnd
Section $(Section_AutoStart) Section_AutoStart
WriteRegStr HKCU "Software\Microsoft\Windows\CurrentVersion\Run" "RetroShare" "$INSTDIR\retroshare.exe -m"
SectionEnd
;Section $(Section_AutoStart) Section_AutoStart
; CreateShortCut "$SMSTARTUP\${APPNAME}.lnk" "$INSTDIR\retroshare.exe" "" "$INSTDIR\retroshare.exe -m" 0
;SectionEnd
Section -FinishSection
${If} $PortableMode = 0
WriteRegStr HKLM "Software\${APPNAME}" "" "$INSTDIR"
WriteRegStr HKLM "Software\${APPNAME}" "Version" "${VERSION}"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APPNAME}" "DisplayName" "${APPNAME}"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APPNAME}" "DisplayVersion" "${VERSION}"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APPNAME}" "DisplayIcon" "$INSTDIR\retroshare.exe"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APPNAME}" "Publisher" "${PUBLISHER}"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APPNAME}" "NoModify" "1"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APPNAME}" "NoRepair" "1"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APPNAME}" "UninstallString" "$INSTDIR\uninstall.exe"
WriteUninstaller "$INSTDIR\uninstall.exe"
${Else}
; Create the file the application uses to detect portable mode
FileOpen $0 "$INSTDIR\portable" w
FileClose $0
${EndIf}
SectionEnd
# Descriptions
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
!insertmacro MUI_DESCRIPTION_TEXT ${Section_Main} $(Section_Main_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_Data} $(Section_Data_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_Shortcuts} $(Section_Shortcuts_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_StartMenu} $(Section_StartMenu_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_Desktop} $(Section_Desktop_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_QuickLaunch} $(Section_QuickLaunch_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_Plugins} $(Section_Plugins_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_Plugin_FeedReader} $(Section_Plugin_FeedReader_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_Plugin_VOIP} $(Section_Plugin_VOIP_Desc)
; !insertmacro MUI_DESCRIPTION_TEXT ${Section_Link} $(Section_Link_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_AutoStart} $(Section_AutoStart_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_Tor} $(Section_Tor_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_WebUI} $(Section_WebUI_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_Service} $(Section_Service_Desc)
!insertmacro MUI_DESCRIPTION_TEXT ${Section_FriendServer} $(Section_FriendServer_Desc)
!insertmacro MUI_FUNCTION_DESCRIPTION_END
# Uninstall
Section "Uninstall"
; Remove file association registry keys
; DeleteRegKey HKCR .pqi
DeleteRegKey HKCR RetroShare
; Remove program/uninstall regsitry keys
DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APPNAME}"
DeleteRegKey HKLM SOFTWARE\${APPNAME}
DeleteRegValue HKCU "Software\Microsoft\Windows\CurrentVersion\Run" "RetroShare"
; Remove shortcuts, if any
Delete "$SMPROGRAMS\${APPNAME}\*.*"
; Remove desktop shortcut
Delete "$DESKTOP\${APPNAME}.lnk"
; Remove Quicklaunch shortcut
Delete "$QUICKLAUNCH\${APPNAME}.lnk"
; Remove Autstart
Delete "$SMSTARTUP\${APPNAME}.lnk"
; Remove directories used
RMDir "$SMPROGRAMS\${APPNAME}"
RMDir /r "$INSTDIR"
; Don't remove the directory, otherwise
; we lose the XPGP keys.
; Should make this an option though...
RMDir /r "${DATADIR_NORMAL}\extensions6"
RMDir /r "${DATADIR_NORMAL}\stylesheets"
SectionEnd
Function .onInit
StrCpy $InstDirNormal "${INSTDIR_NORMAL}"
StrCpy $InstDirPortable "${INSTDIR_PORTABLE}"
StrCpy $PortableMode 0
StrCpy $INSTDIR "$InstDirNormal"
StrCpy $DataDir "${DATADIR_NORMAL}"
InitPluginsDir
Push $R1
File /oname=$PLUGINSDIR\spltmp.bmp "${SOURCEDIR}\retroshare-gui\src\gui\images\logo\logo_splash.png"
advsplash::show 1200 1000 1000 -1 $PLUGINSDIR\spltmp
Pop $R1
Pop $R1
!insertmacro MUI_LANGDLL_DISPLAY
FunctionEnd
!ifdef FRIENDSERVER_EXISTS
Function .onSelChange
SectionGetFlags ${Section_FriendServer} $0
IntOp $0 $0 & ${SF_SELECTED}
${If} $0 == ${SF_SELECTED}
# Activate Tor and set readonly
SectionGetFlags ${Section_Tor} $1
IntOp $1 $1 | ${SF_SELECTED}
IntOp $1 $1 | ${SF_RO}
SectionSetFlags ${Section_Tor} $1
${Else}
# Remove readonly from Tor
SectionGetFlags ${Section_Tor} $1
IntOp $2 ${SF_RO} ~
IntOp $1 $1 & $2
SectionSetFlags ${Section_Tor} $1
${EndIf}
FunctionEnd
!endif
# Installation mode
Function RequireAdmin
UserInfo::GetAccountType
Pop $8
${If} $8 != "admin"
MessageBox MB_ICONSTOP "You need administrator rights to install ${APPNAME}"
SetErrorLevel 740 ;ERROR_ELEVATION_REQUIRED
Abort
${EndIf}
FunctionEnd
Function SetModeDestinationFromInstdir
${If} $PortableMode = 0
StrCpy $InstDirNormal $INSTDIR
${Else}
StrCpy $InstDirPortable $INSTDIR
${EndIf}
FunctionEnd
Function PortableModePageCreate
Call SetModeDestinationFromInstdir ; If the user clicks BACK on the directory page we will remember their mode specific directory
!insertmacro MUI_HEADER_TEXT $(Page_InstallMode) $(Page_InstallMode_Desc)
nsDialogs::Create 1018
Pop $0
${NSD_CreateRadioButton} 5u 25u -10u 8u $(Page_InstallMode_Standard)
Pop $1
${NSD_CreateLabel} 18u 40u -10u 24u $(Page_InstallMode_Standard_Desc)
Pop $0
${NSD_CreateRadioButton} 5u 75u -10u 8u $(Page_InstallMode_Portable)
Pop $2
${NSD_CreateLabel} 18u 90u -10u 24u $(Page_InstallMode_Portable_Desc)
Pop $0
${If} $PortableMode = 0
SendMessage $1 ${BM_SETCHECK} ${BST_CHECKED} 0
${Else}
SendMessage $2 ${BM_SETCHECK} ${BST_CHECKED} 0
${EndIf}
nsDialogs::Show
FunctionEnd
Function PortableModePageLeave
${NSD_GetState} $1 $0
${If} $0 <> ${BST_UNCHECKED}
StrCpy $PortableMode 0
StrCpy $INSTDIR $InstDirNormal
Call RequireAdmin
; Enable sections
SectionSetText ${Section_Shortcuts} $(Section_Shortcuts)
SectionSetText ${Section_StartMenu} $(Section_StartMenu)
SectionSetText ${Section_Desktop} $(Section_Desktop)
SectionSetText ${Section_QuickLaunch} $(Section_QuickLaunch)
SectionSetText ${Section_AutoStart} $(Section_AutoStart)
!insertmacro SelectSection ${Section_Shortcuts}
!insertmacro SelectSection ${Section_AutoStart}
!insertmacro SelectSection ${Section_StartMenu}
!insertmacro SelectSection ${Section_Desktop}
!insertmacro SelectSection ${Section_QuickLaunch}
${Else}
StrCpy $PortableMode 1
StrCpy $INSTDIR $InstDirPortable
; Disable sections
!insertmacro UnselectSection ${Section_Shortcuts}
!insertmacro UnselectSection ${Section_AutoStart}
!insertmacro UnselectSection ${Section_StartMenu}
!insertmacro UnselectSection ${Section_Desktop}
!insertmacro UnselectSection ${Section_QuickLaunch}
SectionSetText ${Section_Shortcuts} ""
SectionSetText ${Section_StartMenu} ""
SectionSetText ${Section_Desktop} ""
SectionSetText ${Section_QuickLaunch} ""
SectionSetText ${Section_AutoStart} ""
${EndIf}
FunctionEnd
Function dir_leave
${If} $PortableMode = 0
StrCpy $DataDir "${DATADIR_NORMAL}"
StrCpy $StyleSheetDir $DataDir
${Else}
StrCpy $DataDir "${DATADIR_PORTABLE}"
StrCpy $StyleSheetDir $INSTDIR
${EndIf}
FunctionEnd

View File

@ -0,0 +1,20 @@
#!/bin/bash
function git_del_tag()
{
mTag=$1
for mRemote in $(git remote); do
echo "Attempting tag $mTag removal from remote $mRemote"
GIT_TERMINAL_PROMPT=0 git push $mRemote :$mTag || true
done
git tag --delete $mTag
}
for mModule in . build_scripts/OBS/ libbitdht/ libretroshare/ openpgpsdk/ retroshare-webui/ ; do
pushd $mModule
git_del_tag v0.6.7a
git tag --list | grep untagged | while read mTag; do git_del_tag $mTag ; done
popd
done

View File

@ -4,8 +4,8 @@ Version=1.0
Name=RetroShare
Comment=Securely communicate with your friends
Exec=/usr/bin/retroshare %U
Icon=/usr/share/pixmaps/retroshare.xpm
Icon=retroshare.xpm
Terminal=false
Type=Application
Categories=Application;Network;P2P;Feed;Chat;InstantMessaging
Categories=Network;Email;InstantMessaging;Chat;Feed;FileTransfer;P2P
MimeType=x-scheme-handler/retroshare;

@ -1 +1 @@
Subproject commit 659423769541169457c41f71c8a038e2d64ba079
Subproject commit d1af0a357a94c47d0e486bee1e5052df660cfa1f

@ -1 +1 @@
Subproject commit 8c02b54e4d16e38b28e77263a0b1570c50df4c99
Subproject commit 2f093fd7b3a013c463dacc65a1756e7643f543c0

@ -1 +1 @@
Subproject commit b41667912751a453e8e5d4733215a0609277a26f
Subproject commit 178aa8ebcef47e3271d5a5ca5c07e45d3b71c81d

7
plugins/CMakeLists.txt Normal file
View File

@ -0,0 +1,7 @@
# plugins/CMakeLists.txt
cmake_minimum_required(VERSION 3.18)
if(RS_GUI)
add_subdirectory(FeedReader)
add_subdirectory(VOIP)
endif()

View File

@ -21,8 +21,16 @@
TEMPLATE = lib
CONFIG *= plugin
DEPENDPATH += $$PWD/../../libretroshare/src/ $$PWD/../../retroshare-gui/src/
INCLUDEPATH += $$PWD/../../libretroshare/src/ $$PWD/../../retroshare-gui/src/
# TODO: Why are these not added by retroshare.pri?
DEPENDPATH += $$PWD/../../retroshare-gui/src/
INCLUDEPATH += $$PWD/../../retroshare-gui/src/
# TODO: Why can we not include use_libretroshare.pri
DEPENDPATH += $$PWD/../../libretroshare/src/
INCLUDEPATH += $$PWD/../../libretroshare/src/
# rapidjson headers are required for libretroshare
INCLUDEPATH += ../../supportlibs/rapidjson/include
linux-* {
target.path = "$${RS_PLUGIN_DIR}"

View File

@ -0,0 +1,144 @@
# plugins/FeedReader/CMakeLists.txt
cmake_minimum_required(VERSION 3.18)
project(FeedReaderPlugin)
find_package(Qt5 COMPONENTS Core Widgets Xml Network REQUIRED)
# --- Dependencies ---
find_package(CURL REQUIRED)
find_package(LibXml2 REQUIRED)
find_package(LibXslt REQUIRED)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_AUTOUIC ON)
# --- Sources ---
set(FEEDREADER_SOURCES
FeedReaderPlugin.cpp
services/p3FeedReader.cc
services/p3FeedReaderThread.cc
services/rsFeedReaderItems.cc
gui/FeedReaderDialog.cpp
gui/FeedReaderMessageWidget.cpp
gui/AddFeedDialog.cpp
gui/PreviewFeedDialog.cpp
gui/FeedReaderNotify.cpp
gui/FeedReaderConfig.cpp
gui/FeedReaderStringDefs.cpp
gui/FeedReaderFeedNotify.cpp
gui/FeedReaderUserNotify.cpp
gui/FeedReaderFeedItem.cpp
gui/FeedTreeWidget.cpp
gui/ProxyWidget.cpp
util/CURLWrapper.cpp
util/XMLWrapper.cpp
util/HTMLWrapper.cpp
util/XPathWrapper.cpp
)
set(FEEDREADER_FORMS
gui/FeedReaderDialog.ui
gui/FeedReaderMessageWidget.ui
gui/AddFeedDialog.ui
gui/PreviewFeedDialog.ui
gui/FeedReaderConfig.ui
gui/FeedReaderFeedItem.ui
gui/ProxyWidget.ui
)
set(FEEDREADER_RESOURCES
gui/FeedReader_images.qrc
lang/FeedReader_lang.qrc
qss/FeedReader_qss.qrc
)
# --- Translations (.ts -> .qm) ---
file(GLOB TS_FILES "lang/*.ts")
if(Qt5LinguistTools_FOUND)
qt5_add_translation(QM_FILES ${TS_FILES})
else()
find_program(LRELEASE_EXECUTABLE NAMES lrelease-qt5 lrelease)
foreach(ts_file ${TS_FILES})
get_filename_component(ts_name ${ts_file} NAME_WE)
set(qm_src_file "${CMAKE_CURRENT_SOURCE_DIR}/lang/${ts_name}.qm")
set(qm_bin_file "${CMAKE_CURRENT_BINARY_DIR}/${ts_name}.qm")
if(EXISTS ${qm_src_file})
list(APPEND QM_FILES ${qm_src_file})
elseif(LRELEASE_EXECUTABLE)
add_custom_command(
OUTPUT ${qm_bin_file}
COMMAND ${LRELEASE_EXECUTABLE} ${ts_file} -qm ${qm_bin_file}
DEPENDS ${ts_file}
VERBATIM
)
list(APPEND QM_FILES ${qm_bin_file})
endif()
endforeach()
endif()
# --- CTarget ---
add_library(FeedReader MODULE
${FEEDREADER_SOURCES}
${FEEDREADER_FORMS}
${FEEDREADER_RESOURCES}
${QM_FILES}
)
set_target_properties(FeedReader PROPERTIES
PREFIX "lib"
LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/plugins"
RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/plugins"
AUTOUIC_SEARCH_PATHS "${CMAKE_CURRENT_SOURCE_DIR}/gui"
)
# --- Links ---
# OpenSSL is a direct dependency: services/p3FeedReaderThread.cc includes
# <openssl/evp.h> and uses the EVP API directly (not only through libretroshare).
find_package(OpenSSL REQUIRED)
if(WIN32)
# On Windows a shared module (plugin DLL) must resolve every symbol at link
# time (no undefined symbols allowed in a PE/DLL), so the plugin has to link
# explicitly against the libraries that provide them. On ELF platforms
# (Linux) the loader resolves these symbols from the hosting retroshare-gui
# process at load time, so this explicit link is only needed on Windows.
target_link_libraries(FeedReader PRIVATE retroshare retroshare-gui)
target_compile_definitions(FeedReader PRIVATE WINDOWS_SYS)
endif()
target_link_libraries(FeedReader PRIVATE
Qt5::Core
Qt5::Widgets
Qt5::Xml
Qt5::Network
CURL::libcurl
LibXml2::LibXml2
LibXslt::LibXslt
OpenSSL::SSL
OpenSSL::Crypto
)
target_compile_options(FeedReader PRIVATE "-Wno-deprecated-declarations")
target_compile_definitions(FeedReader PRIVATE RS_NO_WARN_DEPRECATED)
if(RS_DEVELOPMENT_BUILD)
target_compile_options(FeedReader PRIVATE "-g" "-O0")
endif()
# --- Includes ---
target_include_directories(FeedReader PRIVATE
${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/gui
${CMAKE_CURRENT_SOURCE_DIR}/services
${CMAKE_CURRENT_SOURCE_DIR}/interface
${CMAKE_CURRENT_SOURCE_DIR}/util
${CMAKE_SOURCE_DIR}/libretroshare/src
${CMAKE_SOURCE_DIR}/retroshare-gui/src
${CMAKE_SOURCE_DIR}/retroshare-gui/src/gui
${CMAKE_SOURCE_DIR}/supportlibs/rapidjson/include
)
# --- Installation ---
install(TARGETS FeedReader DESTINATION lib/retroshare/plugins)

View File

@ -28,6 +28,8 @@ greaterThan(QT_MAJOR_VERSION, 4) {
QT += widgets
}
greaterThan(QT_MAJOR_VERSION,5): QT += core5compat
target.files = lib/libFeedReader.so
SOURCES = FeedReaderPlugin.cpp \
@ -45,6 +47,7 @@ SOURCES = FeedReaderPlugin.cpp \
gui/FeedReaderUserNotify.cpp \
gui/FeedReaderFeedItem.cpp \
gui/FeedTreeWidget.cpp \
gui/ProxyWidget.cpp \
util/CURLWrapper.cpp \
util/XMLWrapper.cpp \
util/HTMLWrapper.cpp \
@ -66,6 +69,7 @@ HEADERS = FeedReaderPlugin.h \
gui/FeedReaderUserNotify.h \
gui/FeedReaderFeedItem.h \
gui/FeedTreeWidget.h \
gui/ProxyWidget.h \
util/CURLWrapper.h \
util/XMLWrapper.h \
util/HTMLWrapper.h \
@ -76,7 +80,8 @@ FORMS = gui/FeedReaderDialog.ui \
gui/AddFeedDialog.ui \
gui/PreviewFeedDialog.ui \
gui/FeedReaderConfig.ui \
gui/FeedReaderFeedItem.ui
gui/FeedReaderFeedItem.ui \
gui/ProxyWidget.ui
TARGET = FeedReader
@ -105,12 +110,6 @@ TRANSLATIONS += \
lang/FeedReader_tr.ts \
lang/FeedReader_zh_CN.ts
# when rapidjson is mainstream on all distribs, we will not need the sources anymore
# in the meantime, they are part of the RS directory so that it is always possible to find them
INCLUDEPATH += ../../rapidjson-1.1.0
linux-* {
CONFIG += link_pkgconfig
@ -125,7 +124,7 @@ win32 {
isEmpty(QMAKE_SH) {
# MinGW
LIBS += -lcrypt32
LIBS += -lcrypt32 -lbcrypt
}
# Check for msys2

View File

@ -28,6 +28,7 @@
#include "FeedReaderStringDefs.h"
#include "gui/settings/rsharesettings.h"
#include "gui/common/UIStateHelper.h"
#include "util/DateTime.h"
#include <retroshare/rsgxsforums.h>
#include <retroshare/rsposted.h>
@ -180,8 +181,7 @@ void AddFeedDialog::useStandardUpdateIntervalToggled()
void AddFeedDialog::useStandardProxyToggled()
{
bool checked = ui->useStandardProxyCheckBox->isChecked();
ui->proxyAddressLineEdit->setEnabled(!checked);
ui->proxyPortSpinBox->setEnabled(!checked);
ui->proxyWidget->setEnabled(!checked);
}
void AddFeedDialog::typeForumToggled()
@ -335,13 +335,12 @@ bool AddFeedDialog::fillFeed(uint32_t feedId)
ui->passwordLineEdit->setText(QString::fromUtf8(feedInfo.password.c_str()));
ui->useStandardProxyCheckBox->setChecked(feedInfo.flag.standardProxy);
ui->proxyAddressLineEdit->setText(QString::fromUtf8(feedInfo.proxyAddress.c_str()));
ui->proxyPortSpinBox->setValue(feedInfo.proxyPort);
ui->proxyWidget->setAddress(QString::fromUtf8(feedInfo.proxyAddress.c_str()));
ui->proxyWidget->setPort(feedInfo.proxyPort);
ui->useStandardUpdateInterval->setChecked(feedInfo.flag.standardUpdateInterval);
ui->updateIntervalSpinBox->setValue(feedInfo.updateInterval / 60);
QDateTime dateTime;
dateTime.setTime_t(feedInfo.lastUpdate);
QDateTime dateTime = DateTime::DateTimeFromTime_t(feedInfo.lastUpdate);
ui->lastUpdate->setText(dateTime.toString());
ui->useStandardStorageTimeCheckBox->setChecked(feedInfo.flag.standardStorageTime);
@ -425,8 +424,8 @@ void AddFeedDialog::getFeedInfo(FeedInfo &feedInfo)
feedInfo.password = ui->passwordLineEdit->text().toUtf8().constData();
feedInfo.flag.standardProxy = ui->useStandardProxyCheckBox->isChecked();
feedInfo.proxyAddress = ui->proxyAddressLineEdit->text().toUtf8().constData();
feedInfo.proxyPort = ui->proxyPortSpinBox->value();
feedInfo.proxyAddress = ui->proxyWidget->address().toUtf8().constData();
feedInfo.proxyPort = ui->proxyWidget->port();
feedInfo.flag.standardUpdateInterval = ui->useStandardUpdateInterval->isChecked();
feedInfo.updateInterval = ui->updateIntervalSpinBox->value() * 60;

View File

@ -133,37 +133,16 @@
<property name="title">
<string>Proxy</string>
</property>
<layout class="QGridLayout" name="gridLayout_6">
<item row="0" column="0" colspan="2">
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QCheckBox" name="useStandardProxyCheckBox">
<property name="text">
<string>Use standard proxy</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="serverLabel">
<property name="text">
<string>Server</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="proxyAddressLineEdit"/>
</item>
<item row="1" column="2">
<widget class="QLabel" name="portLabel">
<property name="text">
<string>:</string>
</property>
</widget>
</item>
<item row="1" column="3">
<widget class="QSpinBox" name="proxyPortSpinBox">
<property name="maximum">
<number>65535</number>
</property>
</widget>
<item>
<widget class="ProxyWidget" name="proxyWidget" native="true"/>
</item>
</layout>
</widget>
@ -465,6 +444,12 @@
<extends>QComboBox</extends>
<header>gui/common/RSComboBox.h</header>
</customwidget>
<customwidget>
<class>ProxyWidget</class>
<extends>QWidget</extends>
<header>gui/ProxyWidget.h</header>
<container>1</container>
</customwidget>
</customwidgets>
<tabstops>
<tabstop>urlLineEdit</tabstop>
@ -494,8 +479,7 @@
<tabstop>useStandardUpdateInterval</tabstop>
<tabstop>updateIntervalSpinBox</tabstop>
<tabstop>useStandardProxyCheckBox</tabstop>
<tabstop>proxyAddressLineEdit</tabstop>
<tabstop>proxyPortSpinBox</tabstop>
<tabstop>proxyWidget</tabstop>
</tabstops>
<resources/>
<connections/>

View File

@ -31,8 +31,7 @@ FeedReaderConfig::FeedReaderConfig(QWidget *parent, Qt::WindowFlags flags)
/* Invoke the Qt Designer generated object setup routine */
ui->setupUi(this);
ui->proxyAddressLineEdit->setEnabled(false);
ui->proxyPortSpinBox->setEnabled(false);
ui->proxyWidget->setEnabled(false);
/* Connect signals */
connect(ui->updateIntervalSpinBox, (void(QSpinBox::*)(int))&QSpinBox::valueChanged, this, [this]() {
@ -51,8 +50,7 @@ FeedReaderConfig::FeedReaderConfig(QWidget *parent, Qt::WindowFlags flags)
Settings->setValueToGroup("FeedReaderDialog", "OpenAllInNewTab", ui->openAllInNewTabCheckBox->isChecked());
});
connect(ui->useProxyCheckBox, &QCheckBox::toggled, this, &FeedReaderConfig::updateProxy);
connect(ui->proxyAddressLineEdit, &QLineEdit::textChanged, this, &FeedReaderConfig::updateProxy);
connect(ui->proxyPortSpinBox, (void(QSpinBox::*)(int))&QSpinBox::valueChanged, this, &FeedReaderConfig::updateProxy);
connect(ui->proxyWidget, &ProxyWidget::changed, this, &FeedReaderConfig::updateProxy);
connect(ui->useProxyCheckBox, SIGNAL(toggled(bool)), this, SLOT(useProxyToggled()));
}
@ -75,8 +73,8 @@ void FeedReaderConfig::load()
std::string proxyAddress;
uint16_t proxyPort;
whileBlocking(ui->useProxyCheckBox)->setChecked(rsFeedReader->getStandardProxy(proxyAddress, proxyPort));
whileBlocking(ui->proxyAddressLineEdit)->setText(QString::fromUtf8(proxyAddress.c_str()));
whileBlocking(ui->proxyPortSpinBox)->setValue(proxyPort);
whileBlocking(ui->proxyWidget)->setAddress(QString::fromUtf8(proxyAddress.c_str()));
whileBlocking(ui->proxyWidget)->setPort(proxyPort);
loaded = true;
@ -87,11 +85,10 @@ void FeedReaderConfig::useProxyToggled()
{
bool enabled = ui->useProxyCheckBox->isChecked();
ui->proxyAddressLineEdit->setEnabled(enabled);
ui->proxyPortSpinBox->setEnabled(enabled);
ui->proxyWidget->setEnabled(enabled);
}
void FeedReaderConfig::updateProxy()
{
rsFeedReader->setStandardProxy(ui->useProxyCheckBox->isChecked(), ui->proxyAddressLineEdit->text().toUtf8().constData(), ui->proxyPortSpinBox->value());
rsFeedReader->setStandardProxy(ui->useProxyCheckBox->isChecked(), ui->proxyWidget->address().toUtf8().constData(), ui->proxyWidget->port());
}

View File

@ -36,7 +36,7 @@ class FeedReaderConfig : public ConfigPage
public:
/** Default Constructor */
FeedReaderConfig(QWidget *parent = 0, Qt::WindowFlags flags = 0);
FeedReaderConfig(QWidget *parent = 0, Qt::WindowFlags flags = Qt::WindowFlags());
/** Default Destructor */
virtual ~FeedReaderConfig();

View File

@ -77,37 +77,16 @@
<property name="title">
<string>Proxy</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0" colspan="4">
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QCheckBox" name="useProxyCheckBox">
<property name="text">
<string>Use proxy</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="serverLabel">
<property name="text">
<string>Server</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="proxyAddressLineEdit"/>
</item>
<item row="1" column="3">
<widget class="QSpinBox" name="proxyPortSpinBox">
<property name="maximum">
<number>65535</number>
</property>
</widget>
</item>
<item row="1" column="2">
<widget class="QLabel" name="potLabel">
<property name="text">
<string>:</string>
</property>
</widget>
<item>
<widget class="ProxyWidget" name="proxyWidget" native="true"/>
</item>
</layout>
</widget>
@ -157,12 +136,19 @@
</item>
</layout>
</widget>
<customwidgets>
<customwidget>
<class>ProxyWidget</class>
<extends>QWidget</extends>
<header>gui/ProxyWidget.h</header>
<container>1</container>
</customwidget>
</customwidgets>
<tabstops>
<tabstop>updateIntervalSpinBox</tabstop>
<tabstop>storageTimeSpinBox</tabstop>
<tabstop>useProxyCheckBox</tabstop>
<tabstop>proxyAddressLineEdit</tabstop>
<tabstop>proxyPortSpinBox</tabstop>
<tabstop>proxyWidget</tabstop>
<tabstop>saveInBackgroundCheckBox</tabstop>
<tabstop>setMsgToReadOnActivate</tabstop>
<tabstop>openAllInNewTabCheckBox</tabstop>

View File

@ -34,7 +34,7 @@
#include "FeedReaderStringDefs.h"
#include "gui/common/RSTreeWidgetItem.h"
#include "gui/settings/rsharesettings.h"
#include "gui/notifyqt.h"
#include "gui/RsGUIEventManager.h"
#include "FeedReaderUserNotify.h"
#include "gui/Posted/PostedCreatePostDialog.h"
#include "util/imageutil.h"
@ -73,7 +73,7 @@ FeedReaderDialog::FeedReaderDialog(RsFeedReader *feedReader, FeedReaderNotify *n
connect(mNotify, &FeedReaderNotify::feedChanged, this, &FeedReaderDialog::feedChanged, Qt::QueuedConnection);
connect(mNotify, &FeedReaderNotify::optimizeImage, this, &FeedReaderDialog::optimizeImage, Qt::QueuedConnection);
connect(NotifyQt::getInstance(), SIGNAL(settingsChanged()), this, SLOT(settingsChanged()));
connect(RsGUIEventManager::getInstance(), SIGNAL(settingsChanged()), this, SLOT(settingsChanged()));
/* connect signals */
connect(ui->feedTreeWidget, SIGNAL(itemActivated(QTreeWidgetItem*,int)), this, SLOT(feedTreeItemActivated(QTreeWidgetItem*)));
@ -129,6 +129,8 @@ FeedReaderDialog::FeedReaderDialog(RsFeedReader *feedReader, FeedReaderNotify *n
settingsChanged();
feedTreeItemActivated(NULL);
mFontSizeHandler.registerFontSize(ui->feedTreeWidget);
}
FeedReaderDialog::~FeedReaderDialog()
@ -568,7 +570,7 @@ void FeedReaderDialog::feedChanged(uint32_t feedId, int type)
}
FeedInfo feedInfo;
if (type != NOTIFY_TYPE_DEL) {
if (type != FeedReaderNotify::NOTIFY_TYPE_DEL) {
if (!mFeedReader->getFeedInfo(feedId, feedInfo)) {
return;
}
@ -578,12 +580,12 @@ void FeedReaderDialog::feedChanged(uint32_t feedId, int type)
}
}
if (type == NOTIFY_TYPE_MOD || type == NOTIFY_TYPE_DEL) {
if (type == FeedReaderNotify::NOTIFY_TYPE_MOD || type == FeedReaderNotify::NOTIFY_TYPE_DEL) {
QTreeWidgetItemIterator it(ui->feedTreeWidget);
QTreeWidgetItem *item;
while ((item = *it) != NULL) {
if (item->data(COLUMN_FEED_DATA, ROLE_FEED_ID).toUInt() == feedId) {
if (type == NOTIFY_TYPE_MOD) {
if (type == FeedReaderNotify::NOTIFY_TYPE_MOD) {
updateFeedItem(item, feedInfo);
} else {
delete(item);
@ -594,7 +596,7 @@ void FeedReaderDialog::feedChanged(uint32_t feedId, int type)
}
}
if (type == NOTIFY_TYPE_ADD) {
if (type == FeedReaderNotify::NOTIFY_TYPE_ADD) {
QTreeWidgetItemIterator it(ui->feedTreeWidget);
QTreeWidgetItem *itemParent;
while ((itemParent = *it) != NULL) {

View File

@ -23,6 +23,7 @@
#include <retroshare-gui/mainpage.h>
#include "interface/rsFeedReader.h"
#include "util/FontSizeHandler.h"
namespace Ui {
class FeedReaderDialog;
@ -39,15 +40,15 @@ class FeedReaderDialog : public MainPage
Q_OBJECT
public:
FeedReaderDialog(RsFeedReader *feedReader, FeedReaderNotify *notify, QWidget *parent = 0);
FeedReaderDialog(RsFeedReader *feedReader, FeedReaderNotify *notify, QWidget *parent = 0);
~FeedReaderDialog();
static QIcon iconFromFeed(const FeedInfo &feedInfo);
protected:
virtual UserNotify *createUserNotify(QObject *parent) override;
virtual void showEvent(QShowEvent *event);
bool eventFilter(QObject *obj, QEvent *ev);
virtual void showEvent(QShowEvent *event) override;
bool eventFilter(QObject *obj, QEvent *ev) override;
private slots:
void settingsChanged();
@ -98,6 +99,8 @@ private:
RsFeedReader *mFeedReader;
FeedReaderNotify *mNotify;
FontSizeHandler mFontSizeHandler;
/** Qt Designer generated object */
Ui::FeedReaderDialog *ui;
};

View File

@ -57,10 +57,10 @@
<item row="0" column="0">
<widget class="QFrame" name="toolBarFrame">
<property name="frameShape">
<enum>QFrame::Box</enum>
<enum>QFrame::StyledPanel</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Sunken</enum>
<enum>QFrame::Raised</enum>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_4">
<property name="leftMargin">

View File

@ -27,6 +27,7 @@
#include "FeedReaderFeedItem.h"
#include "gui/settings/rsharesettings.h"
#include "retroshare/rsiface.h"
#include "util/DateTime.h"
FeedReaderFeedNotify::FeedReaderFeedNotify(RsFeedReader *feedReader, FeedReaderNotify *notify, QObject *parent) :
FeedNotify(parent), mFeedReader(feedReader), mNotify(notify)
@ -71,7 +72,7 @@ void FeedReaderFeedNotify::msgChanged(uint32_t feedId, const QString &msgId, int
return;
}
if (type != NOTIFY_TYPE_ADD) {
if (type != FeedReaderNotify::NOTIFY_TYPE_ADD) {
return;
}
@ -135,7 +136,7 @@ FeedItem *FeedReaderFeedNotify::testFeedItem(FeedHolder */*parent*/)
FeedMsgInfo msgInfo;
msgInfo.title = tr("Test message").toUtf8().constData();
msgInfo.description = tr("This is a test message.").toUtf8().constData();
msgInfo.pubDate = QDateTime::currentDateTime().toTime_t();
msgInfo.pubDate = DateTime::DateTimeToTime_t(QDateTime::currentDateTime());
//TODO: parent?
return new FeedReaderFeedItem(mFeedReader, mNotify, feedInfo, msgInfo);

View File

@ -36,11 +36,12 @@
#include "gui/common/RSTreeWidgetItem.h"
#include "gui/settings/rsharesettings.h"
#include "util/HandleRichText.h"
#include "util/QtVersion.h"
#include "util/RsQtVersion.h"
#include "gui/Posted/PostedCreatePostDialog.h"
#include "gui/gxsforums/CreateGxsForumMsg.h"
#include "gui/common/FilesDefs.h"
#include "util/imageutil.h"
#include "util/DateTime.h"
#include "retroshare/rsiface.h"
#include "retroshare/rsgxsforums.h"
@ -154,6 +155,8 @@ FeedReaderMessageWidget::FeedReaderMessageWidget(uint32_t feedId, RsFeedReader *
ui->msgTreeWidget->installEventFilter(this);
setFeedId(feedId);
mFontSizeHandler.registerFontSize(ui->msgTreeWidget);
}
FeedReaderMessageWidget::~FeedReaderMessageWidget()
@ -361,6 +364,9 @@ void FeedReaderMessageWidget::msgTreeCustomPopupMenu(QPoint /*point*/)
action = contextMnu.addAction(QIcon(""), tr("Mark all as read"), this, SLOT(markAllAsReadMsg()));
action->setEnabled(mFeedId);
action = contextMnu.addAction(QIcon(""), tr("Mark all as unread"), this, SLOT(markAllAsUnreadMsg()));
action->setEnabled(mFeedId);
contextMnu.addSeparator();
action = contextMnu.addAction(QIcon(""), tr("Copy link"), this, SLOT(copySelectedLinksMsg()));
@ -474,8 +480,7 @@ void FeedReaderMessageWidget::calculateMsgIconsAndFonts(QTreeWidgetItem *item)
void FeedReaderMessageWidget::updateMsgItem(QTreeWidgetItem *item, FeedMsgInfo &info)
{
QString title = QString::fromUtf8(info.title.c_str());
QDateTime qdatetime;
qdatetime.setTime_t(info.pubDate);
QDateTime qdatetime = DateTime::DateTimeFromTime_t(info.pubDate);
/* add string to all data */
QString sort = QString("%1_%2_%3").arg(title, qdatetime.toString("yyyyMMdd_hhmmss")).arg(info.feedId);
@ -513,12 +518,12 @@ void FeedReaderMessageWidget::feedChanged(uint32_t feedId, int type)
return;
}
if (type == NOTIFY_TYPE_DEL) {
if (type == FeedReaderNotify::NOTIFY_TYPE_DEL) {
setFeedId(0);
return;
}
if (type == NOTIFY_TYPE_MOD) {
if (type == FeedReaderNotify::NOTIFY_TYPE_MOD) {
if (!mFeedReader->getFeedInfo(mFeedId, mFeedInfo)) {
setFeedId(0);
return;
@ -553,18 +558,18 @@ void FeedReaderMessageWidget::msgChanged(uint32_t feedId, const QString &msgId,
}
FeedMsgInfo msgInfo;
if (type != NOTIFY_TYPE_DEL) {
if (type != FeedReaderNotify::NOTIFY_TYPE_DEL) {
if (!mFeedReader->getMsgInfo(feedId, msgId.toStdString(), msgInfo)) {
return;
}
}
if (type == NOTIFY_TYPE_MOD || type == NOTIFY_TYPE_DEL) {
if (type == FeedReaderNotify::NOTIFY_TYPE_MOD || type == FeedReaderNotify::NOTIFY_TYPE_DEL) {
QTreeWidgetItemIterator it(ui->msgTreeWidget);
QTreeWidgetItem *item;
while ((item = *it) != NULL) {
if (item->data(COLUMN_MSG_DATA, ROLE_MSG_ID).toString() == msgId) {
if (type == NOTIFY_TYPE_MOD) {
if (type == FeedReaderNotify::NOTIFY_TYPE_MOD) {
updateMsgItem(item, msgInfo);
filterItem(item);
} else {
@ -576,13 +581,13 @@ void FeedReaderMessageWidget::msgChanged(uint32_t feedId, const QString &msgId,
}
}
if (type == NOTIFY_TYPE_MOD) {
if (type == FeedReaderNotify::NOTIFY_TYPE_MOD) {
if (msgId.toStdString() == currentMsgId()) {
updateCurrentMessage();
}
}
if (type == NOTIFY_TYPE_ADD) {
if (type == FeedReaderNotify::NOTIFY_TYPE_ADD) {
QTreeWidgetItem *item = new RSTreeWidgetItem(mMsgCompareRole);
updateMsgItem(item, msgInfo);
ui->msgTreeWidget->addTopLevelItem(item);
@ -818,6 +823,16 @@ void FeedReaderMessageWidget::markAsUnreadMsg()
}
void FeedReaderMessageWidget::markAllAsReadMsg()
{
setAllMsgAsReadUnread(true);
}
void FeedReaderMessageWidget::markAllAsUnreadMsg()
{
setAllMsgAsReadUnread(false);
}
void FeedReaderMessageWidget::setAllMsgAsReadUnread(bool read)
{
QList<QTreeWidgetItem*> items;
@ -829,7 +844,7 @@ void FeedReaderMessageWidget::markAllAsReadMsg()
}
++it;
}
setMsgAsReadUnread(items, true);
setMsgAsReadUnread(items, read);
}
void FeedReaderMessageWidget::copySelectedLinksMsg()

View File

@ -24,6 +24,7 @@
#include <QWidget>
#include "interface/rsFeedReader.h"
#include "util/FontSizeHandler.h"
namespace Ui {
class FeedReaderMessageWidget;
@ -67,6 +68,7 @@ private slots:
void markAsReadMsg();
void markAsUnreadMsg();
void markAllAsReadMsg();
void markAllAsUnreadMsg();
void copySelectedLinksMsg();
void removeMsg();
void processFeed();
@ -90,6 +92,7 @@ private:
void calculateMsgIconsAndFonts(QTreeWidgetItem *item);
void updateMsgItem(QTreeWidgetItem *item, FeedMsgInfo &info);
void setMsgAsReadUnread(QList<QTreeWidgetItem*> &rows, bool read);
void setAllMsgAsReadUnread(bool read);
void filterItem(QTreeWidgetItem *item, const QString &text, int filterColumn);
void filterItem(QTreeWidgetItem *item);
void toggleMsgText_internal();
@ -107,6 +110,8 @@ private:
RsFeedReader *mFeedReader;
FeedReaderNotify *mNotify;
FontSizeHandler mFontSizeHandler;
Ui::FeedReaderMessageWidget *ui;
};

View File

@ -29,6 +29,13 @@ class FeedReaderNotify : public QObject, public RsFeedReaderNotify
Q_OBJECT
public:
// These replace the variables from the old notify system. It's simpler than switching the entire
// feedreader plugin to the new rsEvents system
static const int NOTIFY_TYPE_ADD = 0x01;
static const int NOTIFY_TYPE_DEL = 0x02;
static const int NOTIFY_TYPE_MOD = 0x03;
FeedReaderNotify();
/* RsFeedReaderNotify */

View File

@ -67,7 +67,7 @@ void FeedReaderUserNotify::iconClicked()
void FeedReaderUserNotify::feedChanged(uint32_t /*feedId*/, int type)
{
if (type == NOTIFY_TYPE_DEL) {
if (type == FeedReaderNotify::NOTIFY_TYPE_DEL) {
updateIcon();
}
}

View File

@ -294,13 +294,13 @@ void PreviewFeedDialog::feedChanged(uint32_t feedId, int type)
return;
}
if (type == NOTIFY_TYPE_DEL) {
if (type == FeedReaderNotify::NOTIFY_TYPE_DEL) {
/* feed deleted */
mFeedId = 0;
return;
}
if (type == NOTIFY_TYPE_ADD || type == NOTIFY_TYPE_MOD) {
if (type == FeedReaderNotify::NOTIFY_TYPE_ADD || type == FeedReaderNotify::NOTIFY_TYPE_MOD) {
FeedInfo feedInfo;
if (!mFeedReader->getFeedInfo(mFeedId, feedInfo)) {
return;
@ -320,18 +320,18 @@ void PreviewFeedDialog::msgChanged(uint32_t feedId, const QString &msgId, int ty
}
switch (type) {
case NOTIFY_TYPE_ADD:
case FeedReaderNotify::NOTIFY_TYPE_ADD:
if (mMsgId.empty()) {
mMsgId = msgId.toStdString();
updateMsg();
}
break;
case NOTIFY_TYPE_MOD:
case FeedReaderNotify::NOTIFY_TYPE_MOD:
if (mMsgId == msgId.toStdString()) {
updateMsg();
}
break;
case NOTIFY_TYPE_DEL:
case FeedReaderNotify::NOTIFY_TYPE_DEL:
if (mMsgId == msgId.toStdString()) {
std::list<std::string>::iterator it = std::find(mMsgIds.begin(), mMsgIds.end(), mMsgId);
if (it != mMsgIds.end()) {

View File

@ -0,0 +1,142 @@
#include "ProxyWidget.h"
#include "ui_ProxyWidget.h"
ProxyWidget::ProxyWidget(QWidget *parent)
: QWidget(parent)
, ui(new Ui::ProxyWidget)
{
ui->setupUi(this);
/* Connect signals */
connectUi(true);
connect(ui->portSpinBox, (void(QSpinBox::*)(int))&QSpinBox::valueChanged, this, &ProxyWidget::changed);
/* Initialize types */
ui->schemeComboBox->addItem("", "");
ui->schemeComboBox->addItem("HTTP", "http://");
ui->schemeComboBox->setItemData(ui->schemeComboBox->count() - 1, tr("HTTP Proxy."), Qt::ToolTipRole);
ui->schemeComboBox->addItem("HTTPS", "https://");
ui->schemeComboBox->setItemData(ui->schemeComboBox->count() - 1, tr("HTTPS Proxy."), Qt::ToolTipRole);
ui->schemeComboBox->addItem("SOCKS4", "socks4://");
ui->schemeComboBox->setItemData(ui->schemeComboBox->count() - 1, tr("SOCKS4 Proxy."), Qt::ToolTipRole);
ui->schemeComboBox->addItem("SOCKS4a", "socks4a://");
ui->schemeComboBox->setItemData(ui->schemeComboBox->count() - 1, tr("SOCKS4a Proxy. Proxy resolves URL hostname."), Qt::ToolTipRole);
ui->schemeComboBox->addItem("SOCKS5", "socks5://");
ui->schemeComboBox->setItemData(ui->schemeComboBox->count() - 1, tr("SOCKS5 Proxy."), Qt::ToolTipRole);
ui->schemeComboBox->addItem("SOCKS5h", "socks5h://");
ui->schemeComboBox->setItemData(ui->schemeComboBox->count() - 1, tr("SOCKS5 Proxy. Proxy resolves URL hostname."), Qt::ToolTipRole);
}
ProxyWidget::~ProxyWidget()
{
delete ui;
}
void ProxyWidget::connectUi(bool doConnect)
{
if (doConnect) {
if (!mAddressConnection) {
mAddressConnection = connect(ui->addressLineEdit, &QLineEdit::textChanged, this, &ProxyWidget::addressChanged);
}
if (!mSchemeConnection) {
mSchemeConnection = connect(ui->schemeComboBox, (void(QComboBox::*)(int))&QComboBox::currentIndexChanged, this, &ProxyWidget::changed);
}
} else {
if (mAddressConnection) {
disconnect(mAddressConnection);
}
if (mSchemeConnection) {
disconnect(mSchemeConnection);
}
}
}
QString ProxyWidget::address()
{
QString host = ui->addressLineEdit->text();
if (host.isEmpty()) {
return "";
}
QString value;
QString scheme = ui->schemeComboBox->currentData().toString();
if (!scheme.isEmpty()) {
value = scheme;
}
value += ui->addressLineEdit->text();
return value;
}
void ProxyWidget::setAddress(const QString &value)
{
int schemeIndex;
QString host;
splitAddress(value, schemeIndex, host);
connectUi(false);
ui->schemeComboBox->setCurrentIndex(schemeIndex);
ui->addressLineEdit->setText(host);
connectUi(true);
}
int ProxyWidget::port()
{
return ui->portSpinBox->value();
}
void ProxyWidget::setPort(int value)
{
ui->portSpinBox->setValue(value);
}
void ProxyWidget::addressChanged(const QString &value)
{
int schemeIndex;
QString host;
splitAddress(value, schemeIndex, host);
connectUi(false);
ui->schemeComboBox->setCurrentIndex(schemeIndex);
if (host != ui->addressLineEdit->text()) {
ui->addressLineEdit->setText(host);
}
connectUi(true);
emit changed();
}
void ProxyWidget::splitAddress(const QString &value, int &schemeIndex, QString &host)
{
if (value.isEmpty()) {
schemeIndex = ui->schemeComboBox->currentIndex();
host = value;
return;
}
QString scheme;
int index = value.indexOf("://");
if (index >= 0) {
scheme = value.left(index + 3);
host = value.mid(index + 3);
} else {
if (ui->schemeComboBox->currentIndex() == 0) {
// Default to HTTP
scheme = "http://";
} else {
scheme = ui->schemeComboBox->currentData().toString();
}
host = value;
}
schemeIndex = ui->schemeComboBox->findData(scheme);
if (schemeIndex < 0) {
/* Unknown scheme */
schemeIndex = 0;
host = value;
}
}

View File

@ -0,0 +1,40 @@
#ifndef PROXYWIDGET_H
#define PROXYWIDGET_H
#include <QWidget>
namespace Ui {
class ProxyWidget;
}
class ProxyWidget : public QWidget
{
Q_OBJECT
public:
explicit ProxyWidget(QWidget *parent = nullptr);
~ProxyWidget();
QString address();
void setAddress(const QString &value);
int port();
void setPort(int value);
Q_SIGNALS:
void changed();
private Q_SLOTS:
void addressChanged(const QString &value);
private:
void connectUi(bool doConnect);
void splitAddress(const QString &value, int &schemeIndex, QString &host);
private:
Ui::ProxyWidget *ui;
QMetaObject::Connection mAddressConnection;
QMetaObject::Connection mSchemeConnection;
};
#endif // PROXYWIDGET_H

View File

@ -0,0 +1,53 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>ProxyWidget</class>
<widget class="QWidget" name="ProxyWidget">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>400</width>
<height>22</height>
</rect>
</property>
<property name="windowTitle">
<string notr="true"/>
</property>
<layout class="QHBoxLayout" name="horizontalLayout">
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<widget class="QComboBox" name="schemeComboBox"/>
</item>
<item>
<widget class="QLineEdit" name="addressLineEdit"/>
</item>
<item>
<widget class="QLabel" name="portLabel">
<property name="text">
<string notr="true">:</string>
</property>
</widget>
</item>
<item>
<widget class="QSpinBox" name="portSpinBox">
<property name="maximum">
<number>65535</number>
</property>
</widget>
</item>
</layout>
</widget>
<resources/>
<connections/>
</ui>

View File

@ -9,7 +9,7 @@
<translation type="unfinished"></translation>
</message>
<message>
<location line="+398"/>
<location line="+377"/>
<source>Board</source>
<translation type="unfinished"></translation>
</message>
@ -34,7 +34,7 @@
<translation type="unfinished"></translation>
</message>
<message>
<location line="-391"/>
<location line="-370"/>
<source>Authentication (not yet supported)</source>
<translation type="unfinished"></translation>
</message>
@ -59,7 +59,7 @@
<translation type="unfinished"></translation>
</message>
<message>
<location line="+50"/>
<location line="+29"/>
<source>Update interval</source>
<translation type="unfinished"></translation>
</message>
@ -89,7 +89,7 @@
<translation type="unfinished"></translation>
</message>
<message>
<location line="-216"/>
<location line="-195"/>
<source>Storage time</source>
<translation type="unfinished"></translation>
</message>
@ -114,17 +114,7 @@
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Server</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+10"/>
<source>:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+200"/>
<location line="+196"/>
<source>Type</source>
<translation type="unfinished"></translation>
</message>
@ -199,7 +189,7 @@
<translation type="unfinished"></translation>
</message>
<message>
<location line="+211"/>
<location line="+208"/>
<location line="+152"/>
<location line="+15"/>
<source>Edit feed</source>
@ -264,17 +254,7 @@
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Server</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+17"/>
<source>:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+10"/>
<location line="+13"/>
<source>Misc</source>
<translation type="unfinished"></translation>
</message>
@ -317,12 +297,12 @@
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../gui/FeedReaderDialog.cpp" line="+101"/>
<location filename="../gui/FeedReaderDialog.cpp" line="+105"/>
<source>Message Folders</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+197"/>
<location line="+199"/>
<source>New</source>
<translation type="unfinished"></translation>
</message>
@ -372,7 +352,7 @@
<translation type="unfinished"></translation>
</message>
<message>
<location line="+241"/>
<location line="+259"/>
<source>Add new folder</source>
<translation type="unfinished"></translation>
</message>
@ -535,7 +515,7 @@
</message>
<message>
<location line="+26"/>
<location filename="../gui/FeedReaderMessageWidget.cpp" line="+117"/>
<location filename="../gui/FeedReaderMessageWidget.cpp" line="+126"/>
<source>Title</source>
<translation type="unfinished"></translation>
</message>
@ -551,6 +531,11 @@
<source>Author</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+121"/>
<source>Copy Link Location</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../gui/FeedReaderMessageWidget.cpp" line="-2"/>
<source>Search Title</source>
@ -567,7 +552,7 @@
<translation type="unfinished"></translation>
</message>
<message>
<location line="+12"/>
<location line="+16"/>
<source>Open link in browser</source>
<translation type="unfinished"></translation>
</message>
@ -577,7 +562,7 @@
<translation type="unfinished"></translation>
</message>
<message>
<location line="+127"/>
<location line="+131"/>
<source>The messages will be added to the forum</source>
<translation type="unfinished"></translation>
</message>
@ -637,7 +622,7 @@
<translation type="unfinished"></translation>
</message>
<message>
<location line="+374"/>
<location line="+412"/>
<source>Hide</source>
<translation type="unfinished"></translation>
</message>
@ -957,4 +942,37 @@
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProxyWidget</name>
<message>
<location filename="../gui/ProxyWidget.cpp" line="+17"/>
<source>HTTP Proxy.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+2"/>
<source>HTTPS Proxy.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+2"/>
<source>SOCKS4 Proxy.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+2"/>
<source>SOCKS4a Proxy. Proxy resolves URL hostname.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+2"/>
<source>SOCKS5 Proxy.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+2"/>
<source>SOCKS5 Proxy. Proxy resolves URL hostname.</source>
<translation type="unfinished"></translation>
</message>
</context>
</TS>

View File

@ -20,6 +20,7 @@
#include "rsFeedReaderItems.h"
#include "p3FeedReader.h"
#include "gui/FeedReaderNotify.h"
#include "p3FeedReaderThread.h"
#include "rsitems/rsconfigitems.h"
#include "retroshare/rsiface.h"
@ -415,7 +416,7 @@ RsFeedResult p3FeedReader::addFolder(uint32_t parentId, const std::string &name,
IndicateConfigChanged(RsConfigMgr::CheckPriority::SAVE_NOW);
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_ADD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_ADD);
}
return RS_FEED_RESULT_SUCCESS;
@ -455,7 +456,7 @@ RsFeedResult p3FeedReader::setFolder(uint32_t feedId, const std::string &name)
IndicateConfigChanged(RsConfigMgr::CheckPriority::SAVE_NOW);
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
return RS_FEED_RESULT_SUCCESS;
@ -502,7 +503,7 @@ RsFeedResult p3FeedReader::addFeed(const FeedInfo &feedInfo, uint32_t &feedId)
IndicateConfigChanged(RsConfigMgr::CheckPriority::SAVE_NOW);
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_ADD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_ADD);
}
return RS_FEED_RESULT_SUCCESS;
@ -587,7 +588,7 @@ RsFeedResult p3FeedReader::setFeed(uint32_t feedId, const FeedInfo &feedInfo)
IndicateConfigChanged(RsConfigMgr::CheckPriority::SAVE_NOW);
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
if (!forumId.empty()) {
@ -658,7 +659,7 @@ RsFeedResult p3FeedReader::setParent(uint32_t feedId, uint32_t parentId)
IndicateConfigChanged(RsConfigMgr::CheckPriority::SAVE_NOW);
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
}
@ -756,7 +757,7 @@ bool p3FeedReader::removeFeed(uint32_t feedId)
/* only notify remove of feed */
std::list<uint32_t>::iterator it;
for (it = removedFeedIds.begin(); it != removedFeedIds.end(); ++it) {
mNotify->notifyFeedChanged(*it, NOTIFY_TYPE_DEL);
mNotify->notifyFeedChanged(*it, FeedReaderNotify::NOTIFY_TYPE_DEL);
}
}
@ -803,7 +804,7 @@ bool p3FeedReader::addPreviewFeed(const FeedInfo &feedInfo, uint32_t &feedId)
}
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_ADD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_ADD);
}
{
@ -925,8 +926,8 @@ bool p3FeedReader::removeMsg(uint32_t feedId, const std::string &msgId)
}
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyMsgChanged(feedId, msgId, NOTIFY_TYPE_DEL);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
mNotify->notifyMsgChanged(feedId, msgId, FeedReaderNotify::NOTIFY_TYPE_DEL);
}
return true;
@ -977,11 +978,11 @@ bool p3FeedReader::removeMsgs(uint32_t feedId, const std::list<std::string> &msg
}
if (mNotify && !removedMsgs.empty()) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
std::list<std::string>::iterator it;
for (it = removedMsgs.begin(); it != removedMsgs.end(); ++it) {
mNotify->notifyMsgChanged(feedId, *it, NOTIFY_TYPE_DEL);
mNotify->notifyMsgChanged(feedId, *it, FeedReaderNotify::NOTIFY_TYPE_DEL);
}
}
@ -1224,7 +1225,7 @@ bool p3FeedReader::processFeed(uint32_t feedId)
if (mNotify) {
for (it = notifyIds.begin(); it != notifyIds.end(); ++it) {
mNotify->notifyFeedChanged(*it, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(*it, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
}
@ -1273,8 +1274,8 @@ bool p3FeedReader::setMessageRead(uint32_t feedId, const std::string &msgId, boo
if (changed) {
IndicateConfigChanged(RsConfigMgr::CheckPriority::SAVE_OFTEN);
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyMsgChanged(feedId, msgId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
mNotify->notifyMsgChanged(feedId, msgId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
}
@ -1313,6 +1314,7 @@ bool p3FeedReader::retransformMsg(uint32_t feedId, const std::string &msgId)
std::string errorString;
std::string descriptionTransformed = mi->descriptionTransformed;
if (p3FeedReaderThread::processTransformation(*fi, mi, errorString) == RS_FEED_ERRORSTATE_OK) {
RsFeedReaderSerialiser::correctMsgSize(mi);
if (mi->descriptionTransformed != descriptionTransformed) {
msgChanged = true;
}
@ -1328,10 +1330,10 @@ bool p3FeedReader::retransformMsg(uint32_t feedId, const std::string &msgId)
IndicateConfigChanged(RsConfigMgr::CheckPriority::SAVE_NOW);
if (mNotify) {
if (feedChanged) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
if (msgChanged) {
mNotify->notifyMsgChanged(feedId, msgId, NOTIFY_TYPE_MOD);
mNotify->notifyMsgChanged(feedId, msgId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
}
}
@ -1466,7 +1468,7 @@ int p3FeedReader::tick()
if (mNotify) {
for (it = notifyIds.begin(); it != notifyIds.end(); ++it) {
mNotify->notifyFeedChanged(*it, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(*it, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
if (imageToOptimze) {
mNotify->notifyOptimizeImage();
@ -1526,7 +1528,7 @@ void p3FeedReader::cleanFeeds()
if (mNotify) {
std::list<std::pair<uint32_t, std::string> >::iterator it;
for (it = removedMsgIds.begin(); it != removedMsgIds.end(); ++it) {
mNotify->notifyMsgChanged(it->first, it->second, NOTIFY_TYPE_DEL);
mNotify->notifyMsgChanged(it->first, it->second, FeedReaderNotify::NOTIFY_TYPE_DEL);
}
}
}
@ -1608,8 +1610,11 @@ bool p3FeedReader::saveList(bool &cleanup, std::list<RsItem *> &saveData)
RsFeedReaderMsg *msg = it2->second;
if (cleanup) {
saveData.push_back(new RsFeedReaderMsg(*msg));
RsFeedReaderMsg *clonedMsg = new RsFeedReaderMsg(*msg);
RsFeedReaderSerialiser::correctMsgSize(clonedMsg);
saveData.push_back(clonedMsg);
} else {
RsFeedReaderSerialiser::correctMsgSize(msg);
saveData.push_back(msg);
}
}
@ -1801,7 +1806,7 @@ bool p3FeedReader::getFeedToDownload(RsFeedReaderFeed &feed, uint32_t neededFeed
}
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
return true;
@ -1852,7 +1857,7 @@ void p3FeedReader::onDownloadSuccess(uint32_t feedId, const std::string &content
}
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
}
@ -1889,7 +1894,7 @@ void p3FeedReader::onDownloadError(uint32_t feedId, RsFeedReaderErrorState resul
}
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
}
@ -1944,7 +1949,7 @@ bool p3FeedReader::getFeedToProcess(RsFeedReaderFeed &feed, uint32_t neededFeedI
}
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
return true;
@ -2124,6 +2129,7 @@ void p3FeedReader::onProcessSuccess_addMsgs(uint32_t feedId, std::list<RsFeedRea
miNew->flag = RS_FEEDMSG_FLAG_NEW;
addedMsgs.push_back(miNew->msgId);
}
RsFeedReaderSerialiser::correctMsgSize(miNew);
fi->msgs[miNew->msgId] = miNew;
newMsgIt = msgs.erase(newMsgIt);
@ -2323,11 +2329,11 @@ void p3FeedReader::onProcessSuccess_addMsgs(uint32_t feedId, std::list<RsFeedRea
}
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
std::list<std::string>::iterator it;
for (it = addedMsgs.begin(); it != addedMsgs.end(); ++it) {
mNotify->notifyMsgChanged(feedId, *it, NOTIFY_TYPE_ADD);
mNotify->notifyMsgChanged(feedId, *it, FeedReaderNotify::NOTIFY_TYPE_ADD);
}
}
}
@ -2365,7 +2371,7 @@ void p3FeedReader::onProcessError(uint32_t feedId, RsFeedReaderErrorState result
}
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
}
@ -2433,7 +2439,7 @@ void p3FeedReader::setFeedInfo(uint32_t feedId, const std::string &name, const s
}
if (mNotify) {
mNotify->notifyFeedChanged(feedId, NOTIFY_TYPE_MOD);
mNotify->notifyFeedChanged(feedId, FeedReaderNotify::NOTIFY_TYPE_MOD);
}
}

View File

@ -32,9 +32,9 @@ class RsFeedReaderMsg;
class p3FeedReaderThread;
class RsGxsForums;
struct RsGxsForumGroup;
class RsGxsForumGroup;
class RsPosted;
struct RsPostedGroup;
class RsPostedGroup;
class RsGxsIfaceHelper;
class p3FeedReader : public RsPQIService, public RsFeedReader

View File

@ -848,6 +848,22 @@ RsFeedReaderErrorState p3FeedReaderThread::process(const RsFeedReaderFeed &feed,
RsFeedReaderErrorState result = RS_FEED_ERRORSTATE_OK;
time_t minimumPubDate = 0;
if (feed.lastUpdate == 0) {
// Get all items on first scan
} else {
// Get storage time
uint32_t storageTime = 0;
if (feed.flag & RS_FEED_FLAG_STANDARD_STORAGE_TIME) {
storageTime = mFeedReader->getStandardStorageTime();
} else {
storageTime = feed.storageTime;
}
if (storageTime > 0) {
minimumPubDate = time(NULL) - storageTime;
}
}
XMLWrapper xml;
if (xml.readXML(feed.content.c_str())) {
xmlNodePtr root = xml.getRootElement();
@ -1006,6 +1022,13 @@ RsFeedReaderErrorState p3FeedReaderThread::process(const RsFeedReaderFeed &feed,
}
}
if (minimumPubDate) {
if (item->pubDate < minimumPubDate) {
// pubDate is less than storage time, don't add as new item
continue;
}
}
entries.push_back(item);
}
} else {
@ -1097,7 +1120,7 @@ RsFeedReaderErrorState p3FeedReaderThread::processMsg(const RsFeedReaderFeed &fe
std::string url;
if (feed.flag & RS_FEED_FLAG_SAVE_COMPLETE_PAGE) {
#ifdef FEEDREADER_DEBUG
std::cerr << "p3FeedReaderThread::processHTML - feed " << feed.feedId << " (" << feed.name << ") download page " << msg->link << std::endl;
std::cerr << "p3FeedReaderThread::processMsg - feed " << feed.feedId << " (" << feed.name << ") download page " << msg->link << std::endl;
#endif
std::string content;
CURLWrapper CURL(proxy);
@ -1134,7 +1157,7 @@ RsFeedReaderErrorState p3FeedReaderThread::processMsg(const RsFeedReaderFeed &fe
if (result != RS_FEED_ERRORSTATE_OK) {
#ifdef FEEDREADER_DEBUG
std::cerr << "p3FeedReaderThread::processHTML - feed " << feed.feedId << " (" << feed.name << ") cannot download page, CURLCode = " << code << ", error = " << errorString << std::endl;
std::cerr << "p3FeedReaderThread::processMsg - feed " << feed.feedId << " (" << feed.name << ") cannot download page, CURLCode = " << code << ", error = " << errorString << std::endl;
#endif
return result;
}
@ -1151,10 +1174,10 @@ RsFeedReaderErrorState p3FeedReaderThread::processMsg(const RsFeedReaderFeed &fe
if (isRunning()) {
/* process description */
bool processPostedFirstImage = (feed.flag & RS_FEED_FLAG_POSTED_FIRST_IMAGE) ? TRUE : FALSE;
bool processPostedFirstImage = (feed.flag & RS_FEED_FLAG_POSTED_FIRST_IMAGE) ? true : false;
if (!msg->attachmentBinary.empty()) {
/* use attachment as image */
processPostedFirstImage = FALSE;
processPostedFirstImage = false;
}
//long todo; // encoding
@ -1178,16 +1201,7 @@ RsFeedReaderErrorState p3FeedReaderThread::processMsg(const RsFeedReaderFeed &fe
switch (node->type) {
case XML_ELEMENT_NODE:
if (xmlStrcasecmp(node->name, BAD_CAST"img") == 0) {
/* process images */
if ((feed.flag & RS_FEED_FLAG_EMBED_IMAGES) == 0) {
/* remove image */
xmlUnlinkNode(node);
nodesToDelete.push_back(node);
continue;
}
} else if (xmlStrcasecmp(node->name, BAD_CAST"script") == 0) {
if (xmlStrcasecmp(node->name, BAD_CAST"script") == 0) {
/* remove script */
xmlUnlinkNode(node);
nodesToDelete.push_back(node);
@ -1274,13 +1288,13 @@ RsFeedReaderErrorState p3FeedReaderThread::processMsg(const RsFeedReaderFeed &fe
if (node->type == XML_ELEMENT_NODE) {
bool removeImage = true;
if (feed.flag & RS_FEED_FLAG_EMBED_IMAGES) {
/* embed image */
if ((feed.flag & RS_FEED_FLAG_EMBED_IMAGES) || (processPostedFirstImage && !postedFirstImageNode)) {
/* embed image or use first image for posted */
std::string src = html.getAttr(node, "src");
if (!src.empty()) {
/* download image */
#ifdef FEEDREADER_DEBUG
std::cerr << "p3FeedReaderThread::processHTML - feed " << feed.feedId << " (" << feed.name << ") download image " << src << std::endl;
std::cerr << "p3FeedReaderThread::processMsg - feed " << feed.feedId << " (" << feed.name << ") download image " << src << std::endl;
#endif
std::vector<unsigned char> data;
CURLWrapper CURL(proxy);
@ -1288,23 +1302,26 @@ RsFeedReaderErrorState p3FeedReaderThread::processMsg(const RsFeedReaderFeed &fe
if (code == CURLE_OK && CURL.responseCode() == 200) {
std::string contentType = CURL.contentType();
if (isContentType(contentType, "image/")) {
std::vector<unsigned char> optimizedData;
std::string optimizedMimeType;
if (mFeedReader->optimizeImage(FeedReaderOptimizeImageTask::SIZE, data, contentType, optimizedData, optimizedMimeType)) {
std::string base64;
if (toBase64(optimizedData, base64)) {
std::string imageBase64;
rs_sprintf(imageBase64, "data:%s;base64,%s", optimizedMimeType.c_str(), base64.c_str());
if (html.setAttr(node, "src", imageBase64.c_str())) {
removeImage = false;
if (feed.flag & RS_FEED_FLAG_EMBED_IMAGES) {
std::vector<unsigned char> optimizedData;
std::string optimizedMimeType;
if (mFeedReader->optimizeImage(FeedReaderOptimizeImageTask::SIZE, data, contentType, optimizedData, optimizedMimeType)) {
std::string base64;
if (toBase64(optimizedData, base64)) {
std::string imageBase64;
rs_sprintf(imageBase64, "data:%s;base64,%s", optimizedMimeType.c_str(), base64.c_str());
if (html.setAttr(node, "src", imageBase64.c_str())) {
removeImage = false;
}
}
}
}
if (processPostedFirstImage && postedFirstImageNode == NULL) {
if (processPostedFirstImage && !postedFirstImageNode) {
/* set first image */
msg->postedFirstImage = data;
msg->postedFirstImageMimeType = contentType;
postedFirstImageNode = node;
removeImage = false;
}
}
}
@ -1348,7 +1365,7 @@ RsFeedReaderErrorState p3FeedReaderThread::processMsg(const RsFeedReaderFeed &fe
if (!html.saveHTML(msg->postedDescriptionWithoutFirstImage)) {
errorString = html.lastError();
#ifdef FEEDREADER_DEBUG
std::cerr << "p3FeedReaderThread::processHTML - feed " << feed.feedId << " (" << feed.name << ") cannot dump html" << std::endl;
std::cerr << "p3FeedReaderThread::processMsg - feed " << feed.feedId << " (" << feed.name << ") cannot dump html" << std::endl;
std::cerr << " Error: " << errorString << std::endl;
#endif
result = RS_FEED_ERRORSTATE_PROCESS_INTERNAL_ERROR;
@ -1357,7 +1374,7 @@ RsFeedReaderErrorState p3FeedReaderThread::processMsg(const RsFeedReaderFeed &fe
} else {
errorString = html.lastError();
#ifdef FEEDREADER_DEBUG
std::cerr << "p3FeedReaderThread::processHTML - feed " << feed.feedId << " (" << feed.name << ") cannot dump html" << std::endl;
std::cerr << "p3FeedReaderThread::processMsg - feed " << feed.feedId << " (" << feed.name << ") cannot dump html" << std::endl;
std::cerr << " Error: " << errorString << std::endl;
#endif
result = RS_FEED_ERRORSTATE_PROCESS_INTERNAL_ERROR;
@ -1366,14 +1383,14 @@ RsFeedReaderErrorState p3FeedReaderThread::processMsg(const RsFeedReaderFeed &fe
}
} else {
#ifdef FEEDREADER_DEBUG
std::cerr << "p3FeedReaderThread::processHTML - feed " << feed.feedId << " (" << feed.name << ") no root element" << std::endl;
std::cerr << "p3FeedReaderThread::processMsg - feed " << feed.feedId << " (" << feed.name << ") no root element" << std::endl;
#endif
result = RS_FEED_ERRORSTATE_PROCESS_HTML_ERROR;
}
} else {
errorString = html.lastError();
#ifdef FEEDREADER_DEBUG
std::cerr << "p3FeedReaderThread::processHTML - feed " << feed.feedId << " (" << feed.name << ") cannot read html" << std::endl;
std::cerr << "p3FeedReaderThread::processMsg - feed " << feed.feedId << " (" << feed.name << ") cannot read html" << std::endl;
std::cerr << " Error: " << errorString << std::endl;
#endif
result = RS_FEED_ERRORSTATE_PROCESS_HTML_ERROR;

View File

@ -284,6 +284,54 @@ std::ostream &RsFeedReaderMsg::print(std::ostream &out, uint16_t /*indent*/)
return out;
}
void RsFeedReaderSerialiser::correctMsgSize(RsFeedReaderMsg *item)
{
if (!item) return;
uint32_t s = 8; /* header */
s += 2; /* version */
s += GetTlvStringSize(item->msgId);
s += sizeof(uint32_t);
s += GetTlvStringSize(item->title);
s += GetTlvStringSize(item->link);
s += GetTlvStringSize(item->author);
s += GetTlvStringSize(item->description);
s += GetTlvStringSize(item->descriptionTransformed);
s += sizeof(uint32_t); /* pubDate */
s += sizeof(uint32_t); /* flag */
s += GetTlvStringSize(item->attachmentLink);
s += GetTlvStringSize(item->attachment);
s += GetTlvStringSize(item->attachmentMimeType);
uint32_t sizeLimit = RsSerialiser::MAX_SERIAL_SIZE - 2000;
if (s > sizeLimit) {
uint32_t baseSize = s - GetTlvStringSize(item->description) - GetTlvStringSize(item->descriptionTransformed);
if (baseSize < sizeLimit) {
uint32_t allowedTextSize = sizeLimit - baseSize;
std::string warning = "<p style='color: #d9534f; font-weight: bold; font-size: 1.1em;'>[Warning: This message has been truncated by RetroShare because its size exceeded the 256 KB safety limit.]</p><br/>";
uint32_t neededSpace = warning.size() + 100;
if (item->descriptionTransformed.empty()) {
if (item->description.size() > allowedTextSize) {
if (allowedTextSize > neededSpace) {
item->description = warning + item->description.substr(0, allowedTextSize - neededSpace) + "... [TRUNCATED]";
} else {
item->description = item->description.substr(0, allowedTextSize - 100) + "... [TRUNCATED]";
}
}
} else {
item->description.clear();
if (item->descriptionTransformed.size() > allowedTextSize) {
if (allowedTextSize > neededSpace) {
item->descriptionTransformed = warning + item->descriptionTransformed.substr(0, allowedTextSize - neededSpace) + "... [TRUNCATED]";
} else {
item->descriptionTransformed = item->descriptionTransformed.substr(0, allowedTextSize - 100) + "... [TRUNCATED]";
}
}
}
}
}
}
uint32_t RsFeedReaderSerialiser::sizeMsg(RsFeedReaderMsg *item)
{
uint32_t s = 8; /* header */
@ -362,7 +410,9 @@ RsFeedReaderMsg *RsFeedReaderSerialiser::deserialiseMsg(void *data, uint32_t *pk
}
if (*pktsize < rssize) /* check size */
{
return NULL; /* not enough data */
}
/* set the packet length */
*pktsize = rssize;

View File

@ -146,6 +146,8 @@ public:
virtual bool serialise(RsItem *item, void *data, uint32_t *size);
virtual RsItem *deserialise(void *data, uint32_t *size);
static void correctMsgSize(RsFeedReaderMsg *item);
private:
/* For RS_PKT_SUBTYPE_FEEDREADER_FEED */
virtual uint32_t sizeFeed(RsFeedReaderFeed *item);

View File

@ -32,7 +32,7 @@ bool HTMLWrapper::readHTML(const char *html, const char *url)
cleanup();
handleError(true, mLastErrorString);
mDocument = htmlReadMemory(html, strlen(html), url, "", /*HTML_PARSE_NOERROR | HTML_PARSE_NOWARNING | */HTML_PARSE_COMPACT | HTML_PARSE_NONET | HTML_PARSE_NOBLANKS);
mDocument = htmlReadMemory(html, strlen(html), url, "UTF-8", /*HTML_PARSE_NOERROR | HTML_PARSE_NOWARNING | */HTML_PARSE_COMPACT | HTML_PARSE_NONET | HTML_PARSE_NOBLANKS);
handleError(false, mLastErrorString);
if (mDocument) {

View File

@ -124,42 +124,24 @@ void XMLWrapper::attach(xmlDocPtr document)
bool XMLWrapper::convertToString(const xmlChar *xmlText, std::string &text)
{
bool result = false;
xmlBufferPtr in = xmlBufferCreateStatic((void*) xmlText, xmlStrlen(xmlText));
xmlBufferPtr out = xmlBufferCreate();
int ret = xmlCharEncOutFunc(mCharEncodingHandler, out, in);
if (ret >= 0) {
result = true;
text = (char*) xmlBufferContent(out);
if (!xmlText) {
text.clear();
return false;
}
xmlBufferFree(in);
xmlBufferFree(out);
return result;
text = (const char*) xmlText;
return true;
}
bool XMLWrapper::convertFromString(const char *text, xmlChar *&xmlText)
{
bool result = false;
xmlBufferPtr in = xmlBufferCreateStatic((void*) text, strlen(text));
xmlBufferPtr out = xmlBufferCreate();
int ret = xmlCharEncInFunc(mCharEncodingHandler, out, in);
if (ret >= 0) {
result = true;
#if LIBXML_VERSION >= 20800
xmlText = xmlBufferDetach(out);
#else
xmlText = xmlStrdup(xmlBufferContent(out));
#endif
if (!text) {
xmlText = NULL;
return false;
}
xmlBufferFree(in);
xmlBufferFree(out);
return result;
xmlText = xmlStrdup(BAD_CAST text);
return xmlText != NULL;
}
xmlDocPtr XMLWrapper::getDocument() const
@ -345,15 +327,7 @@ bool XMLWrapper::getChildText(xmlNodePtr node, const char *childName, std::strin
return nodeDump(div, text, true);
}
if (child->children->type != XML_TEXT_NODE) {
return false;
}
if (child->children->content) {
return convertToString(child->children->content, text);
}
return true;
return getContent(child, text, false);
}
std::string XMLWrapper::getAttr(xmlNodePtr node, xmlAttrPtr attr)

146
plugins/VOIP/CMakeLists.txt Normal file
View File

@ -0,0 +1,146 @@
# plugins/VOIP/CMakeLists.txt
cmake_minimum_required(VERSION 3.18)
project(VOIPPlugin)
# --- Dependencies ---
find_package(Qt5 COMPONENTS Core Widgets Multimedia Xml Network REQUIRED)
find_package(PkgConfig REQUIRED)
pkg_check_modules(AVCODEC REQUIRED libavcodec)
pkg_check_modules(AVUTIL REQUIRED libavutil)
pkg_check_modules(SPEEX REQUIRED speex)
pkg_check_modules(SPEEXDSP REQUIRED speexdsp)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_AUTOUIC ON)
# --- Definitions ---
# --- Sources ---
set(VOIP_SOURCES
VOIPPlugin.cpp
gui/VOIPConfigPanel.cpp
services/p3VOIP.cc
services/rsVOIPItems.cc
gui/AudioStats.cpp
gui/AudioWizard.cpp
gui/SpeexProcessor.cpp
gui/audiodevicehelper.cpp
gui/VideoProcessor.cpp
gui/QVideoDevice.cpp
gui/VOIPChatWidgetHolder.cpp
gui/VOIPGUIHandler.cpp
gui/VOIPNotify.cpp
gui/VOIPToasterItem.cpp
gui/VOIPToasterNotify.cpp
)
set(VOIP_FORMS
gui/AudioStats.ui
gui/AudioWizard.ui
gui/VOIPConfigPanel.ui
gui/VOIPToasterItem.ui
)
set(VOIP_RESOURCES
gui/VOIP_images.qrc
lang/VOIP_lang.qrc
qss/VOIP_qss.qrc
)
# --- Translations (.ts -> .qm) ---
file(GLOB TS_FILES "lang/*.ts")
if(Qt5LinguistTools_FOUND)
qt5_add_translation(QM_FILES ${TS_FILES})
else()
find_program(LRELEASE_EXECUTABLE NAMES lrelease-qt5 lrelease)
foreach(ts_file ${TS_FILES})
get_filename_component(ts_name ${ts_file} NAME_WE)
set(qm_src_file "${CMAKE_CURRENT_SOURCE_DIR}/lang/${ts_name}.qm")
set(qm_bin_file "${CMAKE_CURRENT_BINARY_DIR}/${ts_name}.qm")
if(EXISTS ${qm_src_file})
list(APPEND QM_FILES ${qm_src_file})
elseif(LRELEASE_EXECUTABLE)
add_custom_command(
OUTPUT ${qm_bin_file}
COMMAND ${LRELEASE_EXECUTABLE} ${ts_file} -qm ${qm_bin_file}
DEPENDS ${ts_file}
VERBATIM
)
list(APPEND QM_FILES ${qm_bin_file})
endif()
endforeach()
endif()
# --- Target ---
add_library(VOIP MODULE
${VOIP_SOURCES}
${VOIP_FORMS}
${VOIP_RESOURCES}
${QM_FILES}
)
set_target_properties(VOIP PROPERTIES
PREFIX "lib"
LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/plugins"
RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/plugins"
AUTOUIC_SEARCH_PATHS "${CMAKE_CURRENT_SOURCE_DIR}/gui"
)
# FFmpeg/libav headers (libavcodec/libavutil, included by gui/VideoProcessor.*)
# use the C99 fixed-width constant macros (INT64_C, UINT64_C, ...). In a C++
# translation unit these are only exposed by <stdint.h> when
# __STDC_CONSTANT_MACROS is defined before it is included, so it must be defined
# for the whole target to compile the libav headers.
target_compile_definitions(VOIP PRIVATE __STDC_CONSTANT_MACROS)
if(WIN32)
target_compile_definitions(VOIP PRIVATE WINDOWS_SYS)
endif()
# --- Links ---
if(WIN32)
# See FeedReader/CMakeLists.txt: on Windows a plugin DLL must resolve every
# symbol at link time; on Linux they are resolved from the host process.
target_link_libraries(VOIP PRIVATE retroshare retroshare-gui)
endif()
# NOTE: VOIP makes no direct use of OpenSSL (it relies on libretroshare for any
# cryptography), so it does not find_package/link OpenSSL itself.
target_link_libraries(VOIP PRIVATE
Qt5::Core
Qt5::Widgets
Qt5::Multimedia
Qt5::Xml
Qt5::Network
${AVCODEC_LIBRARIES}
${AVUTIL_LIBRARIES}
${SPEEX_LIBRARIES}
${SPEEXDSP_LIBRARIES}
)
target_compile_options(VOIP PRIVATE "-Wno-deprecated-declarations")
target_compile_definitions(VOIP PRIVATE RS_NO_WARN_DEPRECATED)
if(RS_DEVELOPMENT_BUILD)
target_compile_options(VOIP PRIVATE "-g" "-O0")
endif()
# --- Includes ---
target_include_directories(VOIP PRIVATE
${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/gui
${CMAKE_CURRENT_SOURCE_DIR}/services
${CMAKE_CURRENT_SOURCE_DIR}/interface
${CMAKE_SOURCE_DIR}/libretroshare/src
${CMAKE_SOURCE_DIR}/retroshare-gui/src
${CMAKE_SOURCE_DIR}/retroshare-gui/src/gui
${CMAKE_SOURCE_DIR}/supportlibs/rapidjson/include
${AVCODEC_INCLUDE_DIRS}
${AVUTIL_INCLUDE_DIRS}
${SPEEX_INCLUDE_DIRS}
${SPEEXDSP_INCLUDE_DIRS}
)
# --- Installation ---
install(TARGETS VOIP DESTINATION lib/retroshare/plugins)

View File

@ -40,11 +40,6 @@ target.files = lib/libVOIP.so
DEPENDPATH += $$PWD/../../retroshare-gui/src/temp/ui
INCLUDEPATH += $$PWD/../../retroshare-gui/src/temp/ui
# when rapidjson is mainstream on all distribs, we will not need the sources anymore
# in the meantime, they are part of the RS directory so that it is always possible to find them
INCLUDEPATH += ../../rapidjson-1.1.0
#################################### Linux #####################################

View File

@ -56,13 +56,13 @@ extern "C" {
return new VOIPPlugin() ;
}
// This symbol contains the svn revision number grabbed from the executable.
// This symbol contains the svn revision number grabbed from the executable.
// It will be tested by RS to load the plugin automatically, since it is safe to load plugins
// with same revision numbers, assuming that the revision numbers are up-to-date.
//
uint32_t RETROSHARE_PLUGIN_revision = 0;
// This symbol contains the svn revision number grabbed from the executable.
// This symbol contains the svn revision number grabbed from the executable.
// It will be tested by RS to load the plugin automatically, since it is safe to load plugins
// with same revision numbers, assuming that the revision numbers are up-to-date.
//
@ -99,7 +99,9 @@ VOIPPlugin::VOIPPlugin()
Q_INIT_RESOURCE(VOIP_images);
Q_INIT_RESOURCE(VOIP_qss);
#if LIBAVCODEC_VERSION_MAJOR < 58
avcodec_register_all();
#endif
}
void VOIPPlugin::setInterfaces(RsPlugInInterfaces &interfaces)
@ -118,7 +120,7 @@ ConfigPage *VOIPPlugin::qt_config_page() const
QDialog *VOIPPlugin::qt_about_page() const
{
static QMessageBox *about_dialog = NULL ;
if(about_dialog == NULL)
{
about_dialog = new QMessageBox() ;

View File

@ -37,6 +37,7 @@ QVideoInputDevice::QVideoInputDevice(QWidget *parent)
_capture_device = NULL ;
_video_processor = NULL ;
_echo_output_device = NULL ;
_image_capture = NULL;
}
QVideoInputDevice::~QVideoInputDevice()
@ -231,6 +232,6 @@ void QVideoOutputDevice::showFrame(const QImage& img)
#ifdef DEBUG_QVIDEODEVICE
std::cerr << "img.size = " << img.width() << " x " << img.height() << std::endl;
#endif
setPixmap(QPixmap::fromImage(img).scaled( QSize(height()*4/3,height()),Qt::IgnoreAspectRatio,Qt::SmoothTransformation)) ;
setPixmap(QPixmap::fromImage(img).scaled( QSize(height()*4/3,height()),Qt::KeepAspectRatio,Qt::SmoothTransformation)) ;
}

View File

@ -947,9 +947,9 @@ void VOIPChatWidgetHolder::sendAudioData()
}
}
void VOIPChatWidgetHolder::updateStatus(int status)
void VOIPChatWidgetHolder::updateStatus(RsStatusValue status)
{
bool enabled = (status != RS_STATUS_OFFLINE);
bool enabled = (status != RsStatusValue::RS_STATUS_OFFLINE);
audioListenToggleButton->setEnabled(audioCaptureToggleButton->isChecked() && enabled);
audioListenToggleButtonFS->setEnabled(audioCaptureToggleButton->isChecked() && enabled);

View File

@ -52,7 +52,7 @@ public:
VOIPChatWidgetHolder(ChatWidget *chatWidget, VOIPNotify *notify);
virtual ~VOIPChatWidgetHolder();
virtual void updateStatus(int status);
virtual void updateStatus(RsStatusValue status);
void addAudioData(const RsPeerId &peer_id, QByteArray* array) ;
void addVideoData(const RsPeerId &peer_id, QByteArray* array) ;

View File

@ -33,7 +33,7 @@ void VOIPGUIHandler::ReceivedInvitation(const RsPeerId &peer_id, int flags)
#ifdef VOIPGUIHANDLER_DEBUG
std::cerr << "****** VOIPGUIHandler: received Invitation from peer " << peer_id.toStdString() << " with flags==" << flags << std::endl;
#endif
ChatDialog *di = ChatDialog::getChat(ChatId(peer_id), Settings->getChatFlags());
ChatDialog *di = ChatDialog::getChat(ChatId(peer_id), (RsChatFlags) Settings->getChatFlags());
if (di) {
ChatWidget *cw = di->getChatWidget();
if(cw) {
@ -113,7 +113,7 @@ void VOIPGUIHandler::ReceivedVoipData(const RsPeerId &peer_id)
return ;
}
ChatDialog *di = ChatDialog::getChat(ChatId(peer_id), Settings->getChatFlags());
ChatDialog *di = ChatDialog::getChat(ChatId(peer_id), (RsChatFlags) Settings->getChatFlags());
if (di) {
ChatWidget *cw = di->getChatWidget();
if (cw) {

View File

@ -27,7 +27,7 @@
/*Retroshare-Gui*/
#include "gui/chat/ChatDialog.h"
#include "gui/notifyqt.h"
#include "gui/RsGUIEventManager.h"
#include "util/HandleRichText.h"
VOIPToasterItem::VOIPToasterItem(const RsPeerId &peer_id, const QString &msg, const voipToasterItem_Type type)

View File

@ -131,7 +131,7 @@ void av_frame_free(AVFrame **frame)
#endif // MINGW
VideoProcessor::VideoProcessor()
:_encoded_frame_size(640,480) , vpMtx("VideoProcessor")
: _encoded_out_queue(8), _encoded_frame_size(640,480)
{
//_lastTimeToShowFrame = time(NULL);
_decoded_output_device = NULL ;
@ -154,12 +154,10 @@ VideoProcessor::~VideoProcessor()
{
// clear encoding queue
RS_STACK_MUTEX(vpMtx) ;
while(!_encoded_out_queue.empty())
{
_encoded_out_queue.back().clear() ;
_encoded_out_queue.pop_back() ;
_encoded_out_queue.tail().clear();
_encoded_out_queue.pop() ;
}
}
@ -181,21 +179,12 @@ bool VideoProcessor::processImage(const QImage& img)
if(codec)
{
RsVOIPDataChunk chunk ;
if(codec->encodeData(img.scaled(_encoded_frame_size,Qt::IgnoreAspectRatio,Qt::SmoothTransformation),_target_bandwidth_out,chunk) && chunk.size > 0)
{
RS_STACK_MUTEX(vpMtx) ;
_encoded_out_queue.push_back(chunk) ;
_total_encoded_size_out += chunk.size ;
}
codec->encodeData(img.scaled(_encoded_frame_size,Qt::IgnoreAspectRatio,Qt::SmoothTransformation),_target_bandwidth_out, _encoded_out_queue);
time_t now = time(NULL) ;
if(now > _last_bw_estimate_out_TS)
{
RS_STACK_MUTEX(vpMtx) ;
_estimated_bandwidth_out = uint32_t(0.75*_estimated_bandwidth_out + 0.25 * (_total_encoded_size_out / (float)(now - _last_bw_estimate_out_TS))) ;
_total_encoded_size_out = 0 ;
@ -217,14 +206,8 @@ bool VideoProcessor::processImage(const QImage& img)
bool VideoProcessor::nextEncodedPacket(RsVOIPDataChunk& chunk)
{
RS_STACK_MUTEX(vpMtx) ;
if(_encoded_out_queue.empty())
return false ;
chunk = _encoded_out_queue.front() ;
_encoded_out_queue.pop_front() ;
return true ;
return _encoded_out_queue.pop(chunk)
&& ((_total_encoded_size_out += chunk.size), true);
}
void VideoProcessor::setInternalFrameSize(QSize s)
@ -275,7 +258,6 @@ void VideoProcessor::receiveEncodedData(const RsVOIPDataChunk& chunk)
}
{
RS_STACK_MUTEX(vpMtx) ;
_total_encoded_size_in += chunk.size ;
time_t now = time(NULL) ;
@ -368,10 +350,13 @@ bool JPEGVideo::decodeData(const RsVOIPDataChunk& chunk,QImage& image)
return true ;
}
bool JPEGVideo::encodeData(const QImage& image,uint32_t /* size_hint */,RsVOIPDataChunk& voip_chunk)
bool JPEGVideo::encodeData(const QImage& image,uint32_t /* size_hint */, NetQueue<RsVOIPDataChunk>& dst)
{
// check if we make a diff image, or if we use the full frame.
if(dst.full()) return false;
RsVOIPDataChunk& voip_chunk = dst.head();
QImage encoded_frame ;
bool differential_frame ;
@ -409,7 +394,7 @@ bool JPEGVideo::encodeData(const QImage& image,uint32_t /* size_hint */,RsVOIPDa
encoded_frame.save(&buffer,"JPEG") ;
voip_chunk.data = rs_malloc(HEADER_SIZE + qb.size());
if(!voip_chunk.data)
return false ;
@ -426,12 +411,16 @@ bool JPEGVideo::encodeData(const QImage& image,uint32_t /* size_hint */,RsVOIPDa
voip_chunk.size = HEADER_SIZE + qb.size() ;
voip_chunk.type = RsVOIPDataChunk::RS_VOIP_DATA_TYPE_VIDEO ;
dst.push();
return true ;
}
FFmpegVideo::FFmpegVideo()
{
#if LIBAVCODEC_VERSION_MAJOR < 58
avcodec_register_all();
#endif
// Encoding
encoding_codec = NULL ;
@ -473,8 +462,10 @@ FFmpegVideo::FFmpegVideo()
encoding_context->rc_max_rate = 0;
encoding_context->rc_buffer_size = 0;
#endif
#if LIBAVCODEC_VERSION_MAJOR < 58
if (encoding_codec->capabilities & AV_CODEC_CAP_TRUNCATED)
encoding_context->flags |= AV_CODEC_FLAG_TRUNCATED;
#endif
encoding_context->flags |= AV_CODEC_FLAG_PSNR;//Peak signal-to-noise ratio
encoding_context->flags |= AV_CODEC_CAP_PARAM_CHANGE;
encoding_context->i_quant_factor = 0.769f;
@ -507,11 +498,12 @@ FFmpegVideo::FFmpegVideo()
//encoding_context->max_b_frames = 1;
#if LIBAVCODEC_VERSION_MAJOR < 54
encoding_context->pix_fmt = PIX_FMT_YUV420P; //context->pix_fmt = PIX_FMT_RGB24;
if (codec_id == CODEC_ID_H264) {
if (codec_id == CODEC_ID_H264)
#else
encoding_context->pix_fmt = AV_PIX_FMT_YUV420P; //context->pix_fmt = AV_PIX_FMT_RGB24;
if (codec_id == AV_CODEC_ID_H264) {
if (codec_id == AV_CODEC_ID_H264)
#endif
{
av_opt_set(encoding_context->priv_data, "preset", "slow", 0);
}
@ -569,8 +561,10 @@ FFmpegVideo::FFmpegVideo()
decoding_context->pix_fmt = AV_PIX_FMT_YUV420P;
#endif
#if LIBAVCODEC_VERSION_MAJOR < 58
if(decoding_codec->capabilities & AV_CODEC_CAP_TRUNCATED)
decoding_context->flags |= AV_CODEC_FLAG_TRUNCATED; // we do not send complete frames
#endif
//we can receive truncated frames
decoding_context->flags2 |= AV_CODEC_FLAG2_CHUNKS;
@ -610,12 +604,81 @@ FFmpegVideo::~FFmpegVideo()
#define MAX_FFMPEG_ENCODING_BITRATE 81920
bool FFmpegVideo::encodeData(const QImage& image, uint32_t target_encoding_bitrate, RsVOIPDataChunk& voip_chunk)
static void imageToFrame(AVFrame *frame, const QImage& image) {
QImage input;
if(image.width() == frame->width && image.height() == frame->height)
input = image;
else
input = image.scaled(QSize(frame->width, frame->height),
Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
for (int y = 0; y < frame->height - 1; y += 2)
for (int x = 0; x < frame->width - 1; x += 2) {
QRgb pix00 = input.pixel(QPoint(x+0,y+0));
QRgb pix10 = input.pixel(QPoint(x+1,y+0));
QRgb pix01 = input.pixel(QPoint(x+0,y+1));
QRgb pix11 = input.pixel(QPoint(x+1,y+1));
int R00 = pix00>>16 & 0xff, G00 = pix00>>8 & 0xff, B00 = pix00>>0 & 0xff;
int R10 = pix10>>16 & 0xff, G10 = pix10>>8 & 0xff, B10 = pix10>>0 & 0xff;
int R01 = pix01>>16 & 0xff, G01 = pix01>>8 & 0xff, B01 = pix01>>0 & 0xff;
int R11 = pix11>>16 & 0xff, G11 = pix11>>8 & 0xff, B11 = pix11>>0 & 0xff;
float R = 0.25*(R00+R01+R10+R11);
float G = 0.25*(G00+G01+G10+G11);
float B = 0.25*(B00+B01+B10+B11);
int Y00 = (0.257 * R00) + (0.504 * G00) + (0.098 * B00) + 16.5;
int Y01 = (0.257 * R01) + (0.504 * G01) + (0.098 * B01) + 16.5;
int Y10 = (0.257 * R10) + (0.504 * G10) + (0.098 * B10) + 16.5;
int Y11 = (0.257 * R11) + (0.504 * G11) + (0.098 * B11) + 16.5;
int U = (0.439 * R) - (0.368 * G) - (0.071 * B) + 128.5 ;
int V = -(0.148 * R) - (0.291 * G) + (0.439 * B) + 128.5 ;
frame->data[0][(y+0) * frame->linesize[0] + x+0] = Y00; // Y
frame->data[0][(y+0) * frame->linesize[0] + x+1] = Y01; // Y
frame->data[0][(y+1) * frame->linesize[0] + x+0] = Y10; // Y
frame->data[0][(y+1) * frame->linesize[0] + x+1] = Y11; // Y
frame->data[1][y/2 * frame->linesize[1] + x/2] = U; // Cr
frame->data[2][y/2 * frame->linesize[2] + x/2] = V; // Cb
}
}
static void frameToImage(QImage& image, const AVFrame *frame) {
image = QImage(QSize(frame->width,frame->height),QImage::Format_ARGB32);
#ifdef DEBUG_MPEG_VIDEO
std::cerr << "Decoded frame. Size=" << image.width() << "x" << image.height() << std::endl;
#endif
for (int y = 0; y < frame->height; y++)
for (int x = 0; x < frame->width; x++) {
int Y = frame->data[0][y * frame->linesize[0] + x];
int U = frame->data[1][(y/2) * frame->linesize[1] + x/2];
int V = frame->data[2][(y/2) * frame->linesize[2] + x/2];
int B = (int)(1.164*Y + 1.596*V - 222.421);
int G = (int)(1.164*Y - 0.391*U - 0.813*V + 136.076);
int R = (int)(1.164*Y + 2.018*U - 277.336);
B = std::max(0,std::min(255,B));
G = std::max(0,std::min(255,G));
R = std::max(0,std::min(255,R));
image.setPixel(QPoint(x,y), QRgb(0xff000000 | (R << 16) | (G << 8) | B));
}
}
bool FFmpegVideo::encodeData(const QImage& image, uint32_t target_encoding_bitrate, NetQueue<RsVOIPDataChunk>& dst)
{
#if LIBAVCODEC_VERSION_MAJOR < 58
if(dst.full()) return false;
#endif
#ifdef DEBUG_MPEG_VIDEO
std::cerr << "Encoding frame of size " << image.width() << "x" << image.height() << ", resized to " << encoding_frame_buffer->width << "x" << encoding_frame_buffer->height << " : ";
#endif
QImage input ;
if(target_encoding_bitrate > MAX_FFMPEG_ENCODING_BITRATE)
{
@ -626,54 +689,12 @@ bool FFmpegVideo::encodeData(const QImage& image, uint32_t target_encoding_bitra
encoding_context->rc_max_rate = target_encoding_bitrate;
//encoding_context->bit_rate_tolerance = target_encoding_bitrate;
if(image.width() != encoding_frame_buffer->width || image.height() != encoding_frame_buffer->height)
input = image.scaled(QSize(encoding_frame_buffer->width,encoding_frame_buffer->height),Qt::IgnoreAspectRatio,Qt::SmoothTransformation) ;
else
input = image ;
/* prepare a dummy image */
/* Y */
for (int y = 0; y < encoding_context->height/2; y++)
for (int x = 0; x < encoding_context->width/2; x++)
{
QRgb pix00 = input.pixel(QPoint(2*x+0,2*y+0)) ;
QRgb pix01 = input.pixel(QPoint(2*x+0,2*y+1)) ;
QRgb pix10 = input.pixel(QPoint(2*x+1,2*y+0)) ;
QRgb pix11 = input.pixel(QPoint(2*x+1,2*y+1)) ;
int R00 = (pix00 >> 16) & 0xff ; int G00 = (pix00 >> 8) & 0xff ; int B00 = (pix00 >> 0) & 0xff ;
int R01 = (pix01 >> 16) & 0xff ; int G01 = (pix01 >> 8) & 0xff ; int B01 = (pix01 >> 0) & 0xff ;
int R10 = (pix10 >> 16) & 0xff ; int G10 = (pix10 >> 8) & 0xff ; int B10 = (pix10 >> 0) & 0xff ;
int R11 = (pix11 >> 16) & 0xff ; int G11 = (pix11 >> 8) & 0xff ; int B11 = (pix11 >> 0) & 0xff ;
int Y00 = (0.257 * R00) + (0.504 * G00) + (0.098 * B00) + 16 ;
int Y01 = (0.257 * R01) + (0.504 * G01) + (0.098 * B01) + 16 ;
int Y10 = (0.257 * R10) + (0.504 * G10) + (0.098 * B10) + 16 ;
int Y11 = (0.257 * R11) + (0.504 * G11) + (0.098 * B11) + 16 ;
float R = 0.25*(R00+R01+R10+R11) ;
float G = 0.25*(G00+G01+G10+G11) ;
float B = 0.25*(B00+B01+B10+B11) ;
int U = (0.439 * R) - (0.368 * G) - (0.071 * B) + 128 ;
int V = -(0.148 * R) - (0.291 * G) + (0.439 * B) + 128 ;
encoding_frame_buffer->data[0][(2*y+0) * encoding_frame_buffer->linesize[0] + 2*x+0] = std::min(255,std::max(0,Y00)); // Y
encoding_frame_buffer->data[0][(2*y+0) * encoding_frame_buffer->linesize[0] + 2*x+1] = std::min(255,std::max(0,Y01)); // Y
encoding_frame_buffer->data[0][(2*y+1) * encoding_frame_buffer->linesize[0] + 2*x+0] = std::min(255,std::max(0,Y10)); // Y
encoding_frame_buffer->data[0][(2*y+1) * encoding_frame_buffer->linesize[0] + 2*x+1] = std::min(255,std::max(0,Y11)); // Y
encoding_frame_buffer->data[1][y * encoding_frame_buffer->linesize[1] + x] = std::min(255,std::max(0,U));// Cr
encoding_frame_buffer->data[2][y * encoding_frame_buffer->linesize[2] + x] = std::min(255,std::max(0,V));// Cb
}
imageToFrame(encoding_frame_buffer, image);
encoding_frame_buffer->pts = encoding_frame_count++;
/* encode the image */
int got_output = 0;
AVPacket pkt ;
av_init_packet(&pkt);
#if LIBAVCODEC_VERSION_MAJOR < 54
@ -682,35 +703,53 @@ bool FFmpegVideo::encodeData(const QImage& image, uint32_t target_encoding_bitra
// do
// {
int got_output = 0;
int ret = avcodec_encode_video(encoding_context, pkt.data, pkt.size, encoding_frame_buffer) ;
if (ret > 0) {
got_output = ret;
}
#else
#elif LIBAVCODEC_VERSION_MAJOR < 58
pkt.data = NULL; // packet data will be allocated by the encoder
pkt.size = 0;
// do
// {
int got_output = 0;
int ret = avcodec_encode_video2(encoding_context, &pkt, encoding_frame_buffer, &got_output) ;
#else
int ret = avcodec_send_frame(encoding_context, encoding_frame_buffer);
if(ret == AVERROR(EAGAIN))
ret = 0;
#endif
if (ret < 0)
{
std::cerr << "Error encoding frame!" << std::endl;
return false ;
goto fail;
}
// frame = NULL ; // next attempts: do not encode anything. Do this to just flush the buffer
//
// } while(got_output) ;
if(got_output)
#if LIBAVCODEC_VERSION_MAJOR >= 58
while(!dst.full() && !(ret = avcodec_receive_packet(encoding_context, &pkt)))
#else
if(!got_output) {
std::cerr << "No output produced." << std::endl;
}
else
#endif
{
RsVOIPDataChunk& voip_chunk = dst.head();
voip_chunk.data = rs_malloc(pkt.size + HEADER_SIZE) ;
if(!voip_chunk.data)
return false ;
if(!voip_chunk.data) {
std::cerr << "error: failed to allocate RsVOIPDataChunk data"
<< std::endl;
goto fail;
}
uint32_t flags = 0;
((unsigned char *)voip_chunk.data)[0] = VideoProcessor::VIDEO_PROCESSOR_CODEC_ID_MPEG_VIDEO & 0xff ;
@ -723,28 +762,36 @@ bool FFmpegVideo::encodeData(const QImage& image, uint32_t target_encoding_bitra
voip_chunk.size = pkt.size + HEADER_SIZE;
voip_chunk.type = RsVOIPDataChunk::RS_VOIP_DATA_TYPE_VIDEO ;
dst.push();
#ifdef DEBUG_MPEG_VIDEO
std::cerr << "Output : " << pkt.size << " bytes." << std::endl;
fwrite(pkt.data,1,pkt.size,encoding_debug_file) ;
fflush(encoding_debug_file) ;
#endif
av_free_packet(&pkt);
return true ;
}
else
{
voip_chunk.data = NULL;
voip_chunk.size = 0;
voip_chunk.type = RsVOIPDataChunk::RS_VOIP_DATA_TYPE_VIDEO ;
std::cerr << "No output produced." << std::endl;
return false ;
}
#if LIBAVCODEC_VERSION_MAJOR >= 58
if(ret == AVERROR(EAGAIN))
ret = 0;
else if(ret < 0) {
std::cerr << "error: failed to get packet from encoder: " << ret
<< std::endl;
}
#endif
fail:
#if LIBAVCODEC_VERSION_MAJOR < 58
av_free_packet(&pkt);
#else
av_packet_unref(&pkt);
#endif
return ret == 0;
}
bool FFmpegVideo::decodeData(const RsVOIPDataChunk& chunk,QImage& image)
bool FFmpegVideo::decodeData(const RsVOIPDataChunk& chunk, QImage& image)
{
#ifdef DEBUG_MPEG_VIDEO
std::cerr << "Decoding data of size " << chunk.size << std::endl;
@ -752,16 +799,8 @@ bool FFmpegVideo::decodeData(const RsVOIPDataChunk& chunk,QImage& image)
#endif
uint32_t s = chunk.size - HEADER_SIZE ;
#if defined(__MINGW32__)
unsigned char *tmp = (unsigned char*)_aligned_malloc(s + AV_INPUT_BUFFER_PADDING_SIZE, 16) ;
#else
#ifdef __MACH__
//Mac OS X appears to be 16-byte mem aligned.
unsigned char *tmp = (unsigned char*)malloc(s + AV_INPUT_BUFFER_PADDING_SIZE) ;
#else //MAC
unsigned char *tmp = (unsigned char*)memalign(16, s + AV_INPUT_BUFFER_PADDING_SIZE) ;
#endif //MAC
#endif //MINGW
unsigned char *tmp =
(unsigned char *)av_malloc(s + AV_INPUT_BUFFER_PADDING_SIZE);
if (tmp == NULL) {
std::cerr << "FFmpegVideo::decodeData() Unable to allocate new buffer of size " << s << std::endl;
return false;
@ -772,13 +811,52 @@ bool FFmpegVideo::decodeData(const RsVOIPDataChunk& chunk,QImage& image)
/* set end of buffer to 0 (this ensures that no overreading happens for damaged mpeg streams) */
memset(&tmp[s], 0, AV_INPUT_BUFFER_PADDING_SIZE) ;
decoding_buffer.size = s ;
decoding_buffer.data = tmp;
int got_frame = 1 ;
av_packet_from_data(&decoding_buffer, tmp, s);
#if LIBAVCODEC_VERSION_MAJOR >= 58
int ret = avcodec_send_packet(decoding_context, &decoding_buffer);
av_packet_unref(&decoding_buffer);
if(ret) {
// EAGAIN is an error here because the decoder's buffer should be empty
std::cerr << "error: failed to send packet to decoder: " << ret
<< std::endl;
}
ret = avcodec_receive_frame(decoding_context, decoding_frame_buffer);
if(ret == AVERROR(EAGAIN)) {
std::cerr << "warning: "
<< "decoder consumed a packet but didn't generate a frame" << std::endl;
return false;
}
else if(ret) {
std::cerr << "error: failed to fetch frame from decoder: " << ret
<< std::endl;
return false ;
}
frameToImage(image, decoding_frame_buffer);
#ifdef DEBUG_MPEG_VIDEO
std::cerr << "debug(MPEG_VIDEO): decoded frame: size="
<< image.width() << "x" << image.height() << std::endl;
#endif
// Clear out the internal buffer and drop the frames to avoid latency.
// Video decoders typically only create one frame per packet, so this
// shouldn't happen under normal circumstances.
// Ideally, we would render the most recent frame and discard earlier ones,
// but that would require copying of frames that is not worth it.
while(!avcodec_receive_frame(decoding_context, decoding_frame_buffer)) {
std::cerr << "warning: dropping decoded frame";
}
#else
int got_frame = 1 ;
while (decoding_buffer.size > 0 || (!decoding_buffer.data && got_frame)) {
int len = avcodec_decode_video2(decoding_context,decoding_frame_buffer,&got_frame,&decoding_buffer) ;
if (len < 0)
{
std::cerr << "Error decoding frame! Return=" << len << std::endl;
@ -790,31 +868,18 @@ bool FFmpegVideo::decodeData(const RsVOIPDataChunk& chunk,QImage& image)
if(got_frame)
{
image = QImage(QSize(decoding_frame_buffer->width,decoding_frame_buffer->height),QImage::Format_ARGB32) ;
frameToImage(image, decoding_frame_buffer);
#ifdef DEBUG_MPEG_VIDEO
std::cerr << "Decoded frame. Size=" << image.width() << "x" << image.height() << std::endl;
#endif
for (int y = 0; y < decoding_frame_buffer->height; y++)
for (int x = 0; x < decoding_frame_buffer->width; x++)
{
int Y = decoding_frame_buffer->data[0][y * decoding_frame_buffer->linesize[0] + x] ;
int U = decoding_frame_buffer->data[1][(y/2) * decoding_frame_buffer->linesize[1] + x/2] ;
int V = decoding_frame_buffer->data[2][(y/2) * decoding_frame_buffer->linesize[2] + x/2] ;
int B = std::min(255,std::max(0,(int)(1.164*(Y - 16) + 1.596*(V - 128)))) ;
int G = std::min(255,std::max(0,(int)(1.164*(Y - 16) - 0.813*(V - 128) - 0.391*(U - 128)))) ;
int R = std::min(255,std::max(0,(int)(1.164*(Y - 16) + 2.018*(U - 128)))) ;
image.setPixel(QPoint(x,y),QRgb( 0xff000000 + (R << 16) + (G << 8) + B)) ;
}
}
}
/* flush the decoder */
decoding_buffer.data = NULL;
decoding_buffer.size = 0;
//avcodec_decode_video2(decoding_context,decoding_frame_buffer,&got_frame,&decoding_buffer) ;
#endif
return true ;
}

View File

@ -30,12 +30,35 @@ extern "C" {
class QVideoOutputDevice ;
template<typename T>
class NetQueue {
std::vector<T> arr;
const unsigned int mask;
std::atomic<unsigned int> mhead;
std::atomic<unsigned int> mtail;
public:
NetQueue(unsigned int size) : arr(size), mask(size - 1), mhead(0), mtail(0) {
if(size & mask) throw std::invalid_argument("size must be a power of 2");
}
bool full() const { return mhead - mtail == arr.size(); }
T& head() { return arr[mhead & mask]; }
void push() { mhead++; }
bool push(const T& e) { return !full() && ((arr[mhead++ & mask] = e), true); }
bool empty() const { return mhead == mtail; }
T& tail() { return arr[mtail & mask]; }
void pop() { mtail++; }
bool pop(T& e) { return !empty() && ((e = arr[mtail++ & mask]), true); }
};
class VideoCodec
{
public:
virtual bool encodeData(const QImage& Image, uint32_t size_hint, RsVOIPDataChunk& chunk) = 0;
virtual bool encodeData(const QImage& Image, uint32_t size_hint, NetQueue<RsVOIPDataChunk>& dst) = 0;
virtual bool decodeData(const RsVOIPDataChunk& chunk,QImage& image) = 0;
protected:
static const uint32_t HEADER_SIZE = 0x04 ;
};
@ -47,10 +70,10 @@ class JPEGVideo: public VideoCodec
{
public:
JPEGVideo() ;
protected:
virtual bool encodeData(const QImage& Image, uint32_t target_encoding_bitrate, RsVOIPDataChunk& chunk) ;
virtual bool decodeData(const RsVOIPDataChunk& chunk,QImage& image) ;
virtual bool encodeData(const QImage& Image, uint32_t target_encoding_bitrate, NetQueue<RsVOIPDataChunk>& dst) ;
virtual bool decodeData(const RsVOIPDataChunk& chunk, QImage& image) ;
static const uint32_t JPEG_VIDEO_FLAGS_DIFFERENTIAL_FRAME = 0x0001 ;
private:
@ -73,19 +96,19 @@ public:
~FFmpegVideo() ;
protected:
virtual bool encodeData(const QImage& Image, uint32_t target_encoding_bitrate, RsVOIPDataChunk& chunk) ;
virtual bool encodeData(const QImage& Image, uint32_t target_encoding_bitrate, NetQueue<RsVOIPDataChunk>& dst) ;
virtual bool decodeData(const RsVOIPDataChunk& chunk,QImage& image) ;
private:
AVCodec *encoding_codec;
AVCodec *decoding_codec;
const AVCodec *encoding_codec;
const AVCodec *decoding_codec;
AVCodecContext *encoding_context;
AVCodecContext *decoding_context;
AVFrame *encoding_frame_buffer ;
AVFrame *decoding_frame_buffer ;
AVPacket decoding_buffer;
uint64_t encoding_frame_count ;
#ifdef DEBUG_MPEG_VIDEO
FILE *encoding_debug_file ;
#endif
@ -106,11 +129,11 @@ class VideoProcessor
VIDEO_PROCESSOR_CODEC_ID_DDWT_VIDEO = 0x0002,
VIDEO_PROCESSOR_CODEC_ID_MPEG_VIDEO = 0x0003
};
// =====================================================================================
// =------------------------------------ DECODING -------------------------------------=
// =====================================================================================
// Gets the next image to be displayed. Once returned, the image should
// be cleared from the incoming queue.
//
@ -129,9 +152,9 @@ class VideoProcessor
// =====================================================================================
// =------------------------------------ ENCODING -------------------------------------=
// =====================================================================================
public:
// Takes the next image to be encoded.
// Takes the next image to be encoded.
//
bool processImage(const QImage& Image) ;
bool encodedPacketReady() const { return !_encoded_out_queue.empty() ; }
@ -141,35 +164,33 @@ class VideoProcessor
//
void setMaximumBandwidth(uint32_t bytes_per_second) ;
void setInternalFrameSize(QSize) ;
// returns the current encoding frame rate in bytes per second.
//
uint32_t currentBandwidthOut() const { return _estimated_bandwidth_out ; }
protected:
std::list<RsVOIPDataChunk> _encoded_out_queue ;
NetQueue<RsVOIPDataChunk> _encoded_out_queue;
QSize _encoded_frame_size ;
// =====================================================================================
// =------------------------------------- Codecs --------------------------------------=
// =====================================================================================
JPEGVideo _jpeg_video_codec ;
FFmpegVideo _mpeg_video_codec ;
uint16_t _encoding_current_codec ;
time_t _last_bw_estimate_in_TS;
time_t _last_bw_estimate_out_TS;
uint32_t _total_encoded_size_in ;
uint32_t _total_encoded_size_out ;
float _estimated_bandwidth_in ;
float _estimated_bandwidth_out ;
float _target_bandwidth_out ;
RsMutex vpMtx ;
};
float _target_bandwidth_out ;
};

View File

@ -45,9 +45,9 @@ class RsVOIPItem: public RsItem
{
public:
RsVOIPItem(uint8_t voip_subtype) : RsItem(RS_PKT_VERSION_SERVICE,RS_SERVICE_TYPE_VOIP_PLUGIN,voip_subtype)
{
{
setPriorityLevel(QOS_PRIORITY_RS_VOIP) ;
}
}
virtual ~RsVOIPItem() {}
virtual void clear() {}
@ -70,7 +70,7 @@ class RsVOIPDataItem: public RsVOIPItem
public:
RsVOIPDataItem() :RsVOIPItem(RS_PKT_SUBTYPE_VOIP_DATA) {}
virtual ~RsVOIPDataItem()
virtual ~RsVOIPDataItem()
{
free(voip_data) ;
voip_data = NULL ;
@ -78,9 +78,9 @@ class RsVOIPDataItem: public RsVOIPItem
virtual void serial_process(RsGenericSerializer::SerializeJob j,RsGenericSerializer::SerializeContext& ctx);
uint32_t flags ;
uint32_t data_size ;
void *voip_data ;
uint32_t data_size = 0;
void *voip_data = nullptr;
};
#ifdef TODO

Some files were not shown because too many files have changed in this diff Show More